adata-ui 0.1.2 → 0.1.6
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/README.md +3 -20
- package/dist/adata-ui.common.js +4478 -290
- package/dist/adata-ui.common.js.map +1 -1
- package/dist/adata-ui.css +1 -1
- package/dist/adata-ui.umd.js +4478 -290
- package/dist/adata-ui.umd.js.map +1 -1
- package/dist/adata-ui.umd.min.js +1 -1
- package/dist/adata-ui.umd.min.js.map +1 -1
- package/package-lock.json +25791 -12100
- package/package.json +71 -52
- package/src/App.vue +23 -28
- package/src/components/Alert/Alert.stories.js +17 -0
- package/src/components/Alert/Alert.vue +63 -0
- package/src/components/Button/BaseButton.vue +241 -0
- package/src/components/Button/Button.stories.js +23 -0
- package/src/components/Footer/Footer.stories.js +20 -0
- package/src/components/Footer/Footer.vue +233 -0
- package/src/components/Header/Header.stories.js +55 -0
- package/src/components/Header/Header.vue +315 -0
- package/src/components/Header/Profile.vue +806 -0
- package/src/components/PasswordField/PasswordField.stories.js +16 -0
- package/src/components/PasswordField/PasswordField.vue +68 -0
- package/src/components/TextField/TextField.stories.js +17 -0
- package/src/components/TextField/TextField.vue +355 -0
- package/src/components/index.js +12 -5
- package/src/components/transitions/SlideToggle.vue +55 -0
- package/src/components/transitions/VerticalMobileToggle.vue +76 -0
- package/src/configs/navigationBarConfig.js +22 -0
- package/src/configs/profileDropDown.js +101 -0
- package/src/stories/Button.stories.js +46 -0
- package/src/stories/Button.vue +54 -0
- package/src/stories/Header.stories.js +21 -0
- package/src/stories/Header.vue +59 -0
- package/src/stories/Introduction.stories.mdx +211 -0
- package/src/stories/Page.stories.js +25 -0
- package/src/stories/Page.vue +88 -0
- package/src/stories/assets/code-brackets.svg +1 -0
- package/src/stories/assets/colors.svg +1 -0
- package/src/stories/assets/comments.svg +1 -0
- package/src/stories/assets/direction.svg +1 -0
- package/src/stories/assets/flow.svg +1 -0
- package/src/stories/assets/plugin.svg +1 -0
- package/src/stories/assets/repo.svg +1 -0
- package/src/stories/assets/stackalt.svg +1 -0
- package/src/stories/button.css +30 -0
- package/src/stories/header.css +26 -0
- package/src/stories/page.css +69 -0
- package/src/components/Button.vue +0 -18
- package/src/components/HelloWorld.vue +0 -58
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import PasswordField from "./PasswordField.vue";
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
title: 'PasswordField',
|
|
5
|
+
component: PasswordField,
|
|
6
|
+
template: "<password-field label='Example'></password-field>"
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
const Template = (args, { argTypes }) => ({
|
|
10
|
+
components: { PasswordField },
|
|
11
|
+
props: Object.keys(argTypes),
|
|
12
|
+
template: '<password-field v-bind="$props"></password-field>'
|
|
13
|
+
})
|
|
14
|
+
|
|
15
|
+
export const BasePasswordField = Template.bind({});
|
|
16
|
+
BasePasswordField.args = {label: 'Password'}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="adt-text-block">
|
|
3
|
+
<div class="adt-text-block__field">
|
|
4
|
+
<input
|
|
5
|
+
ref="input"
|
|
6
|
+
:type="type"
|
|
7
|
+
:value="value"
|
|
8
|
+
required
|
|
9
|
+
@input="$emit('input', $event.target.value)"
|
|
10
|
+
class="adt-text-block__input"
|
|
11
|
+
:class="{ error: !!errorText }"
|
|
12
|
+
/>
|
|
13
|
+
<label class="adt-text-block__label">{{ label }}</label>
|
|
14
|
+
<div v-if="showPassword" @click="showPassword = false" class="adt-text-block__icon desktop">
|
|
15
|
+
<svg width="12" height="12" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 511.992 511.992" id="openedEye">
|
|
16
|
+
<path
|
|
17
|
+
d="M510.096 249.937c-4.032-5.867-100.928-143.275-254.101-143.275-131.435 0-248.555 136.619-253.483 142.443-3.349 3.968-3.349 9.792 0 13.781C7.44 268.71 124.56 405.329 255.995 405.329S504.549 268.71 509.477 262.886c3.094-3.669 3.371-8.981.619-12.949zM255.995 383.996c-105.365 0-205.547-100.48-230.997-128 25.408-27.541 125.483-128 230.997-128 123.285 0 210.304 100.331 231.552 127.424-24.534 26.645-125.291 128.576-231.552 128.576z"></path>
|
|
18
|
+
<path
|
|
19
|
+
d="M255.995 170.662c-47.061 0-85.333 38.272-85.333 85.333s38.272 85.333 85.333 85.333 85.333-38.272 85.333-85.333-38.272-85.333-85.333-85.333zm0 149.334c-35.285 0-64-28.715-64-64s28.715-64 64-64 64 28.715 64 64-28.715 64-64 64z"></path>
|
|
20
|
+
</svg>
|
|
21
|
+
</div>
|
|
22
|
+
<div v-else @click="showPassword = true" class="adt-text-block__icon desktop">
|
|
23
|
+
<svg width="12" height="12" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512.001 512.001" id="closedEye">
|
|
24
|
+
<path
|
|
25
|
+
d="M316.332 195.662c-4.16-4.16-10.923-4.16-15.083 0s-4.16 10.944 0 15.083c12.075 12.075 18.752 28.139 18.752 45.248 0 35.285-28.715 64-64 64-17.109 0-33.173-6.656-45.248-18.752-4.16-4.16-10.923-4.16-15.083 0-4.16 4.139-4.16 10.923 0 15.083 16.085 16.128 37.525 25.003 60.331 25.003 47.061 0 85.333-38.272 85.333-85.333 0-22.807-8.874-44.247-25.002-60.332zm-45.462-23.531c-4.843-.853-9.792-1.472-14.869-1.472-47.061 0-85.333 38.272-85.333 85.333 0 5.077.619 10.027 1.493 14.869.917 5.163 5.419 8.811 10.475 8.811.619 0 1.237-.043 1.877-.171 5.781-1.024 9.664-6.571 8.64-12.352-.661-3.627-1.152-7.317-1.152-11.157 0-35.285 28.715-64 64-64 3.84 0 7.531.491 11.157 1.131 5.675 1.152 11.328-2.859 12.352-8.64 1.024-5.781-2.858-11.328-8.64-12.352z"></path>
|
|
26
|
+
<path
|
|
27
|
+
d="M509.462 249.102c-2.411-2.859-60.117-70.208-139.712-111.445-5.163-2.709-11.669-.661-14.379 4.587-2.709 5.227-.661 11.669 4.587 14.379 61.312 31.744 110.293 81.28 127.04 99.371-25.429 27.541-125.504 128-230.997 128-35.797 0-71.872-8.64-107.264-25.707-5.248-2.581-11.669-.341-14.229 4.971-2.581 5.291-.341 11.669 4.971 14.229 38.293 18.496 77.504 27.84 116.523 27.84 131.435 0 248.555-136.619 253.483-142.443 3.369-3.969 3.348-9.793-.023-13.782zM325.996 118.947c-24.277-8.171-47.829-12.288-69.995-12.288-131.435 0-248.555 136.619-253.483 142.443-3.115 3.669-3.371 9.003-.597 12.992 1.472 2.112 36.736 52.181 97.856 92.779a10.48 10.48 0 005.888 1.792c3.435 0 6.827-1.664 8.875-4.8 3.264-4.885 1.92-11.52-2.987-14.763-44.885-29.845-75.605-65.877-87.104-80.533 24.555-26.667 125.291-128.576 231.552-128.576 19.861 0 41.131 3.755 63.189 11.157 5.589 2.005 11.648-1.088 13.504-6.699 1.878-5.589-1.109-11.626-6.698-13.504z"></path>
|
|
28
|
+
<path
|
|
29
|
+
d="M444.865 67.128c-4.16-4.16-10.923-4.16-15.083 0L67.116 429.795c-4.16 4.16-4.16 10.923 0 15.083a10.716 10.716 0 007.552 3.115c2.731 0 5.461-1.045 7.531-3.115L444.865 82.211c4.16-4.16 4.16-10.923 0-15.083z"></path>
|
|
30
|
+
</svg>
|
|
31
|
+
</div>
|
|
32
|
+
</div>
|
|
33
|
+
<div class="adt-text-block__error" v-if="!!errorText">
|
|
34
|
+
{{ errorText }}
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</template>
|
|
38
|
+
|
|
39
|
+
<script>
|
|
40
|
+
export default {
|
|
41
|
+
name: "PasswordField",
|
|
42
|
+
props: {
|
|
43
|
+
errorText: {
|
|
44
|
+
type: String,
|
|
45
|
+
default: ""
|
|
46
|
+
},
|
|
47
|
+
label: {
|
|
48
|
+
type: String,
|
|
49
|
+
required: true,
|
|
50
|
+
},
|
|
51
|
+
value: {
|
|
52
|
+
type: [String, null],
|
|
53
|
+
required: true,
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
data() {
|
|
57
|
+
return {
|
|
58
|
+
showPassword: false
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
computed: {
|
|
62
|
+
type() {
|
|
63
|
+
return this.showPassword ? "text" : "password";
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
</script>
|
|
68
|
+
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import TextField from "./TextField.vue";
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
title: 'TextField',
|
|
5
|
+
component: TextField,
|
|
6
|
+
data: () => ({ value: "" }),
|
|
7
|
+
template: "<text-field @input='(val) => {this.value = val}' label='Example'></text-field>>"
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const Template = (args, { argTypes }) => ({
|
|
11
|
+
components: { TextField },
|
|
12
|
+
props: Object.keys(argTypes),
|
|
13
|
+
template: '<text-field v-bind="$props"></text-field>'
|
|
14
|
+
})
|
|
15
|
+
|
|
16
|
+
export const Clearable = Template.bind({});
|
|
17
|
+
Clearable.args = {label: 'Clearable', clearable: true}
|
|
@@ -0,0 +1,355 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="adt-text-block">
|
|
3
|
+
<div class="adt-text-block__field">
|
|
4
|
+
<input
|
|
5
|
+
v-if="!mask"
|
|
6
|
+
ref="input"
|
|
7
|
+
:type="type"
|
|
8
|
+
:value="value"
|
|
9
|
+
:placeholder="placeholder"
|
|
10
|
+
required
|
|
11
|
+
@input="$emit('input', $event.target.value)"
|
|
12
|
+
class="adt-text-block__input"
|
|
13
|
+
:class="{ error: !!errorText }"
|
|
14
|
+
/>
|
|
15
|
+
<TheMask
|
|
16
|
+
v-else
|
|
17
|
+
ref="maskInput"
|
|
18
|
+
:value="value"
|
|
19
|
+
:mask="mask"
|
|
20
|
+
:type="type"
|
|
21
|
+
:masked="false"
|
|
22
|
+
:placeholder="inputPlaceholder"
|
|
23
|
+
required
|
|
24
|
+
@input.native="$emit('input', $event.target.value)"
|
|
25
|
+
@focus.native="showPlaceholder = true"
|
|
26
|
+
@blur.native="showPlaceholder = false"
|
|
27
|
+
class="adt-text-block__input"
|
|
28
|
+
:class="{ error: !!errorText }"
|
|
29
|
+
/>
|
|
30
|
+
<label class="adt-text-block__label">{{ label }}<span v-if="required" class="adt-text-block__required">*</span></label>
|
|
31
|
+
<div class="adt-text-block__icon desktop" v-if="clearable && value && value.length > 0" @click="$emit('input', '')">
|
|
32
|
+
<svg width="12" height="12" fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" id="clearIcon">
|
|
33
|
+
<path d="M2 2l12 12m0-12L2 14" stroke="#2C3E50" stroke-linecap="round" stroke-linejoin="round"></path>
|
|
34
|
+
</svg>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
<div class="adt-text-block__error" v-if="!!errorText">
|
|
38
|
+
{{ errorText }}
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
</template>
|
|
42
|
+
|
|
43
|
+
<script>
|
|
44
|
+
import { TheMask } from 'vue-the-mask';
|
|
45
|
+
|
|
46
|
+
export default {
|
|
47
|
+
name: "TextField",
|
|
48
|
+
props: {
|
|
49
|
+
errorText: {
|
|
50
|
+
type: String,
|
|
51
|
+
default: ""
|
|
52
|
+
},
|
|
53
|
+
label: {
|
|
54
|
+
type: String,
|
|
55
|
+
required: true,
|
|
56
|
+
},
|
|
57
|
+
type: {
|
|
58
|
+
type: String,
|
|
59
|
+
default: "text",
|
|
60
|
+
},
|
|
61
|
+
mask: {
|
|
62
|
+
type: String,
|
|
63
|
+
default: ""
|
|
64
|
+
},
|
|
65
|
+
value: {
|
|
66
|
+
type: String,
|
|
67
|
+
required: true,
|
|
68
|
+
},
|
|
69
|
+
placeholder: {
|
|
70
|
+
type: String,
|
|
71
|
+
default: ""
|
|
72
|
+
},
|
|
73
|
+
clearable: {
|
|
74
|
+
type: Boolean,
|
|
75
|
+
default: false
|
|
76
|
+
},
|
|
77
|
+
required: {
|
|
78
|
+
type: Boolean,
|
|
79
|
+
default: false
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
components: {
|
|
83
|
+
TheMask
|
|
84
|
+
},
|
|
85
|
+
data() {
|
|
86
|
+
return {
|
|
87
|
+
showPlaceholder: false
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
computed: {
|
|
91
|
+
inputPlaceholder() {
|
|
92
|
+
return this.showPlaceholder ? this.placeholder : ""
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
</script>
|
|
97
|
+
|
|
98
|
+
<style lang="scss">
|
|
99
|
+
*:focus {
|
|
100
|
+
outline: none;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.adt-text-block {
|
|
104
|
+
$self: &;
|
|
105
|
+
position: relative;
|
|
106
|
+
width: 100%;
|
|
107
|
+
|
|
108
|
+
&.magnifier {
|
|
109
|
+
#{$self}__input {
|
|
110
|
+
padding: 19px 40px 5px 40px;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
#{$self}__label {
|
|
114
|
+
left: 40px;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
&.magnifier-mobile {
|
|
119
|
+
#{$self}__magnifier {
|
|
120
|
+
display: block;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
#{$self}__input {
|
|
124
|
+
padding: 19px 8px 5px 11px;
|
|
125
|
+
border-top-right-radius: 0;
|
|
126
|
+
border-bottom-right-radius: 0;
|
|
127
|
+
-webkit-appearance: none;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
#{$self}__label {
|
|
131
|
+
left: 12px;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
&__input-mob-search {
|
|
136
|
+
border-top-right-radius: 0;
|
|
137
|
+
border-bottom-right-radius: 0;
|
|
138
|
+
-webkit-appearance: none;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
&__error {
|
|
142
|
+
text-align: left;
|
|
143
|
+
font-size: var(--fs-content-micro);
|
|
144
|
+
line-height: 14px;
|
|
145
|
+
color: #ff2e43;
|
|
146
|
+
margin-top: 6px;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
&__field {
|
|
150
|
+
position: relative;
|
|
151
|
+
overflow: hidden;
|
|
152
|
+
@media(max-width: 1025px) {
|
|
153
|
+
width: 100%;
|
|
154
|
+
display: flex;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
&__input {
|
|
159
|
+
background: #ffffff;
|
|
160
|
+
border: 1px solid #c4c4c4;
|
|
161
|
+
box-sizing: border-box;
|
|
162
|
+
border-radius: 2px;
|
|
163
|
+
width: 100%;
|
|
164
|
+
height: 40px;
|
|
165
|
+
font-size: var(--fs-form);
|
|
166
|
+
color: #1A2030;
|
|
167
|
+
padding: 19px 40px 5px 16px;
|
|
168
|
+
transition: 0.3s all;
|
|
169
|
+
@media(max-width: 1025px) {
|
|
170
|
+
padding: 19px 36px 7px 12px;
|
|
171
|
+
height: 40px;
|
|
172
|
+
border: 1px solid #71757A;
|
|
173
|
+
font-size: var(--fs-content-mini);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
&:focus ~ #{$self}__label,
|
|
177
|
+
&:not(:focus):valid ~ #{$self}__label {
|
|
178
|
+
top: 12px;
|
|
179
|
+
font-size: var(--fs-content-micro);
|
|
180
|
+
color: #71757A;
|
|
181
|
+
@media(max-width: 1025px) {
|
|
182
|
+
font-size: var(--fs-content-nano);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
&:focus {
|
|
187
|
+
border: 1px solid #2c3e50;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
&::placeholder {
|
|
191
|
+
font-size: 12px;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
&.error {
|
|
195
|
+
background: #ff2e431f;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
&__label {
|
|
200
|
+
position: absolute;
|
|
201
|
+
pointer-events: none;
|
|
202
|
+
left: 16px;
|
|
203
|
+
top: 50%;
|
|
204
|
+
transform: translateY(-50%);
|
|
205
|
+
white-space: nowrap;
|
|
206
|
+
overflow: hidden;
|
|
207
|
+
line-height: 40px;
|
|
208
|
+
transition: 0.3s;
|
|
209
|
+
color: #71757A;
|
|
210
|
+
font-size: var(--fs-form-placeholder);
|
|
211
|
+
@media(max-width: 1025px) {
|
|
212
|
+
left: 12px;
|
|
213
|
+
font-size: var(--fs-content-micro);
|
|
214
|
+
line-height: 16px;
|
|
215
|
+
color: #71757A;
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
&__icon {
|
|
220
|
+
position: absolute;
|
|
221
|
+
right: 16px;
|
|
222
|
+
height: 100%;
|
|
223
|
+
top: 0;
|
|
224
|
+
display: flex;
|
|
225
|
+
align-items: center;
|
|
226
|
+
|
|
227
|
+
&:hover {
|
|
228
|
+
cursor: pointer;
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
&__required {
|
|
233
|
+
color: #FF000087;
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
&__options {
|
|
237
|
+
position: absolute;
|
|
238
|
+
top: calc(100% + 4px);
|
|
239
|
+
left: 0;
|
|
240
|
+
width: 100%;
|
|
241
|
+
background: #fff;
|
|
242
|
+
z-index: 1000;
|
|
243
|
+
border-radius: 2px;
|
|
244
|
+
border: 1px solid #71757A;
|
|
245
|
+
padding: 12px 0;
|
|
246
|
+
@media(max-width: 1025px) {
|
|
247
|
+
overflow: auto;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
#searchVariant {
|
|
251
|
+
background: #eef0f5;
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.search-options {
|
|
256
|
+
&__item {
|
|
257
|
+
padding: 5px 16px;
|
|
258
|
+
line-height: 16px;
|
|
259
|
+
font-size: 14px;
|
|
260
|
+
color: var(--newGray);
|
|
261
|
+
transition: 0.3s all;
|
|
262
|
+
cursor: pointer;
|
|
263
|
+
@media(max-width: 1025px) {
|
|
264
|
+
font-size: 10px;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
&:hover {
|
|
268
|
+
background: #eef0f5;
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
.mobile-magnifier {
|
|
274
|
+
display: flex;
|
|
275
|
+
justify-content: center;
|
|
276
|
+
align-items: center;
|
|
277
|
+
height: 40px;
|
|
278
|
+
width: 40px;
|
|
279
|
+
min-width: 40px;
|
|
280
|
+
border: 1px solid #71757A;
|
|
281
|
+
border-radius: 0 2px 2px 0;
|
|
282
|
+
border-left: none;
|
|
283
|
+
background: #FFCD33;
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
&__input-mob-filter {
|
|
287
|
+
background: #ffffff;
|
|
288
|
+
border: 1px solid #71757A;
|
|
289
|
+
border-bottom: none;
|
|
290
|
+
box-sizing: border-box;
|
|
291
|
+
border-radius: 2px;
|
|
292
|
+
width: 100%;
|
|
293
|
+
height: 48px;
|
|
294
|
+
font-size: 16px;
|
|
295
|
+
line-height: 19px;
|
|
296
|
+
display: flex;
|
|
297
|
+
align-items: center;
|
|
298
|
+
color: #1A2030;
|
|
299
|
+
padding: 19px 40px 5px 16px;
|
|
300
|
+
transition: 0.3s all;
|
|
301
|
+
-webkit-appearance: none;
|
|
302
|
+
-moz-appearance: none;
|
|
303
|
+
appearance: none;
|
|
304
|
+
|
|
305
|
+
&:focus ~ #{$self}__label-mob-filter,
|
|
306
|
+
&:not(:focus):valid ~ #{$self}__label-mob-filter {
|
|
307
|
+
top: 11px;
|
|
308
|
+
font-size: 10px;
|
|
309
|
+
color: #71757A;
|
|
310
|
+
@media(max-width: 1025px) {
|
|
311
|
+
font-size: 7px;
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
&:focus {
|
|
316
|
+
border: 1px solid #2c3e50;
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
&::placeholder {
|
|
320
|
+
font-size: 12px;
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
&.error {
|
|
324
|
+
background: #ff2e431f;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
&__label-mob-filter {
|
|
329
|
+
position: absolute;
|
|
330
|
+
pointer-events: none;
|
|
331
|
+
left: 16px;
|
|
332
|
+
top: 50%;
|
|
333
|
+
transform: translateY(-50%);
|
|
334
|
+
white-space: nowrap;
|
|
335
|
+
overflow: hidden;
|
|
336
|
+
line-height: 40px;
|
|
337
|
+
transition: 0.3s;
|
|
338
|
+
color: #71757A;
|
|
339
|
+
@media(max-width: 1025px) {
|
|
340
|
+
left: 16px;
|
|
341
|
+
font-size: 14px;
|
|
342
|
+
line-height: 16px;
|
|
343
|
+
color: #71757A;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
&__red {
|
|
347
|
+
color: rgba(255, 0, 0, 0.53);
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
&__magnifier {
|
|
351
|
+
left: 8px;
|
|
352
|
+
width: fit-content;
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
</style>
|
package/src/components/index.js
CHANGED
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import Vue from 'vue'
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
2
|
+
import AButton from './Button/BaseButton'
|
|
3
|
+
import ATextField from './TextField/TextField'
|
|
4
|
+
import APasswordField from './PasswordField/PasswordField'
|
|
5
|
+
import AAlert from './Alert/Alert'
|
|
6
|
+
import AHeader from './Header/Header'
|
|
7
|
+
import AFooter from './Footer/Footer'
|
|
5
8
|
const Components = {
|
|
6
|
-
|
|
7
|
-
|
|
9
|
+
AButton,
|
|
10
|
+
ATextField,
|
|
11
|
+
APasswordField,
|
|
12
|
+
AAlert,
|
|
13
|
+
AHeader,
|
|
14
|
+
AFooter
|
|
8
15
|
};
|
|
9
16
|
|
|
10
17
|
Object.keys(Components).forEach(name => {
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<transition
|
|
3
|
+
v-on:before-enter="beforeEnter"
|
|
4
|
+
v-on:enter="enter"
|
|
5
|
+
v-on:after-enter="afterEnter"
|
|
6
|
+
v-on:before-leave="beforeLeave"
|
|
7
|
+
v-on:leave="leave"
|
|
8
|
+
v-on:after-leave="afterLeave"
|
|
9
|
+
>
|
|
10
|
+
<slot :animationClass="'slideToggleAnimation'" :compareNotificationClass="'compareNotification'"
|
|
11
|
+
:fastAnimation="'fastAnimation'"/>
|
|
12
|
+
</transition>
|
|
13
|
+
</template>
|
|
14
|
+
<script>
|
|
15
|
+
export default {
|
|
16
|
+
methods: {
|
|
17
|
+
beforeEnter: function (el) {
|
|
18
|
+
el.style.height = "0";
|
|
19
|
+
el.style.overflow = "hidden";
|
|
20
|
+
},
|
|
21
|
+
enter: function (el) {
|
|
22
|
+
el.style.height = el.scrollHeight + "px";
|
|
23
|
+
},
|
|
24
|
+
afterEnter: function (el) {
|
|
25
|
+
el.style.height = "auto";
|
|
26
|
+
el.style.overflow = "initial";
|
|
27
|
+
},
|
|
28
|
+
beforeLeave: function (el) {
|
|
29
|
+
el.style.overflow = "hidden";
|
|
30
|
+
el.style.height = el.scrollHeight + "px";
|
|
31
|
+
el.scrollHeight;
|
|
32
|
+
},
|
|
33
|
+
leave: function (el) {
|
|
34
|
+
el.style.height = "0";
|
|
35
|
+
},
|
|
36
|
+
afterLeave: function (el) {
|
|
37
|
+
el.style.height = "auto";
|
|
38
|
+
el.style.overflow = "initial";
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
};
|
|
42
|
+
</script>
|
|
43
|
+
<style scoped>
|
|
44
|
+
.slideToggleAnimation {
|
|
45
|
+
transition: 0.3s all;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.fastAnimation {
|
|
49
|
+
transition: 0.01s all;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.compareNotification {
|
|
53
|
+
transition: 3s all;
|
|
54
|
+
}
|
|
55
|
+
</style>
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<transition
|
|
3
|
+
v-on:before-enter="beforeEnter"
|
|
4
|
+
v-on:enter="enter"
|
|
5
|
+
v-on:after-enter="afterEnter"
|
|
6
|
+
v-on:before-leave="beforeLeave"
|
|
7
|
+
v-on:leave="leave"
|
|
8
|
+
v-on:after-leave="afterLeave"
|
|
9
|
+
>
|
|
10
|
+
<slot :animationClass="'slideToggleAnimation'" :compareNotificationClass="'compareNotification'" />
|
|
11
|
+
</transition>
|
|
12
|
+
</template>
|
|
13
|
+
<script>
|
|
14
|
+
export default {
|
|
15
|
+
props: {
|
|
16
|
+
zIndex: {
|
|
17
|
+
type: Number,
|
|
18
|
+
default: 0
|
|
19
|
+
},
|
|
20
|
+
top: {
|
|
21
|
+
type: String,
|
|
22
|
+
default: "0%"
|
|
23
|
+
},
|
|
24
|
+
overflow: {
|
|
25
|
+
type: String,
|
|
26
|
+
default: "initial"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
methods: {
|
|
30
|
+
beforeEnter: function (el) {
|
|
31
|
+
el.style.width = "0";
|
|
32
|
+
el.style.overflowX = "hidden";
|
|
33
|
+
el.style.overflowY = "hidden";
|
|
34
|
+
el.style.position = "fixed";
|
|
35
|
+
el.style.top = "0";
|
|
36
|
+
el.style.right = "0";
|
|
37
|
+
el.style.background = "#fff";
|
|
38
|
+
},
|
|
39
|
+
afterEnter: function (el) {
|
|
40
|
+
el.style.height = "100vh";
|
|
41
|
+
el.style.width = "100vw";
|
|
42
|
+
el.style.overflowX = "hidden";
|
|
43
|
+
el.style.overflowY = "auto";
|
|
44
|
+
el.style.position = "fixed";
|
|
45
|
+
el.style.top = this.top;
|
|
46
|
+
el.style.right = "0";
|
|
47
|
+
el.style.background = "#fff";
|
|
48
|
+
el.style.zIndex = (90 + this.zIndex).toString();
|
|
49
|
+
},
|
|
50
|
+
beforeLeave: function (el) {
|
|
51
|
+
el.style.overflow = "hidden";
|
|
52
|
+
el.style.width = el.scrollHeight + "px";
|
|
53
|
+
el.scrollHeight;
|
|
54
|
+
},
|
|
55
|
+
leave: function (el) {
|
|
56
|
+
el.style.width = "0";
|
|
57
|
+
},
|
|
58
|
+
afterLeave: function (el) {
|
|
59
|
+
el.style.position = "fixed";
|
|
60
|
+
el.style.top = "0";
|
|
61
|
+
el.style.right = "0";
|
|
62
|
+
el.style.width = "auto";
|
|
63
|
+
el.style.overflow = "initial";
|
|
64
|
+
},
|
|
65
|
+
},
|
|
66
|
+
};
|
|
67
|
+
</script>
|
|
68
|
+
<style scoped>
|
|
69
|
+
.slideToggleAnimation {
|
|
70
|
+
transition: 0.3s all;
|
|
71
|
+
|
|
72
|
+
}
|
|
73
|
+
.compareNotification{
|
|
74
|
+
transition: 3s all;
|
|
75
|
+
}
|
|
76
|
+
</style>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export const menuList = [
|
|
2
|
+
{
|
|
3
|
+
id: 1,
|
|
4
|
+
name: "Контрагенты",
|
|
5
|
+
url: 'https://pk.adata.kz',
|
|
6
|
+
},
|
|
7
|
+
{
|
|
8
|
+
id: 2,
|
|
9
|
+
name: "Тендеры",
|
|
10
|
+
url: 'https://tender.adata.kz',
|
|
11
|
+
},
|
|
12
|
+
{
|
|
13
|
+
id: 3,
|
|
14
|
+
name: "Работа",
|
|
15
|
+
url: 'https://work.adata.kz',
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
id: 4,
|
|
19
|
+
name: "Штрафы",
|
|
20
|
+
url: 'https://fines.adata.kz',
|
|
21
|
+
}
|
|
22
|
+
];
|