adata-ui 0.1.65 → 0.1.68

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "adata-ui",
3
- "version": "0.1.65",
3
+ "version": "0.1.68",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
package/src/App.vue CHANGED
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <div id="app"><a-header active-tab-key="" login-url="" mode="" is-authenticated /></div>
2
+ <div id="app"><a-header active-tab-key="" login-url="" mode="" is-authenticated request-count="199" days-remaining="18 часов 44 минуты"/></div>
3
3
  </template>
4
4
 
5
5
  <script>
@@ -90,14 +90,17 @@ export default {
90
90
 
91
91
  &.size {
92
92
  &_extra_sm {
93
+ height: 24px;
93
94
  padding: 2px 16px;
94
95
  line-height: 20px;
95
96
  }
96
97
  &_sm {
98
+ height: 32px;
97
99
  padding: 6px 20px;
98
100
  line-height: 20px;
99
101
  }
100
102
  &_md {
103
+ height: 40px;
101
104
  padding: 8px 30px;
102
105
  line-height: 24px;
103
106
  }
@@ -214,6 +214,15 @@
214
214
  </clipPath>
215
215
  </defs>
216
216
  </svg>
217
+ <svg v-if="currency.currency === 'CNY'" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
218
+ <path d="M0 2C0 0.895431 0.895431 0 2 0H14C15.1046 0 16 0.895431 16 2V14C16 15.1046 15.1046 16 14 16H2C0.895431 16 0 15.1046 0 14V2Z" fill="#DE2910"/>
219
+ <path d="M4.00115 1.60043L5.41155 5.94203L1.71875 3.25883H6.28355L2.59075 5.94203L4.00115 1.60043Z" fill="#FFDE00"/>
220
+ <path d="M7.3125 2.01103L8.3117 0.863831L8.1781 2.37983L7.3957 1.07503L8.7957 1.67023L7.3125 2.01103Z" fill="#FFDE00"/>
221
+ <path d="M8.80803 3.31335L10.1744 2.64375L9.46323 3.98855L9.24803 2.48215L10.3072 3.57415L8.80803 3.31335Z" fill="#FFDE00"/>
222
+ <path d="M8.82968 5.38077L10.3497 5.32637L9.15208 6.26477L9.56968 4.80157L10.0913 6.23037L8.82968 5.38077Z" fill="#FFDE00"/>
223
+ <path d="M7.3758 6.6997L8.7998 7.2365L7.3326 7.6397L8.283 6.4509L8.2118 7.9709L7.3758 6.6997Z" fill="#FFDE00"/>
224
+ </svg>
225
+
217
226
  <span>{{ currency.currency }}</span>
218
227
  </div>
219
228
  <div class="menu-mobile__info-column">
@@ -376,10 +385,8 @@ export default {
376
385
  isOpenNotification: false,
377
386
  };
378
387
  },
379
-
380
388
  created() {
381
389
  this.fetchCurrencies();
382
- this.fetchWeather()
383
390
  },
384
391
  mounted() {
385
392
  this.setBalance(this.balance);
@@ -5,7 +5,7 @@
5
5
  <div class="container">
6
6
  <div class="info-notification__wrapper">
7
7
  <div class="info-notification__content">
8
- <svg id="note-svg" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
8
+ <svg class="info-notification__info" id="note-svg" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
9
9
  <circle cx="8" cy="8" r="6" stroke="white"/>
10
10
  <path d="M9.6613 11.1367L9.54952 11.5936C9.21418 11.726 8.94631 11.8267 8.74685 11.896C8.54716 11.9654 8.31514 12 8.05079 12C7.64483 12 7.32906 11.9006 7.10386 11.703C6.87865 11.5047 6.76601 11.2534 6.76601 10.9485C6.76601 10.8305 6.77418 10.7091 6.79117 10.5854C6.80831 10.4616 6.83556 10.3222 6.87284 10.1663L7.29192 8.68297C7.32921 8.54094 7.3609 8.40636 7.38628 8.27909C7.41202 8.15261 7.42442 8.03624 7.42442 7.93149C7.42442 7.74206 7.3852 7.60956 7.30712 7.53507C7.22904 7.46079 7.08005 7.42307 6.85886 7.42307C6.75052 7.42307 6.63917 7.44042 6.52567 7.47398C6.41167 7.50768 6.31423 7.54023 6.23242 7.57049L6.34449 7.11319C6.61902 7.00141 6.88144 6.90569 7.13246 6.82625C7.38348 6.74659 7.62066 6.70672 7.84501 6.70672C8.24818 6.70672 8.55928 6.80416 8.77775 6.99904C8.99622 7.19406 9.10542 7.44688 9.10542 7.75841C9.10542 7.82287 9.09825 7.93644 9.08283 8.09877C9.06777 8.26145 9.03974 8.41051 8.99887 8.5461L8.58158 10.0235C8.54738 10.1421 8.51662 10.2778 8.48988 10.4304C8.46227 10.5821 8.44908 10.6979 8.44908 10.7757C8.44908 10.9718 8.49282 11.1058 8.5805 11.177C8.66884 11.2482 8.82098 11.2836 9.03709 11.2836C9.13854 11.2836 9.25398 11.2656 9.38225 11.2302C9.51016 11.1949 9.60344 11.1638 9.6613 11.1367ZM9.76713 4.93424C9.76713 5.19164 9.67012 5.41147 9.47517 5.59223C9.28072 5.77363 9.04641 5.8644 8.7723 5.8644C8.49733 5.8644 8.26245 5.77363 8.06577 5.59223C7.86946 5.4114 7.77109 5.19164 7.77109 4.93424C7.77109 4.67734 7.86946 4.45716 8.06577 4.27411C8.26209 4.09134 8.4974 4 8.7723 4C9.04634 4 9.28072 4.09156 9.47517 4.27411C9.67026 4.45716 9.76713 4.67742 9.76713 4.93424Z" fill="white"/>
11
11
  </svg>
@@ -108,6 +108,15 @@
108
108
  </clipPath>
109
109
  </defs>
110
110
  </svg>
111
+ <svg v-if="currency.currency === 'CNY'" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
112
+ <path d="M0 2C0 0.895431 0.895431 0 2 0H14C15.1046 0 16 0.895431 16 2V14C16 15.1046 15.1046 16 14 16H2C0.895431 16 0 15.1046 0 14V2Z" fill="#DE2910"/>
113
+ <path d="M4.00115 1.60043L5.41155 5.94203L1.71875 3.25883H6.28355L2.59075 5.94203L4.00115 1.60043Z" fill="#FFDE00"/>
114
+ <path d="M7.3125 2.01103L8.3117 0.863831L8.1781 2.37983L7.3957 1.07503L8.7957 1.67023L7.3125 2.01103Z" fill="#FFDE00"/>
115
+ <path d="M8.80803 3.31335L10.1744 2.64375L9.46323 3.98855L9.24803 2.48215L10.3072 3.57415L8.80803 3.31335Z" fill="#FFDE00"/>
116
+ <path d="M8.82968 5.38077L10.3497 5.32637L9.15208 6.26477L9.56968 4.80157L10.0913 6.23037L8.82968 5.38077Z" fill="#FFDE00"/>
117
+ <path d="M7.3758 6.6997L8.7998 7.2365L7.3326 7.6397L8.283 6.4509L8.2118 7.9709L7.3758 6.6997Z" fill="#FFDE00"/>
118
+ </svg>
119
+
111
120
  <div class="info-header__inner-item">
112
121
  <span class="info-header__result">{{ currency.sell }}</span>
113
122
  <svg v-if="currency.sell_state === 'DOWN'" width="16" height="17" viewBox="0 0 16 17" fill="none" xmlns="http://www.w3.org/2000/svg">
@@ -207,18 +216,22 @@ export default {
207
216
  font-size: 14px;
208
217
  @media(max-width: 1025px) {
209
218
  position: relative;
210
- height: 30px;
219
+ min-height: 30px;
211
220
  }
212
221
  &__wrapper {
213
222
  display: flex;
214
223
  justify-content: space-between;
215
224
  align-items: center;
225
+ gap: 10px;
216
226
  }
217
227
  &__content {
218
228
  display: flex;
219
229
  align-items: center;
220
230
  gap: 10px;
221
231
  }
232
+ &__info {
233
+ flex-shrink: 0;
234
+ }
222
235
  &__close {
223
236
  display: flex;
224
237
  align-items: center;
@@ -17,7 +17,7 @@
17
17
  fill="#2C3E50"></path>
18
18
  </svg>
19
19
  </div>
20
- <a :href="loginUrl" class="sign" v-show="!isAuthenticated">
20
+ <a @click.prevent="goAuth" class="sign" v-show="!isAuthenticated">
21
21
  <svg width="18" height="18" fill="#25476AFF" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" class="desktop">
22
22
  <path fill="#fff" d="M0 0h16v16H0z" stroke="none"></path>
23
23
  <path d="M8 10l2-2.054L8.077 6" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"></path>
@@ -42,11 +42,12 @@
42
42
  <div class="profile-menu__inner">
43
43
  <div class="profile-menu__items" v-if="listDropDown.length">
44
44
  <div v-for="(elem, index) in listDropDown" :key="index">
45
- <div :class="elem.link ? 'profile-menu__balance-link': 'profile-menu__links'"
46
- class="gray-text"
47
- v-if="elem[mode]"
48
- @click="handleClick(elem[mode], elem.name)"
49
- >
45
+ <a :href="elem[mode]" :class="elem.link ? 'profile-menu__balance-link': 'profile-menu__links'"
46
+ class="gray-text"
47
+ v-if="elem[mode]"
48
+ @click="preventLink(elem.disabled, $event)"
49
+ onclick="`return false`"
50
+ >
50
51
  <div>
51
52
  {{ elem.name }}
52
53
  </div>
@@ -57,7 +58,7 @@
57
58
  >
58
59
  {{ elem.link }}
59
60
  </span>
60
- </div>
61
+ </a>
61
62
  <div v-if="elem.children" @click="rotateItem(index)" class="gray-text profile-menu__item">
62
63
  <div class="profile-menu__item__children">{{ elem.name }}
63
64
  <span v-if="elem.children.length > 0">
@@ -303,6 +304,11 @@ export default {
303
304
  logout() {
304
305
  this.$emit("logout");
305
306
  },
307
+ preventLink(disabled, e) {
308
+ if (disabled) {
309
+ e.preventDefault()
310
+ }
311
+ },
306
312
  async showModal(url, name) {
307
313
  if (name.includes('Текущий')) {
308
314
  if(window.location.href.includes(url)) {
@@ -324,6 +330,12 @@ export default {
324
330
  this.chosenElem = this.listDropDown[index];
325
331
  this.$set(this.listDropDown[index], 'opened', !this.listDropDown[index].opened)
326
332
  },
333
+ goAuth() {
334
+ const fullPath = encodeURIComponent(window.location.toString())
335
+ if (window) {
336
+ window.location.href = `${this.loginUrl}?url=${fullPath}`
337
+ }
338
+ }
327
339
  }
328
340
  };
329
341
  </script>
@@ -5,8 +5,8 @@
5
5
  <th v-for="(col, i) in cols" :key="i">{{ col.name }}</th>
6
6
  </tr>
7
7
  </thead>
8
- <tbody v-for="(row, i) in rows" :key="i">
9
- <tr>
8
+ <tbody>
9
+ <tr v-for="(row, i) in rows" :key="i">
10
10
  <td v-for="col in cols" :key="col.key" :data-label="`${col.name}`">
11
11
  <slot :name="'key-' + col.key" :row="row">
12
12
  {{ row[col.key] || defaultEmpty }}