@nuraly/lumenui 0.1.0 → 0.2.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.
- package/dist/nuralyui.bundle.js +23024 -17355
- package/dist/nuralyui.bundle.js.gz +0 -0
- package/dist/src/components/alert/alert.component.d.ts +8 -5
- package/dist/src/components/alert/alert.component.js +24 -20
- package/dist/src/components/alert/alert.style.d.ts +0 -7
- package/dist/src/components/alert/alert.style.js +48 -90
- package/dist/src/components/alert/bundle.js +82 -108
- package/dist/src/components/alert/bundle.js.gz +0 -0
- package/dist/src/components/badge/badge.component.d.ts +9 -8
- package/dist/src/components/badge/badge.component.js +17 -14
- package/dist/src/components/badge/badge.style.d.ts +0 -7
- package/dist/src/components/badge/badge.style.js +49 -107
- package/dist/src/components/badge/bundle.js +81 -119
- package/dist/src/components/badge/bundle.js.gz +0 -0
- package/dist/src/components/breadcrumb/breadcrumb.component.d.ts +8 -10
- package/dist/src/components/breadcrumb/breadcrumb.component.js +16 -15
- package/dist/src/components/breadcrumb/breadcrumb.style.d.ts +0 -7
- package/dist/src/components/breadcrumb/breadcrumb.style.js +42 -60
- package/dist/src/components/breadcrumb/bundle.js +96 -93
- package/dist/src/components/breadcrumb/bundle.js.gz +0 -0
- package/dist/src/components/button/bundle.js +221 -470
- package/dist/src/components/button/bundle.js.gz +0 -0
- package/dist/src/components/button/button.component.d.ts +2 -1
- package/dist/src/components/button/button.component.js +6 -6
- package/dist/src/components/button/button.style.d.ts +0 -7
- package/dist/src/components/button/button.style.js +167 -433
- package/dist/src/components/canvas/base-canvas.component.d.ts +2 -1
- package/dist/src/components/canvas/base-canvas.component.js +1 -0
- package/dist/src/components/canvas/bundle.js +16919 -9595
- package/dist/src/components/canvas/bundle.js.gz +0 -0
- package/dist/src/components/canvas/canvas.constants.d.ts +1 -1
- package/dist/src/components/canvas/canvas.constants.js +1 -1
- package/dist/src/components/canvas/chatbot-panel.style.js +31 -31
- package/dist/src/components/canvas/index.d.ts +2 -0
- package/dist/src/components/canvas/index.js +3 -0
- package/dist/src/components/canvas/whiteboard-canvas.component.d.ts +3 -1
- package/dist/src/components/canvas/whiteboard-canvas.component.js +19 -1
- package/dist/src/components/canvas/whiteboard-canvas.style.js +159 -138
- package/dist/src/components/canvas/whiteboard-node.component.d.ts +2 -1
- package/dist/src/components/canvas/whiteboard-node.component.js +2 -1
- package/dist/src/components/canvas/whiteboard-node.style.js +44 -44
- package/dist/src/components/canvas/workflow-canvas-only.d.ts +4 -0
- package/dist/src/components/canvas/workflow-canvas-only.js +5 -0
- package/dist/src/components/canvas/workflow-canvas.component.d.ts +3 -1
- package/dist/src/components/canvas/workflow-canvas.component.js +24 -2
- package/dist/src/components/canvas/workflow-canvas.style.js +776 -648
- package/dist/src/components/canvas/workflow-canvas.types.d.ts +113 -4
- package/dist/src/components/canvas/workflow-canvas.types.js +646 -3
- package/dist/src/components/canvas/workflow-node.component.d.ts +3 -2
- package/dist/src/components/canvas/workflow-node.component.js +5 -5
- package/dist/src/components/canvas/workflow-node.style.js +183 -181
- package/dist/src/components/card/bundle.js +43 -35
- package/dist/src/components/card/bundle.js.gz +0 -0
- package/dist/src/components/card/card.component.d.ts +6 -1
- package/dist/src/components/card/card.component.js +8 -2
- package/dist/src/components/card/card.style.js +26 -30
- package/dist/src/components/carousel/bundle.js +8 -8
- package/dist/src/components/carousel/bundle.js.gz +0 -0
- package/dist/src/components/carousel/carousel.component.d.ts +12 -0
- package/dist/src/components/carousel/carousel.component.js +16 -4
- package/dist/src/components/chatbot/bundle.js +422 -406
- package/dist/src/components/chatbot/bundle.js.gz +0 -0
- package/dist/src/components/chatbot/chatbot.component.d.ts +2 -1
- package/dist/src/components/chatbot/chatbot.component.js +1 -0
- package/dist/src/components/chatbot/chatbot.style.js +277 -277
- package/dist/src/components/checkbox/bundle.js +86 -245
- package/dist/src/components/checkbox/bundle.js.gz +0 -0
- package/dist/src/components/checkbox/checkbox.component.d.ts +5 -2
- package/dist/src/components/checkbox/checkbox.component.js +11 -13
- package/dist/src/components/checkbox/checkbox.style.js +56 -231
- package/dist/src/components/code-editor/bundle.js +151 -25
- package/dist/src/components/code-editor/bundle.js.gz +0 -0
- package/dist/src/components/code-editor/code-editor.component.d.ts +18 -56
- package/dist/src/components/code-editor/code-editor.component.js +141 -394
- package/dist/src/components/code-editor/code-editor.style.js +139 -15
- package/dist/src/components/collapse/bundle.js +97 -84
- package/dist/src/components/collapse/bundle.js.gz +0 -0
- package/dist/src/components/collapse/collapse.component.d.ts +7 -1
- package/dist/src/components/collapse/collapse.component.js +11 -2
- package/dist/src/components/collapse/collapse.style.js +60 -60
- package/dist/src/components/colorpicker/bundle.js +85 -48
- package/dist/src/components/colorpicker/bundle.js.gz +0 -0
- package/dist/src/components/colorpicker/color-holder.component.d.ts +2 -4
- package/dist/src/components/colorpicker/color-holder.component.js +5 -6
- package/dist/src/components/colorpicker/color-holder.style.js +11 -11
- package/dist/src/components/colorpicker/color-picker.component.d.ts +2 -1
- package/dist/src/components/colorpicker/color-picker.component.js +1 -0
- package/dist/src/components/colorpicker/color-picker.style.js +12 -12
- package/dist/src/components/colorpicker/default-color-sets.component.d.ts +2 -2
- package/dist/src/components/colorpicker/default-color-sets.component.js +4 -3
- package/dist/src/components/colorpicker/default-color-sets.style.js +5 -5
- package/dist/src/components/container/bundle.js +24 -14
- package/dist/src/components/container/bundle.js.gz +0 -0
- package/dist/src/components/container/container.component.d.ts +4 -1
- package/dist/src/components/container/container.component.js +7 -5
- package/dist/src/components/container/container.style.js +9 -9
- package/dist/src/components/datepicker/bundle.js +193 -177
- package/dist/src/components/datepicker/bundle.js.gz +0 -0
- package/dist/src/components/datepicker/datepicker.component.d.ts +2 -1
- package/dist/src/components/datepicker/datepicker.component.js +1 -0
- package/dist/src/components/datepicker/datepicker.style.js +65 -65
- package/dist/src/components/datepicker/datepicker.style.variables.js +91 -91
- package/dist/src/components/db-connection-select/bundle.js +7 -6
- package/dist/src/components/db-connection-select/bundle.js.gz +0 -0
- package/dist/src/components/db-connection-select/db-connection-select.component.d.ts +3 -0
- package/dist/src/components/db-connection-select/db-connection-select.component.js +4 -0
- package/dist/src/components/divider/bundle.js +61 -35
- package/dist/src/components/divider/bundle.js.gz +0 -0
- package/dist/src/components/divider/divider.component.d.ts +4 -6
- package/dist/src/components/divider/divider.component.js +10 -14
- package/dist/src/components/divider/divider.style.js +41 -31
- package/dist/src/components/document/bundle.js +50 -48
- package/dist/src/components/document/bundle.js.gz +0 -0
- package/dist/src/components/document/document.component.d.ts +12 -1
- package/dist/src/components/document/document.component.js +18 -6
- package/dist/src/components/document/document.style.js +21 -36
- package/dist/src/components/dropdown/bundle.js +117 -101
- package/dist/src/components/dropdown/bundle.js.gz +0 -0
- package/dist/src/components/dropdown/dropdown.component.d.ts +2 -1
- package/dist/src/components/dropdown/dropdown.component.js +1 -0
- package/dist/src/components/dropdown/dropdown.style.js +68 -68
- package/dist/src/components/file-upload/bundle.js +82 -76
- package/dist/src/components/file-upload/bundle.js.gz +0 -0
- package/dist/src/components/file-upload/file-upload.component.d.ts +2 -1
- package/dist/src/components/file-upload/file-upload.component.js +1 -0
- package/dist/src/components/file-upload/styles.js +59 -59
- package/dist/src/components/flex/bundle.js +18 -8
- package/dist/src/components/flex/bundle.js.gz +0 -0
- package/dist/src/components/flex/flex.component.d.ts +4 -1
- package/dist/src/components/flex/flex.component.js +7 -4
- package/dist/src/components/flex/flex.style.js +2 -2
- package/dist/src/components/form/bundle.js +22 -10
- package/dist/src/components/form/bundle.js.gz +0 -0
- package/dist/src/components/form/form.component.d.ts +4 -1
- package/dist/src/components/form/form.component.js +5 -1
- package/dist/src/components/form/form.style.js +2 -2
- package/dist/src/components/grid/bundle.js +26 -14
- package/dist/src/components/grid/bundle.js.gz +0 -0
- package/dist/src/components/grid/col.component.d.ts +4 -1
- package/dist/src/components/grid/col.component.js +4 -1
- package/dist/src/components/grid/col.style.js +2 -2
- package/dist/src/components/grid/row.component.d.ts +4 -1
- package/dist/src/components/grid/row.component.js +4 -1
- package/dist/src/components/grid/row.style.js +2 -2
- package/dist/src/components/icon/bundle.js +78 -252
- package/dist/src/components/icon/bundle.js.gz +0 -0
- package/dist/src/components/icon/icon-paths.d.ts +2 -0
- package/dist/src/components/icon/icon-paths.js +141 -0
- package/dist/src/components/icon/icon.component.d.ts +10 -12
- package/dist/src/components/icon/icon.component.js +42 -93
- package/dist/src/components/icon/icon.style.js +42 -130
- package/dist/src/components/icon/icon.variables.js +9 -9
- package/dist/src/components/iconpicker/bundle.js +859 -1511
- package/dist/src/components/iconpicker/bundle.js.gz +0 -0
- package/dist/src/components/iconpicker/icon-picker.component.d.ts +2 -1
- package/dist/src/components/iconpicker/icon-picker.component.js +1 -0
- package/dist/src/components/iconpicker/icon-picker.style.js +13 -13
- package/dist/src/components/image/bundle.js +43 -33
- package/dist/src/components/image/bundle.js.gz +0 -0
- package/dist/src/components/image/image.component.d.ts +10 -1
- package/dist/src/components/image/image.component.js +13 -3
- package/dist/src/components/image/image.style.js +19 -26
- package/dist/src/components/input/bundle.js +420 -644
- package/dist/src/components/input/bundle.js.gz +0 -0
- package/dist/src/components/input/input.component.d.ts +16 -3
- package/dist/src/components/input/input.component.js +43 -27
- package/dist/src/components/input/input.style.d.ts +1 -1
- package/dist/src/components/input/input.style.js +331 -634
- package/dist/src/components/kv-secret-select/bundle.js +2 -1
- package/dist/src/components/kv-secret-select/bundle.js.gz +0 -0
- package/dist/src/components/kv-secret-select/kv-secret-select.component.d.ts +3 -0
- package/dist/src/components/kv-secret-select/kv-secret-select.component.js +4 -0
- package/dist/src/components/label/bundle.js +37 -60
- package/dist/src/components/label/bundle.js.gz +0 -0
- package/dist/src/components/label/label.component.d.ts +8 -4
- package/dist/src/components/label/label.component.js +9 -14
- package/dist/src/components/label/label.style.js +17 -25
- package/dist/src/components/label/label.style.variables.js +18 -18
- package/dist/src/components/layout/bundle.js +86 -70
- package/dist/src/components/layout/bundle.js.gz +0 -0
- package/dist/src/components/layout/content.component.d.ts +2 -1
- package/dist/src/components/layout/content.component.js +2 -1
- package/dist/src/components/layout/content.style.js +3 -3
- package/dist/src/components/layout/footer.component.d.ts +2 -1
- package/dist/src/components/layout/footer.component.js +3 -2
- package/dist/src/components/layout/footer.style.js +7 -7
- package/dist/src/components/layout/header.component.d.ts +2 -1
- package/dist/src/components/layout/header.component.js +3 -2
- package/dist/src/components/layout/header.style.js +7 -7
- package/dist/src/components/layout/layout.component.d.ts +4 -7
- package/dist/src/components/layout/layout.component.js +9 -22
- package/dist/src/components/layout/layout.style.js +1 -1
- package/dist/src/components/layout/sider.component.d.ts +3 -1
- package/dist/src/components/layout/sider.component.js +3 -1
- package/dist/src/components/layout/sider.style.js +29 -29
- package/dist/src/components/menu/bundle.js +135 -125
- package/dist/src/components/menu/bundle.js.gz +0 -0
- package/dist/src/components/menu/menu.component.d.ts +2 -1
- package/dist/src/components/menu/menu.component.js +1 -0
- package/dist/src/components/menu/menu.style.js +87 -87
- package/dist/src/components/modal/bundle.js +105 -96
- package/dist/src/components/modal/bundle.js.gz +0 -0
- package/dist/src/components/modal/modal.component.d.ts +2 -1
- package/dist/src/components/modal/modal.component.js +1 -0
- package/dist/src/components/modal/modal.style.js +69 -71
- package/dist/src/components/panel/bundle.js +190 -391
- package/dist/src/components/panel/bundle.js.gz +0 -0
- package/dist/src/components/panel/panel.component.d.ts +2 -1
- package/dist/src/components/panel/panel.component.js +1 -0
- package/dist/src/components/panel/panel.style.js +65 -65
- package/dist/src/components/popconfirm/bundle.js +107 -93
- package/dist/src/components/popconfirm/bundle.js.gz +0 -0
- package/dist/src/components/popconfirm/popconfirm-manager.component.d.ts +2 -1
- package/dist/src/components/popconfirm/popconfirm-manager.component.js +1 -0
- package/dist/src/components/popconfirm/popconfirm-manager.style.js +16 -16
- package/dist/src/components/popconfirm/popconfirm.component.d.ts +2 -1
- package/dist/src/components/popconfirm/popconfirm.component.js +9 -5
- package/dist/src/components/popconfirm/popconfirm.style.js +43 -43
- package/dist/src/components/radio/bundle.js +56 -86
- package/dist/src/components/radio/bundle.js.gz +0 -0
- package/dist/src/components/radio/radio.component.d.ts +8 -2
- package/dist/src/components/radio/radio.component.js +17 -9
- package/dist/src/components/radio/radio.style.js +30 -77
- package/dist/src/components/radio-group/bundle.js +125 -89
- package/dist/src/components/radio-group/bundle.js.gz +0 -0
- package/dist/src/components/radio-group/radio-group.component.d.ts +5 -1
- package/dist/src/components/radio-group/radio-group.component.js +18 -10
- package/dist/src/components/radio-group/radio-group.style.js +44 -44
- package/dist/src/components/select/bundle.js +260 -367
- package/dist/src/components/select/bundle.js.gz +0 -0
- package/dist/src/components/select/select.component.d.ts +12 -17
- package/dist/src/components/select/select.component.js +35 -35
- package/dist/src/components/select/select.style.js +184 -324
- package/dist/src/components/skeleton/bundle.js +82 -162
- package/dist/src/components/skeleton/bundle.js.gz +0 -0
- package/dist/src/components/skeleton/skeleton.component.d.ts +10 -5
- package/dist/src/components/skeleton/skeleton.component.js +20 -7
- package/dist/src/components/skeleton/skeleton.style.js +34 -133
- package/dist/src/components/slider-input/bundle.js +89 -88
- package/dist/src/components/slider-input/bundle.js.gz +0 -0
- package/dist/src/components/slider-input/slider-input.component.d.ts +11 -0
- package/dist/src/components/slider-input/slider-input.component.js +20 -8
- package/dist/src/components/slider-input/slider-input.style.js +47 -47
- package/dist/src/components/slider-input/slider-input.style.variables.js +32 -32
- package/dist/src/components/table/bundle.js +149 -128
- package/dist/src/components/table/bundle.js.gz +0 -0
- package/dist/src/components/table/table.component.d.ts +2 -1
- package/dist/src/components/table/table.component.js +1 -0
- package/dist/src/components/table/table.style.js +79 -79
- package/dist/src/components/tabs/bundle.js +462 -663
- package/dist/src/components/tabs/bundle.js.gz +0 -0
- package/dist/src/components/tabs/tabs.component.d.ts +6 -1
- package/dist/src/components/tabs/tabs.component.js +8 -1
- package/dist/src/components/tabs/tabs.style.js +200 -201
- package/dist/src/components/tag/bundle.js +44 -36
- package/dist/src/components/tag/bundle.js.gz +0 -0
- package/dist/src/components/tag/tag.component.d.ts +7 -6
- package/dist/src/components/tag/tag.component.js +10 -19
- package/dist/src/components/tag/tag.style.js +20 -24
- package/dist/src/components/textarea/bundle.js +131 -94
- package/dist/src/components/textarea/bundle.js.gz +0 -0
- package/dist/src/components/textarea/textarea.component.d.ts +7 -1
- package/dist/src/components/textarea/textarea.component.js +10 -3
- package/dist/src/components/textarea/textarea.style.d.ts +1 -13
- package/dist/src/components/textarea/textarea.style.js +79 -91
- package/dist/src/components/timeline/bundle.js +71 -134
- package/dist/src/components/timeline/bundle.js.gz +0 -0
- package/dist/src/components/timeline/timeline.component.d.ts +9 -6
- package/dist/src/components/timeline/timeline.component.js +16 -13
- package/dist/src/components/timeline/timeline.style.d.ts +0 -7
- package/dist/src/components/timeline/timeline.style.js +41 -122
- package/dist/src/components/timepicker/bundle.js +196 -166
- package/dist/src/components/timepicker/bundle.js.gz +0 -0
- package/dist/src/components/timepicker/timepicker.component.d.ts +2 -1
- package/dist/src/components/timepicker/timepicker.component.js +1 -0
- package/dist/src/components/timepicker/timepicker.style.js +42 -42
- package/dist/src/components/timepicker/timepicker.style.variables.js +91 -91
- package/dist/src/components/toast/bundle.js +97 -81
- package/dist/src/components/toast/bundle.js.gz +0 -0
- package/dist/src/components/toast/toast.component.d.ts +2 -1
- package/dist/src/components/toast/toast.component.js +1 -0
- package/dist/src/components/toast/toast.style.js +62 -62
- package/dist/src/components/tooltips/bundle.js +10 -10
- package/dist/src/components/tooltips/bundle.js.gz +0 -0
- package/dist/src/components/tooltips/tooltips.component.d.ts +8 -0
- package/dist/src/components/tooltips/tooltips.component.js +9 -1
- package/dist/src/components/tooltips/tooltips.style.js +6 -6
- package/dist/src/components/video/bundle.js +47 -36
- package/dist/src/components/video/bundle.js.gz +0 -0
- package/dist/src/components/video/video.component.d.ts +12 -1
- package/dist/src/components/video/video.component.js +18 -6
- package/dist/src/components/video/video.style.js +18 -24
- package/package.json +25 -12
- package/packages/common/dist/VERSIONS.md +2 -2
- package/packages/common/dist/shared/base-mixin.d.ts +21 -19
- package/packages/common/dist/shared/base-mixin.d.ts.map +1 -1
- package/packages/common/dist/shared/base-mixin.js +102 -18
- package/packages/common/dist/shared/base-mixin.js.map +1 -1
- package/packages/common/dist/shared/index.d.ts +1 -0
- package/packages/common/dist/shared/index.d.ts.map +1 -1
- package/packages/common/dist/shared/index.js +2 -0
- package/packages/common/dist/shared/index.js.map +1 -1
- package/packages/common/dist/shared/style-injector.d.ts +11 -0
- package/packages/common/dist/shared/style-injector.d.ts.map +1 -0
- package/packages/common/dist/shared/style-injector.js +53 -0
- package/packages/common/dist/shared/style-injector.js.map +1 -0
- package/packages/common/dist/shared/theme-mixin.d.ts +2 -24
- package/packages/common/dist/shared/theme-mixin.d.ts.map +1 -1
- package/packages/common/dist/shared/theme-mixin.js +5 -38
- package/packages/common/dist/shared/theme-mixin.js.map +1 -1
- package/packages/themes/dist/default.css +0 -10
- package/packages/themes/dist/package.json +1 -1
|
@@ -2,15 +2,15 @@ import { css } from 'lit';
|
|
|
2
2
|
export const styles = css `
|
|
3
3
|
:host {
|
|
4
4
|
display: block;
|
|
5
|
-
font-family:
|
|
5
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
|
|
6
6
|
}
|
|
7
7
|
.upload {
|
|
8
8
|
width: 100%;
|
|
9
9
|
}
|
|
10
10
|
.upload-dragger {
|
|
11
|
-
background-color:
|
|
12
|
-
border: 1px dashed
|
|
13
|
-
border-radius:
|
|
11
|
+
background-color: #f8f9fa;
|
|
12
|
+
border: 1px dashed #d9d9d9;
|
|
13
|
+
border-radius: 6px;
|
|
14
14
|
box-sizing: border-box;
|
|
15
15
|
width: 100%;
|
|
16
16
|
height: 180px;
|
|
@@ -18,48 +18,48 @@ export const styles = css `
|
|
|
18
18
|
cursor: pointer;
|
|
19
19
|
position: relative;
|
|
20
20
|
overflow: hidden;
|
|
21
|
-
transition: border-color
|
|
21
|
+
transition: border-color 0.3s;
|
|
22
22
|
display: flex;
|
|
23
23
|
flex-direction: column;
|
|
24
24
|
justify-content: center;
|
|
25
25
|
align-items: center;
|
|
26
26
|
}
|
|
27
27
|
.upload-dragger:hover {
|
|
28
|
-
border-color:
|
|
28
|
+
border-color: #409eff;
|
|
29
29
|
}
|
|
30
30
|
.upload-dragger.is-dragover {
|
|
31
|
-
background-color:
|
|
32
|
-
border-color:
|
|
31
|
+
background-color: rgba(64, 158, 255, 0.06);
|
|
32
|
+
border-color: #409eff;
|
|
33
33
|
}
|
|
34
34
|
.upload-icon {
|
|
35
35
|
font-size: 28px;
|
|
36
|
-
color:
|
|
36
|
+
color: #c0c4cc;
|
|
37
37
|
margin-bottom: 8px;
|
|
38
38
|
}
|
|
39
39
|
.upload-text {
|
|
40
|
-
color:
|
|
41
|
-
font-size:
|
|
40
|
+
color: #606266;
|
|
41
|
+
font-size: 14px;
|
|
42
42
|
text-align: center;
|
|
43
43
|
padding: 0 12px;
|
|
44
44
|
}
|
|
45
45
|
.upload-tip {
|
|
46
|
-
font-size:
|
|
47
|
-
color:
|
|
46
|
+
font-size: 12px;
|
|
47
|
+
color: #909399;
|
|
48
48
|
margin-top: 7px;
|
|
49
49
|
padding: 0 12px;
|
|
50
50
|
}
|
|
51
51
|
.upload-button {
|
|
52
52
|
padding: 8px 16px;
|
|
53
|
-
background-color:
|
|
54
|
-
color:
|
|
53
|
+
background-color: #409eff;
|
|
54
|
+
color: white;
|
|
55
55
|
border: none;
|
|
56
|
-
border-radius:
|
|
56
|
+
border-radius: 4px;
|
|
57
57
|
cursor: pointer;
|
|
58
|
-
font-size:
|
|
59
|
-
transition: background-color
|
|
58
|
+
font-size: 14px;
|
|
59
|
+
transition: background-color 0.3s;
|
|
60
60
|
}
|
|
61
61
|
.upload-button:hover {
|
|
62
|
-
background-color:
|
|
62
|
+
background-color: #66b1ff;
|
|
63
63
|
}
|
|
64
64
|
.file-list {
|
|
65
65
|
margin-top: 10px;
|
|
@@ -69,9 +69,9 @@ export const styles = css `
|
|
|
69
69
|
display: flex;
|
|
70
70
|
align-items: center;
|
|
71
71
|
margin-bottom: 8px;
|
|
72
|
-
transition: all
|
|
72
|
+
transition: all 0.3s;
|
|
73
73
|
padding: 8px;
|
|
74
|
-
border-radius:
|
|
74
|
+
border-radius: 4px;
|
|
75
75
|
gap: 8px;
|
|
76
76
|
width: 100%;
|
|
77
77
|
box-sizing: border-box;
|
|
@@ -81,22 +81,22 @@ export const styles = css `
|
|
|
81
81
|
max-width: 100%;
|
|
82
82
|
}
|
|
83
83
|
.file-item:hover {
|
|
84
|
-
background-color:
|
|
84
|
+
background-color: #f8f9fa;
|
|
85
85
|
}
|
|
86
86
|
.file-name {
|
|
87
87
|
flex: 1;
|
|
88
88
|
white-space: nowrap;
|
|
89
89
|
overflow: hidden;
|
|
90
90
|
text-overflow: ellipsis;
|
|
91
|
-
color:
|
|
91
|
+
color: #606266;
|
|
92
92
|
min-width: 0;
|
|
93
93
|
max-width: 100%;
|
|
94
94
|
word-break: break-all;
|
|
95
95
|
width: 0;
|
|
96
96
|
}
|
|
97
97
|
.file-size {
|
|
98
|
-
color:
|
|
99
|
-
font-size:
|
|
98
|
+
color: #909399;
|
|
99
|
+
font-size: 12px;
|
|
100
100
|
flex-shrink: 0;
|
|
101
101
|
margin-left: 8px;
|
|
102
102
|
white-space: nowrap;
|
|
@@ -116,10 +116,10 @@ export const styles = css `
|
|
|
116
116
|
border: none;
|
|
117
117
|
padding: 4px;
|
|
118
118
|
cursor: pointer;
|
|
119
|
-
color:
|
|
119
|
+
color: #909399;
|
|
120
120
|
}
|
|
121
121
|
.file-actions button:hover {
|
|
122
|
-
color:
|
|
122
|
+
color: #409eff;
|
|
123
123
|
}
|
|
124
124
|
|
|
125
125
|
/* Dark theme support - using data-theme attribute */
|
|
@@ -128,80 +128,80 @@ export const styles = css `
|
|
|
128
128
|
/* Upload dragger - dark theme */
|
|
129
129
|
:host-context([data-theme*="dark"]) .upload-dragger,
|
|
130
130
|
:host([data-theme*="dark"]) .upload-dragger {
|
|
131
|
-
background-color:
|
|
132
|
-
border-color:
|
|
131
|
+
background-color: #262626;
|
|
132
|
+
border-color: #525252;
|
|
133
133
|
}
|
|
134
134
|
:host-context([data-theme*="dark"]) .upload-dragger:hover,
|
|
135
135
|
:host([data-theme*="dark"]) .upload-dragger:hover {
|
|
136
|
-
border-color:
|
|
136
|
+
border-color: #78a9ff;
|
|
137
137
|
}
|
|
138
138
|
:host-context([data-theme*="dark"]) .upload-dragger.is-dragover,
|
|
139
139
|
:host([data-theme*="dark"]) .upload-dragger.is-dragover {
|
|
140
140
|
background-color: rgba(120, 169, 255, 0.1);
|
|
141
|
-
border-color:
|
|
141
|
+
border-color: #78a9ff;
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
/* Upload icon - dark theme */
|
|
145
145
|
:host-context([data-theme*="dark"]) .upload-icon,
|
|
146
146
|
:host([data-theme*="dark"]) .upload-icon {
|
|
147
|
-
color:
|
|
147
|
+
color: #8d8d8d;
|
|
148
148
|
}
|
|
149
149
|
|
|
150
150
|
/* Upload text - dark theme */
|
|
151
151
|
:host-context([data-theme*="dark"]) .upload-text,
|
|
152
152
|
:host([data-theme*="dark"]) .upload-text {
|
|
153
|
-
color:
|
|
153
|
+
color: #f4f4f4;
|
|
154
154
|
}
|
|
155
155
|
|
|
156
156
|
/* Upload tip - dark theme */
|
|
157
157
|
:host-context([data-theme*="dark"]) .upload-tip,
|
|
158
158
|
:host([data-theme*="dark"]) .upload-tip {
|
|
159
|
-
color:
|
|
159
|
+
color: #8d8d8d;
|
|
160
160
|
}
|
|
161
161
|
|
|
162
162
|
/* File item - dark theme */
|
|
163
163
|
:host-context([data-theme*="dark"]) .file-item,
|
|
164
164
|
:host([data-theme*="dark"]) .file-item {
|
|
165
|
-
background-color:
|
|
166
|
-
border-radius:
|
|
165
|
+
background-color: #262626;
|
|
166
|
+
border-radius: 4px;
|
|
167
167
|
}
|
|
168
168
|
:host-context([data-theme*="dark"]) .file-item:hover,
|
|
169
169
|
:host([data-theme*="dark"]) .file-item:hover {
|
|
170
|
-
background-color:
|
|
170
|
+
background-color: #393939;
|
|
171
171
|
}
|
|
172
172
|
|
|
173
173
|
/* File name - dark theme */
|
|
174
174
|
:host-context([data-theme*="dark"]) .file-name,
|
|
175
175
|
:host([data-theme*="dark"]) .file-name {
|
|
176
|
-
color:
|
|
176
|
+
color: #f4f4f4;
|
|
177
177
|
}
|
|
178
178
|
|
|
179
179
|
/* File size - dark theme */
|
|
180
180
|
:host-context([data-theme*="dark"]) .file-size,
|
|
181
181
|
:host([data-theme*="dark"]) .file-size {
|
|
182
|
-
color:
|
|
182
|
+
color: #8d8d8d;
|
|
183
183
|
}
|
|
184
184
|
|
|
185
185
|
/* File actions - dark theme */
|
|
186
186
|
:host-context([data-theme*="dark"]) .file-actions button,
|
|
187
187
|
:host([data-theme*="dark"]) .file-actions button {
|
|
188
|
-
color:
|
|
188
|
+
color: #8d8d8d;
|
|
189
189
|
}
|
|
190
190
|
:host-context([data-theme*="dark"]) .file-actions button:hover,
|
|
191
191
|
:host([data-theme*="dark"]) .file-actions button:hover {
|
|
192
|
-
color:
|
|
192
|
+
color: #78a9ff;
|
|
193
193
|
}
|
|
194
194
|
|
|
195
195
|
/* File item SVG icons - dark theme */
|
|
196
196
|
:host-context([data-theme*="dark"]) .file-item > svg,
|
|
197
197
|
:host([data-theme*="dark"]) .file-item > svg {
|
|
198
|
-
color:
|
|
198
|
+
color: #8d8d8d;
|
|
199
199
|
}
|
|
200
200
|
|
|
201
201
|
/* Progress bar - dark theme */
|
|
202
202
|
:host-context([data-theme*="dark"]) .progress-bar,
|
|
203
203
|
:host([data-theme*="dark"]) .progress-bar {
|
|
204
|
-
background-color:
|
|
204
|
+
background-color: #525252;
|
|
205
205
|
}
|
|
206
206
|
|
|
207
207
|
/* Preview modal - dark theme */
|
|
@@ -214,7 +214,7 @@ export const styles = css `
|
|
|
214
214
|
.progress-bar {
|
|
215
215
|
height: 2px;
|
|
216
216
|
width: 100%;
|
|
217
|
-
background-color:
|
|
217
|
+
background-color: #e6e6e6;
|
|
218
218
|
margin-top: 4px;
|
|
219
219
|
position: relative;
|
|
220
220
|
border-radius: 2px;
|
|
@@ -222,7 +222,7 @@ export const styles = css `
|
|
|
222
222
|
}
|
|
223
223
|
.progress-inner {
|
|
224
224
|
height: 100%;
|
|
225
|
-
background-color:
|
|
225
|
+
background-color: #409eff;
|
|
226
226
|
position: absolute;
|
|
227
227
|
left: 0;
|
|
228
228
|
top: 0;
|
|
@@ -234,21 +234,21 @@ export const styles = css `
|
|
|
234
234
|
position: absolute;
|
|
235
235
|
right: 0;
|
|
236
236
|
top: -18px;
|
|
237
|
-
font-size:
|
|
238
|
-
color:
|
|
237
|
+
font-size: 12px;
|
|
238
|
+
color: #409eff;
|
|
239
239
|
}
|
|
240
240
|
|
|
241
241
|
.hidden {
|
|
242
242
|
display: none;
|
|
243
243
|
}
|
|
244
244
|
.success {
|
|
245
|
-
color:
|
|
245
|
+
color: #67c23a;
|
|
246
246
|
}
|
|
247
247
|
.error {
|
|
248
|
-
color:
|
|
248
|
+
color: #f56c6c;
|
|
249
249
|
}
|
|
250
250
|
.icon-delete {
|
|
251
|
-
color:
|
|
251
|
+
color: #f56c6c;
|
|
252
252
|
}
|
|
253
253
|
.file-preview {
|
|
254
254
|
width: 100%;
|
|
@@ -258,7 +258,7 @@ export const styles = css `
|
|
|
258
258
|
display: block;
|
|
259
259
|
max-width: 100%;
|
|
260
260
|
max-height: 200px;
|
|
261
|
-
border-radius:
|
|
261
|
+
border-radius: 4px;
|
|
262
262
|
object-fit: contain;
|
|
263
263
|
cursor: zoom-in;
|
|
264
264
|
}
|
|
@@ -268,11 +268,11 @@ export const styles = css `
|
|
|
268
268
|
left: 0;
|
|
269
269
|
width: 100%;
|
|
270
270
|
height: 100%;
|
|
271
|
-
background-color:
|
|
271
|
+
background-color: rgba(0, 0, 0, 0.7);
|
|
272
272
|
display: flex;
|
|
273
273
|
justify-content: center;
|
|
274
274
|
align-items: center;
|
|
275
|
-
z-index:
|
|
275
|
+
z-index: 1000;
|
|
276
276
|
}
|
|
277
277
|
.preview-modal img {
|
|
278
278
|
max-width: 90%;
|
|
@@ -283,7 +283,7 @@ export const styles = css `
|
|
|
283
283
|
position: absolute;
|
|
284
284
|
top: 20px;
|
|
285
285
|
right: 20px;
|
|
286
|
-
color:
|
|
286
|
+
color: white;
|
|
287
287
|
font-size: 30px;
|
|
288
288
|
background: none;
|
|
289
289
|
border: none;
|
|
@@ -291,7 +291,7 @@ export const styles = css `
|
|
|
291
291
|
}
|
|
292
292
|
.preview-icon {
|
|
293
293
|
padding: 4px;
|
|
294
|
-
color:
|
|
294
|
+
color: #409eff;
|
|
295
295
|
cursor: zoom-in;
|
|
296
296
|
}
|
|
297
297
|
|
|
@@ -306,14 +306,14 @@ export const styles = css `
|
|
|
306
306
|
@media (max-width: 600px) {
|
|
307
307
|
.upload-dragger {
|
|
308
308
|
height: 140px;
|
|
309
|
-
padding:
|
|
309
|
+
padding: 12px;
|
|
310
310
|
}
|
|
311
311
|
.upload-icon {
|
|
312
312
|
font-size: 24px;
|
|
313
313
|
}
|
|
314
314
|
.upload-text,
|
|
315
315
|
.upload-tip {
|
|
316
|
-
font-size:
|
|
316
|
+
font-size: 13px;
|
|
317
317
|
}
|
|
318
318
|
.file-item {
|
|
319
319
|
display: grid;
|
|
@@ -325,7 +325,7 @@ export const styles = css `
|
|
|
325
325
|
"actions actions";
|
|
326
326
|
gap: 4px 8px;
|
|
327
327
|
align-items: center;
|
|
328
|
-
padding:
|
|
328
|
+
padding: 8px;
|
|
329
329
|
width: 100%;
|
|
330
330
|
box-sizing: border-box;
|
|
331
331
|
overflow: hidden; /* Hide content that overflows */
|
|
@@ -366,7 +366,7 @@ export const styles = css `
|
|
|
366
366
|
}
|
|
367
367
|
.upload-button {
|
|
368
368
|
width: 100%;
|
|
369
|
-
font-size:
|
|
369
|
+
font-size: 16px;
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
372
|
`;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{css as e,
|
|
1
|
+
import{css as e,html as t,LitElement as i}from"lit";import{property as n,customElement as s}from"lit/decorators.js";const r=e`
|
|
2
2
|
:host {
|
|
3
3
|
display: block;
|
|
4
4
|
box-sizing: border-box;
|
|
@@ -7,9 +7,9 @@ import{css as e,LitElement as t,html as r}from"lit";import{property as n,customE
|
|
|
7
7
|
.nr-flex {
|
|
8
8
|
display: flex;
|
|
9
9
|
box-sizing: border-box;
|
|
10
|
-
|
|
10
|
+
|
|
11
11
|
/* Theme-aware */
|
|
12
|
-
color:
|
|
12
|
+
color: #161616;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
/* Inline flex */
|
|
@@ -92,23 +92,33 @@ import{css as e,LitElement as t,html as r}from"lit";import{property as n,customE
|
|
|
92
92
|
.nr-flex[data-align="stretch"] {
|
|
93
93
|
align-items: stretch;
|
|
94
94
|
}
|
|
95
|
-
|
|
95
|
+
`
|
|
96
|
+
/**
|
|
97
|
+
* @license
|
|
98
|
+
* Copyright 2023 Nuraly, Laabidi Aymen
|
|
99
|
+
* SPDX-License-Identifier: MIT
|
|
100
|
+
*/,o=e=>class extends e{constructor(){super(...arguments),this.handleSystemThemeChange=()=>{this.closest("[data-theme]")||document.documentElement.hasAttribute("data-theme")||this.requestUpdate()}}connectedCallback(){super.connectedCallback(),this.setupThemeObserver(),this.setupDesignSystemObserver(),this.setupSystemThemeListener()}disconnectedCallback(){var e,t,i;super.disconnectedCallback(),null===(e=this.themeObserver)||void 0===e||e.disconnect(),null===(t=this.designSystemObserver)||void 0===t||t.disconnect(),null===(i=this.mediaQuery)||void 0===i||i.removeEventListener("change",this.handleSystemThemeChange)}get currentTheme(){var e,t;const i=(null===(e=this.closest("[data-theme]"))||void 0===e?void 0:e.getAttribute("data-theme"))||document.documentElement.getAttribute("data-theme");return i||((null===(t=window.matchMedia)||void 0===t?void 0:t.call(window,"(prefers-color-scheme: dark)").matches)?"dark":"light")}get currentDesignSystem(){var e;const t=(null===(e=this.closest("[design-system]"))||void 0===e?void 0:e.getAttribute("design-system"))||document.documentElement.getAttribute("design-system");return"carbon"===t?t:"default"}setupThemeObserver(){this.themeObserver=new MutationObserver(()=>{this.requestUpdate()}),this.themeObserver.observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]})}setupDesignSystemObserver(){this.designSystemObserver=new MutationObserver(()=>{this.requestUpdate()}),this.designSystemObserver.observe(document.documentElement,{attributes:!0,attributeFilter:["design-system"]})}setupSystemThemeListener(){window.matchMedia&&(this.mediaQuery=window.matchMedia("(prefers-color-scheme: dark)"),this.mediaQuery.addEventListener("change",this.handleSystemThemeChange))}},a=()=>{var e;return void 0!==globalThis.litElementVersions||"undefined"!=typeof process&&"development"===(null===(e=process.env)||void 0===e?void 0:e.NODE_ENV)||"undefined"!=typeof window&&("localhost"===window.location.hostname||"127.0.0.1"===window.location.hostname)},l=e=>class extends e{constructor(){super(...arguments),this.requiredComponents=[]}validateDependencies(){if(a())for(const e of this.requiredComponents)if(!this.isComponentAvailable(e))throw new Error(`Required component "${e}" is not registered. Please import and register the component before using ${this.tagName.toLowerCase()}. Example: import '@nuralyui/${e}';`)}validateDependenciesWithHandler(e){if(!a())return!0;let t=!0;for(const i of this.requiredComponents)if(!this.isComponentAvailable(i)){t=!1;const n=new Error(`Required component "${i}" is not registered. Please import and register the component before using ${this.tagName.toLowerCase()}.`);e?e(i,n):console.error(n.message)}return t}isComponentAvailable(e){return!!customElements.get(e)}getMissingDependencies(){return this.requiredComponents.filter(e=>!this.isComponentAvailable(e))}areDependenciesAvailable(){return this.requiredComponents.every(e=>this.isComponentAvailable(e))}addRequiredComponent(e){this.requiredComponents.includes(e)||this.requiredComponents.push(e)}removeRequiredComponent(e){const t=this.requiredComponents.indexOf(e);t>-1&&this.requiredComponents.splice(t,1)}},d=e=>class extends e{dispatchCustomEvent(e,t){this.dispatchEvent(new CustomEvent(e,{detail:t,bubbles:!0,composed:!0}))}dispatchEventWithMetadata(e,t){var i;const n=Object.assign(Object.assign({},t),{timestamp:Date.now(),componentName:(null===(i=this.tagName)||void 0===i?void 0:i.toLowerCase())||"unknown"});this.dispatchCustomEvent(e,n)}dispatchInputEvent(e,t){const i=Object.assign({target:t.target||this,value:t.value,originalEvent:t.originalEvent},t);this.dispatchCustomEvent(e,i)}dispatchFocusEvent(e,t){const i=Object.assign({target:t.target||this,value:t.value,focused:t.focused,cursorPosition:t.cursorPosition,selectedText:t.selectedText},t);this.dispatchCustomEvent(e,i)}dispatchValidationEvent(e,t){var i;const n=Object.assign({target:t.target||this,value:t.value,isValid:null!==(i=t.isValid)&&void 0!==i&&i,error:t.error},t);this.dispatchCustomEvent(e,n)}dispatchActionEvent(e,t){const i=Object.assign({target:t.target||this,action:t.action,previousValue:t.previousValue,newValue:t.newValue},t);this.dispatchCustomEvent(e,i)}isReadonlyKeyAllowed(e){if(e.ctrlKey||e.metaKey){return["KeyA","KeyC"].includes(e.code)}return["Tab","Escape","ArrowLeft","ArrowRight","ArrowUp","ArrowDown","Home","End","PageUp","PageDown"].includes(e.key)}isActivationKey(e){return"Enter"===e.key||" "===e.key}},c=new Set,h=new Map;
|
|
96
101
|
/**
|
|
97
102
|
* @license
|
|
98
103
|
* Copyright 2023 Nuraly, Laabidi Aymen
|
|
99
104
|
* SPDX-License-Identifier: MIT
|
|
100
105
|
*/
|
|
101
|
-
|
|
106
|
+
const u=e=>{class t extends e{constructor(){super(...arguments),this.t=null}createRenderRoot(){return this.constructor.useShadowDom?super.createRenderRoot():this}connectedCallback(){const e=this.constructor.useShadowDom;if(!e&&null===this.t)for(this.t=[];this.firstChild;)this.t.push(this.removeChild(this.firstChild));if(super.connectedCallback(),!e){const e=this.constructor,t=this.tagName.toLowerCase(),i=e.styles;if(i){const e=f(i);e&&function(e,t,i){var n;if(!h.has(e)){const i=new CSSStyleSheet;i.replaceSync(t),h.set(e,i)}const s=h.get(e),r=`doc:${e}`;if(c.has(r)||(document.adoptedStyleSheets=[...document.adoptedStyleSheets,s],c.add(r)),i){let t=i;for(;t;){const i=t.getRootNode();if(!(i instanceof ShadowRoot))break;{const r=`shadow:${((null===(n=i.host)||void 0===n?void 0:n.tagName)||"").toLowerCase()}:${e}`;c.has(r)||(i.adoptedStyleSheets=[...i.adoptedStyleSheets,s],c.add(r)),t=i.host}}}}(t,e,this)}}}get lightChildren(){return this.t?this.t.filter(e=>!(e instanceof Element&&e.hasAttribute("slot"))):[]}lightChildrenNamed(e){return this.t?this.t.filter(t=>t instanceof Element&&t.getAttribute("slot")===e):[]}}return t.useShadowDom=!1,t};function f(e){return Array.isArray(e)?e.map(e=>f(e)).filter(Boolean).join("\n"):e&&"string"==typeof e.cssText?e.cssText:"string"==typeof e?e:""}const p="";
|
|
107
|
+
/**
|
|
108
|
+
* @license
|
|
109
|
+
* Copyright 2023 Nuraly, Laabidi Aymen
|
|
110
|
+
* SPDX-License-Identifier: MIT
|
|
111
|
+
*/var m=function(e,t,i,n){for(var s,r=arguments.length,o=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n,a=e.length-1;a>=0;a--)(s=e[a])&&(o=(r<3?s(o):r>3?s(t,i,o):s(t,i))||o);return r>3&&o&&Object.defineProperty(t,i,o),o};let v=class extends((e=>l(o(d(u(e)))))(i)){constructor(){super(...arguments),this.direction="row",this.vertical=!1,this.wrap="nowrap",this.justify="",this.align="",this.gap=0,this.inline=!1,this.flex=""}getFlexDirection(){return this.vertical?"column":this.direction}getGapValue(e){if("number"==typeof e)return`${e}px`;if("string"==typeof e)switch(e){case"small":return"8px";case"medium":return"16px";case"large":return"24px";default:return e}return"0"}getGapStyles(){const e={};if(Array.isArray(this.gap)){const[t,i]=this.gap;e["column-gap"]=this.getGapValue(t),e["row-gap"]=this.getGapValue(i)}else this.gap&&(e.gap=this.getGapValue(this.gap));return e}getFlexStyles(){const e=Object.assign({},this.getGapStyles());return this.flex&&(e.flex=this.flex),Object.entries(e).map(([e,t])=>`${e}: ${t}`).join("; ")}render(){const e=this.getFlexDirection(),i=this.getFlexStyles();return t`
|
|
102
112
|
<div
|
|
113
|
+
part="flex"
|
|
103
114
|
class="nr-flex"
|
|
104
115
|
data-direction="${e}"
|
|
105
116
|
data-wrap="${this.wrap}"
|
|
106
117
|
data-justify="${this.justify}"
|
|
107
118
|
data-align="${this.align}"
|
|
108
119
|
data-inline="${this.inline}"
|
|
109
|
-
|
|
110
|
-
style="${t}"
|
|
120
|
+
style="${i}"
|
|
111
121
|
>
|
|
112
122
|
<slot></slot>
|
|
113
123
|
</div>
|
|
114
|
-
`}};
|
|
124
|
+
`}};v.styles=r,v.useShadowDom=!0,m([n({type:String})],v.prototype,"direction",void 0),m([n({type:Boolean})],v.prototype,"vertical",void 0),m([n({type:String})],v.prototype,"wrap",void 0),m([n({type:String})],v.prototype,"justify",void 0),m([n({type:String})],v.prototype,"align",void 0),m([n({type:Object})],v.prototype,"gap",void 0),m([n({type:Boolean})],v.prototype,"inline",void 0),m([n({type:String})],v.prototype,"flex",void 0),v=m([s("nr-flex")],v);export{p as EMPTY_STRING,v as NrFlexElement};
|
|
Binary file
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { LitElement } from 'lit';
|
|
7
7
|
import { FlexDirection, FlexWrap, FlexJustify, FlexAlign, Gap } from './flex.types.js';
|
|
8
|
-
declare const NrFlexElement_base: (new (...args: any[]) => import("@nuralyui/common/mixins").DependencyAware) & (new (...args: any[]) => import("@nuralyui/common/mixins").ThemeAware) & (new (...args: any[]) => import("@nuralyui/common/mixins").EventHandlerCapable) & typeof LitElement;
|
|
8
|
+
declare const NrFlexElement_base: (new (...args: any[]) => import("@nuralyui/common/mixins").DependencyAware) & (new (...args: any[]) => import("@nuralyui/common/mixins").ThemeAware) & (new (...args: any[]) => import("@nuralyui/common/mixins").EventHandlerCapable) & (new (...args: any[]) => import("packages/common/src/shared/base-mixin.js").LightDomContent) & typeof LitElement;
|
|
9
9
|
/**
|
|
10
10
|
* Flex layout component for flexible box layouts
|
|
11
11
|
*
|
|
@@ -43,9 +43,12 @@ declare const NrFlexElement_base: (new (...args: any[]) => import("@nuralyui/com
|
|
|
43
43
|
* ```
|
|
44
44
|
*
|
|
45
45
|
* @slot default - Flex items
|
|
46
|
+
*
|
|
47
|
+
* @csspart flex - The inner div that applies flexbox direction, wrap, justify, align, and gap
|
|
46
48
|
*/
|
|
47
49
|
export declare class NrFlexElement extends NrFlexElement_base {
|
|
48
50
|
static styles: import("lit").CSSResult;
|
|
51
|
+
static useShadowDom: boolean;
|
|
49
52
|
/** Flex direction (shorthand: use vertical prop for column) */
|
|
50
53
|
direction: FlexDirection;
|
|
51
54
|
/** Shorthand for flex-direction: column */
|
|
@@ -51,6 +51,8 @@ import { EMPTY_STRING } from './flex.types.js';
|
|
|
51
51
|
* ```
|
|
52
52
|
*
|
|
53
53
|
* @slot default - Flex items
|
|
54
|
+
*
|
|
55
|
+
* @csspart flex - The inner div that applies flexbox direction, wrap, justify, align, and gap
|
|
54
56
|
*/
|
|
55
57
|
let NrFlexElement = class NrFlexElement extends NuralyUIBaseMixin(LitElement) {
|
|
56
58
|
constructor() {
|
|
@@ -89,11 +91,11 @@ let NrFlexElement = class NrFlexElement extends NuralyUIBaseMixin(LitElement) {
|
|
|
89
91
|
// Check if it's a preset
|
|
90
92
|
switch (value) {
|
|
91
93
|
case "small" /* FlexGap.Small */:
|
|
92
|
-
return '
|
|
94
|
+
return '8px';
|
|
93
95
|
case "medium" /* FlexGap.Medium */:
|
|
94
|
-
return '
|
|
96
|
+
return '16px';
|
|
95
97
|
case "large" /* FlexGap.Large */:
|
|
96
|
-
return '
|
|
98
|
+
return '24px';
|
|
97
99
|
default:
|
|
98
100
|
return value; // Use as-is (could be CSS variable or custom value)
|
|
99
101
|
}
|
|
@@ -132,13 +134,13 @@ let NrFlexElement = class NrFlexElement extends NuralyUIBaseMixin(LitElement) {
|
|
|
132
134
|
const flexStyles = this.getFlexStyles();
|
|
133
135
|
return html `
|
|
134
136
|
<div
|
|
137
|
+
part="flex"
|
|
135
138
|
class="nr-flex"
|
|
136
139
|
data-direction="${flexDirection}"
|
|
137
140
|
data-wrap="${this.wrap}"
|
|
138
141
|
data-justify="${this.justify}"
|
|
139
142
|
data-align="${this.align}"
|
|
140
143
|
data-inline="${this.inline}"
|
|
141
|
-
data-theme="${this.currentTheme}"
|
|
142
144
|
style="${flexStyles}"
|
|
143
145
|
>
|
|
144
146
|
<slot></slot>
|
|
@@ -147,6 +149,7 @@ let NrFlexElement = class NrFlexElement extends NuralyUIBaseMixin(LitElement) {
|
|
|
147
149
|
}
|
|
148
150
|
};
|
|
149
151
|
NrFlexElement.styles = styles;
|
|
152
|
+
NrFlexElement.useShadowDom = true;
|
|
150
153
|
__decorate([
|
|
151
154
|
property({ type: String })
|
|
152
155
|
], NrFlexElement.prototype, "direction", void 0);
|