adata-ui 2.1.35 → 2.1.36

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.
@@ -9,6 +9,7 @@ defineEmits(['click'])
9
9
  <template>
10
10
  <div
11
11
  class="hidden w-max cursor-pointer items-center gap-2 rounded-2xl bg-blue-700 px-4 py-[6px] font-semibold dark:bg-blue-500 lg:flex"
12
+ data-test-id="header-login-button"
12
13
  @click="$emit('click')"
13
14
  >
14
15
  <icon-logout class="text-white dark:text-gray-900 lg:h-4 lg:w-4" />
@@ -44,6 +44,7 @@ function onClick(loc: any) {
44
44
  >
45
45
  <nuxt-link
46
46
  v-for="loc in locales"
47
+ :data-test-id="`header-switch-${loc?.code}-language-button`"
47
48
  :class="[
48
49
  'text-sm cursor-pointer px-4 py-2.5 flex justify-between',
49
50
  {'text-primary bg-deepblue-500/5': locale === loc.code}
@@ -85,9 +85,9 @@ async function send() {
85
85
  </script>
86
86
 
87
87
  <template>
88
- <a-modal v-model="isOpen">
88
+ <a-modal v-model="isOpen" data-test-id="report-form-modal">
89
89
  <template #header>
90
- <p class="heading-02 text-center">
90
+ <p class="heading-02 text-center" data-test-id="report-form-title">
91
91
  {{ t('modals.report_bug.title') }}
92
92
  </p>
93
93
  </template>
@@ -104,12 +104,14 @@ async function send() {
104
104
  <a-input-standard
105
105
  v-model="form.name"
106
106
  required
107
+ data-test-id="report-form-name-input"
107
108
  :label="t('modals.report_bug.labels.name')"
108
109
  :error="getError('name')"
109
110
  />
110
111
  <a-input-standard
111
112
  v-model="form.email"
112
113
  required
114
+ data-test-id="report-form-email-input"
113
115
  :label="t('modals.report_bug.labels.email')"
114
116
  :error="getError('email')"
115
117
  />
@@ -119,6 +121,7 @@ async function send() {
119
121
  required
120
122
  data-maska="8 (###) ### ## ##"
121
123
  clearable
124
+ data-test-id="report-form-phone-input"
122
125
  :label="t('modals.report_bug.labels.phone')"
123
126
  :error="getError('phone_number')"
124
127
  />
@@ -126,6 +129,7 @@ async function send() {
126
129
  <a-textarea
127
130
  v-model="form.comment"
128
131
  required
132
+ data-test-id="report-form-comment-textarea"
129
133
  :label="t('modals.report_bug.labels.comment')"
130
134
  size="md"
131
135
  :error="getError('comment')"
@@ -140,12 +144,14 @@ async function send() {
140
144
  <a-button
141
145
  view="outline"
142
146
  class="w-full"
147
+ data-test-id="report-form-close-button"
143
148
  @click="emit('close')"
144
149
  >
145
150
  {{ t('actions.close') }}
146
151
  </a-button>
147
152
  <a-button
148
153
  class="w-full"
154
+ data-test-id="report-form-submit-button"
149
155
  @click="send"
150
156
  >
151
157
  {{ t('actions.send') }}
@@ -142,7 +142,7 @@ const closeMessage = () => {
142
142
  class="hidden min-h-10 bg-gray-50 dark:bg-gray-950 lg:block"
143
143
  >
144
144
  <div class="a-container flex justify-between py-2 items-center text-sm">
145
- <div class="flex items-center leading-[24px]">
145
+ <div class="flex items-center leading-[24px]" data-test-id="header-currency-bar">
146
146
  <div v-for="currency in currencies" :key="currency.currency" class="mr-4 flex gap-2">
147
147
  <div class="flex items-center">
148
148
  <component
@@ -165,13 +165,13 @@ const closeMessage = () => {
165
165
  <div v-if="isAuthenticated" class="flex items-center gap-5">
166
166
  <div v-if="limitRemaining != null || limitRemaining != undefined">
167
167
  <span class="mr-2 text-xs">{{ t('header.top.requestLimit') }}</span>
168
- <a-status-badge size="sm">
168
+ <a-status-badge size="sm" data-test-id="header-daily-requests-count">
169
169
  {{ limitRemaining }}
170
170
  </a-status-badge>
171
171
  </div>
172
172
  <div v-if="daysRemaining">
173
173
  <span class="mr-2 text-xs">{{ t('header.top.daysLeft') }}</span>
174
- <a-status-badge size="sm">
174
+ <a-status-badge size="sm" data-test-id="header-tariff-days-remaining-count">
175
175
  {{ daysRemaining }}
176
176
  </a-status-badge>
177
177
  </div>
@@ -17,6 +17,7 @@
17
17
  activeTab === option.key ? selectedClasses() : defaultClasses(!!option.disabled),
18
18
  sizeOptions[size]
19
19
  ]"
20
+ :data-test-id="option?.dataTestId"
20
21
  @click="onChanged(option, $event)"
21
22
  >
22
23
  <slot name="option" :option="option">
@@ -20,4 +20,5 @@ export interface Tab {
20
20
  disabled?: boolean
21
21
  prevent?:boolean
22
22
  badgeColor?: 'primary' | 'success' | 'danger' | 'gray' | 'orange' | 'warning'
23
+ dataTestId?: string
23
24
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "adata-ui",
3
3
  "type": "module",
4
- "version": "2.1.35",
4
+ "version": "2.1.36",
5
5
  "main": "./nuxt.config.ts",
6
6
  "scripts": {
7
7
  "dev": "nuxi dev .playground",