triafly-ui-kit 1.0.22 → 1.0.23
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 +93 -93
- package/package.json +106 -106
- package/dist/_commonjsHelpers-C6fGbg64.js +0 -6
- package/dist/assets/Accordeon.css +0 -1
- package/dist/assets/Alert.css +0 -1
- package/dist/assets/Avatar.css +0 -1
- package/dist/assets/Badge.css +0 -1
- package/dist/assets/Button.css +0 -1
- package/dist/assets/ButtonsArray.css +0 -1
- package/dist/assets/Checkbox.css +0 -1
- package/dist/assets/CliTextareaInput.css +0 -1
- package/dist/assets/CustomLink.css +0 -1
- package/dist/assets/DropdownInput.css +0 -1
- package/dist/assets/DropdownMenu.css +0 -1
- package/dist/assets/FileUpload.css +0 -1
- package/dist/assets/FormRoot.css +0 -1
- package/dist/assets/Loader.css +0 -1
- package/dist/assets/ModalWindow.css +0 -1
- package/dist/assets/Pagination.css +0 -1
- package/dist/assets/Radio.css +0 -1
- package/dist/assets/SearchInput.css +0 -1
- package/dist/assets/Skeleton.css +0 -1
- package/dist/assets/Switch.css +0 -1
- package/dist/assets/Table.css +0 -1
- package/dist/assets/Tabs.css +0 -1
- package/dist/assets/TextInput.css +0 -1
- package/dist/assets/TextareaInput.css +0 -1
- package/dist/assets/ToastContext.css +0 -1
- package/dist/assets/Tooltip.css +0 -1
- package/dist/assets/Tooltip2.css +0 -1
- package/dist/assets/fonts/FiraCode-Regular.ttf +0 -0
- package/dist/assets/fonts/Manrope-Bold.ttf +0 -0
- package/dist/assets/fonts/Manrope-Regular.ttf +0 -0
- package/dist/assets/fonts/Manrope-SemiBold.ttf +0 -0
- package/dist/assets/fonts/RobotoSlab-SemiBold.ttf +0 -0
- package/dist/components/Ui/Accordeon/Accordeon.js +0 -33
- package/dist/components/Ui/Accordeon/Accordeon.stories.js +0 -72
- package/dist/components/Ui/Accordeon/index.js +0 -4
- package/dist/components/Ui/Alert/Alert.js +0 -14
- package/dist/components/Ui/Alert/index.js +0 -4
- package/dist/components/Ui/Avatar/Avatar.js +0 -10
- package/dist/components/Ui/Avatar/index.js +0 -4
- package/dist/components/Ui/Badge/Badge.js +0 -43
- package/dist/components/Ui/Badge/index.js +0 -4
- package/dist/components/Ui/Button/Button.js +0 -49
- package/dist/components/Ui/Button/index.js +0 -4
- package/dist/components/Ui/ButtonsArray/ButtonsArray.js +0 -28
- package/dist/components/Ui/ButtonsArray/ButtonsArray.stories.js +0 -78
- package/dist/components/Ui/ButtonsArray/index.js +0 -4
- package/dist/components/Ui/Checkbox/Checkbox.js +0 -39
- package/dist/components/Ui/Checkbox/Checkbox.stories.js +0 -120
- package/dist/components/Ui/Checkbox/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/CliTextareaInput.js +0 -121
- package/dist/components/Ui/CliTextareaInput/index.js +0 -23
- package/dist/components/Ui/CliTextareaInput/utils/escapeHtml/escapeHtml.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/fixJson/fixJson.js +0 -12
- package/dist/components/Ui/CliTextareaInput/utils/highlightSyntax/highlightSyntax.js +0 -20
- package/dist/components/Ui/CliTextareaInput/utils/highlightSyntax/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/index.js +0 -17
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useFixFormat/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useFixFormat/useFixFormat.js +0 -29
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useHistoryNavigation/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useHistoryNavigation/useHistoryNavigation.js +0 -34
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useKeyHandlers/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useKeyHandlers/useKeyHandlers.js +0 -45
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useLineNumbers/index.js +0 -5
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useLineNumbers/useLineNumbers.js +0 -17
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useScrollSync/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useScrollSync/useScrollSync.js +0 -13
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useTextActions/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useTextActions/useTextActions.js +0 -37
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useTextCoursore/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/hooks/useTextCoursore/useTextCoursore.js +0 -14
- package/dist/components/Ui/CliTextareaInput/utils/index.js +0 -21
- package/dist/components/Ui/CliTextareaInput/utils/processJson/index.js +0 -4
- package/dist/components/Ui/CliTextareaInput/utils/processJson/processJson.js +0 -11
- package/dist/components/Ui/CliTextareaInput/utils/processXml/processXml.js +0 -8
- package/dist/components/Ui/CliTextareaInput/utils/processYml/processYml.js +0 -27
- package/dist/components/Ui/CliTextareaInput/utils/types.js +0 -1
- package/dist/components/Ui/CustomLink/CustomLink.js +0 -49
- package/dist/components/Ui/CustomLink/index.js +0 -4
- package/dist/components/Ui/DropdownInput/DropdownInput.js +0 -91
- package/dist/components/Ui/DropdownInput/DropdownInput.stories.js +0 -77
- package/dist/components/Ui/DropdownInput/index.js +0 -4
- package/dist/components/Ui/DropdownMenu/DropdownMenu.js +0 -83
- package/dist/components/Ui/DropdownMenu/DropdownMenu.stories.js +0 -50
- package/dist/components/Ui/DropdownMenu/index.js +0 -4
- package/dist/components/Ui/FileUpload/FileUpload.js +0 -615
- package/dist/components/Ui/FileUpload/fn.js +0 -10
- package/dist/components/Ui/FileUpload/index.js +0 -4
- package/dist/components/Ui/FileUpload/types.js +0 -1
- package/dist/components/Ui/Form/FormContext/FormContext.js +0 -5
- package/dist/components/Ui/Form/FormItem/FormItem.js +0 -107
- package/dist/components/Ui/Form/FormItem/fn.js +0 -25
- package/dist/components/Ui/Form/FormItem/types.js +0 -1
- package/dist/components/Ui/Form/FormRoot/FormRoot.js +0 -25
- package/dist/components/Ui/Form/FormRoot/index.js +0 -4
- package/dist/components/Ui/Form/FormRoot/types.js +0 -1
- package/dist/components/Ui/Form/index.js +0 -6
- package/dist/components/Ui/Form/useForm/index.js +0 -4
- package/dist/components/Ui/Form/useForm/useForm.js +0 -111
- package/dist/components/Ui/Form/utils/fn.js +0 -31
- package/dist/components/Ui/Form/utils/types.js +0 -1
- package/dist/components/Ui/Icons/Icons.js +0 -577
- package/dist/components/Ui/Icons/index.js +0 -97
- package/dist/components/Ui/Icons/utils/CreateIcon.js +0 -23
- package/dist/components/Ui/Loader/Loader.js +0 -6
- package/dist/components/Ui/Loader/index.js +0 -4
- package/dist/components/Ui/ModalWindow/ModalWindow.js +0 -50
- package/dist/components/Ui/ModalWindow/index.js +0 -4
- package/dist/components/Ui/Pagination/Pagination.js +0 -294
- package/dist/components/Ui/Pagination/index.js +0 -4
- package/dist/components/Ui/Radio/Radio.js +0 -30
- package/dist/components/Ui/Radio/Radio.stories.js +0 -42
- package/dist/components/Ui/Radio/index.js +0 -4
- package/dist/components/Ui/SearchInput/SearchData.js +0 -30
- package/dist/components/Ui/SearchInput/SearchInput.js +0 -109
- package/dist/components/Ui/Skeleton/Skeleton.js +0 -28
- package/dist/components/Ui/Skeleton/index.js +0 -4
- package/dist/components/Ui/Switch/Switch.js +0 -25
- package/dist/components/Ui/Switch/index.js +0 -4
- package/dist/components/Ui/Table/MemoizedRow/MemoizedRow.js +0 -79
- package/dist/components/Ui/Table/Table.js +0 -160
- package/dist/components/Ui/Table/TableTypes.js +0 -1
- package/dist/components/Ui/Table/index.js +0 -4
- package/dist/components/Ui/Tabs/Tabs.js +0 -24
- package/dist/components/Ui/Tabs/Tabs.stories.js +0 -67
- package/dist/components/Ui/Tabs/index.js +0 -4
- package/dist/components/Ui/TextInput/TextInput.js +0 -85
- package/dist/components/Ui/TextInput/TextInput.stories.js +0 -225
- package/dist/components/Ui/TextInput/index.js +0 -4
- package/dist/components/Ui/TextareaInput/TextareaInput.js +0 -68
- package/dist/components/Ui/TextareaInput/TextareaInput.stories.js +0 -19
- package/dist/components/Ui/TextareaInput/index.js +0 -4
- package/dist/components/Ui/Tooltip/Tooltip.js +0 -92
- package/dist/components/Ui/Tooltip/Tooltip.stories.js +0 -92
- package/dist/components/Ui/Tooltip/index.js +0 -4
- package/dist/context/ToastContext/ToastContext.js +0 -40
- package/dist/context/ToastContext/index.js +0 -5
- package/dist/context/TriaflyContext/TriaflyContext.types.js +0 -1
- package/dist/context/TriaflyContext/TriaflyProvider.js +0 -27
- package/dist/context/TriaflyContext/hooks/index.js +0 -8
- package/dist/context/TriaflyContext/hooks/useBreakpointValue/index.js +0 -4
- package/dist/context/TriaflyContext/hooks/useBreakpointValue/useBreakpointValue.js +0 -11
- package/dist/context/TriaflyContext/hooks/useModal/index.js +0 -4
- package/dist/context/TriaflyContext/hooks/useModal/useModal.js +0 -16
- package/dist/context/TriaflyContext/hooks/useTheme/index.js +0 -4
- package/dist/context/TriaflyContext/hooks/useTheme/useTheme.js +0 -17
- package/dist/context/TriaflyContext/index.js +0 -12
- package/dist/index-2QXL0WYc.js +0 -45
- package/dist/main.d.ts +0 -1229
- package/dist/main.js +0 -162
- package/dist/vite-env.d.js +0 -1
@@ -1 +0,0 @@
|
|
1
|
-
.Pagination__Wrap{display:flex;align-items:center;justify-content:center}.pagination{display:flex;list-style:none;padding:0}.page-item{margin:0 8px 0 0}.page-item:last-of-type{margin:0}.page-link{cursor:pointer;border-radius:6px;width:36px;height:36px;display:flex;align-items:center;justify-content:center;color:var(--color-text-primary-default)}.page-link:hover{background-color:var(--color-bg-brand-lightest-default);color:var(--color-text-brand-default)}.active .page-link{background-color:var(--color-bg-brand-default);color:var(--light-color-static)}.page-toggler.disabled .page-link{pointer-events:none}.page-toggler.disabled .page-link svg *{fill:var(--color-icon-secondary-default)}.page-toggler .page-link:hover{background-color:transparent}.page-toggler .page-link:hover svg *{fill:var(--color-icon-brand-default)}
|
package/dist/assets/Radio.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
.radio{display:flex;align-items:center}.radio:not(:last-child){margin:0 0 8px}.radio.disabled{cursor:default;opacity:40%}.radio input[type=radio]{display:none}.radio input[type=radio]:checked+.checkmark{border:5px solid var(--color-bg-brand-default)}.radio .radio-label{display:flex;align-items:center;cursor:pointer}.radio .radio-label .test{line-height:16.8px}.radio .checkmark{box-sizing:border-box;position:relative;display:block;width:20px;height:20px;border-radius:50%;border:1px solid var(--color-border-primary-default);background-color:var(--color-bg-neutral-basic-default);margin-right:8px;transition:.04s;-webkit-user-select:none;user-select:none}
|
@@ -1 +0,0 @@
|
|
1
|
-
.search-input{border:1px solid var(--color-border-primary-default);border-radius:22px;margin:0 12px 0 0}.search-input:focus-within{border:2px solid var(--color-border-primary-default);margin:0 11px 0 -1px}.search-input:focus-within .text-input .input-container input{margin:-1px}.search-input .text-input .input-container input{border:none}.search-input .text-input .input-container input:focus{outline:none}.search-input__label{margin:0 0 8px}.search-input .guess-box{padding:0 12px 12px}.search-input .guess-box ul{border-top:1px solid var(--color-border-primary-default);padding:12px 0 0}.search-input .guess-box ul li{min-height:36px;display:flex;align-items:center;padding:0 8px;cursor:pointer}.search-input .guess-box ul li:hover{background-color:var(--color-bg-innerisland-default)}.dropdown-input-test{position:relative}.dropdown-input-test .caret{fill:var(--color-icon-secondary-default);position:absolute;bottom:9px;right:10px}.dropdown-input-test .input-box{position:relative;cursor:pointer;display:flex;justify-content:space-between;align-items:center;outline:none;background-color:var(--color-bg-neutral-basic-default)}.dropdown-input-test .input-box.disabled{background-color:var(--color-bg-island-disabled);pointer-events:none}.dropdown-input-test .input-box.invalid{border-color:var(--color-border-error-default)}.dropdown-input-test .input-box.invalid>span{color:var(--color-border-error-default)}.dropdown-input-test .input-box.invalid svg *{fill:var(--color-border-error-default)}.dropdown-input-test .input-box .placeholder{color:var(--color-text-secondary-default)}.dropdown-input-test .options{position:absolute;top:100%;bottom:auto;left:1%;right:1%;max-height:304px;overflow-y:auto;overflow-x:hidden;background-color:var(--color-bg-neutral-basic-default);border-radius:8px;border:1px solid var(--color-border-primary-default);margin:1px -1px 0;z-index:21}.dropdown-input-test .options.above{bottom:calc(100% + 1px);top:auto}.dropdown-input-test .options li{padding:0 8px;min-height:36px;cursor:pointer;display:flex;align-items:center}.dropdown-input-test .options li:hover,.dropdown-input-test .options li.dropdown-input__option--selected{background-color:var(--color-bg-neutral-lightest-default)}
|
package/dist/assets/Skeleton.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
._skeleton_yatxz_1{display:inline-block;background-color:var(--color-bg-island-selected)}._animated_yatxz_6{background:linear-gradient(90deg,var(--color-bg-island-selected) 25%,var(--color-bg-island-selected) 50%,var(--color-bg-island-selected) 75%);background-size:200% 100%;animation:_skeleton-loading_yatxz_1 1.5s infinite linear}@keyframes _skeleton-loading_yatxz_1{0%{background-position:200% 0}to{background-position:-200% 0}}
|
package/dist/assets/Switch.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
.switch-container:not(:last-child){margin:0 0 12px}.switch-container label{display:flex;align-items:center;justify-content:space-between}.switch input[type=checkbox]{position:absolute;opacity:0;cursor:pointer}.switch{display:inline-flex;align-items:center;line-height:16.8px;cursor:pointer;-webkit-user-select:none;user-select:none}.switch.disabled{opacity:50%;cursor:default}.switch input[type=checkbox]+.slider{display:flex;align-items:center;width:43px;height:24px;border:1px solid var(--color-bg-brand-default);border-radius:12px;transition:all .2s;margin:0 0 0 8px}.switch input[type=checkbox]+.slider:after{content:"";display:block;width:18px;height:18px;border-radius:50%;background-color:var(--color-bg-brand-default);margin:0 2px;transition:all .2s}.switch input[type=checkbox]:checked+.slider{background-color:var(--color-bg-brand-default);border-color:var(--color-bg-brand-default)}.switch input[type=checkbox]:checked+.slider:after{background-color:var(--light-color-static);margin:0 0 0 20px}
|
package/dist/assets/Table.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
.table-component{width:100%;overflow:auto;position:relative}.table-component__wrapper{width:100%}.table-component__wrapper.bordered{border:1px solid var(--color-border-primary-default);border-radius:8px}.table-component__wrapper__table{width:100%;border-collapse:separate;border-spacing:0}.table-component__wrapper__table.bordered{border:none}.table-component__wrapper__table__thead{background-color:var(--color-bg-innerisland-default);height:41px}.table-component__wrapper__table__thead.stickyHeader{position:sticky;top:0;z-index:10}.table-component__wrapper__table__thead__tr:hover{background-color:var(--color-bg-island-selected)}.table-component__wrapper__table__thead__th{padding:12px;text-align:left;position:relative}.table-component__wrapper__table__thead__th.bordered{border-left:1px solid var(--color-border-primary-default);border-bottom:none}.table-component__wrapper__table__thead__th.bordered:first-child{border-left:none}.table-component__wrapper__table__thead__th.stickyLeft{position:sticky;left:0;background-color:inherit;z-index:9}.table-component__wrapper__table__thead__th .th-content{display:flex;align-items:center;gap:4px}.table-component__wrapper__table__thead__th .sort-icon{display:inline-flex}.table-component__wrapper__table__tbody__tr:hover{background-color:var(--color-bg-island-selected)}.table-component__wrapper__table__tbody--hoverable{cursor:pointer}.table-component__wrapper__table__tbody__td{padding:12px}.table-component__wrapper__table__tbody__td--bordered{border-top:1px solid var(--color-border-primary-default);border-left:1px solid var(--color-border-primary-default)}.table-component__wrapper__table__tbody__td--bordered:first-child{border-left:none}.table-component__wrapper__table__tbody__td--sticky-left{position:sticky;left:0;background-color:inherit;z-index:8}.table-component__wrapper.borderBottom .table-component__wrapper__table__tbody td{border-bottom:1px solid var(--color-border-primary-default)}
|
package/dist/assets/Tabs.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
.tabs .tabs-bar{display:flex}.tabs .tab-button{padding:0 8px 4px;display:flex;justify-content:center;align-items:center;border:none;border-bottom:1px solid var(--color-border-primary-default);background-color:transparent;cursor:pointer}.tabs .tab-button:first-of-type{padding:0 8px 4px 0}.tabs .tab-button:last-of-type{padding:0 0 4px 8px}.tabs .tab-button:hover,.tabs .tab-button.active{color:var(--color-border-brand-default);border-bottom:1px solid var(--color-border-brand-default)}.tabs .tab-button.disabled{pointer-events:none}
|
@@ -1 +0,0 @@
|
|
1
|
-
.text-input{display:flex;flex-direction:column}.text-input label{margin:0 0 8px}.text-input .input-container{display:flex;position:relative;z-index:0}.text-input .input-container.has-icon input{padding:10px 8px 10px 36px}.text-input .input-container.has-icon input:active,.text-input .input-container.has-icon input:focus{padding:9px 7px 9px 35px}.text-input .input-container.has-icon .icon{position:absolute;left:8px;top:calc(50% - 10px);z-index:2}.text-input .input-container.has-icon .icon *{fill:var(--color-icon-secondary-default)}.text-input .input-container input{border:1px solid var(--color-border-primary-default);border-radius:8px;height:44px;padding:10px 8px;outline:none;background-color:var(--color-bg-neutral-basic-default);z-index:1;flex-grow:1;color:var(--color-text-primary-default)}.text-input .input-container input[disabled]{background-color:var(--color-bg-island-disabled);pointer-events:none}.text-input .input-container input::placeholder{color:var(--color-text-secondary-default)}.text-input .input-container input:active,.text-input .input-container input:focus{border:2px solid var(--color-border-primary-default);padding:9px 7px}.text-input .input-container input.has-icon{padding:10px 8px 10px 36px}.text-input.sm.rounded input{border-radius:18px}.text-input.sm .input-container input{height:36px}.text-input.rounded input{border-radius:22px}.text-input.invalid input,.text-input.invalid input:active,.text-input.invalid input:focus{border-color:var(--color-border-error-default);color:var(--color-border-error-default)}.text-input.invalid .icon *{fill:var(--color-border-error-default)!important}.text-input.invalid .helper-text{color:var(--color-border-error-default)}.text-input.clearable input{padding-right:36px!important}.text-input.clearable .clear-value{position:absolute;right:8px;top:calc(50% - 10px);cursor:pointer;z-index:1;height:20px}.text-input.clearable .clear-value *{fill:var(--color-icon-secondary-default)}.text-input .helper-text{font-size:12px;color:var(--color-text-secondary-default);margin:8px 0 0}.text-input .loader{position:absolute;right:8px;top:calc(50% - 10px)}.text-input .loader *{fill:var(--color-icon-secondary-default)}
|
@@ -1 +0,0 @@
|
|
1
|
-
@font-face{font-family:Roboto Slab;src:url(../assets/fonts/RobotoSlab-SemiBold.ttf) format("truetype");font-weight:600}@font-face{font-family:Manrope;src:url(../assets/fonts/Manrope-Regular.ttf) format("truetype");font-weight:400}@font-face{font-family:Manrope;src:url(../assets/fonts/Manrope-Semibold.ttf) format("truetype");font-weight:600}@font-face{font-family:Manrope;src:url(../assets/fonts/Manrope-Bold.ttf) format("truetype");font-weight:700}@font-face{font-family:Fira Code;src:url(../assets/fonts/FiraCode-Regular.ttf) format("truetype");font-weight:400}*{font-family:Manrope,sans-serif;font-size:14px;line-height:1.2em;letter-spacing:.02em;font-weight:400;color:var(--color-text-primary-default)}h1,h2,h3,h4,h5,h6{margin:0}a{color:var(--color-text-brand-default);text-decoration:none}a:hover{color:var(--color-text-brand-hover)}a[href=""]{opacity:40%;cursor:default;pointer-events:none}p:not(:last-child){margin:0 0 8px}.textarea-input{display:flex;flex-direction:column;resize:none}.textarea-input label{margin:0 0 8px}.textarea-input .char-limit{text-align:right;margin-top:8px;font-size:12px;font-weight:400;color:var(--color-text-secondary-default)}.textarea-input .textarea-wrapper{position:relative}.textarea-input textarea{border:1px solid var(--color-border-primary-default);border-radius:8px;padding:10.5px 8px;color:var(--color-text-primary-default);max-width:100%;min-width:100%;min-height:64px;resize:both;background-color:var(--color-bg-neutral-basic-default);font-size:14px;font-weight:400}.textarea-input textarea[disabled]{background-color:var(--color-bg-island-disabled);pointer-events:none}.textarea-input textarea::placeholder{color:var(--color-text-secondary-default)}.textarea-input textarea:focus{border:2px solid var(--color-border-primary-default);padding:9.5px 7px}.textarea-input textarea.no-resize{resize:none}.textarea-input .helper-text{font-size:12px;color:var(--color-text-secondary-default);margin:8px 0 0}.textarea-input.invalid textarea{border-color:var(--color-border-error-default);color:var(--color-border-error-default)}.textarea-input.invalid svg *{fill:var(--color-border-error-default)}.textarea-input.invalid .helper-text{color:var(--color-border-error-default)}.textarea-input.clearable textarea{padding-right:36px!important}.textarea-input.clearable .clear-value{position:absolute;right:8px;top:8px;cursor:pointer;z-index:1;height:20px}.textarea-input.clearable .clear-value *{fill:var(--color-icon-secondary-default)}
|
@@ -1 +0,0 @@
|
|
1
|
-
._Wrapper_12sk9_1{position:fixed;bottom:20px;right:20px;z-index:101;display:flex;flex-direction:column;gap:10px}._Toast_12sk9_11{color:var(--color-text-primary-inversed);padding:20px 24px;border-radius:8px;display:flex;justify-content:space-between;align-items:center;min-width:250px;max-width:400px;font-size:16px;box-shadow:0 6px 15px -2px var(--effect-shadow-L, rgba(18, 18, 18, .08));animation:_fadeIn_12sk9_1 .5s ease-in-out;background-color:var(--color-bg-neutral-basic-inversed)}@keyframes _fadeIn_12sk9_1{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}
|
package/dist/assets/Tooltip.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
._container_193w2_1{position:relative;width:100%;height:100vh;padding:20px;display:flex;flex-wrap:wrap;justify-content:space-between;align-content:space-between;border:1px dashed #ccc;box-sizing:border-box}._trigger_193w2_14{padding:8px 16px;background-color:#1976d2;color:#fff;border-radius:4px;font-size:14px;cursor:pointer;transition:background-color .2s;text-align:center}._trigger_193w2_14:hover{background-color:#1565c0}._clickTrigger_193w2_29{background-color:#388e3c}._clickTrigger_193w2_29:hover{background-color:#2e7d32}._positionsContainer_193w2_38{padding:20px}._positionGroup_193w2_42{display:flex;gap:20px;margin-bottom:30px;justify-content:center;flex-wrap:wrap}
|
package/dist/assets/Tooltip2.css
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
.tooltip-wrapper{position:relative;display:inline-block;cursor:pointer}.tooltip-content{position:absolute;background-color:var(--color-bg-brand-default);color:var(--light-color-static);padding:12px 16px;border-radius:8px;z-index:9999;width:max-content;max-width:300px;white-space:normal;text-align:center}.tooltip-content:after{content:"";position:absolute;border-width:5px;border-style:solid}.tooltip-content.white{background-color:var(--color-bg-neutral-basic-default);color:var(--color-text-primary-default);box-shadow:0 0 10px -2px var(--effects-effect-shadow-XL, rgba(18, 18, 18, .15))}.tooltip-content.white.tooltip-top:after{border-color:var(--color-bg-neutral-basic-default) transparent transparent transparent}.tooltip-content.white.tooltip-bottom:after{border-color:transparent transparent var(--color-bg-neutral-basic-default) transparent}.tooltip-content.white.tooltip-left:after{border-color:transparent transparent transparent var(--color-bg-neutral-basic-default)}.tooltip-content.white.tooltip-right:after{border-color:transparent var(--color-bg-neutral-basic-default) transparent transparent}.tooltip-top{bottom:calc(100% + 8px);left:50%;transform:translate(-50%)}.tooltip-top:after{top:100%;left:50%;transform:translate(-50%);border-color:var(--color-bg-brand-default) transparent transparent transparent}.tooltip-bottom{top:calc(100% + 8px);left:50%;transform:translate(-50%)}.tooltip-bottom:after{bottom:100%;left:50%;transform:translate(-50%);border-color:transparent transparent var(--color-bg-brand-default) transparent}.tooltip-left{top:50%;right:calc(100% + 8px);transform:translateY(-50%)}.tooltip-left:after{top:50%;left:100%;transform:translateY(-50%);border-color:transparent transparent transparent var(--color-bg-brand-default)}.tooltip-right{top:50%;left:calc(100% + 8px);transform:translateY(-50%)}.tooltip-right:after{top:50%;right:100%;transform:translateY(-50%);border-color:transparent var(--color-bg-brand-default) transparent transparent}
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -1,33 +0,0 @@
|
|
1
|
-
import { jsxs as s, jsx as c } from "react/jsx-runtime";
|
2
|
-
import { useState as m, useRef as p } from "react";
|
3
|
-
import '../../../assets/Accordeon.css';const f = ({
|
4
|
-
title: o,
|
5
|
-
content: r,
|
6
|
-
openTitle: i,
|
7
|
-
closeTitle: l
|
8
|
-
}) => {
|
9
|
-
var n;
|
10
|
-
const [e, a] = m(!1), t = p(null), d = () => {
|
11
|
-
a(!e);
|
12
|
-
};
|
13
|
-
return /* @__PURE__ */ s("div", { className: "accordeon", children: [
|
14
|
-
/* @__PURE__ */ c(
|
15
|
-
"div",
|
16
|
-
{
|
17
|
-
className: "content-wrapper",
|
18
|
-
style: {
|
19
|
-
maxHeight: e ? `${(n = t.current) == null ? void 0 : n.scrollHeight}px` : "0px",
|
20
|
-
transition: "max-height 0.3s ease-out"
|
21
|
-
},
|
22
|
-
children: /* @__PURE__ */ c("div", { className: "content", ref: t, children: r })
|
23
|
-
}
|
24
|
-
),
|
25
|
-
/* @__PURE__ */ s("div", { className: "title", onClick: d, children: [
|
26
|
-
o,
|
27
|
-
e ? l : i
|
28
|
-
] })
|
29
|
-
] });
|
30
|
-
};
|
31
|
-
export {
|
32
|
-
f as Accordeon
|
33
|
-
};
|
@@ -1,72 +0,0 @@
|
|
1
|
-
import { jsxs as e, jsx as t } from "react/jsx-runtime";
|
2
|
-
import { Accordeon as r } from "./Accordeon.js";
|
3
|
-
const s = {
|
4
|
-
title: "UIKit/Accordeon",
|
5
|
-
// Название группы историй
|
6
|
-
component: r,
|
7
|
-
// Компонент, для которого создаются истории
|
8
|
-
tags: ["autodocs"],
|
9
|
-
// Автоматическая генерация документации
|
10
|
-
argTypes: {
|
11
|
-
title: {
|
12
|
-
control: "text",
|
13
|
-
// Позволяет редактировать заголовок в интерфейсе Storybook
|
14
|
-
description: "Заголовок аккордеона"
|
15
|
-
},
|
16
|
-
content: {
|
17
|
-
control: "text",
|
18
|
-
// Позволяет редактировать контент в интерфейсе Storybook
|
19
|
-
description: "Контент аккордеона"
|
20
|
-
}
|
21
|
-
}
|
22
|
-
}, c = {
|
23
|
-
args: {
|
24
|
-
title: "Заголовок аккордеона!",
|
25
|
-
content: "Это контент аккордеона. Он может быть текстом, компонентом или чем угодно."
|
26
|
-
}
|
27
|
-
}, d = {
|
28
|
-
args: {
|
29
|
-
...c.args
|
30
|
-
// Используем аргументы из Default
|
31
|
-
},
|
32
|
-
decorators: [
|
33
|
-
(n) => /* @__PURE__ */ t("div", { style: { width: "300px" }, children: /* @__PURE__ */ t(n, {}) })
|
34
|
-
],
|
35
|
-
parameters: {
|
36
|
-
// Открываем аккордеон по умолчанию
|
37
|
-
docs: {
|
38
|
-
source: {
|
39
|
-
code: "<Accordeon title='Заголовок' content='Контент аккордеона' isOpen={true} />"
|
40
|
-
}
|
41
|
-
}
|
42
|
-
}
|
43
|
-
}, a = {
|
44
|
-
args: {
|
45
|
-
title: "Аккордеон с HTML",
|
46
|
-
content: /* @__PURE__ */ e("div", { children: [
|
47
|
-
/* @__PURE__ */ t("h3", { children: "Заголовок внутри контента" }),
|
48
|
-
/* @__PURE__ */ t("p", { children: "Этот аккордеон содержит HTML-контент." }),
|
49
|
-
/* @__PURE__ */ e("ul", { children: [
|
50
|
-
/* @__PURE__ */ t("li", { children: "Пункт 1" }),
|
51
|
-
/* @__PURE__ */ t("li", { children: "Пункт 2" }),
|
52
|
-
/* @__PURE__ */ t("li", { children: "Пункт 3" })
|
53
|
-
] })
|
54
|
-
] })
|
55
|
-
}
|
56
|
-
}, h = {
|
57
|
-
args: {
|
58
|
-
title: "Аккордеон с длинным контентом",
|
59
|
-
content: Array.from({ length: 10 }, (n, o) => /* @__PURE__ */ e("p", { children: [
|
60
|
-
"Это строка номер ",
|
61
|
-
o + 1,
|
62
|
-
" в длинном контенте."
|
63
|
-
] }, o))
|
64
|
-
}
|
65
|
-
};
|
66
|
-
export {
|
67
|
-
c as Default,
|
68
|
-
d as Opened,
|
69
|
-
a as WithHTMLContent,
|
70
|
-
h as WithLongContent,
|
71
|
-
s as default
|
72
|
-
};
|
@@ -1,14 +0,0 @@
|
|
1
|
-
import { jsx as n, Fragment as s, jsxs as m } from "react/jsx-runtime";
|
2
|
-
import '../../../assets/Alert.css';const o = ({
|
3
|
-
text: r,
|
4
|
-
icon: e,
|
5
|
-
status: t,
|
6
|
-
isMultiline: i,
|
7
|
-
isOpen: l
|
8
|
-
}) => l ? /* @__PURE__ */ m("div", { className: `alert ${t} ${i ? "multiline" : ""}`, children: [
|
9
|
-
e,
|
10
|
-
r
|
11
|
-
] }) : /* @__PURE__ */ n(s, {});
|
12
|
-
export {
|
13
|
-
o as Alert
|
14
|
-
};
|
@@ -1,10 +0,0 @@
|
|
1
|
-
import { jsx as a } from "react/jsx-runtime";
|
2
|
-
import '../../../assets/Avatar.css';const c = ({ imageUrl: s, username: i }) => /* @__PURE__ */ a("div", { className: "avatar", children: s ? /* @__PURE__ */ a("img", { src: s, alt: i, className: "avatar-image" }) : /* @__PURE__ */ a("div", { className: "avatar-initials", children: ((r) => {
|
3
|
-
if (!r) return "";
|
4
|
-
const t = r.split(" ");
|
5
|
-
let e = t[0].substring(0, 1).toUpperCase();
|
6
|
-
return t.length > 1 && (e += t[t.length - 1].substring(0, 1).toUpperCase()), e;
|
7
|
-
})(i) }) });
|
8
|
-
export {
|
9
|
-
c as Avatar
|
10
|
-
};
|
@@ -1,43 +0,0 @@
|
|
1
|
-
import { jsxs as i, jsx as o } from "react/jsx-runtime";
|
2
|
-
import { c as d } from "../../../index-2QXL0WYc.js";
|
3
|
-
import '../../../assets/Badge.css';const m = "_badge_mb34a_3", r = "_outline_mb34a_20", u = "_solid_mb34a_25", g = "_subtle_mb34a_30", k = "_done_mb34a_40", p = "_success_mb34a_41", f = "_warning_mb34a_46", v = "_error_mb34a_51", N = "_active_mb34a_56", w = "_blocked_mb34a_61", x = "_icon_mb34a_66", h = "_clickable_mb34a_73", s = {
|
4
|
-
badge: m,
|
5
|
-
outline: r,
|
6
|
-
solid: u,
|
7
|
-
subtle: g,
|
8
|
-
default: "_default_mb34a_35",
|
9
|
-
done: k,
|
10
|
-
success: p,
|
11
|
-
warning: f,
|
12
|
-
error: v,
|
13
|
-
active: N,
|
14
|
-
blocked: w,
|
15
|
-
icon: x,
|
16
|
-
clickable: h
|
17
|
-
}, B = ({
|
18
|
-
children: _,
|
19
|
-
variant: n = "outline",
|
20
|
-
status: l = "default",
|
21
|
-
iconLeft: c,
|
22
|
-
iconRight: a,
|
23
|
-
isClickable: e = !1,
|
24
|
-
onClick: t,
|
25
|
-
borderRadius: b
|
26
|
-
}) => /* @__PURE__ */ i(
|
27
|
-
"span",
|
28
|
-
{
|
29
|
-
className: d(s.badge, s[n], s[l], {
|
30
|
-
[s.clickable]: e
|
31
|
-
}),
|
32
|
-
onClick: e ? t : void 0,
|
33
|
-
style: { borderRadius: b },
|
34
|
-
children: [
|
35
|
-
c && /* @__PURE__ */ o("span", { className: s.icon, children: c }),
|
36
|
-
_,
|
37
|
-
a && /* @__PURE__ */ o("span", { className: s.icon, children: a })
|
38
|
-
]
|
39
|
-
}
|
40
|
-
);
|
41
|
-
export {
|
42
|
-
B as Badge
|
43
|
-
};
|
@@ -1,49 +0,0 @@
|
|
1
|
-
import { jsxs as u, jsx as t } from "react/jsx-runtime";
|
2
|
-
import { useNavigate as N } from "react-router-dom";
|
3
|
-
import { Loader as v } from "../Loader/Loader.js";
|
4
|
-
import '../../../assets/Button.css';const i = () => /* @__PURE__ */ t("svg", { className: "arrow", width: "12", height: "10", fill: "none", children: /* @__PURE__ */ t(
|
5
|
-
"path",
|
6
|
-
{
|
7
|
-
d: "M11.9999 5c0 .13261-.0527.25979-.1464.35356-.0938.09376-.221.14644-.3536.14644H1.70678l3.64688 3.64625c.04645.04646.0833.10161.10844.1623.02514.0607.03808.12576.03808.19145 0 .0657-.01294.13075-.03808.19145-.02514.0607-.06199.11585-.10844.1623-.04646.04646-.10161.08331-.16231.10845-.06069.02514-.12575.0381-.19144.0381-.0657 0-.13076-.01296-.19145-.0381-.0607-.02514-.11585-.06199-.16231-.10845l-4.499995-4.5c-.0464882-.04643-.0833677-.10158-.1085298-.16228C.012463 5.13077-.00048828 5.06571-.00048828 5c0-.0657.01295128-.13077.03811348-.19147.0251621-.0607.0620416-.11584.1085298-.16228L4.64615.146253c.09382-.09382.22107-.14652766.35376-.14652766.13268 0 .25993.05270766.35375.14652766.09382.093821.14652.221068.14652.35375 0 .132682-.0527.25993-.14652.35375L1.70678 4.5h9.79312c.1326 0 .2598.05268.3536.14645.0937.09377.1464.22094.1464.35355Z",
|
8
|
-
fill: "#fff"
|
9
|
-
}
|
10
|
-
) }), $ = ({
|
11
|
-
label: c,
|
12
|
-
style: o,
|
13
|
-
onClick: e,
|
14
|
-
isDisabled: d,
|
15
|
-
title: h,
|
16
|
-
className: m = "",
|
17
|
-
isLoading: l,
|
18
|
-
navigation: n,
|
19
|
-
type: f = "button",
|
20
|
-
icon: s,
|
21
|
-
iconTail: a,
|
22
|
-
to: r
|
23
|
-
}) => {
|
24
|
-
const b = N(), p = () => {
|
25
|
-
e && e(), r && b(`${r}`);
|
26
|
-
};
|
27
|
-
return /* @__PURE__ */ u(
|
28
|
-
"button",
|
29
|
-
{
|
30
|
-
style: o,
|
31
|
-
className: `btn ${m} ${l ? "loading" : ""}`,
|
32
|
-
title: h,
|
33
|
-
onClick: p,
|
34
|
-
disabled: d,
|
35
|
-
type: f,
|
36
|
-
children: [
|
37
|
-
s && /* @__PURE__ */ t("div", { className: "icon", children: s }),
|
38
|
-
n === "back" && /* @__PURE__ */ t(i, {}),
|
39
|
-
c && /* @__PURE__ */ t("span", { className: "btn-label", children: c }),
|
40
|
-
l && /* @__PURE__ */ t(v, {}),
|
41
|
-
a && /* @__PURE__ */ t("div", { className: "icon-tail", children: a }),
|
42
|
-
n === "next" && /* @__PURE__ */ t(i, {})
|
43
|
-
]
|
44
|
-
}
|
45
|
-
);
|
46
|
-
};
|
47
|
-
export {
|
48
|
-
$ as Button
|
49
|
-
};
|
@@ -1,28 +0,0 @@
|
|
1
|
-
import { jsxs as d, jsx as e } from "react/jsx-runtime";
|
2
|
-
import { useState as u } from "react";
|
3
|
-
import '../../../assets/ButtonsArray.css';const p = ({
|
4
|
-
tabs: i,
|
5
|
-
label: a,
|
6
|
-
initialActiveTab: l = 0,
|
7
|
-
onChange: c
|
8
|
-
}) => {
|
9
|
-
const [n, o] = u(l), r = (s, t) => {
|
10
|
-
o(s), c && c(t);
|
11
|
-
};
|
12
|
-
return /* @__PURE__ */ d("div", { className: "buttons", children: [
|
13
|
-
a && /* @__PURE__ */ e("span", { className: "buttons-label", children: a }),
|
14
|
-
/* @__PURE__ */ e("div", { className: "buttons-bar", children: i.map((s, t) => /* @__PURE__ */ e(
|
15
|
-
"button",
|
16
|
-
{
|
17
|
-
disabled: s.disabled,
|
18
|
-
onClick: () => r(t, s.key),
|
19
|
-
className: `button ${t === n ? "active" : ""} status-${s.status}`,
|
20
|
-
children: s.label
|
21
|
-
},
|
22
|
-
s.key
|
23
|
-
)) })
|
24
|
-
] });
|
25
|
-
};
|
26
|
-
export {
|
27
|
-
p as ButtonsArray
|
28
|
-
};
|
@@ -1,78 +0,0 @@
|
|
1
|
-
import { ButtonsArray as e } from "./ButtonsArray.js";
|
2
|
-
const a = {
|
3
|
-
title: "UIKit/ButtonsArray",
|
4
|
-
component: e,
|
5
|
-
tags: ["autodocs"],
|
6
|
-
argTypes: {
|
7
|
-
initialActiveTab: {
|
8
|
-
control: { type: "number", min: 0 }
|
9
|
-
},
|
10
|
-
onChange: { action: "tabChanged" }
|
11
|
-
}
|
12
|
-
}, l = {
|
13
|
-
args: {
|
14
|
-
tabs: [
|
15
|
-
{ label: "All", key: "all" },
|
16
|
-
{ label: "Active", key: "active" },
|
17
|
-
{ label: "Completed", key: "completed" }
|
18
|
-
],
|
19
|
-
label: "Filter tasks:"
|
20
|
-
}
|
21
|
-
}, s = {
|
22
|
-
args: {
|
23
|
-
label: "Document status:",
|
24
|
-
tabs: [
|
25
|
-
{ label: "Draft", key: "draft", status: "none" },
|
26
|
-
{ label: "In Review", key: "review", status: "warning" },
|
27
|
-
{ label: "Rejected", key: "rejected", status: "error" },
|
28
|
-
{ label: "Approved", key: "approved", status: "success" }
|
29
|
-
]
|
30
|
-
}
|
31
|
-
}, o = {
|
32
|
-
args: {
|
33
|
-
tabs: [
|
34
|
-
{ label: "First", key: "first" },
|
35
|
-
{ label: "Second", key: "second" },
|
36
|
-
{ label: "Third", key: "third" }
|
37
|
-
],
|
38
|
-
initialActiveTab: 1
|
39
|
-
}
|
40
|
-
}, b = {
|
41
|
-
args: {
|
42
|
-
label: "Account type:",
|
43
|
-
tabs: [
|
44
|
-
{ label: "Basic", key: "basic" },
|
45
|
-
{ label: "Premium", key: "premium", disabled: !0 },
|
46
|
-
{ label: "Enterprise", key: "enterprise" }
|
47
|
-
]
|
48
|
-
}
|
49
|
-
}, r = {
|
50
|
-
args: {
|
51
|
-
tabs: [
|
52
|
-
{ label: "Yes", key: "yes" },
|
53
|
-
{ label: "No", key: "no" }
|
54
|
-
]
|
55
|
-
}
|
56
|
-
}, i = {
|
57
|
-
args: {
|
58
|
-
label: "Categories:",
|
59
|
-
tabs: [
|
60
|
-
{ label: "Electronics", key: "electronics" },
|
61
|
-
{ label: "Clothing", key: "clothing" },
|
62
|
-
{ label: "Home", key: "home" },
|
63
|
-
{ label: "Sports", key: "sports" },
|
64
|
-
{ label: "Books", key: "books" },
|
65
|
-
{ label: "Toys", key: "toys" },
|
66
|
-
{ label: "Beauty", key: "beauty" }
|
67
|
-
]
|
68
|
-
}
|
69
|
-
};
|
70
|
-
export {
|
71
|
-
l as Default,
|
72
|
-
b as DisabledTabs,
|
73
|
-
i as ManyTabs,
|
74
|
-
r as SmallSelection,
|
75
|
-
o as WithInitialActiveTab,
|
76
|
-
s as WithStatusIndicators,
|
77
|
-
a as default
|
78
|
-
};
|
@@ -1,39 +0,0 @@
|
|
1
|
-
import { jsx as r, jsxs as t } from "react/jsx-runtime";
|
2
|
-
import { useRef as f, useEffect as h } from "react";
|
3
|
-
import '../../../assets/Checkbox.css';const i = ({
|
4
|
-
label: s,
|
5
|
-
isDisabled: a,
|
6
|
-
isChecked: o = !1,
|
7
|
-
isIndeterminate: e = !1,
|
8
|
-
onChange: l,
|
9
|
-
name: n = "Checkbox"
|
10
|
-
}) => {
|
11
|
-
const c = f(null);
|
12
|
-
return h(() => {
|
13
|
-
c.current && (c.current.indeterminate = e);
|
14
|
-
}, [e]), /* @__PURE__ */ r("div", { className: "checkbox-container", children: /* @__PURE__ */ t(
|
15
|
-
"label",
|
16
|
-
{
|
17
|
-
className: `checkbox ${a ? "disabled" : ""} ${e ? "indeterminate" : ""}`,
|
18
|
-
children: [
|
19
|
-
/* @__PURE__ */ r(
|
20
|
-
"input",
|
21
|
-
{
|
22
|
-
ref: c,
|
23
|
-
name: n,
|
24
|
-
type: "checkbox",
|
25
|
-
checked: o,
|
26
|
-
onChange: l,
|
27
|
-
disabled: a
|
28
|
-
}
|
29
|
-
),
|
30
|
-
/* @__PURE__ */ r("span", { className: "checkmark" }),
|
31
|
-
s
|
32
|
-
]
|
33
|
-
}
|
34
|
-
) });
|
35
|
-
};
|
36
|
-
i.displayName = "Checkbox";
|
37
|
-
export {
|
38
|
-
i as Checkbox
|
39
|
-
};
|
@@ -1,120 +0,0 @@
|
|
1
|
-
import { jsxs as s, jsx as e } from "react/jsx-runtime";
|
2
|
-
import { useState as p } from "react";
|
3
|
-
import { Checkbox as i } from "./Checkbox.js";
|
4
|
-
const k = {
|
5
|
-
title: "UIKit/Checkbox",
|
6
|
-
component: i,
|
7
|
-
tags: ["autodocs"],
|
8
|
-
argTypes: {
|
9
|
-
isChecked: {
|
10
|
-
control: "boolean",
|
11
|
-
description: "Состояние чекбокса (выбран/не выбран)"
|
12
|
-
},
|
13
|
-
isDisabled: {
|
14
|
-
control: "boolean",
|
15
|
-
description: "Отключен ли чекбокс"
|
16
|
-
},
|
17
|
-
label: {
|
18
|
-
control: "text",
|
19
|
-
description: "Текстовая метка чекбокса"
|
20
|
-
},
|
21
|
-
name: {
|
22
|
-
control: "text",
|
23
|
-
description: "Атрибут name для input элемента"
|
24
|
-
},
|
25
|
-
onChange: {
|
26
|
-
action: "changed",
|
27
|
-
description: "Обработчик изменения состояния"
|
28
|
-
}
|
29
|
-
}
|
30
|
-
}, g = {
|
31
|
-
args: {
|
32
|
-
label: "Чекбокс"
|
33
|
-
}
|
34
|
-
}, C = {
|
35
|
-
args: {
|
36
|
-
label: "Выбранный чекбокс",
|
37
|
-
isChecked: !0
|
38
|
-
}
|
39
|
-
}, f = {
|
40
|
-
args: {
|
41
|
-
label: "Отключенный чекбокс",
|
42
|
-
isDisabled: !0
|
43
|
-
}
|
44
|
-
}, D = {
|
45
|
-
args: {
|
46
|
-
label: "Выбранный и отключенный",
|
47
|
-
isChecked: !0,
|
48
|
-
isDisabled: !0
|
49
|
-
}
|
50
|
-
}, y = {
|
51
|
-
args: {}
|
52
|
-
}, I = {
|
53
|
-
args: {
|
54
|
-
label: "Неопределённое состояние",
|
55
|
-
isIndeterminate: !0
|
56
|
-
}
|
57
|
-
}, v = {
|
58
|
-
args: {
|
59
|
-
label: "Неопределённое и отключенное",
|
60
|
-
isIndeterminate: !0,
|
61
|
-
isDisabled: !0
|
62
|
-
}
|
63
|
-
}, b = () => {
|
64
|
-
const [a, c] = p([
|
65
|
-
{ id: 1, checked: !1 },
|
66
|
-
{ id: 2, checked: !0 },
|
67
|
-
{ id: 3, checked: !1 }
|
68
|
-
]), d = a.every((t) => t.checked), r = a.some((t) => t.checked);
|
69
|
-
let n = !1;
|
70
|
-
d ? n = !0 : r && (n = "indeterminate");
|
71
|
-
const o = () => {
|
72
|
-
const t = !d;
|
73
|
-
c(a.map((l) => ({ ...l, checked: t })));
|
74
|
-
}, h = (t) => {
|
75
|
-
c(a.map((l) => l.id === t ? { ...l, checked: !l.checked } : l));
|
76
|
-
};
|
77
|
-
return /* @__PURE__ */ s("div", { style: { display: "flex", flexDirection: "column", gap: "8px" }, children: [
|
78
|
-
/* @__PURE__ */ e(
|
79
|
-
i,
|
80
|
-
{
|
81
|
-
label: "Выбрать все",
|
82
|
-
isChecked: n === !0,
|
83
|
-
isIndeterminate: n === "indeterminate",
|
84
|
-
onChange: o
|
85
|
-
}
|
86
|
-
),
|
87
|
-
/* @__PURE__ */ e("div", { style: { marginLeft: "24px", display: "flex", flexDirection: "column", gap: "8px" }, children: a.map((t) => /* @__PURE__ */ e(
|
88
|
-
i,
|
89
|
-
{
|
90
|
-
label: `Элемент ${t.id}`,
|
91
|
-
isChecked: t.checked,
|
92
|
-
onChange: () => h(t.id)
|
93
|
-
},
|
94
|
-
t.id
|
95
|
-
)) })
|
96
|
-
] });
|
97
|
-
}, S = () => /* @__PURE__ */ s("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
98
|
-
/* @__PURE__ */ e(i, { label: "Обычный чекбокс" }),
|
99
|
-
/* @__PURE__ */ e(i, { label: "Выбранный чекбокс", isChecked: !0 }),
|
100
|
-
/* @__PURE__ */ e(i, { label: "Отключенный чекбокс", isDisabled: !0 }),
|
101
|
-
/* @__PURE__ */ e(i, { label: "Выбранный и отключенный", isChecked: !0, isDisabled: !0 }),
|
102
|
-
/* @__PURE__ */ e(i, { label: "Неопределённое состояние", isIndeterminate: !0 }),
|
103
|
-
/* @__PURE__ */ e(i, { label: "Неопределённое и отключенное", isIndeterminate: !0, isDisabled: !0 }),
|
104
|
-
/* @__PURE__ */ e(i, {})
|
105
|
-
] }), P = () => /* @__PURE__ */ e("div", { style: { display: "flex", flexDirection: "column", gap: "24px" }, children: /* @__PURE__ */ s("div", { children: [
|
106
|
-
/* @__PURE__ */ e("h1", { style: { fontSize: "24px", marginBottom: "24px" }, children: "Эмуляция родительского чекбокса с дочерними" }),
|
107
|
-
/* @__PURE__ */ e(b, {})
|
108
|
-
] }) });
|
109
|
-
export {
|
110
|
-
C as Checked,
|
111
|
-
D as CheckedDisabled,
|
112
|
-
g as Default,
|
113
|
-
f as Disabled,
|
114
|
-
I as Indeterminate,
|
115
|
-
v as IndeterminateDisabled,
|
116
|
-
P as InteractivePlayground,
|
117
|
-
S as States,
|
118
|
-
y as WithoutLabel,
|
119
|
-
k as default
|
120
|
-
};
|