layers-design-system 2.3.0 → 2.5.1

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.
Files changed (186) hide show
  1. package/dist/layers-design-system.js +78496 -0
  2. package/dist/layers-design-system.umd.cjs +285 -0
  3. package/dist/style.css +1 -0
  4. package/package.json +26 -12
  5. package/.nvmrc +0 -1
  6. package/babel.config.js +0 -5
  7. package/src/assets/button-text-editor/double-quotes.svg +0 -4
  8. package/src/assets/button-text-editor/remove-formatting.svg +0 -5
  9. package/src/assets/button-text-editor/title.svg +0 -4
  10. package/src/assets/failed-to-load/failed-to-load.svg +0 -60
  11. package/src/assets/l-presentation/external-apps.png +0 -0
  12. package/src/assets/l-presentation/notification.png +0 -0
  13. package/src/assets/search-topics/empty-tags.svg +0 -59
  14. package/src/components/LAlert/docs.vue +0 -81
  15. package/src/components/LAlert/index.vue +0 -43
  16. package/src/components/LAttachmentChip/docs.vue +0 -84
  17. package/src/components/LAttachmentChip/index.vue +0 -179
  18. package/src/components/LBox/docs.vue +0 -26
  19. package/src/components/LBox/index.vue +0 -19
  20. package/src/components/LBoxHeader/index.vue +0 -24
  21. package/src/components/LBreadcrumb/docs.vue +0 -21
  22. package/src/components/LBreadcrumb/index.vue +0 -22
  23. package/src/components/LBreadcrumbItem/index.vue +0 -7
  24. package/src/components/LButton/docs.vue +0 -205
  25. package/src/components/LButton/index.vue +0 -369
  26. package/src/components/LButtonGroup/index.vue +0 -7
  27. package/src/components/LCarousel/docs.vue +0 -32
  28. package/src/components/LCarousel/index.vue +0 -88
  29. package/src/components/LCheckbox/docs.vue +0 -62
  30. package/src/components/LCheckbox/index.vue +0 -34
  31. package/src/components/LCheckboxButton/index.vue +0 -30
  32. package/src/components/LCheckboxGroup/index.vue +0 -53
  33. package/src/components/LChip/docs.vue +0 -113
  34. package/src/components/LChip/index.vue +0 -78
  35. package/src/components/LCircularLoader/docs.vue +0 -30
  36. package/src/components/LCircularLoader/index.vue +0 -97
  37. package/src/components/LCollapse/docs.vue +0 -68
  38. package/src/components/LCollapse/index.vue +0 -13
  39. package/src/components/LCollapseItem/index.vue +0 -28
  40. package/src/components/LDatePicker/docs.vue +0 -66
  41. package/src/components/LDatePicker/index.vue +0 -63
  42. package/src/components/LDialog/docs.vue +0 -36
  43. package/src/components/LDialog/index.vue +0 -37
  44. package/src/components/LDropdown/index.vue +0 -7
  45. package/src/components/LDropdownItem/index.vue +0 -13
  46. package/src/components/LDropdownMenu/docs.vue +0 -44
  47. package/src/components/LDropdownMenu/index.vue +0 -12
  48. package/src/components/LFailedToLoad/docs.vue +0 -37
  49. package/src/components/LFailedToLoad/index.vue +0 -61
  50. package/src/components/LForm/index.vue +0 -7
  51. package/src/components/LFormItem/index.vue +0 -12
  52. package/src/components/LHelperBox/assets/link.svg +0 -4
  53. package/src/components/LHelperBox/assets/open-envelope.svg +0 -9
  54. package/src/components/LHelperBox/docs.vue +0 -29
  55. package/src/components/LHelperBox/index.vue +0 -83
  56. package/src/components/LIcon/docs.vue +0 -174
  57. package/src/components/LIcon/index.vue +0 -55
  58. package/src/components/LImage/index.vue +0 -7
  59. package/src/components/LImageViewer/docs.vue +0 -111
  60. package/src/components/LImageViewer/index.vue +0 -449
  61. package/src/components/LInput/docs.vue +0 -43
  62. package/src/components/LInput/index.vue +0 -60
  63. package/src/components/LLinearProgress/docs.vue +0 -21
  64. package/src/components/LLinearProgress/index.vue +0 -74
  65. package/src/components/LNotice/docs.vue +0 -26
  66. package/src/components/LNotice/index.vue +0 -86
  67. package/src/components/LNotification/index.vue +0 -182
  68. package/src/components/LOption/index.vue +0 -7
  69. package/src/components/LOptionGroup/index.vue +0 -7
  70. package/src/components/LPresentation/docs.vue +0 -35
  71. package/src/components/LPresentation/index.vue +0 -182
  72. package/src/components/LProgress/index.vue +0 -7
  73. package/src/components/LPromptDialog/index.vue +0 -82
  74. package/src/components/LRadio/docs.vue +0 -54
  75. package/src/components/LRadio/index.vue +0 -13
  76. package/src/components/LRadioButton/index.vue +0 -30
  77. package/src/components/LRadioGroup/index.vue +0 -54
  78. package/src/components/LSearchBar/AddFilterButton.vue +0 -71
  79. package/src/components/LSearchBar/Filters/Editors/AmountEditor.vue +0 -110
  80. package/src/components/LSearchBar/Filters/Editors/DateEditor.vue +0 -146
  81. package/src/components/LSearchBar/Filters/Editors/NumberEditor.vue +0 -141
  82. package/src/components/LSearchBar/Filters/Editors/StringEditor.vue +0 -140
  83. package/src/components/LSearchBar/Filters/Editors/index.js +0 -16
  84. package/src/components/LSearchBar/Filters/FilterChip.vue +0 -105
  85. package/src/components/LSearchBar/Filters/Views/AmountView.vue +0 -28
  86. package/src/components/LSearchBar/Filters/Views/DateView.vue +0 -46
  87. package/src/components/LSearchBar/Filters/Views/NumberView.vue +0 -24
  88. package/src/components/LSearchBar/Filters/Views/StringView.vue +0 -47
  89. package/src/components/LSearchBar/Filters/Views/index.js +0 -16
  90. package/src/components/LSearchBar/docs.vue +0 -60
  91. package/src/components/LSearchBar/index.vue +0 -240
  92. package/src/components/LSearchTopics/RecentTermSearched.vue +0 -30
  93. package/src/components/LSearchTopics/TopicItem.vue +0 -346
  94. package/src/components/LSearchTopics/docs/drawer.vue +0 -254
  95. package/src/components/LSearchTopics/docs.vue +0 -60
  96. package/src/components/LSearchTopics/header.vue +0 -199
  97. package/src/components/LSearchTopics/helpers/showDialogConfirmation.js +0 -30
  98. package/src/components/LSearchTopics/helpers/showDiscardChangesDialog.js +0 -27
  99. package/src/components/LSearchTopics/index.vue +0 -750
  100. package/src/components/LSelect/docs.vue +0 -129
  101. package/src/components/LSelect/index.vue +0 -9
  102. package/src/components/LSlider/index.vue +0 -7
  103. package/src/components/LSwitch/docs.vue +0 -24
  104. package/src/components/LSwitch/index.vue +0 -60
  105. package/src/components/LTabPane/index.vue +0 -7
  106. package/src/components/LTable/FieldTypes/AmountView.vue +0 -16
  107. package/src/components/LTable/FieldTypes/DateView.vue +0 -18
  108. package/src/components/LTable/FieldTypes/EmailView.vue +0 -8
  109. package/src/components/LTable/FieldTypes/NumberView.vue +0 -13
  110. package/src/components/LTable/FieldTypes/PaymentStatusView.vue +0 -8
  111. package/src/components/LTable/FieldTypes/StringView.vue +0 -24
  112. package/src/components/LTable/FieldTypes/index.js +0 -18
  113. package/src/components/LTable/LTableBody.vue +0 -245
  114. package/src/components/LTable/LTableBodySpacer.vue +0 -17
  115. package/src/components/LTable/LTableEndspace.vue +0 -20
  116. package/src/components/LTable/LTableHeader.vue +0 -155
  117. package/src/components/LTable/LTableHeaderCell.vue +0 -188
  118. package/src/components/LTable/LTableHeaderLoader.vue +0 -62
  119. package/src/components/LTable/LTableHeaderResizer.vue +0 -162
  120. package/src/components/LTable/LTableLoadMore.vue +0 -56
  121. package/src/components/LTable/LTablePagination.vue +0 -174
  122. package/src/components/LTable/LTableReloader.vue +0 -61
  123. package/src/components/LTable/ListAdapter.js +0 -74
  124. package/src/components/LTable/docs.vue +0 -111
  125. package/src/components/LTable/helpers.js +0 -194
  126. package/src/components/LTable/index.vue +0 -961
  127. package/src/components/LTabs/docs.vue +0 -28
  128. package/src/components/LTabs/index.vue +0 -37
  129. package/src/components/LTargetChip/docs.vue +0 -86
  130. package/src/components/LTargetChip/index.vue +0 -64
  131. package/src/components/LTargetInput/docs.vue +0 -72
  132. package/src/components/LTargetInput/index.vue +0 -78
  133. package/src/components/LTextEditor/FloatingLink.vue +0 -91
  134. package/src/components/LTextEditor/LinkBox.vue +0 -94
  135. package/src/components/LTextEditor/docs.vue +0 -32
  136. package/src/components/LTextEditor/extensions/LayersBlockquote.js +0 -12
  137. package/src/components/LTextEditor/extensions/LayersBold.js +0 -11
  138. package/src/components/LTextEditor/extensions/LayersBreakLine.js +0 -16
  139. package/src/components/LTextEditor/extensions/LayersBubbleMenu.js +0 -10
  140. package/src/components/LTextEditor/extensions/LayersBulletList.js +0 -12
  141. package/src/components/LTextEditor/extensions/LayersHeading.js +0 -13
  142. package/src/components/LTextEditor/extensions/LayersHistory.js +0 -10
  143. package/src/components/LTextEditor/extensions/LayersItalic.js +0 -11
  144. package/src/components/LTextEditor/extensions/LayersLink.js +0 -29
  145. package/src/components/LTextEditor/extensions/LayersOrderedList.js +0 -12
  146. package/src/components/LTextEditor/extensions/LayersParagraph.js +0 -44
  147. package/src/components/LTextEditor/extensions/LayersPlaceholder.js +0 -11
  148. package/src/components/LTextEditor/extensions/LayersUnderline.js +0 -29
  149. package/src/components/LTextEditor/helpers/addProtocol.js +0 -5
  150. package/src/components/LTextEditor/helpers/removeEmptyTags.js +0 -5
  151. package/src/components/LTextEditor/index.vue +0 -421
  152. package/src/components/LTimeSelect/docs.vue +0 -41
  153. package/src/components/LTimeSelect/index.vue +0 -49
  154. package/src/components/LToggleButtonGroup/index.vue +0 -87
  155. package/src/components/LTooltip/docs.vue +0 -66
  156. package/src/components/LTooltip/index.vue +0 -28
  157. package/src/components/LTransitionExpand/docs.vue +0 -26
  158. package/src/components/LTransitionExpand/index.vue +0 -88
  159. package/src/components/LUpload/index.vue +0 -7
  160. package/src/docs/Colors.vue +0 -50
  161. package/src/docs/Home.vue +0 -11
  162. package/src/docs/Notifications.vue +0 -88
  163. package/src/docs/index.vue +0 -76
  164. package/src/docs/routes.js +0 -20
  165. package/src/helpers/Colors.js +0 -79
  166. package/src/helpers/FieldTypeComponents.js +0 -43
  167. package/src/helpers/Icons.js +0 -67
  168. package/src/helpers/Notification.js +0 -94
  169. package/src/helpers/PrettySize.js +0 -25
  170. package/src/helpers/RegisterElementUIComponents.js +0 -9
  171. package/src/helpers/Schemas.js +0 -18
  172. package/src/helpers/util.js +0 -15
  173. package/src/main-docs.js +0 -132
  174. package/src/main.js +0 -101
  175. package/src/style/colors.scss +0 -31
  176. package/src/style/element-variables.scss +0 -21
  177. package/src/style/icons.scss +0 -5
  178. package/src/style/layers-variables.scss +0 -73
  179. package/src/style/layout.scss +0 -2288
  180. package/src/style/main.scss +0 -11
  181. package/src/style/notifications.scss +0 -88
  182. package/src/style/transitions.scss +0 -43
  183. package/src/style/typography.scss +0 -155
  184. package/vue.config.js +0 -14
  185. /package/{public → dist}/favicon.ico +0 -0
  186. /package/{public → dist}/index.html +0 -0
@@ -1,449 +0,0 @@
1
- <template>
2
- <div
3
- class="image-viewer"
4
- style="position: relative;"
5
- >
6
- <div class="header" :class="{'colapsed': !showCommands}">
7
- <l-button
8
- circle
9
- @click="back"
10
- class="header-button"
11
- icon="uil-arrow-left"
12
- >
13
- </l-button>
14
- <div v-if="images.length !== 1">{{ parseInt(selected) + 1 }}/{{ images.length }}</div>
15
- <l-button
16
- circle
17
- @click="download"
18
- class="header-button"
19
- icon="el-icon-download"
20
- ></l-button>
21
- </div>
22
- <transition name="el-notification-fade">
23
- <l-button
24
- @click="previous"
25
- @touchstart="previous"
26
- circle
27
- icon="uil-angle-left"
28
- class="nav-button left"
29
- v-if="selected > 0 && showCommands"
30
- >
31
- </l-button>
32
- </transition>
33
- <transition name="el-notification-fade">
34
- <l-button
35
- @click="next"
36
- circle
37
- icon="uil-angle-right"
38
- class="nav-button right"
39
- v-if="selected < images.length - 1 && showCommands"
40
- >
41
- </l-button>
42
- </transition>
43
- <div class="row scroll-container" id="gallery-container" :style="{overflow: zoomed ? 'hidden' : 'auto'}">
44
- <div
45
- observer-targets
46
- class="image-container"
47
- @click="toggleCommands"
48
- @mousedown="updateMouseDown"
49
- @mouseup="updateMouseUp"
50
- v-for="(image, index) in images"
51
- :ref="`${image.id}-${index}`"
52
- :id="index"
53
- :key="index"
54
- >
55
- <v-zoomer :zoomed.sync="zoomed" class="image" ref="zoomer">
56
- <img class="image" :src="image.src"/>
57
- </v-zoomer>
58
- </div>
59
- </div>
60
- <div v-if="images.length" class="web-image-selector">
61
- <div class="carousel-container">
62
- <div
63
- class="fade-box left"
64
- ></div>
65
- <div
66
- class="carousel-inner"
67
- :style="{ transform: `translateX(${this.scale * 8.5}em)` }"
68
- >
69
- <div
70
- v-for="(image, index) in cards"
71
- :key="image.id"
72
- @click="select(index)"
73
- class="card"
74
- :class="{ selected: index == selected }"
75
- :data-scale="image.scale"
76
- >
77
- <img :src="image.src" style="width: 100%; height: 100%; object-fit: cover;" />
78
- </div>
79
- </div>
80
- <div
81
- class="fade-box right"
82
- ></div>
83
- </div>
84
- </div>
85
- </div>
86
- </template>
87
-
88
- <script>
89
- let targets = null
90
-
91
- export default {
92
- tagName: "l-image-viewer",
93
- name: "LImageViewer",
94
-
95
- props: ["images", "index"],
96
-
97
- data: function () {
98
- return {
99
- selected: 0,
100
- cards: [],
101
- scale: 0,
102
- showCommands: true,
103
- latestTap: 0,
104
- lastMouseUp: 0,
105
- lastMouseDown: 0,
106
- zoomed: false,
107
- }
108
- },
109
-
110
- mounted() {
111
- targets = document.querySelectorAll('[observer-targets]')
112
- this.intersectionObserver = new IntersectionObserver((event) => this.onChangeVisibility(event[0]), {
113
- threshold: [0.9, 1],
114
- })
115
-
116
- targets.forEach(target => {
117
- this.intersectionObserver.observe(target)
118
- })
119
-
120
- const initialIndex = parseInt(this.index) || 0
121
- this.cards = this.images.map((image, index) => {
122
- image.scale = index
123
- return image
124
- })
125
-
126
- this.scale = 2 - (this.index)
127
-
128
- this.slideAndScale()
129
-
130
- this.select(initialIndex)
131
- },
132
-
133
- beforeDestroy() {
134
- this.intersectionObserver.disconnect;
135
- },
136
-
137
- methods: {
138
- onChangeVisibility(event) {
139
- if (event.isIntersecting) {
140
- this.selected = Number(event.target.id)
141
- }
142
- },
143
-
144
- toggleCommands() {
145
- let now = new Date().getTime();
146
- let timesince = now - this.latestTap;
147
- let clickDuration = this.lastMouseUp - this.lastMouseDown
148
- if((timesince > 700 || timesince < 0 ) && clickDuration < 100){
149
- this.showCommands = !this.showCommands
150
- } else if (clickDuration > 1500) {
151
- this.download()
152
- }
153
-
154
- this.latestTap = new Date().getTime();
155
- },
156
-
157
- updateMouseUp(){
158
- this.lastMouseUp = new Date().getTime()
159
- },
160
-
161
- updateMouseDown() {
162
- this.lastMouseDown = new Date().getTime()
163
- },
164
-
165
- back() {
166
- this.$emit("close", null);
167
- },
168
-
169
- download: async function () {
170
- const selectedImage = this.images[this.selected]
171
- const LayersPortal = window.LayersPortal
172
- if (LayersPortal) {
173
- await LayersPortal('download', {
174
- url: selectedImage.src,
175
- name: selectedImage.name,
176
- })
177
- } else {
178
- window.open(selectedImage.src);
179
- }
180
- },
181
-
182
- previous() {
183
- if(this.selected <= 0) return
184
-
185
- document.getElementById('gallery-container').scrollTo({
186
- left: Math.abs(window.innerWidth - (window.innerWidth*(this.selected))),
187
- behavior: 'smooth'
188
- })
189
-
190
- if (this.cards[0].scale < 2) {
191
- this.scale++
192
- }
193
- this.lastMouseDown = 0
194
- this.slideAndScale()
195
- },
196
-
197
- next() {
198
- if(this.selected >= targets.length - 1) return
199
-
200
- document.getElementById('gallery-container').scrollTo({
201
- left: window.innerWidth*(this.selected + 1),
202
- behavior: 'smooth'
203
- })
204
-
205
- if (this.cards[this.cards.length - 1].scale != 2) {
206
- this.scale--
207
- }
208
-
209
- this.lastMouseDown = 0
210
- this.slideAndScale()
211
- },
212
-
213
- select(index) {
214
- if(index > this.selected) {
215
- document.getElementById('gallery-container').scrollTo({
216
- left: window.innerWidth*(index),
217
- behavior: 'smooth'
218
- })
219
- }
220
-
221
- if(index < this.selected) {
222
- document.getElementById('gallery-container').scrollTo({
223
- left: Math.abs(window.innerWidth - (window.innerWidth*(index + 1))),
224
- behavior: 'smooth'
225
- })
226
- }
227
-
228
- const selectedCardScale = this.cards[index].scale;
229
- if (selectedCardScale !== 2) {
230
- this.scale -= selectedCardScale - 2;
231
- this.slideAndScale();
232
- }
233
-
234
- },
235
-
236
- slideAndScale: function () {
237
- this.cards.map((card, i) => {
238
- card.scale = i + this.scale;
239
- });
240
- },
241
- },
242
-
243
- watch: {
244
- selected: function(current, previous) {
245
- this.$refs.zoomer[previous].reset()
246
- }
247
- }
248
- };
249
- </script>
250
-
251
- <style scoped>
252
- .image-viewer {
253
- display: flex;
254
- flex-direction: column;
255
- height: 100%;
256
- width: 100vw;
257
- }
258
-
259
- .header {
260
- display: flex;
261
- flex: 1 1 auto;
262
- flex-direction: row;
263
- justify-content: space-between;
264
- align-items: center;
265
- height: 56px;
266
- transition: max-height 0.3s ease-out;
267
- max-height: 60px;
268
- margin-right: 16px;
269
- margin-left: 16px;
270
- }
271
-
272
- .header.colapsed {
273
- max-height: 0;
274
- }
275
-
276
- .header-button {
277
- border: none !important;
278
- font-size: 24px !important;
279
- }
280
-
281
- .nav-button {
282
- position: absolute;
283
- top: 50%;
284
- z-index: 99999;
285
- height: 32px;
286
- width: 32px;
287
- }
288
-
289
- .nav-button.right {
290
- right: 10%;
291
- }
292
-
293
- .nav-button.left {
294
- left: 10%;
295
- }
296
-
297
-
298
- .image-container {
299
- display: flex;
300
- flex: 1 1 auto;
301
- min-width: 100vw;
302
- flex-direction: column;
303
- scroll-snap-align: center;
304
- scroll-snap-stop: always;
305
- }
306
-
307
- .translate {
308
- transform: translateX(0, 100vw);
309
- }
310
-
311
- .image {
312
- height: 100%;
313
- width: 100%;
314
- object-fit: contain;
315
- }
316
-
317
- .vue-zoomer {
318
- height: 100% !important;
319
- }
320
-
321
- .border-none {
322
- border: none;
323
- }
324
-
325
- .card {
326
- font-family: sans-serif;
327
- line-height: 120px;
328
- width: 120px;
329
- height: 120px;
330
- background: white;
331
- border-radius: 4px;
332
- overflow: hidden;
333
- display: inline-block;
334
- margin: 0 10px;
335
- position: relative;
336
- bottom: -1.2em;
337
- transition: transform 0.3s ease, background 0.2s ease, box-shadow 0.2s ease;
338
- cursor: pointer;
339
- }
340
-
341
- .card[data-scale="0"],
342
- .card[data-scale="4"] {
343
- transform: scale(1);
344
- z-index: 0;
345
- }
346
- .card[data-scale="1"],
347
- .card[data-scale="3"] {
348
- transform: scale(1.05);
349
- z-index: 1;
350
- }
351
- .card[data-scale="2"] {
352
- transform: scale(1.1);
353
- z-index: 2;
354
- }
355
-
356
- .selected {
357
- box-shadow: 0 0 0 4px var(--aqua);
358
- }
359
-
360
- .web-image-selector {
361
- display: flex;
362
- min-height: 170px;
363
- max-height: 170px;
364
- margin-top: 10px;
365
- }
366
-
367
- .carousel-container {
368
- position: relative;
369
- white-space: nowrap;
370
- overflow-x: hidden;
371
- height: 100%;
372
- width: 41.5em;
373
- margin: auto;
374
- transform: translateY((-0.6 * 120px));
375
- }
376
-
377
- .carousel-inner {
378
- position: absolute;
379
- transition: transform 0.3s ease;
380
- }
381
-
382
- .fade-box {
383
- position: absolute;
384
- top: 0;
385
- height: 170px;
386
- width: 100px;
387
- z-index: 10;
388
- bottom: -1.2em;
389
- }
390
-
391
- .fade-box.right {
392
- right: 0;
393
- background-image: linear-gradient(
394
- 270deg,
395
- #ffffff 45.07%,
396
- rgba(255, 255, 255, 0) 100%
397
- );
398
- }
399
-
400
- .fade-box.left {
401
- left: 0;
402
- background: linear-gradient(
403
- 90deg,
404
- #ffffff 31.57%,
405
- rgba(255, 255, 255, 0) 100%
406
- );
407
- }
408
-
409
- .scroll-container {
410
- background-color: white;
411
- padding: 0px;
412
- transition: all 0.3s ease-out;
413
- scroll-snap-type: x mandatory;
414
- overflow: auto;
415
- position: relative;
416
- width: 100%;
417
- height: auto;
418
- z-index: 1;
419
- display: flex;
420
- flex: 1 1 auto;
421
- transition-property: transform;
422
- box-sizing: content-box;
423
- touch-action: pan-x pinch-zoom;
424
- -ms-overflow-style: none; /* IE and Edge */
425
- scrollbar-width: none; /* Firefox */
426
- }
427
-
428
- .scroll-container::-webkit-scrollbar {
429
- display: none;
430
- }
431
-
432
- @media (max-width: 768px) {
433
- .web-image-selector {
434
- display: none !important;
435
- }
436
-
437
- .image {
438
- margin: 0px;
439
- }
440
-
441
- .nav-button.right {
442
- right: 16px;
443
- }
444
-
445
- .nav-button.left {
446
- left: 16px;
447
- }
448
- }
449
- </style>
@@ -1,43 +0,0 @@
1
- <template>
2
- <div id="app">
3
- <h1>Input</h1>
4
-
5
- <div>
6
- <h3>Basic</h3>
7
- <div class="row">
8
- <l-input placeholder="Please input" v-model="input"></l-input>
9
- </div>
10
- </div>
11
-
12
- <div>
13
- <h3>Original (from Element UI)</h3>
14
- <el-input placeholder="Please input" v-model="input"></el-input>
15
- </div>
16
-
17
- <div>
18
- <h3>Error</h3>
19
- <div class="row">
20
- <l-input
21
- v-model="input"
22
- prefix-icon="uil-map-marker"
23
- suffix-icon="uil-angle-right"
24
- placeholder="Please input"
25
- :error="true"
26
- error-message="Este input é obrigatório"
27
- ></l-input>
28
- </div>
29
- </div>
30
-
31
- </div>
32
- </template>
33
-
34
- <script>
35
- export default {
36
- name: 'Input',
37
- data() {
38
- return {
39
- input: ''
40
- }
41
- }
42
- };
43
- </script>
@@ -1,60 +0,0 @@
1
- <template functional>
2
- <div class="l-input-wrapper"
3
- :style="[
4
- data.style,
5
- data.staticStyle
6
- ]"
7
- :class="[
8
- data.class,
9
- data.staticClass,
10
- ]">
11
- <el-input
12
- v-bind="data.attrs"
13
- v-on="listeners"
14
- class="l-input"
15
- :class="{ 'l-input-error': props.error }"
16
- >
17
- <slot />
18
- </el-input>
19
- <div class="l-input-error-message" v-if="props.errorMessage">
20
- {{ props.errorMessage }}
21
- </div>
22
- </div>
23
- </template>
24
- <script>
25
- import Vue from "vue"
26
- import { Input } from "element-ui"
27
- Vue.component(Input.name, Input)
28
-
29
- export default {
30
- tagName: "l-input",
31
- name: 'Linput'
32
- }
33
- </script>
34
-
35
- <style type="text/css">
36
- .l-input-error > .el-input__inner {
37
- border: 1px solid var(--color-danger);
38
- }
39
- .l-input.l-input-error .el-input__prefix {
40
- color: var(--color-danger);
41
- }
42
- .l-input-error-message {
43
- color: var(--color-danger);
44
- font-weight: 600;
45
- font-size: 12px;
46
- line-height: 130%;
47
- margin-top: 2px;
48
- }
49
- .l-input.el-input--prefix .el-input__inner {
50
- padding-left: 42px;
51
- }
52
- .l-input .el-input__prefix {
53
- left: 12px;
54
- color: var(--color-grey-80);
55
- }
56
- .l-input .el-input__prefix .el-input__icon,
57
- .l-input .el-input__suffix .el-input__icon {
58
- font-size: 20px;
59
- }
60
- </style>
@@ -1,21 +0,0 @@
1
- <template>
2
- <div id="app">
3
- <h1>Linear Progress</h1>
4
-
5
- <div>
6
- <div class="row">
7
- <l-linear-progress />
8
- </div>
9
- </div>
10
- </div>
11
- </template>
12
-
13
- <script>
14
- export default {
15
- name: "LinearProgress"
16
- };
17
- </script>
18
-
19
- <style scoped>
20
-
21
- </style>
@@ -1,74 +0,0 @@
1
- <template functional>
2
- <div
3
- class="l-linear-progress"
4
- :style="[
5
- data.style,
6
- data.staticStyle,
7
- { 'height': props.height + 'px' },
8
- ]"
9
- :class="[
10
- data.class,
11
- data.staticClass,
12
- ]">
13
- <div class="l-linear-progress-background" :style="{ '--color': parent.$L.getColor(props.background) }"></div>
14
- <div class="l-linear-progress-indeterminate"
15
- :style="{ '--color': parent.$L.getColor(props.color) }"
16
- :class="[props.color]">
17
- </div>
18
- </div>
19
- </template>
20
- <script>
21
- export default {
22
- tagName: "l-linear-progress",
23
- props: {
24
- color: { type: String, default: () => 'rainbow' },
25
- background: { type: String, default: () => 'transparent' },
26
- height: { type: Number, default: () => 4 },
27
- },
28
- };
29
- </script>
30
- <style>
31
- .l-linear-progress {
32
- width: 100%;
33
- height: 4px;
34
- background: transparent;
35
- overflow: hidden;
36
- position: relative;
37
- transition: .2s cubic-bezier(.4,0,.6,1);
38
- }
39
- .l-linear-progress .rainbow {
40
- background: linear-gradient(90deg, #00B8AD 0%, #5451D6 33.19%, #F97777 50%, #FFCA65 90%, #FFCA65 100%);
41
- }
42
- .l-linear-progress-indeterminate {
43
- height: inherit;
44
- left: 0;
45
- right: auto;
46
- animation-iteration-count: infinite;
47
- bottom: 0;
48
- height: inherit;
49
- position: absolute;
50
- top: 0;
51
- width: auto;
52
- will-change: left,right;
53
- animation-name: indeterminate;
54
- animation-duration: 1.2s;
55
- animation-delay: 0.2s;
56
- left: -100%;
57
- right: 100%;
58
- }
59
- @keyframes indeterminate {
60
- 0% {
61
- right:100%;
62
- left:-100%;
63
- }
64
- 40% {
65
- right:-10%;
66
- left:-50%;
67
- }
68
- to {
69
- right:-10%;
70
- left:100%;
71
- }
72
- }
73
-
74
- </style>
@@ -1,26 +0,0 @@
1
- <template>
2
- <div>
3
- <h1>Notice</h1>
4
-
5
- <l-notice type="danger">
6
- Texto do problemão.
7
- <br />Texto do problemão.
8
- </l-notice>
9
- <l-notice type="warning">Texto do probleminha.</l-notice>
10
- <l-notice type="success">Texto de sucesso.</l-notice>
11
- <l-notice color="purple" icon="uil-sync">Texto texto texto texto.</l-notice>
12
- <l-notice color="danger" outline :fill="false" :show-icon="false">Texto texto texto texto.</l-notice>
13
- </div>
14
- </template>
15
-
16
- <script>
17
- export default {
18
- name: "Notice"
19
- };
20
- </script>
21
-
22
- <style scoped>
23
- .l-notice {
24
- margin-bottom: 20px;
25
- }
26
- </style>