@moni-labs/moni-ui 0.4.4 → 0.4.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/custom-elements.json +4670 -16030
- package/dist/browser/moni-ui.iife.min.js +848 -117
- package/dist/browser/moni-ui.iife.min.js.br +0 -0
- package/dist/browser/moni-ui.iife.min.js.gz +0 -0
- package/dist/browser/moni-ui.iife.min.js.map +1 -1
- package/dist/browser/moni-ui.min.js +3138 -1813
- package/dist/browser/moni-ui.min.js.br +0 -0
- package/dist/browser/moni-ui.min.js.gz +0 -0
- package/dist/browser/moni-ui.min.js.map +1 -1
- package/dist/cdn/components/moni-button-group.js +5 -3
- package/dist/cdn/components/moni-button.js +2 -2
- package/dist/cdn/components/moni-carousel.js +1 -1
- package/dist/cdn/components/moni-color-field.js +9 -6
- package/dist/cdn/components/moni-context-menu.js +4 -1
- package/dist/cdn/components/moni-file-field.js +9 -9
- package/dist/cdn/components/moni-morph-modal.js +2 -2
- package/dist/cdn/components/moni-nav.js +5 -5
- package/dist/cdn/components/moni-select.js +2 -0
- package/dist/cdn/components/moni-side-sheet.js +18 -6
- package/dist/cdn/components/moni-snackbar.js +15 -2
- package/dist/cdn/components/moni-stepper.js +1 -1
- package/dist/cdn/components/moni-text-field.js +2 -0
- package/dist/cdn/components/moni-textarea.js +2 -0
- package/dist/cdn/components/moni-toolbar.js +3 -1
- package/dist/cdn/components/moni-tooltip.js +60 -4
- package/dist/cdn/importmap.json +98 -98
- package/dist/components/index.d.ts +8 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +8 -0
- package/dist/components/moni-button-group.d.ts.map +1 -1
- package/dist/components/moni-button-group.js +15 -4
- package/dist/components/moni-button.js +2 -2
- package/dist/components/moni-carousel.d.ts +2 -0
- package/dist/components/moni-carousel.d.ts.map +1 -1
- package/dist/components/moni-carousel.js +18 -0
- package/dist/components/moni-color-field.d.ts +19 -0
- package/dist/components/moni-color-field.d.ts.map +1 -1
- package/dist/components/moni-color-field.js +43 -2
- package/dist/components/moni-context-menu.d.ts.map +1 -1
- package/dist/components/moni-context-menu.js +14 -3
- package/dist/components/moni-file-field.d.ts.map +1 -1
- package/dist/components/moni-file-field.js +6 -3
- package/dist/components/moni-morph-modal.d.ts +21 -0
- package/dist/components/moni-morph-modal.d.ts.map +1 -1
- package/dist/components/moni-morph-modal.js +574 -52
- package/dist/components/moni-nav.d.ts.map +1 -1
- package/dist/components/moni-nav.js +4 -3
- package/dist/components/moni-select-option.d.ts.map +1 -1
- package/dist/components/moni-select-option.js +19 -0
- package/dist/components/moni-select.d.ts.map +1 -1
- package/dist/components/moni-select.js +2 -0
- package/dist/components/moni-side-sheet.d.ts +5 -0
- package/dist/components/moni-side-sheet.d.ts.map +1 -1
- package/dist/components/moni-side-sheet.js +48 -17
- package/dist/components/moni-snackbar.d.ts +1 -0
- package/dist/components/moni-snackbar.d.ts.map +1 -1
- package/dist/components/moni-snackbar.js +21 -1
- package/dist/components/moni-stepper.d.ts.map +1 -1
- package/dist/components/moni-stepper.js +4 -0
- package/dist/components/moni-text-field.d.ts.map +1 -1
- package/dist/components/moni-text-field.js +2 -0
- package/dist/components/moni-textarea.d.ts.map +1 -1
- package/dist/components/moni-textarea.js +2 -0
- package/dist/components/moni-toolbar.d.ts.map +1 -1
- package/dist/components/moni-toolbar.js +3 -1
- package/dist/components/moni-tooltip.d.ts +11 -2
- package/dist/components/moni-tooltip.d.ts.map +1 -1
- package/dist/components/moni-tooltip.js +195 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/docs/COMPONENTS.md +10 -0
- package/docs/LLM-GUIDE.md +107 -0
- package/docs/PUBLISHING.md +31 -0
- package/docs/README.md +64 -0
- package/docs/api.json +6178 -0
- package/docs/assets/moni-app-bar/elevated--false.png +0 -0
- package/docs/assets/moni-app-bar/elevated--true.png +0 -0
- package/docs/assets/moni-app-bar/placement--bottom.png +0 -0
- package/docs/assets/moni-app-bar/placement--top.png +0 -0
- package/docs/assets/moni-app-bar/size--default.png +0 -0
- package/docs/assets/moni-app-bar/size--prominent.png +0 -0
- package/docs/assets/moni-app-bar/subtitle--default.png +0 -0
- package/docs/assets/moni-app-bar/title--default.png +0 -0
- package/docs/assets/moni-app-bar/variant--floating.png +0 -0
- package/docs/assets/moni-app-bar/variant--standard.png +0 -0
- package/docs/assets/moni-badge/border--false.png +0 -0
- package/docs/assets/moni-badge/border--true.png +0 -0
- package/docs/assets/moni-badge/color--error.png +0 -0
- package/docs/assets/moni-badge/color--primary.png +0 -0
- package/docs/assets/moni-badge/color--secondary.png +0 -0
- package/docs/assets/moni-badge/color--tertiary.png +0 -0
- package/docs/assets/moni-badge/inline--false.png +0 -0
- package/docs/assets/moni-badge/inline--true.png +0 -0
- package/docs/assets/moni-badge/position--bottom.png +0 -0
- package/docs/assets/moni-badge/position--empty.png +0 -0
- package/docs/assets/moni-badge/position--left.png +0 -0
- package/docs/assets/moni-badge/position--none.png +0 -0
- package/docs/assets/moni-badge/position--right.png +0 -0
- package/docs/assets/moni-badge/position--top.png +0 -0
- package/docs/assets/moni-badge/shape--circle.png +0 -0
- package/docs/assets/moni-badge/shape--empty.png +0 -0
- package/docs/assets/moni-badge/shape--min.png +0 -0
- package/docs/assets/moni-badge/shape--square.png +0 -0
- package/docs/assets/moni-badge/value--default.png +0 -0
- package/docs/assets/moni-bottom-sheet/expandedHeight--default.png +0 -0
- package/docs/assets/moni-bottom-sheet/handle--false.png +0 -0
- package/docs/assets/moni-bottom-sheet/handle--true.png +0 -0
- package/docs/assets/moni-bottom-sheet/maxWidth--default.png +0 -0
- package/docs/assets/moni-bottom-sheet/modal--false.png +0 -0
- package/docs/assets/moni-bottom-sheet/modal--true.png +0 -0
- package/docs/assets/moni-bottom-sheet/open--true.png +0 -0
- package/docs/assets/moni-bottom-sheet/positioning--absolute.png +0 -0
- package/docs/assets/moni-bottom-sheet/positioning--body.png +0 -0
- package/docs/assets/moni-bottom-sheet/positioning--fixed.png +0 -0
- package/docs/assets/moni-bottom-sheet/positioning--static.png +0 -0
- package/docs/assets/moni-bottom-sheet/size--auto.png +0 -0
- package/docs/assets/moni-bottom-sheet/size--large.png +0 -0
- package/docs/assets/moni-bottom-sheet/size--medium.png +0 -0
- package/docs/assets/moni-bottom-sheet/size--small.png +0 -0
- package/docs/assets/moni-bottom-sheet/title--default.png +0 -0
- package/docs/assets/moni-button/active--false.png +0 -0
- package/docs/assets/moni-button/active--true.png +0 -0
- package/docs/assets/moni-button/disabled--false.png +0 -0
- package/docs/assets/moni-button/disabled--true.png +0 -0
- package/docs/assets/moni-button/href--default.png +0 -0
- package/docs/assets/moni-button/icon--default.png +0 -0
- package/docs/assets/moni-button/iconTrailing--default.png +0 -0
- package/docs/assets/moni-button/loading--false.png +0 -0
- package/docs/assets/moni-button/loading--true.png +0 -0
- package/docs/assets/moni-button/shape--bottom-round-flat.png +0 -0
- package/docs/assets/moni-button/shape--bottom-round.png +0 -0
- package/docs/assets/moni-button/shape--circle.png +0 -0
- package/docs/assets/moni-button/shape--inner-round.png +0 -0
- package/docs/assets/moni-button/shape--left-round-flat.png +0 -0
- package/docs/assets/moni-button/shape--left-round.png +0 -0
- package/docs/assets/moni-button/shape--no-round.png +0 -0
- package/docs/assets/moni-button/shape--right-round-flat.png +0 -0
- package/docs/assets/moni-button/shape--right-round.png +0 -0
- package/docs/assets/moni-button/shape--round.png +0 -0
- package/docs/assets/moni-button/shape--square.png +0 -0
- package/docs/assets/moni-button/shape--top-round-flat.png +0 -0
- package/docs/assets/moni-button/shape--top-round.png +0 -0
- package/docs/assets/moni-button/size--extra.png +0 -0
- package/docs/assets/moni-button/size--large.png +0 -0
- package/docs/assets/moni-button/size--medium.png +0 -0
- package/docs/assets/moni-button/size--small.png +0 -0
- package/docs/assets/moni-button/size--xlarge.png +0 -0
- package/docs/assets/moni-button/size--xsmall.png +0 -0
- package/docs/assets/moni-button/type--button.png +0 -0
- package/docs/assets/moni-button/type--reset.png +0 -0
- package/docs/assets/moni-button/type--submit.png +0 -0
- package/docs/assets/moni-button/variant--elevated.png +0 -0
- package/docs/assets/moni-button/variant--error.png +0 -0
- package/docs/assets/moni-button/variant--fill.png +0 -0
- package/docs/assets/moni-button/variant--filled.png +0 -0
- package/docs/assets/moni-button/variant--outlined.png +0 -0
- package/docs/assets/moni-button/variant--text.png +0 -0
- package/docs/assets/moni-button/variant--tonal.png +0 -0
- package/docs/assets/moni-button-group/gap--default.png +0 -0
- package/docs/assets/moni-button-group/label--default.png +0 -0
- package/docs/assets/moni-button-group/labelledBy--default.png +0 -0
- package/docs/assets/moni-button-group/multi--false.png +0 -0
- package/docs/assets/moni-button-group/multi--true.png +0 -0
- package/docs/assets/moni-button-group/resizing--fixed.png +0 -0
- package/docs/assets/moni-button-group/resizing--flexible.png +0 -0
- package/docs/assets/moni-button-group/role--group.png +0 -0
- package/docs/assets/moni-button-group/role--radiogroup.png +0 -0
- package/docs/assets/moni-button-group/role--toolbar.png +0 -0
- package/docs/assets/moni-button-group/selectionRequired--false.png +0 -0
- package/docs/assets/moni-button-group/selectionRequired--true.png +0 -0
- package/docs/assets/moni-button-group/shape--round.png +0 -0
- package/docs/assets/moni-button-group/shape--square.png +0 -0
- package/docs/assets/moni-button-group/size--extra.png +0 -0
- package/docs/assets/moni-button-group/size--large.png +0 -0
- package/docs/assets/moni-button-group/size--medium.png +0 -0
- package/docs/assets/moni-button-group/size--small.png +0 -0
- package/docs/assets/moni-button-group/size--xlarge.png +0 -0
- package/docs/assets/moni-button-group/size--xsmall.png +0 -0
- package/docs/assets/moni-button-group/variant--connected.png +0 -0
- package/docs/assets/moni-button-group/variant--standard.png +0 -0
- package/docs/assets/moni-button-segment/checked--false.png +0 -0
- package/docs/assets/moni-button-segment/checked--true.png +0 -0
- package/docs/assets/moni-button-segment/disabled--false.png +0 -0
- package/docs/assets/moni-button-segment/disabled--true.png +0 -0
- package/docs/assets/moni-button-segment/hideCheck--false.png +0 -0
- package/docs/assets/moni-button-segment/hideCheck--true.png +0 -0
- package/docs/assets/moni-button-segment/position--first.png +0 -0
- package/docs/assets/moni-button-segment/position--last.png +0 -0
- package/docs/assets/moni-button-segment/position--middle.png +0 -0
- package/docs/assets/moni-button-segment/position--solo.png +0 -0
- package/docs/assets/moni-button-segment/size--extra.png +0 -0
- package/docs/assets/moni-button-segment/size--large.png +0 -0
- package/docs/assets/moni-button-segment/size--medium.png +0 -0
- package/docs/assets/moni-button-segment/size--small.png +0 -0
- package/docs/assets/moni-button-segment/size--xlarge.png +0 -0
- package/docs/assets/moni-button-segment/size--xsmall.png +0 -0
- package/docs/assets/moni-button-segment/value--default.png +0 -0
- package/docs/assets/moni-card/clickable--false.png +0 -0
- package/docs/assets/moni-card/clickable--true.png +0 -0
- package/docs/assets/moni-card/disabled--false.png +0 -0
- package/docs/assets/moni-card/disabled--true.png +0 -0
- package/docs/assets/moni-card/draggable--false.png +0 -0
- package/docs/assets/moni-card/draggable--true.png +0 -0
- package/docs/assets/moni-card/variant--elevated.png +0 -0
- package/docs/assets/moni-card/variant--filled.png +0 -0
- package/docs/assets/moni-card/variant--outlined.png +0 -0
- package/docs/assets/moni-carousel/auto--false.png +0 -0
- package/docs/assets/moni-carousel/auto--true.png +0 -0
- package/docs/assets/moni-carousel/autoplay--false.png +0 -0
- package/docs/assets/moni-carousel/autoplay--true.png +0 -0
- package/docs/assets/moni-carousel/autoplayInterval--default.png +0 -0
- package/docs/assets/moni-carousel/borderRadius--default.png +0 -0
- package/docs/assets/moni-carousel/gap--default.png +0 -0
- package/docs/assets/moni-carousel/headerText--default.png +0 -0
- package/docs/assets/moni-carousel/hideNav--false.png +0 -0
- package/docs/assets/moni-carousel/hideNav--true.png +0 -0
- package/docs/assets/moni-carousel/infinite--false.png +0 -0
- package/docs/assets/moni-carousel/infinite--true.png +0 -0
- package/docs/assets/moni-carousel/items--default.png +0 -0
- package/docs/assets/moni-carousel/largeWidth--default.png +0 -0
- package/docs/assets/moni-carousel/layout--hero.png +0 -0
- package/docs/assets/moni-carousel/layout--multi-browse.png +0 -0
- package/docs/assets/moni-carousel/layout--uncontained.png +0 -0
- package/docs/assets/moni-carousel/mediumWidth--default.png +0 -0
- package/docs/assets/moni-carousel/padding--default.png +0 -0
- package/docs/assets/moni-carousel/showAll--false.png +0 -0
- package/docs/assets/moni-carousel/showAll--true.png +0 -0
- package/docs/assets/moni-carousel/showAllText--default.png +0 -0
- package/docs/assets/moni-carousel/smallWidth--default.png +0 -0
- package/docs/assets/moni-checkbox/checked--false.png +0 -0
- package/docs/assets/moni-checkbox/checked--true.png +0 -0
- package/docs/assets/moni-checkbox/checkedIcon--default.png +0 -0
- package/docs/assets/moni-checkbox/disabled--false.png +0 -0
- package/docs/assets/moni-checkbox/disabled--true.png +0 -0
- package/docs/assets/moni-checkbox/label--default.png +0 -0
- package/docs/assets/moni-checkbox/name--default.png +0 -0
- package/docs/assets/moni-checkbox/size--extra.png +0 -0
- package/docs/assets/moni-checkbox/size--large.png +0 -0
- package/docs/assets/moni-checkbox/size--medium.png +0 -0
- package/docs/assets/moni-checkbox/size--small.png +0 -0
- package/docs/assets/moni-checkbox/uncheckedIcon--default.png +0 -0
- package/docs/assets/moni-checkbox/value--default.png +0 -0
- package/docs/assets/moni-chip/disabled--false.png +0 -0
- package/docs/assets/moni-chip/disabled--true.png +0 -0
- package/docs/assets/moni-chip/icon--default.png +0 -0
- package/docs/assets/moni-chip/loading--false.png +0 -0
- package/docs/assets/moni-chip/loading--true.png +0 -0
- package/docs/assets/moni-chip/removable--false.png +0 -0
- package/docs/assets/moni-chip/removable--true.png +0 -0
- package/docs/assets/moni-chip/selected--false.png +0 -0
- package/docs/assets/moni-chip/selected--true.png +0 -0
- package/docs/assets/moni-chip/shape--bottom-round.png +0 -0
- package/docs/assets/moni-chip/shape--circle.png +0 -0
- package/docs/assets/moni-chip/shape--left-round.png +0 -0
- package/docs/assets/moni-chip/shape--no-round.png +0 -0
- package/docs/assets/moni-chip/shape--right-round.png +0 -0
- package/docs/assets/moni-chip/shape--round.png +0 -0
- package/docs/assets/moni-chip/shape--square.png +0 -0
- package/docs/assets/moni-chip/shape--top-round.png +0 -0
- package/docs/assets/moni-chip/size--large.png +0 -0
- package/docs/assets/moni-chip/size--medium.png +0 -0
- package/docs/assets/moni-chip/size--small.png +0 -0
- package/docs/assets/moni-chip/variant--assist.png +0 -0
- package/docs/assets/moni-chip/variant--fill.png +0 -0
- package/docs/assets/moni-chip/variant--filter.png +0 -0
- package/docs/assets/moni-chip/variant--input.png +0 -0
- package/docs/assets/moni-chip/variant--outlined.png +0 -0
- package/docs/assets/moni-chip/variant--suggestion.png +0 -0
- package/docs/assets/moni-color-field/disabled--false.png +0 -0
- package/docs/assets/moni-color-field/disabled--true.png +0 -0
- package/docs/assets/moni-color-field/error--false.png +0 -0
- package/docs/assets/moni-color-field/error--true.png +0 -0
- package/docs/assets/moni-color-field/errorText--default.png +0 -0
- package/docs/assets/moni-color-field/helper--default.png +0 -0
- package/docs/assets/moni-color-field/label--default.png +0 -0
- package/docs/assets/moni-color-field/name--default.png +0 -0
- package/docs/assets/moni-color-field/shape--no-round.png +0 -0
- package/docs/assets/moni-color-field/shape--round.png +0 -0
- package/docs/assets/moni-color-field/shape--square.png +0 -0
- package/docs/assets/moni-color-field/size--extra.png +0 -0
- package/docs/assets/moni-color-field/size--large.png +0 -0
- package/docs/assets/moni-color-field/size--medium.png +0 -0
- package/docs/assets/moni-color-field/size--small.png +0 -0
- package/docs/assets/moni-color-field/value--default.png +0 -0
- package/docs/assets/moni-color-field/variant--filled.png +0 -0
- package/docs/assets/moni-color-field/variant--outlined.png +0 -0
- package/docs/assets/moni-context-menu/flip--false.png +0 -0
- package/docs/assets/moni-context-menu/flip--true.png +0 -0
- package/docs/assets/moni-context-menu/placement--bottom.png +0 -0
- package/docs/assets/moni-context-menu/placement--left.png +0 -0
- package/docs/assets/moni-context-menu/placement--right.png +0 -0
- package/docs/assets/moni-context-menu/placement--top.png +0 -0
- package/docs/assets/moni-dialog/modal--false.png +0 -0
- package/docs/assets/moni-dialog/modal--true.png +0 -0
- package/docs/assets/moni-dialog/open--true.png +0 -0
- package/docs/assets/moni-dialog/side--bottom.png +0 -0
- package/docs/assets/moni-dialog/side--center.png +0 -0
- package/docs/assets/moni-dialog/side--left.png +0 -0
- package/docs/assets/moni-dialog/side--max.png +0 -0
- package/docs/assets/moni-dialog/side--right.png +0 -0
- package/docs/assets/moni-dialog/side--top.png +0 -0
- package/docs/assets/moni-dialog/size--large.png +0 -0
- package/docs/assets/moni-dialog/size--medium.png +0 -0
- package/docs/assets/moni-dialog/size--small.png +0 -0
- package/docs/assets/moni-dialog/title--default.png +0 -0
- package/docs/assets/moni-divider/inset--leading.png +0 -0
- package/docs/assets/moni-divider/inset--middle.png +0 -0
- package/docs/assets/moni-divider/inset--none.png +0 -0
- package/docs/assets/moni-expansion/open--false.png +0 -0
- package/docs/assets/moni-expansion/open--true.png +0 -0
- package/docs/assets/moni-expansion/title--default.png +0 -0
- package/docs/assets/moni-fab/accessibleLabel--default.png +0 -0
- package/docs/assets/moni-fab/color--default.png +0 -0
- package/docs/assets/moni-fab/disabled--false.png +0 -0
- package/docs/assets/moni-fab/disabled--true.png +0 -0
- package/docs/assets/moni-fab/expanded--false.png +0 -0
- package/docs/assets/moni-fab/expanded--true.png +0 -0
- package/docs/assets/moni-fab/extended--false.png +0 -0
- package/docs/assets/moni-fab/extended--true.png +0 -0
- package/docs/assets/moni-fab/icon--default.png +0 -0
- package/docs/assets/moni-fab/label--default.png +0 -0
- package/docs/assets/moni-fab/name--default.png +0 -0
- package/docs/assets/moni-fab/position--default.png +0 -0
- package/docs/assets/moni-fab/shape--circle.png +0 -0
- package/docs/assets/moni-fab/shape--rounded.png +0 -0
- package/docs/assets/moni-fab/size--default.png +0 -0
- package/docs/assets/moni-fab/type--button.png +0 -0
- package/docs/assets/moni-fab/type--reset.png +0 -0
- package/docs/assets/moni-fab/type--submit.png +0 -0
- package/docs/assets/moni-fab/value--default.png +0 -0
- package/docs/assets/moni-fab-menu/closeIcon--default.png +0 -0
- package/docs/assets/moni-fab-menu/closeLabel--default.png +0 -0
- package/docs/assets/moni-fab-menu/color--default.png +0 -0
- package/docs/assets/moni-fab-menu/direction--default.png +0 -0
- package/docs/assets/moni-fab-menu/disabled--false.png +0 -0
- package/docs/assets/moni-fab-menu/disabled--true.png +0 -0
- package/docs/assets/moni-fab-menu/icon--default.png +0 -0
- package/docs/assets/moni-fab-menu/label--default.png +0 -0
- package/docs/assets/moni-fab-menu/open--false.png +0 -0
- package/docs/assets/moni-fab-menu/open--true.png +0 -0
- package/docs/assets/moni-fab-menu/position--default.png +0 -0
- package/docs/assets/moni-fab-menu/shape--circle.png +0 -0
- package/docs/assets/moni-fab-menu/shape--rounded.png +0 -0
- package/docs/assets/moni-fab-menu/size--default.png +0 -0
- package/docs/assets/moni-file-field/accept--default.png +0 -0
- package/docs/assets/moni-file-field/buttonLabel--default.png +0 -0
- package/docs/assets/moni-file-field/disabled--false.png +0 -0
- package/docs/assets/moni-file-field/disabled--true.png +0 -0
- package/docs/assets/moni-file-field/error--false.png +0 -0
- package/docs/assets/moni-file-field/error--true.png +0 -0
- package/docs/assets/moni-file-field/errorText--default.png +0 -0
- package/docs/assets/moni-file-field/helper--default.png +0 -0
- package/docs/assets/moni-file-field/icon--default.png +0 -0
- package/docs/assets/moni-file-field/label--default.png +0 -0
- package/docs/assets/moni-file-field/multiple--false.png +0 -0
- package/docs/assets/moni-file-field/multiple--true.png +0 -0
- package/docs/assets/moni-file-field/name--default.png +0 -0
- package/docs/assets/moni-file-field/shape--no-round.png +0 -0
- package/docs/assets/moni-file-field/shape--round.png +0 -0
- package/docs/assets/moni-file-field/shape--square.png +0 -0
- package/docs/assets/moni-file-field/size--extra.png +0 -0
- package/docs/assets/moni-file-field/size--large.png +0 -0
- package/docs/assets/moni-file-field/size--medium.png +0 -0
- package/docs/assets/moni-file-field/size--small.png +0 -0
- package/docs/assets/moni-file-field/trailingIcon--default.png +0 -0
- package/docs/assets/moni-file-field/value--default.png +0 -0
- package/docs/assets/moni-file-field/variant--filled.png +0 -0
- package/docs/assets/moni-file-field/variant--outlined.png +0 -0
- package/docs/assets/moni-icon/filled--false.png +0 -0
- package/docs/assets/moni-icon/filled--true.png +0 -0
- package/docs/assets/moni-icon/name--default.png +0 -0
- package/docs/assets/moni-icon/size--extra.png +0 -0
- package/docs/assets/moni-icon/size--large.png +0 -0
- package/docs/assets/moni-icon/size--medium.png +0 -0
- package/docs/assets/moni-icon/size--small.png +0 -0
- package/docs/assets/moni-icon/size--tiny.png +0 -0
- package/docs/assets/moni-list/rounded--false.png +0 -0
- package/docs/assets/moni-list/rounded--true.png +0 -0
- package/docs/assets/moni-list/variant--border.png +0 -0
- package/docs/assets/moni-list/variant--empty.png +0 -0
- package/docs/assets/moni-list-item/active--false.png +0 -0
- package/docs/assets/moni-list-item/active--true.png +0 -0
- package/docs/assets/moni-list-item/avatar--default.png +0 -0
- package/docs/assets/moni-list-item/disabled--false.png +0 -0
- package/docs/assets/moni-list-item/disabled--true.png +0 -0
- package/docs/assets/moni-list-item/href--default.png +0 -0
- package/docs/assets/moni-list-item/icon--default.png +0 -0
- package/docs/assets/moni-list-item/lines--default.png +0 -0
- package/docs/assets/moni-list-item/trailingIcon--default.png +0 -0
- package/docs/assets/moni-loading-indicator/variant--contained.png +0 -0
- package/docs/assets/moni-loading-indicator/variant--uncontained.png +0 -0
- package/docs/assets/moni-menu/active--true.png +0 -0
- package/docs/assets/moni-menu/flip--false.png +0 -0
- package/docs/assets/moni-menu/flip--true.png +0 -0
- package/docs/assets/moni-menu/noWrap--false.png +0 -0
- package/docs/assets/moni-menu/noWrap--true.png +0 -0
- package/docs/assets/moni-menu/placement--bottom.png +0 -0
- package/docs/assets/moni-menu/placement--left.png +0 -0
- package/docs/assets/moni-menu/placement--max.png +0 -0
- package/docs/assets/moni-menu/placement--min.png +0 -0
- package/docs/assets/moni-menu/placement--right.png +0 -0
- package/docs/assets/moni-menu/placement--top.png +0 -0
- package/docs/assets/moni-menu/space--extra-space.png +0 -0
- package/docs/assets/moni-menu/space--large-space.png +0 -0
- package/docs/assets/moni-menu/space--medium-space.png +0 -0
- package/docs/assets/moni-menu/space--no-space.png +0 -0
- package/docs/assets/moni-menu/space--small-space.png +0 -0
- package/docs/assets/moni-menu/space--space.png +0 -0
- package/docs/assets/moni-menu-item/active--false.png +0 -0
- package/docs/assets/moni-menu-item/active--true.png +0 -0
- package/docs/assets/moni-menu-item/disabled--false.png +0 -0
- package/docs/assets/moni-menu-item/disabled--true.png +0 -0
- package/docs/assets/moni-menu-item/icon--default.png +0 -0
- package/docs/assets/moni-menu-item/label--default.png +0 -0
- package/docs/assets/moni-morph-modal/autoSize--false.png +0 -0
- package/docs/assets/moni-morph-modal/autoSize--true.png +0 -0
- package/docs/assets/moni-morph-modal/expandedHeight--default.png +0 -0
- package/docs/assets/moni-morph-modal/expandedWidth--default.png +0 -0
- package/docs/assets/moni-morph-modal/hasBackdrop--false.png +0 -0
- package/docs/assets/moni-morph-modal/hasBackdrop--true.png +0 -0
- package/docs/assets/moni-morph-modal/modal--false.png +0 -0
- package/docs/assets/moni-morph-modal/modal--true.png +0 -0
- package/docs/assets/moni-morph-modal/open--true.png +0 -0
- package/docs/assets/moni-morph-modal/placement--default.png +0 -0
- package/docs/assets/moni-morph-modal/showCloseButton--false.png +0 -0
- package/docs/assets/moni-morph-modal/showCloseButton--true.png +0 -0
- package/docs/assets/moni-nav/layout--auto.png +0 -0
- package/docs/assets/moni-nav/layout--horizontal.png +0 -0
- package/docs/assets/moni-nav/layout--vertical.png +0 -0
- package/docs/assets/moni-nav/modal--false.png +0 -0
- package/docs/assets/moni-nav/modal--true.png +0 -0
- package/docs/assets/moni-nav/open--false.png +0 -0
- package/docs/assets/moni-nav/open--true.png +0 -0
- package/docs/assets/moni-nav/placement--bottom.png +0 -0
- package/docs/assets/moni-nav/placement--left.png +0 -0
- package/docs/assets/moni-nav/placement--right.png +0 -0
- package/docs/assets/moni-nav/placement--top.png +0 -0
- package/docs/assets/moni-nav/variant--drawer.png +0 -0
- package/docs/assets/moni-nav/variant--rail.png +0 -0
- package/docs/assets/moni-nav-item/active--false.png +0 -0
- package/docs/assets/moni-nav-item/active--true.png +0 -0
- package/docs/assets/moni-nav-item/href--default.png +0 -0
- package/docs/assets/moni-nav-item/icon--default.png +0 -0
- package/docs/assets/moni-nav-item/label--default.png +0 -0
- package/docs/assets/moni-nav-item/layout--default.png +0 -0
- package/docs/assets/moni-nav-item/placement--default.png +0 -0
- package/docs/assets/moni-nav-item/variant--default.png +0 -0
- package/docs/assets/moni-progress/bufferValue--default.png +0 -0
- package/docs/assets/moni-progress/indeterminate--false.png +0 -0
- package/docs/assets/moni-progress/indeterminate--true.png +0 -0
- package/docs/assets/moni-progress/label--default.png +0 -0
- package/docs/assets/moni-progress/max--default.png +0 -0
- package/docs/assets/moni-progress/mode--default.png +0 -0
- package/docs/assets/moni-progress/size--default.png +0 -0
- package/docs/assets/moni-progress/stopIndicator--false.png +0 -0
- package/docs/assets/moni-progress/stopIndicator--true.png +0 -0
- package/docs/assets/moni-progress/value--default.png +0 -0
- package/docs/assets/moni-progress/variant--default.png +0 -0
- package/docs/assets/moni-progress/waveTransition--false.png +0 -0
- package/docs/assets/moni-progress/waveTransition--true.png +0 -0
- package/docs/assets/moni-radio/checked--false.png +0 -0
- package/docs/assets/moni-radio/checked--true.png +0 -0
- package/docs/assets/moni-radio/checkedIcon--default.png +0 -0
- package/docs/assets/moni-radio/disabled--false.png +0 -0
- package/docs/assets/moni-radio/disabled--true.png +0 -0
- package/docs/assets/moni-radio/iconContainer--circle.png +0 -0
- package/docs/assets/moni-radio/iconContainer--none.png +0 -0
- package/docs/assets/moni-radio/label--default.png +0 -0
- package/docs/assets/moni-radio/name--default.png +0 -0
- package/docs/assets/moni-radio/size--extra.png +0 -0
- package/docs/assets/moni-radio/size--large.png +0 -0
- package/docs/assets/moni-radio/size--medium.png +0 -0
- package/docs/assets/moni-radio/size--small.png +0 -0
- package/docs/assets/moni-radio/uncheckedIcon--default.png +0 -0
- package/docs/assets/moni-radio/value--default.png +0 -0
- package/docs/assets/moni-ripple/active--false.png +0 -0
- package/docs/assets/moni-ripple/active--true.png +0 -0
- package/docs/assets/moni-ripple/color--primary.png +0 -0
- package/docs/assets/moni-ripple/color--secondary.png +0 -0
- package/docs/assets/moni-ripple/color--surface.png +0 -0
- package/docs/assets/moni-ripple/speed--fast.png +0 -0
- package/docs/assets/moni-ripple/speed--normal.png +0 -0
- package/docs/assets/moni-ripple/speed--slow.png +0 -0
- package/docs/assets/moni-ripple/x--default.png +0 -0
- package/docs/assets/moni-ripple/y--default.png +0 -0
- package/docs/assets/moni-segmented-button/gap--default.png +0 -0
- package/docs/assets/moni-segmented-button/hideCheck--false.png +0 -0
- package/docs/assets/moni-segmented-button/hideCheck--true.png +0 -0
- package/docs/assets/moni-segmented-button/multi--false.png +0 -0
- package/docs/assets/moni-segmented-button/multi--true.png +0 -0
- package/docs/assets/moni-segmented-button/name--default.png +0 -0
- package/docs/assets/moni-segmented-button/size--extra.png +0 -0
- package/docs/assets/moni-segmented-button/size--large.png +0 -0
- package/docs/assets/moni-segmented-button/size--medium.png +0 -0
- package/docs/assets/moni-segmented-button/size--small.png +0 -0
- package/docs/assets/moni-segmented-button/size--xlarge.png +0 -0
- package/docs/assets/moni-segmented-button/size--xsmall.png +0 -0
- package/docs/assets/moni-select/clearable--false.png +0 -0
- package/docs/assets/moni-select/clearable--true.png +0 -0
- package/docs/assets/moni-select/disabled--false.png +0 -0
- package/docs/assets/moni-select/disabled--true.png +0 -0
- package/docs/assets/moni-select/dropdownMaxHeight--default.png +0 -0
- package/docs/assets/moni-select/dropdownWidth--default.png +0 -0
- package/docs/assets/moni-select/error--false.png +0 -0
- package/docs/assets/moni-select/error--true.png +0 -0
- package/docs/assets/moni-select/errorText--default.png +0 -0
- package/docs/assets/moni-select/helper--default.png +0 -0
- package/docs/assets/moni-select/icon--default.png +0 -0
- package/docs/assets/moni-select/label--default.png +0 -0
- package/docs/assets/moni-select/loading--false.png +0 -0
- package/docs/assets/moni-select/loading--true.png +0 -0
- package/docs/assets/moni-select/name--default.png +0 -0
- package/docs/assets/moni-select/placeholder--default.png +0 -0
- package/docs/assets/moni-select/placement--auto.png +0 -0
- package/docs/assets/moni-select/placement--bottom.png +0 -0
- package/docs/assets/moni-select/placement--left.png +0 -0
- package/docs/assets/moni-select/placement--right.png +0 -0
- package/docs/assets/moni-select/placement--top.png +0 -0
- package/docs/assets/moni-select/positioning--absolute.png +0 -0
- package/docs/assets/moni-select/positioning--body.png +0 -0
- package/docs/assets/moni-select/positioning--fixed.png +0 -0
- package/docs/assets/moni-select/searchable--false.png +0 -0
- package/docs/assets/moni-select/searchable--true.png +0 -0
- package/docs/assets/moni-select/shape--no-round.png +0 -0
- package/docs/assets/moni-select/shape--round.png +0 -0
- package/docs/assets/moni-select/shape--square.png +0 -0
- package/docs/assets/moni-select/sheet--false.png +0 -0
- package/docs/assets/moni-select/sheet--true.png +0 -0
- package/docs/assets/moni-select/size--extra.png +0 -0
- package/docs/assets/moni-select/size--large.png +0 -0
- package/docs/assets/moni-select/size--medium.png +0 -0
- package/docs/assets/moni-select/size--small.png +0 -0
- package/docs/assets/moni-select/trailingIcon--default.png +0 -0
- package/docs/assets/moni-select/value--default.png +0 -0
- package/docs/assets/moni-select/variant--filled.png +0 -0
- package/docs/assets/moni-select/variant--outlined.png +0 -0
- package/docs/assets/moni-select-option/disabled--false.png +0 -0
- package/docs/assets/moni-select-option/disabled--true.png +0 -0
- package/docs/assets/moni-select-option/group--default.png +0 -0
- package/docs/assets/moni-select-option/label--default.png +0 -0
- package/docs/assets/moni-select-option/selected--false.png +0 -0
- package/docs/assets/moni-select-option/selected--true.png +0 -0
- package/docs/assets/moni-select-option/value--default.png +0 -0
- package/docs/assets/moni-shape/border--false.png +0 -0
- package/docs/assets/moni-shape/border--true.png +0 -0
- package/docs/assets/moni-shape/color--primary.png +0 -0
- package/docs/assets/moni-shape/color--secondary.png +0 -0
- package/docs/assets/moni-shape/color--surface.png +0 -0
- package/docs/assets/moni-shape/color--tertiary.png +0 -0
- package/docs/assets/moni-shape/duration--default.png +0 -0
- package/docs/assets/moni-shape/easing--default.png +0 -0
- package/docs/assets/moni-shape/name--empty.png +0 -0
- package/docs/assets/moni-shape/shadow--false.png +0 -0
- package/docs/assets/moni-shape/shadow--true.png +0 -0
- package/docs/assets/moni-shape/shapeRadius--default.png +0 -0
- package/docs/assets/moni-shape/size--extra.png +0 -0
- package/docs/assets/moni-shape/size--large.png +0 -0
- package/docs/assets/moni-shape/size--medium.png +0 -0
- package/docs/assets/moni-shape/size--small.png +0 -0
- package/docs/assets/moni-shape/type--default.png +0 -0
- package/docs/assets/moni-side-sheet/detached--false.png +0 -0
- package/docs/assets/moni-side-sheet/detached--true.png +0 -0
- package/docs/assets/moni-side-sheet/expandedWidth--default.png +0 -0
- package/docs/assets/moni-side-sheet/hideClose--false.png +0 -0
- package/docs/assets/moni-side-sheet/hideClose--true.png +0 -0
- package/docs/assets/moni-side-sheet/maxWidth--default.png +0 -0
- package/docs/assets/moni-side-sheet/modal--false.png +0 -0
- package/docs/assets/moni-side-sheet/modal--true.png +0 -0
- package/docs/assets/moni-side-sheet/noBorder--false.png +0 -0
- package/docs/assets/moni-side-sheet/noBorder--true.png +0 -0
- package/docs/assets/moni-side-sheet/open--true.png +0 -0
- package/docs/assets/moni-side-sheet/showBack--false.png +0 -0
- package/docs/assets/moni-side-sheet/showBack--true.png +0 -0
- package/docs/assets/moni-side-sheet/side--left.png +0 -0
- package/docs/assets/moni-side-sheet/side--right.png +0 -0
- package/docs/assets/moni-side-sheet/title--default.png +0 -0
- package/docs/assets/moni-side-sheet/withHandle--false.png +0 -0
- package/docs/assets/moni-side-sheet/withHandle--true.png +0 -0
- package/docs/assets/moni-slider/disabled--false.png +0 -0
- package/docs/assets/moni-slider/disabled--true.png +0 -0
- package/docs/assets/moni-slider/indicator--false.png +0 -0
- package/docs/assets/moni-slider/indicator--true.png +0 -0
- package/docs/assets/moni-slider/indicatorPlacement--bottom.png +0 -0
- package/docs/assets/moni-slider/indicatorPlacement--top.png +0 -0
- package/docs/assets/moni-slider/insetIcon--default.png +0 -0
- package/docs/assets/moni-slider/isVertical--false.png +0 -0
- package/docs/assets/moni-slider/isVertical--true.png +0 -0
- package/docs/assets/moni-slider/max--default.png +0 -0
- package/docs/assets/moni-slider/min--default.png +0 -0
- package/docs/assets/moni-slider/name--default.png +0 -0
- package/docs/assets/moni-slider/range--false.png +0 -0
- package/docs/assets/moni-slider/range--true.png +0 -0
- package/docs/assets/moni-slider/size--extra.png +0 -0
- package/docs/assets/moni-slider/size--large.png +0 -0
- package/docs/assets/moni-slider/size--medium.png +0 -0
- package/docs/assets/moni-slider/size--small.png +0 -0
- package/docs/assets/moni-slider/size--tiny.png +0 -0
- package/docs/assets/moni-slider/step--default.png +0 -0
- package/docs/assets/moni-slider/tickInterval--default.png +0 -0
- package/docs/assets/moni-slider/ticks--false.png +0 -0
- package/docs/assets/moni-slider/ticks--true.png +0 -0
- package/docs/assets/moni-snackbar/action--default.png +0 -0
- package/docs/assets/moni-snackbar/active--true.png +0 -0
- package/docs/assets/moni-snackbar/maxLines--default.png +0 -0
- package/docs/assets/moni-snackbar/placement--bottom.png +0 -0
- package/docs/assets/moni-snackbar/placement--top.png +0 -0
- package/docs/assets/moni-snackbar/text--default.png +0 -0
- package/docs/assets/moni-split-button/gap--default.png +0 -0
- package/docs/assets/moni-split-button/size--extra.png +0 -0
- package/docs/assets/moni-split-button/size--large.png +0 -0
- package/docs/assets/moni-split-button/size--medium.png +0 -0
- package/docs/assets/moni-split-button/size--small.png +0 -0
- package/docs/assets/moni-split-button/size--xlarge.png +0 -0
- package/docs/assets/moni-split-button/size--xsmall.png +0 -0
- package/docs/assets/moni-split-button/variant--elevated.png +0 -0
- package/docs/assets/moni-split-button/variant--filled.png +0 -0
- package/docs/assets/moni-split-button/variant--outlined.png +0 -0
- package/docs/assets/moni-split-button/variant--tonal.png +0 -0
- package/docs/assets/moni-step/active--false.png +0 -0
- package/docs/assets/moni-step/active--true.png +0 -0
- package/docs/assets/moni-step/completed--false.png +0 -0
- package/docs/assets/moni-step/completed--true.png +0 -0
- package/docs/assets/moni-step/description--default.png +0 -0
- package/docs/assets/moni-step/icon--default.png +0 -0
- package/docs/assets/moni-step/index--default.png +0 -0
- package/docs/assets/moni-step/orientation--horizontal.png +0 -0
- package/docs/assets/moni-step/orientation--vertical.png +0 -0
- package/docs/assets/moni-step/title--default.png +0 -0
- package/docs/assets/moni-stepper/current--default.png +0 -0
- package/docs/assets/moni-stepper/orientation--horizontal.png +0 -0
- package/docs/assets/moni-stepper/orientation--vertical.png +0 -0
- package/docs/assets/moni-switch/checked--false.png +0 -0
- package/docs/assets/moni-switch/checked--true.png +0 -0
- package/docs/assets/moni-switch/checkedIcon--default.png +0 -0
- package/docs/assets/moni-switch/disabled--false.png +0 -0
- package/docs/assets/moni-switch/disabled--true.png +0 -0
- package/docs/assets/moni-switch/icon--false.png +0 -0
- package/docs/assets/moni-switch/icon--true.png +0 -0
- package/docs/assets/moni-switch/label--default.png +0 -0
- package/docs/assets/moni-switch/name--default.png +0 -0
- package/docs/assets/moni-switch/uncheckedIcon--default.png +0 -0
- package/docs/assets/moni-switch/value--default.png +0 -0
- package/docs/assets/moni-tab/active--false.png +0 -0
- package/docs/assets/moni-tab/active--true.png +0 -0
- package/docs/assets/moni-tab/href--default.png +0 -0
- package/docs/assets/moni-tab/icon--default.png +0 -0
- package/docs/assets/moni-tab/label--default.png +0 -0
- package/docs/assets/moni-tabs/align--center.png +0 -0
- package/docs/assets/moni-tabs/align--default.png +0 -0
- package/docs/assets/moni-tabs/align--left.png +0 -0
- package/docs/assets/moni-tabs/align--right.png +0 -0
- package/docs/assets/moni-tabs/indicatorSize--default.png +0 -0
- package/docs/assets/moni-tabs/indicatorSize--max.png +0 -0
- package/docs/assets/moni-tabs/indicatorSize--min.png +0 -0
- package/docs/assets/moni-tabs/mode--primary.png +0 -0
- package/docs/assets/moni-tabs/mode--secondary.png +0 -0
- package/docs/assets/moni-tabs/scrollable--false.png +0 -0
- package/docs/assets/moni-tabs/scrollable--true.png +0 -0
- package/docs/assets/moni-tabs/vertical--false.png +0 -0
- package/docs/assets/moni-tabs/vertical--true.png +0 -0
- package/docs/assets/moni-text-field/disabled--false.png +0 -0
- package/docs/assets/moni-text-field/disabled--true.png +0 -0
- package/docs/assets/moni-text-field/error--false.png +0 -0
- package/docs/assets/moni-text-field/error--true.png +0 -0
- package/docs/assets/moni-text-field/errorText--default.png +0 -0
- package/docs/assets/moni-text-field/helper--default.png +0 -0
- package/docs/assets/moni-text-field/icon--default.png +0 -0
- package/docs/assets/moni-text-field/label--default.png +0 -0
- package/docs/assets/moni-text-field/loading--false.png +0 -0
- package/docs/assets/moni-text-field/loading--true.png +0 -0
- package/docs/assets/moni-text-field/mask--default.png +0 -0
- package/docs/assets/moni-text-field/maskAlias--default.png +0 -0
- package/docs/assets/moni-text-field/maskOptions--default.png +0 -0
- package/docs/assets/moni-text-field/name--default.png +0 -0
- package/docs/assets/moni-text-field/placeholder--default.png +0 -0
- package/docs/assets/moni-text-field/prefix--default.png +0 -0
- package/docs/assets/moni-text-field/shape--no-round.png +0 -0
- package/docs/assets/moni-text-field/shape--round.png +0 -0
- package/docs/assets/moni-text-field/size--extra.png +0 -0
- package/docs/assets/moni-text-field/size--large.png +0 -0
- package/docs/assets/moni-text-field/size--medium.png +0 -0
- package/docs/assets/moni-text-field/size--small.png +0 -0
- package/docs/assets/moni-text-field/suffix--default.png +0 -0
- package/docs/assets/moni-text-field/suffixButtonIcon--default.png +0 -0
- package/docs/assets/moni-text-field/suffixButtonLabel--default.png +0 -0
- package/docs/assets/moni-text-field/trailingIcon--default.png +0 -0
- package/docs/assets/moni-text-field/type--email.png +0 -0
- package/docs/assets/moni-text-field/type--number.png +0 -0
- package/docs/assets/moni-text-field/type--password.png +0 -0
- package/docs/assets/moni-text-field/type--search.png +0 -0
- package/docs/assets/moni-text-field/type--tel.png +0 -0
- package/docs/assets/moni-text-field/type--text.png +0 -0
- package/docs/assets/moni-text-field/type--url.png +0 -0
- package/docs/assets/moni-text-field/value--default.png +0 -0
- package/docs/assets/moni-text-field/variant--filled.png +0 -0
- package/docs/assets/moni-text-field/variant--outlined.png +0 -0
- package/docs/assets/moni-text-field/variant--underlined.png +0 -0
- package/docs/assets/moni-textarea/autosize--false.png +0 -0
- package/docs/assets/moni-textarea/autosize--true.png +0 -0
- package/docs/assets/moni-textarea/disabled--false.png +0 -0
- package/docs/assets/moni-textarea/disabled--true.png +0 -0
- package/docs/assets/moni-textarea/error--false.png +0 -0
- package/docs/assets/moni-textarea/error--true.png +0 -0
- package/docs/assets/moni-textarea/errorText--default.png +0 -0
- package/docs/assets/moni-textarea/helper--default.png +0 -0
- package/docs/assets/moni-textarea/icon--default.png +0 -0
- package/docs/assets/moni-textarea/label--default.png +0 -0
- package/docs/assets/moni-textarea/loading--false.png +0 -0
- package/docs/assets/moni-textarea/loading--true.png +0 -0
- package/docs/assets/moni-textarea/maxRows--default.png +0 -0
- package/docs/assets/moni-textarea/maxlength--default.png +0 -0
- package/docs/assets/moni-textarea/name--default.png +0 -0
- package/docs/assets/moni-textarea/noCounter--false.png +0 -0
- package/docs/assets/moni-textarea/noCounter--true.png +0 -0
- package/docs/assets/moni-textarea/placeholder--default.png +0 -0
- package/docs/assets/moni-textarea/prefix--default.png +0 -0
- package/docs/assets/moni-textarea/rows--default.png +0 -0
- package/docs/assets/moni-textarea/shape--no-round.png +0 -0
- package/docs/assets/moni-textarea/shape--round.png +0 -0
- package/docs/assets/moni-textarea/shape--square.png +0 -0
- package/docs/assets/moni-textarea/size--extra.png +0 -0
- package/docs/assets/moni-textarea/size--large.png +0 -0
- package/docs/assets/moni-textarea/size--medium.png +0 -0
- package/docs/assets/moni-textarea/size--small.png +0 -0
- package/docs/assets/moni-textarea/suffix--default.png +0 -0
- package/docs/assets/moni-textarea/trailingIcon--default.png +0 -0
- package/docs/assets/moni-textarea/value--default.png +0 -0
- package/docs/assets/moni-textarea/variant--filled.png +0 -0
- package/docs/assets/moni-textarea/variant--outlined.png +0 -0
- package/docs/assets/moni-time-picker/hideHeadline--false.png +0 -0
- package/docs/assets/moni-time-picker/hideHeadline--true.png +0 -0
- package/docs/assets/moni-time-picker/hideModeToggle--false.png +0 -0
- package/docs/assets/moni-time-picker/hideModeToggle--true.png +0 -0
- package/docs/assets/moni-time-picker/hourLabel--default.png +0 -0
- package/docs/assets/moni-time-picker/minuteLabel--default.png +0 -0
- package/docs/assets/moni-time-picker/mode--dial.png +0 -0
- package/docs/assets/moni-time-picker/mode--input.png +0 -0
- package/docs/assets/moni-time-picker/orientation--auto.png +0 -0
- package/docs/assets/moni-time-picker/orientation--horizontal.png +0 -0
- package/docs/assets/moni-time-picker/orientation--vertical.png +0 -0
- package/docs/assets/moni-time-picker/use24Hour--false.png +0 -0
- package/docs/assets/moni-time-picker/use24Hour--true.png +0 -0
- package/docs/assets/moni-time-picker/value--default.png +0 -0
- package/docs/assets/moni-toolbar/scrolled--false.png +0 -0
- package/docs/assets/moni-toolbar/scrolled--true.png +0 -0
- package/docs/assets/moni-toolbar/title--default.png +0 -0
- package/docs/assets/moni-toolbar/type--floating.png +0 -0
- package/docs/assets/moni-toolbar/type--standard.png +0 -0
- package/docs/assets/moni-tooltip/position--bottom-end.png +0 -0
- package/docs/assets/moni-tooltip/position--bottom-start.png +0 -0
- package/docs/assets/moni-tooltip/position--bottom.png +0 -0
- package/docs/assets/moni-tooltip/position--left.png +0 -0
- package/docs/assets/moni-tooltip/position--right.png +0 -0
- package/docs/assets/moni-tooltip/position--top-end.png +0 -0
- package/docs/assets/moni-tooltip/position--top-start.png +0 -0
- package/docs/assets/moni-tooltip/position--top.png +0 -0
- package/docs/assets/moni-tooltip/rich--false.png +0 -0
- package/docs/assets/moni-tooltip/rich--true.png +0 -0
- package/docs/assets/moni-tooltip/rotateWithTarget--false.png +0 -0
- package/docs/assets/moni-tooltip/rotateWithTarget--true.png +0 -0
- package/docs/assets/moni-tooltip/size--empty.png +0 -0
- package/docs/assets/moni-tooltip/size--large.png +0 -0
- package/docs/assets/moni-tooltip/size--medium.png +0 -0
- package/docs/assets/moni-tooltip/size--small.png +0 -0
- package/docs/assets/moni-tooltip/text--default.png +0 -0
- package/docs/assets/moni-typography/as--default.png +0 -0
- package/docs/assets/moni-typography/size--large.png +0 -0
- package/docs/assets/moni-typography/size--medium.png +0 -0
- package/docs/assets/moni-typography/size--small.png +0 -0
- package/docs/assets/moni-typography/text--default.png +0 -0
- package/docs/assets/moni-typography/variant--body.png +0 -0
- package/docs/assets/moni-typography/variant--display.png +0 -0
- package/docs/assets/moni-typography/variant--headline.png +0 -0
- package/docs/assets/moni-typography/variant--label.png +0 -0
- package/docs/assets/moni-typography/variant--title.png +0 -0
- package/docs/components/app-bar.md +192 -0
- package/docs/components/badge.md +207 -0
- package/docs/components/bottom-sheet.md +220 -0
- package/docs/components/button-group.md +207 -0
- package/docs/components/button-segment.md +171 -0
- package/docs/components/button.md +277 -0
- package/docs/components/card.md +181 -0
- package/docs/components/carousel.md +275 -0
- package/docs/components/checkbox.md +196 -0
- package/docs/components/chip.md +222 -0
- package/docs/components/color-field.md +195 -0
- package/docs/components/context-menu.md +132 -0
- package/docs/components/dialog.md +193 -0
- package/docs/components/divider.md +123 -0
- package/docs/components/expansion.md +130 -0
- package/docs/components/fab-menu.md +162 -0
- package/docs/components/fab.md +202 -0
- package/docs/components/file-field.md +244 -0
- package/docs/components/icon.md +156 -0
- package/docs/components/list-item.md +189 -0
- package/docs/components/list.md +121 -0
- package/docs/components/loading-indicator.md +124 -0
- package/docs/components/menu-item.md +131 -0
- package/docs/components/menu.md +181 -0
- package/docs/components/morph-modal.md +183 -0
- package/docs/components/nav-item.md +169 -0
- package/docs/components/nav.md +172 -0
- package/docs/components/progress.md +172 -0
- package/docs/components/radio.md +200 -0
- package/docs/components/ripple.md +177 -0
- package/docs/components/segmented-button.md +145 -0
- package/docs/components/select-option.md +148 -0
- package/docs/components/select.md +332 -0
- package/docs/components/shape.md +169 -0
- package/docs/components/side-sheet.md +218 -0
- package/docs/components/slider.md +240 -0
- package/docs/components/snackbar.md +167 -0
- package/docs/components/split-button.md +148 -0
- package/docs/components/step.md +169 -0
- package/docs/components/stepper.md +121 -0
- package/docs/components/switch.md +198 -0
- package/docs/components/tab.md +133 -0
- package/docs/components/tabs.md +163 -0
- package/docs/components/text-field.md +321 -0
- package/docs/components/textarea.md +290 -0
- package/docs/components/time-picker.md +184 -0
- package/docs/components/toolbar.md +142 -0
- package/docs/components/tooltip.md +184 -0
- package/docs/components/typography.md +148 -0
- package/docs/llms.txt +53 -0
- package/package.json +6 -1
- package/src/components/index.test.ts +24 -0
- package/src/components/index.ts +8 -1
- package/src/components/moni-button-group.test.ts +15 -1
- package/src/components/moni-button-group.ts +19 -4
- package/src/components/moni-button.test.ts +8 -2
- package/src/components/moni-button.ts +2 -2
- package/src/components/moni-carousel.test.ts +15 -1
- package/src/components/moni-carousel.ts +19 -2
- package/src/components/moni-color-field.test.ts +71 -0
- package/src/components/moni-color-field.ts +50 -1
- package/src/components/moni-context-menu.test.ts +16 -0
- package/src/components/moni-context-menu.ts +14 -2
- package/src/components/moni-file-field.test.ts +4 -2
- package/src/components/moni-file-field.ts +6 -3
- package/src/components/moni-morph-modal.test.ts +173 -2
- package/src/components/moni-morph-modal.ts +622 -55
- package/src/components/moni-nav.ts +6 -3
- package/src/components/moni-select-option.ts +19 -0
- package/src/components/moni-select.test.ts +16 -0
- package/src/components/moni-select.ts +2 -0
- package/src/components/moni-side-sheet.test.ts +39 -2
- package/src/components/moni-side-sheet.ts +49 -17
- package/src/components/moni-snackbar.test.ts +16 -0
- package/src/components/moni-snackbar.ts +24 -1
- package/src/components/moni-stepper.ts +4 -0
- package/src/components/moni-text-field.test.ts +25 -0
- package/src/components/moni-text-field.ts +2 -0
- package/src/components/moni-textarea.test.ts +16 -0
- package/src/components/moni-textarea.ts +2 -0
- package/src/components/moni-toolbar.test.ts +6 -3
- package/src/components/moni-toolbar.ts +4 -2
- package/src/components/moni-tooltip.test.ts +77 -3
- package/src/components/moni-tooltip.ts +194 -3
- package/src/index.ts +8 -0
|
@@ -64,7 +64,7 @@ CustomEase.create('morph-close', '0.4, 0, 0.2, 1');
|
|
|
64
64
|
*
|
|
65
65
|
* @slot default - El contenido del cuerpo principal del modal.
|
|
66
66
|
* @slot header - Contenido de encabezado personalizado (sobrescribe el atributo `title`).
|
|
67
|
-
* @slot
|
|
67
|
+
* @slot footer - Botones de acción mostrados en la parte inferior derecha.
|
|
68
68
|
*/
|
|
69
69
|
const litBool = {
|
|
70
70
|
fromAttribute: (value) => value !== 'false' && value !== null,
|
|
@@ -162,6 +162,8 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
162
162
|
* @type {boolean}
|
|
163
163
|
*/
|
|
164
164
|
this.blurContent = false;
|
|
165
|
+
/** Muestra en consola el origen, geometría y estrategia usada por cada morph. */
|
|
166
|
+
this.debug = false;
|
|
165
167
|
this._hasHeader = false;
|
|
166
168
|
this._hasFooter = false;
|
|
167
169
|
this._hasTriggerLabel = false;
|
|
@@ -171,6 +173,8 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
171
173
|
this._handlingOpenChange = false;
|
|
172
174
|
this._zIndex = 100;
|
|
173
175
|
this._morphEls = { text: null, icon: null };
|
|
176
|
+
this._targetSnapshot = null;
|
|
177
|
+
this._originFallbacks = [];
|
|
174
178
|
this._targetStylesCache = new Map();
|
|
175
179
|
/**
|
|
176
180
|
* Handler encapsulado para el evento click en el trigger.
|
|
@@ -275,6 +279,7 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
275
279
|
console.warn('[moni-morph-modal] cannot show: target not found');
|
|
276
280
|
return;
|
|
277
281
|
}
|
|
282
|
+
this._captureOriginFallbacks(this._targetEl);
|
|
278
283
|
this._isAnimating = true;
|
|
279
284
|
// Flag interno para evitar loops infinitos en el hook `updated()`
|
|
280
285
|
this._handlingOpenChange = true;
|
|
@@ -288,6 +293,8 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
288
293
|
this.style.setProperty('--_z-index', String(this._zIndex));
|
|
289
294
|
this.style.setProperty('--_backdrop-duration', '0.38s');
|
|
290
295
|
this.style.setProperty('--_backdrop-ease', 'cubic-bezier(0.15, 0.85, 0.2, 1)');
|
|
296
|
+
if (this._backdrop)
|
|
297
|
+
gsap.set(this._backdrop, { clearProps: 'opacity,transition' });
|
|
291
298
|
// Fase "First": Ocultamos o cubrimos el trigger original según la configuración del desarrollador
|
|
292
299
|
this._hideTargetContent();
|
|
293
300
|
void this.updateComplete.then(async () => {
|
|
@@ -302,14 +309,15 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
302
309
|
await new Promise((resolve) => requestAnimationFrame(resolve));
|
|
303
310
|
// 1. "First": Calculamos el estado visual actual del trigger
|
|
304
311
|
const targetState = this._getTargetState(this._targetEl);
|
|
312
|
+
this._debugMorph('open', this._targetEl, 'target', [this._targetEl]);
|
|
305
313
|
const panel = this._panel;
|
|
306
314
|
// 2. "Invert": Posicionamos el modal como un clon visual exacto del trigger.
|
|
307
315
|
// Desactivamos la sombra y forzamos el color/borde para coincidir con el botón/FAB.
|
|
308
|
-
this._applyRect(panel, targetState.rect);
|
|
316
|
+
this._applyRect(panel, this._toPanelCoordinateRect(targetState.rect));
|
|
309
317
|
panel.style.backgroundColor = targetState.backgroundColor;
|
|
310
318
|
panel.style.color = targetState.color;
|
|
311
319
|
panel.style.borderRadius = targetState.borderRadius;
|
|
312
|
-
panel.style.boxShadow =
|
|
320
|
+
panel.style.boxShadow = targetState.boxShadow;
|
|
313
321
|
panel.style.zIndex = String(this._zIndex);
|
|
314
322
|
panel.style.visibility = 'visible';
|
|
315
323
|
panel.style.opacity = '1';
|
|
@@ -544,8 +552,6 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
544
552
|
hide() {
|
|
545
553
|
if (this._isAnimating || !this._visible)
|
|
546
554
|
return;
|
|
547
|
-
if (!this._targetEl)
|
|
548
|
-
return;
|
|
549
555
|
this._isAnimating = true;
|
|
550
556
|
this._panel.classList.add('is-animating');
|
|
551
557
|
// Soluciona el caso donde el usuario no definió un fondo para .panel y lo aplicó en .body
|
|
@@ -555,9 +561,12 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
555
561
|
const body = this.shadowRoot.querySelector('.body');
|
|
556
562
|
const footer = this.shadowRoot.querySelector('footer');
|
|
557
563
|
const closeBtn = this.shadowRoot.querySelector('.close-btn');
|
|
558
|
-
const fadeTargets = [body, footer, closeBtn].filter(Boolean);
|
|
559
564
|
const headerWrapper = this.shadowRoot.querySelector('.header-morph-wrapper');
|
|
560
|
-
const
|
|
565
|
+
const fadeTargets = [body, footer, closeBtn, headerWrapper].filter(Boolean);
|
|
566
|
+
// El contenido pierde definición al retirarse, evitando un corte plano
|
|
567
|
+
// antes de que la superficie comience su recorrido. `blurContent`
|
|
568
|
+
// conserva la variante más expresiva para quienes desean mayor intensidad.
|
|
569
|
+
const targetBlur = this.blurContent ? 'blur(12px)' : 'blur(6px)';
|
|
561
570
|
gsap.fromTo(fadeTargets, { opacity: 1, filter: 'blur(0px)' }, {
|
|
562
571
|
opacity: 0,
|
|
563
572
|
filter: targetBlur,
|
|
@@ -565,11 +574,16 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
565
574
|
ease: 'power2.in',
|
|
566
575
|
onComplete: () => {
|
|
567
576
|
const panel = this._panel;
|
|
577
|
+
const closingTarget = this._resolveClosingTarget();
|
|
568
578
|
this._cleanupMorphElements();
|
|
569
579
|
const prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches;
|
|
570
|
-
|
|
580
|
+
// El cierre usa un único snapshot compuesto. La ruta histórica que
|
|
581
|
+
// creaba `morph-text` y `morph-icon` por separado podía ejecutarse a
|
|
582
|
+
// la vez que el snapshot y dejar etiquetas flotando sobre el modal.
|
|
583
|
+
let shouldMorph = false;
|
|
571
584
|
const morphTargets = [];
|
|
572
585
|
let source = null;
|
|
586
|
+
let destinationMorph = null;
|
|
573
587
|
if (shouldMorph) {
|
|
574
588
|
this._animateLabelClose();
|
|
575
589
|
source = this._resolveMorphSource();
|
|
@@ -594,6 +608,26 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
594
608
|
if (morphTargets.length === 0)
|
|
595
609
|
shouldMorph = false;
|
|
596
610
|
}
|
|
611
|
+
// Si el destino de cierre cambió, el contenido final debe ser una
|
|
612
|
+
// representación completa del target (no solamente su icono). Esto
|
|
613
|
+
// permite hacer morph hacia rich buttons, cards, imágenes y cualquier
|
|
614
|
+
// otra superficie compuesta.
|
|
615
|
+
if (closingTarget && !shouldMorph && !prefersReducedMotion) {
|
|
616
|
+
const visualTarget = this._resolveVisualTarget(closingTarget);
|
|
617
|
+
const destinationRect = visualTarget.getBoundingClientRect();
|
|
618
|
+
if (destinationRect.width > 0 && destinationRect.height > 0) {
|
|
619
|
+
// El contenido del trigger permanece oculto mientras el modal está
|
|
620
|
+
// abierto. Lo restauramos únicamente durante la captura para que el
|
|
621
|
+
// snapshot no herede opacity:0/color:transparent.
|
|
622
|
+
if (closingTarget === this._targetEl)
|
|
623
|
+
this._restoreTargetContent();
|
|
624
|
+
const element = this._createTargetSnapshot(visualTarget, destinationRect);
|
|
625
|
+
if (closingTarget === this._targetEl)
|
|
626
|
+
this._hideTargetContent();
|
|
627
|
+
element.style.opacity = '0';
|
|
628
|
+
destinationMorph = { element, rect: destinationRect, source: visualTarget };
|
|
629
|
+
}
|
|
630
|
+
}
|
|
597
631
|
if (shouldMorph && headerWrapper) {
|
|
598
632
|
headerWrapper.style.opacity = '0';
|
|
599
633
|
}
|
|
@@ -601,9 +635,32 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
601
635
|
props: 'backgroundColor,borderRadius,color,boxShadow'
|
|
602
636
|
});
|
|
603
637
|
const morphState = Flip.getState(morphTargets, {
|
|
604
|
-
props: 'color,fontSize,fontWeight,lineHeight'
|
|
638
|
+
props: 'color,fontSize,fontWeight,lineHeight,opacity'
|
|
605
639
|
});
|
|
606
|
-
|
|
640
|
+
if (!closingTarget) {
|
|
641
|
+
gsap.to(this._backdrop, {
|
|
642
|
+
opacity: 0,
|
|
643
|
+
duration: prefersReducedMotion ? 0.01 : 0.22,
|
|
644
|
+
ease: 'power2.in'
|
|
645
|
+
});
|
|
646
|
+
gsap.to(panel, {
|
|
647
|
+
autoAlpha: 0,
|
|
648
|
+
scale: 0.92,
|
|
649
|
+
duration: prefersReducedMotion ? 0.01 : 0.22,
|
|
650
|
+
ease: 'power2.in',
|
|
651
|
+
overwrite: true,
|
|
652
|
+
onComplete: () => {
|
|
653
|
+
gsap.set(panel, { clearProps: 'transform' });
|
|
654
|
+
this._finishHide(fadeTargets, headerWrapper);
|
|
655
|
+
}
|
|
656
|
+
});
|
|
657
|
+
return;
|
|
658
|
+
}
|
|
659
|
+
const targetState = this._getTargetState(closingTarget);
|
|
660
|
+
if (destinationMorph) {
|
|
661
|
+
this._runTargetMorphTimeline(panel, targetState, destinationMorph, fadeTargets, headerWrapper, prefersReducedMotion);
|
|
662
|
+
return;
|
|
663
|
+
}
|
|
607
664
|
let naturalSize;
|
|
608
665
|
if (this.autoSize) {
|
|
609
666
|
const prevW = panel.style.getPropertyValue('--_panel-width');
|
|
@@ -629,11 +686,11 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
629
686
|
const finalRect = this._computeFinalRect(targetState.rect, naturalSize);
|
|
630
687
|
panel.style.setProperty('--_panel-width', `${finalRect.width}px`);
|
|
631
688
|
panel.style.setProperty('--_panel-height', `${finalRect.height}px`);
|
|
632
|
-
this._applyRect(panel, targetState.rect);
|
|
689
|
+
this._applyRect(panel, this._toPanelCoordinateRect(targetState.rect));
|
|
633
690
|
panel.style.backgroundColor = targetState.backgroundColor;
|
|
634
691
|
panel.style.color = targetState.color;
|
|
635
692
|
panel.style.borderRadius = targetState.borderRadius;
|
|
636
|
-
panel.style.boxShadow =
|
|
693
|
+
panel.style.boxShadow = targetState.boxShadow;
|
|
637
694
|
if (shouldMorph && source) {
|
|
638
695
|
if (this._morphEls.text && source.text) {
|
|
639
696
|
this._positionElement(this._morphEls.text, source.text.rect);
|
|
@@ -657,31 +714,12 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
657
714
|
duration: 0.3,
|
|
658
715
|
ease: 'morph-close',
|
|
659
716
|
zIndex: this._zIndex,
|
|
660
|
-
onComplete: () =>
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
this.open = false;
|
|
667
|
-
this._handlingOpenChange = false;
|
|
668
|
-
this._isAnimating = false;
|
|
669
|
-
this._panel.classList.remove('is-animating');
|
|
670
|
-
this._panel.style.removeProperty('--_panel-width');
|
|
671
|
-
this._panel.style.removeProperty('--_panel-height');
|
|
672
|
-
this._cleanupMorphElements();
|
|
673
|
-
this._restoreTargetContent();
|
|
674
|
-
gsap.set(fadeTargets, { clearProps: 'opacity,transform,filter' });
|
|
675
|
-
if (headerWrapper)
|
|
676
|
-
headerWrapper.style.opacity = '1';
|
|
677
|
-
this.style.removeProperty('z-index');
|
|
678
|
-
this.style.removeProperty('--_z-index');
|
|
679
|
-
this.style.removeProperty('--_backdrop-duration');
|
|
680
|
-
this.style.removeProperty('--_backdrop-ease');
|
|
681
|
-
const idx = MoniMorphModal_1._openStack.indexOf(this);
|
|
682
|
-
if (idx > -1)
|
|
683
|
-
MoniMorphModal_1._openStack.splice(idx, 1);
|
|
684
|
-
}
|
|
717
|
+
onComplete: () => this._finishHide(fadeTargets, headerWrapper)
|
|
718
|
+
});
|
|
719
|
+
gsap.to(this._backdrop, {
|
|
720
|
+
opacity: 0,
|
|
721
|
+
duration: 0.3,
|
|
722
|
+
ease: 'power2.inOut'
|
|
685
723
|
});
|
|
686
724
|
if (morphTargets.length > 0) {
|
|
687
725
|
if (this.blurContent) {
|
|
@@ -701,6 +739,290 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
701
739
|
}
|
|
702
740
|
});
|
|
703
741
|
}
|
|
742
|
+
_runTargetMorphTimeline(panel, target, destination, fadeTargets, headerWrapper, prefersReducedMotion) {
|
|
743
|
+
const current = this._toPanelCoordinateRect(panel.getBoundingClientRect());
|
|
744
|
+
const targetRect = this._toPanelCoordinateRect(target.rect);
|
|
745
|
+
const destinationRect = this._toPanelCoordinateRect(destination.rect);
|
|
746
|
+
const destinationContent = destination.element;
|
|
747
|
+
const activeTargetAnimations = destination.source.getAnimations?.({ subtree: true }) ?? [];
|
|
748
|
+
const remainingTargetMotion = activeTargetAnimations.reduce((remaining, animation) => {
|
|
749
|
+
const timing = animation.effect?.getComputedTiming();
|
|
750
|
+
const endTime = typeof timing?.endTime === 'number' ? timing.endTime : 0;
|
|
751
|
+
const currentTime = typeof animation.currentTime === 'number' ? animation.currentTime : 0;
|
|
752
|
+
return Math.max(remaining, Math.max(0, endTime - currentTime) / 1000);
|
|
753
|
+
}, 0);
|
|
754
|
+
const morphDuration = Math.min(1.2, Math.max(0.46, remainingTargetMotion));
|
|
755
|
+
const start = {
|
|
756
|
+
x: current.left + current.width / 2,
|
|
757
|
+
y: current.top + current.height / 2
|
|
758
|
+
};
|
|
759
|
+
const end = {
|
|
760
|
+
x: targetRect.left + targetRect.width / 2,
|
|
761
|
+
y: targetRect.top + targetRect.height / 2
|
|
762
|
+
};
|
|
763
|
+
const dx = end.x - start.x;
|
|
764
|
+
const dy = end.y - start.y;
|
|
765
|
+
const distance = Math.hypot(dx, dy) || 1;
|
|
766
|
+
// En una Bézier cuadrática el desplazamiento máximo visible equivale
|
|
767
|
+
// aproximadamente a la mitad del offset del control. 0.72 produce una
|
|
768
|
+
// curva expresiva visible (~36% de la distancia) sin formar un bucle.
|
|
769
|
+
const arc = Math.min(360, Math.max(48, distance * 0.72));
|
|
770
|
+
const perpendicular = { x: -dy / distance, y: dx / distance };
|
|
771
|
+
const midpoint = { x: (start.x + end.x) / 2, y: (start.y + end.y) / 2 };
|
|
772
|
+
const viewportCenter = this._toPanelCoordinateRect(new DOMRect(window.innerWidth / 2, window.innerHeight / 2, 0, 0));
|
|
773
|
+
const candidates = [1, -1].map((direction) => ({
|
|
774
|
+
x: midpoint.x + perpendicular.x * arc * direction,
|
|
775
|
+
y: midpoint.y + perpendicular.y * arc * direction
|
|
776
|
+
}));
|
|
777
|
+
const centerDistance = (point) => Math.abs(Math.abs(dy) >= Math.abs(dx)
|
|
778
|
+
? point.x - viewportCenter.x
|
|
779
|
+
: point.y - viewportCenter.y);
|
|
780
|
+
const control = centerDistance(candidates[0]) <= centerDistance(candidates[1])
|
|
781
|
+
? candidates[0]
|
|
782
|
+
: candidates[1];
|
|
783
|
+
Object.assign(destinationContent.style, {
|
|
784
|
+
position: 'absolute',
|
|
785
|
+
inset: '50% auto auto 50%',
|
|
786
|
+
width: `${destinationRect.width}px`,
|
|
787
|
+
height: `${destinationRect.height}px`,
|
|
788
|
+
transform: 'translate(-50%, -50%) scale(.78)',
|
|
789
|
+
color: window.getComputedStyle(destination.source).color || target.color,
|
|
790
|
+
opacity: '0'
|
|
791
|
+
});
|
|
792
|
+
if (prefersReducedMotion) {
|
|
793
|
+
panel.appendChild(destinationContent);
|
|
794
|
+
this._applyRect(panel, targetRect);
|
|
795
|
+
panel.style.backgroundColor = target.backgroundColor;
|
|
796
|
+
panel.style.color = target.color;
|
|
797
|
+
panel.style.borderRadius = target.borderRadius;
|
|
798
|
+
panel.style.boxShadow = target.boxShadow;
|
|
799
|
+
this._backdrop.style.opacity = '0';
|
|
800
|
+
destinationContent.style.opacity = '1';
|
|
801
|
+
this._finishHide(fadeTargets, headerWrapper);
|
|
802
|
+
return;
|
|
803
|
+
}
|
|
804
|
+
const timeline = gsap.timeline({
|
|
805
|
+
onComplete: () => {
|
|
806
|
+
gsap.set(panel, { clearProps: 'transform' });
|
|
807
|
+
this._finishHide(fadeTargets, headerWrapper);
|
|
808
|
+
}
|
|
809
|
+
});
|
|
810
|
+
panel.style.left = `${current.left}px`;
|
|
811
|
+
panel.style.top = `${current.top}px`;
|
|
812
|
+
panel.style.width = `${current.width}px`;
|
|
813
|
+
panel.style.height = `${current.height}px`;
|
|
814
|
+
const panelStartStyle = window.getComputedStyle(panel);
|
|
815
|
+
const panelStartVisual = {
|
|
816
|
+
backgroundColor: panelStartStyle.backgroundColor,
|
|
817
|
+
color: panelStartStyle.color,
|
|
818
|
+
borderRadius: panelStartStyle.borderRadius,
|
|
819
|
+
boxShadow: panelStartStyle.boxShadow
|
|
820
|
+
};
|
|
821
|
+
// GSAP es el único propietario de la opacidad durante el recorrido.
|
|
822
|
+
// La transición CSS del estado `.open` produciría un segundo easing y
|
|
823
|
+
// haría que el scrim pareciera desaparecer al final de golpe.
|
|
824
|
+
this._backdrop.style.transition = 'none';
|
|
825
|
+
this._backdrop.style.opacity = '1';
|
|
826
|
+
const motion = { progress: 0 };
|
|
827
|
+
let contentAttached = false;
|
|
828
|
+
if (this.debug) {
|
|
829
|
+
console.log('[moni-morph-modal] arc', { start, control, end, distance, arc, morphDuration });
|
|
830
|
+
}
|
|
831
|
+
timeline
|
|
832
|
+
.addLabel('morph', 0)
|
|
833
|
+
.to(motion, {
|
|
834
|
+
progress: 1,
|
|
835
|
+
duration: morphDuration,
|
|
836
|
+
ease: 'power2.inOut',
|
|
837
|
+
onUpdate: () => {
|
|
838
|
+
const progress = motion.progress;
|
|
839
|
+
const liveState = this._getTargetState(destination.source);
|
|
840
|
+
const liveRect = this._toPanelCoordinateRect(liveState.rect);
|
|
841
|
+
const liveTransform = this._readTransformState(destination.source);
|
|
842
|
+
const liveEnd = {
|
|
843
|
+
x: liveRect.left + liveRect.width / 2,
|
|
844
|
+
y: liveRect.top + liveRect.height / 2
|
|
845
|
+
};
|
|
846
|
+
const liveDx = liveEnd.x - start.x;
|
|
847
|
+
const liveDy = liveEnd.y - start.y;
|
|
848
|
+
const liveDistance = Math.hypot(liveDx, liveDy) || 1;
|
|
849
|
+
const liveArc = Math.min(360, Math.max(48, liveDistance * 0.72));
|
|
850
|
+
const livePerpendicular = { x: -liveDy / liveDistance, y: liveDx / liveDistance };
|
|
851
|
+
const liveMidpoint = {
|
|
852
|
+
x: (start.x + liveEnd.x) / 2,
|
|
853
|
+
y: (start.y + liveEnd.y) / 2
|
|
854
|
+
};
|
|
855
|
+
const liveCandidates = [1, -1].map((direction) => ({
|
|
856
|
+
x: liveMidpoint.x + livePerpendicular.x * liveArc * direction,
|
|
857
|
+
y: liveMidpoint.y + livePerpendicular.y * liveArc * direction
|
|
858
|
+
}));
|
|
859
|
+
const liveControl = centerDistance(liveCandidates[0]) <= centerDistance(liveCandidates[1])
|
|
860
|
+
? liveCandidates[0]
|
|
861
|
+
: liveCandidates[1];
|
|
862
|
+
// El backdrop comparte exactamente el playhead del arco. Se mantiene
|
|
863
|
+
// algo más presente al comienzo y luego se retira progresivamente.
|
|
864
|
+
this._backdrop.style.opacity = String(Math.max(0, 1 - progress));
|
|
865
|
+
const inverse = 1 - progress;
|
|
866
|
+
const centerX = inverse * inverse * start.x +
|
|
867
|
+
2 * inverse * progress * liveControl.x +
|
|
868
|
+
progress * progress * liveEnd.x;
|
|
869
|
+
const centerY = inverse * inverse * start.y +
|
|
870
|
+
2 * inverse * progress * liveControl.y +
|
|
871
|
+
progress * progress * liveEnd.y;
|
|
872
|
+
// La contracción modal mantiene su easing, pero cualquier mutación
|
|
873
|
+
// adicional del target se suma completa para seguirla en tiempo real.
|
|
874
|
+
const liveVisualWidth = destination.source.offsetWidth || liveRect.width;
|
|
875
|
+
const liveVisualHeight = destination.source.offsetHeight || liveRect.height;
|
|
876
|
+
const initialVisualWidth = destination.source.offsetWidth || targetRect.width;
|
|
877
|
+
const initialVisualHeight = destination.source.offsetHeight || targetRect.height;
|
|
878
|
+
const width = current.width + (initialVisualWidth - current.width) * progress +
|
|
879
|
+
(liveVisualWidth - initialVisualWidth);
|
|
880
|
+
const height = current.height + (initialVisualHeight - current.height) * progress +
|
|
881
|
+
(liveVisualHeight - initialVisualHeight);
|
|
882
|
+
panel.style.width = `${width}px`;
|
|
883
|
+
panel.style.height = `${height}px`;
|
|
884
|
+
gsap.set(panel, {
|
|
885
|
+
x: centerX - width / 2 - current.left,
|
|
886
|
+
y: centerY - height / 2 - current.top,
|
|
887
|
+
rotation: liveTransform.rotation * progress,
|
|
888
|
+
skewX: liveTransform.skewX * progress,
|
|
889
|
+
scaleX: 1 + (liveTransform.scaleX - 1) * progress,
|
|
890
|
+
scaleY: 1 + (liveTransform.scaleY - 1) * progress,
|
|
891
|
+
backgroundColor: gsap.utils.interpolate(panelStartVisual.backgroundColor, liveState.backgroundColor, progress),
|
|
892
|
+
color: gsap.utils.interpolate(panelStartVisual.color, liveState.color, progress),
|
|
893
|
+
borderRadius: gsap.utils.interpolate(panelStartVisual.borderRadius, liveState.borderRadius, progress),
|
|
894
|
+
boxShadow: gsap.utils.interpolate(panelStartVisual.boxShadow, liveState.boxShadow, progress)
|
|
895
|
+
});
|
|
896
|
+
// El contenido del target no debe flotar sobre el modal grande. Solo
|
|
897
|
+
// comienza a materializarse cuando posición y relación de aspecto ya
|
|
898
|
+
// se aproximan al destino, pero continúa viajando con la superficie.
|
|
899
|
+
const contentProgress = Math.max(0, Math.min(1, (progress - 0.6) / 0.4));
|
|
900
|
+
if (!contentAttached && contentProgress > 0) {
|
|
901
|
+
panel.appendChild(destinationContent);
|
|
902
|
+
contentAttached = true;
|
|
903
|
+
}
|
|
904
|
+
// Conservamos el layout nativo del target y escalamos toda su
|
|
905
|
+
// composición. Redimensionar el wrapper convertiría porcentajes
|
|
906
|
+
// computados en píxeles fijos y dejaría la imagen arriba a la izquierda.
|
|
907
|
+
destinationContent.style.width = `${liveVisualWidth}px`;
|
|
908
|
+
destinationContent.style.height = `${liveVisualHeight}px`;
|
|
909
|
+
const revealScale = 0.82 + contentProgress * 0.18;
|
|
910
|
+
gsap.set(destinationContent, {
|
|
911
|
+
opacity: contentProgress,
|
|
912
|
+
scaleX: (width / Math.max(1, liveVisualWidth)) * revealScale,
|
|
913
|
+
scaleY: (height / Math.max(1, liveVisualHeight)) * revealScale
|
|
914
|
+
});
|
|
915
|
+
}
|
|
916
|
+
}, 'morph')
|
|
917
|
+
.addLabel('target-fade')
|
|
918
|
+
.to(panel, {
|
|
919
|
+
autoAlpha: 0,
|
|
920
|
+
duration: 0.08,
|
|
921
|
+
ease: 'power1.out',
|
|
922
|
+
onStart: () => {
|
|
923
|
+
// Handoff atómico: el contenido real ocupa el lugar del snapshot
|
|
924
|
+
// antes de retirar la última superficie. Evita un frame vacío o una
|
|
925
|
+
// duplicación perceptible al finalizar el morph.
|
|
926
|
+
destinationContent.style.visibility = 'hidden';
|
|
927
|
+
this._restoreTargetContent();
|
|
928
|
+
panel.style.backgroundColor = 'transparent';
|
|
929
|
+
panel.style.boxShadow = 'none';
|
|
930
|
+
panel.style.borderColor = 'transparent';
|
|
931
|
+
}
|
|
932
|
+
}, `morph+=${morphDuration}`);
|
|
933
|
+
}
|
|
934
|
+
_finishHide(fadeTargets, headerWrapper) {
|
|
935
|
+
const panel = this._panel;
|
|
936
|
+
panel.style.visibility = 'hidden';
|
|
937
|
+
panel.style.opacity = '0';
|
|
938
|
+
panel.style.pointerEvents = 'none';
|
|
939
|
+
this._visible = false;
|
|
940
|
+
this._handlingOpenChange = true;
|
|
941
|
+
this.open = false;
|
|
942
|
+
this._handlingOpenChange = false;
|
|
943
|
+
this._isAnimating = false;
|
|
944
|
+
panel.classList.remove('is-animating');
|
|
945
|
+
panel.style.removeProperty('--_panel-width');
|
|
946
|
+
panel.style.removeProperty('--_panel-height');
|
|
947
|
+
this._cleanupMorphElements();
|
|
948
|
+
this._restoreTargetContent();
|
|
949
|
+
gsap.set(fadeTargets, { clearProps: 'opacity,transform,filter' });
|
|
950
|
+
if (headerWrapper)
|
|
951
|
+
headerWrapper.style.opacity = '1';
|
|
952
|
+
this.style.removeProperty('z-index');
|
|
953
|
+
this.style.removeProperty('--_z-index');
|
|
954
|
+
this.style.removeProperty('--_backdrop-duration');
|
|
955
|
+
this.style.removeProperty('--_backdrop-ease');
|
|
956
|
+
// Conservamos opacity:0 hasta la próxima apertura. Limpiarla aquí puede
|
|
957
|
+
// producir un flash de scrim antes de que Lit retire la clase `.open`.
|
|
958
|
+
const idx = MoniMorphModal_1._openStack.indexOf(this);
|
|
959
|
+
if (idx > -1)
|
|
960
|
+
MoniMorphModal_1._openStack.splice(idx, 1);
|
|
961
|
+
}
|
|
962
|
+
_captureOriginFallbacks(origin) {
|
|
963
|
+
this._originFallbacks = [];
|
|
964
|
+
let current = this._getComposedParent(origin);
|
|
965
|
+
while (current && current !== document.body && current !== document.documentElement) {
|
|
966
|
+
this._originFallbacks.push(current);
|
|
967
|
+
current = this._getComposedParent(current);
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
_getComposedParent(el) {
|
|
971
|
+
if (el.parentElement)
|
|
972
|
+
return el.parentElement;
|
|
973
|
+
const root = el.getRootNode();
|
|
974
|
+
return root instanceof ShadowRoot ? root.host : null;
|
|
975
|
+
}
|
|
976
|
+
_resolveClosingTarget() {
|
|
977
|
+
if (this.target)
|
|
978
|
+
this._resolveTarget();
|
|
979
|
+
const candidates = [this._targetEl, ...this._originFallbacks].filter((candidate, index, all) => !!candidate && all.indexOf(candidate) === index);
|
|
980
|
+
const resolved = candidates.find((candidate) => this._isUsableClosingTarget(candidate)) ?? null;
|
|
981
|
+
const strategy = !resolved ? 'fade' : resolved === this._targetEl ? 'target' : 'ancestor';
|
|
982
|
+
this._debugMorph('close', resolved, strategy, candidates);
|
|
983
|
+
return resolved;
|
|
984
|
+
}
|
|
985
|
+
_debugMorph(phase, resolved, strategy, candidates) {
|
|
986
|
+
if (!this.debug)
|
|
987
|
+
return;
|
|
988
|
+
const rows = candidates.map((element, index) => {
|
|
989
|
+
const rect = element.getBoundingClientRect();
|
|
990
|
+
return {
|
|
991
|
+
index,
|
|
992
|
+
element: `${element.tagName.toLowerCase()}${element.id ? `#${element.id}` : ''}`,
|
|
993
|
+
connected: element.isConnected,
|
|
994
|
+
usable: this._isUsableClosingTarget(element),
|
|
995
|
+
x: Math.round(rect.x),
|
|
996
|
+
y: Math.round(rect.y),
|
|
997
|
+
width: Math.round(rect.width),
|
|
998
|
+
height: Math.round(rect.height)
|
|
999
|
+
};
|
|
1000
|
+
});
|
|
1001
|
+
console.groupCollapsed(`[moni-morph-modal] ${phase} → ${strategy}`);
|
|
1002
|
+
console.log('Origin:', this._targetEl);
|
|
1003
|
+
console.log('Resolved morph target:', resolved);
|
|
1004
|
+
console.table(rows);
|
|
1005
|
+
console.groupEnd();
|
|
1006
|
+
}
|
|
1007
|
+
_isUsableClosingTarget(el) {
|
|
1008
|
+
if (!el?.isConnected)
|
|
1009
|
+
return false;
|
|
1010
|
+
const rect = el.getBoundingClientRect();
|
|
1011
|
+
if (rect.width < 2 || rect.height < 2)
|
|
1012
|
+
return false;
|
|
1013
|
+
if (rect.right <= 0 || rect.bottom <= 0 || rect.left >= window.innerWidth || rect.top >= window.innerHeight)
|
|
1014
|
+
return false;
|
|
1015
|
+
let current = el;
|
|
1016
|
+
while (current && current !== document.body) {
|
|
1017
|
+
const style = getComputedStyle(current);
|
|
1018
|
+
if (style.display === 'none' || style.visibility === 'hidden' || style.contentVisibility === 'hidden')
|
|
1019
|
+
return false;
|
|
1020
|
+
if (Number.parseFloat(style.opacity || '1') === 0 && !this._targetStylesCache.has(current))
|
|
1021
|
+
return false;
|
|
1022
|
+
current = this._getComposedParent(current);
|
|
1023
|
+
}
|
|
1024
|
+
return true;
|
|
1025
|
+
}
|
|
704
1026
|
toggle() {
|
|
705
1027
|
if (this._visible || this.open)
|
|
706
1028
|
this.hide();
|
|
@@ -747,6 +1069,14 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
747
1069
|
if (parts.iconTrailing)
|
|
748
1070
|
saveAndHide(parts.iconTrailing, 'opacity');
|
|
749
1071
|
}
|
|
1072
|
+
else if (this._targetEl.tagName === 'MONI-FAB') {
|
|
1073
|
+
const icon = this._targetEl.shadowRoot?.querySelector('.icon');
|
|
1074
|
+
const label = this._targetEl.shadowRoot?.querySelector('.label');
|
|
1075
|
+
if (icon)
|
|
1076
|
+
saveAndHide(icon, 'opacity');
|
|
1077
|
+
if (label)
|
|
1078
|
+
saveAndHide(label, 'opacity');
|
|
1079
|
+
}
|
|
750
1080
|
else {
|
|
751
1081
|
saveAndHide(this._targetEl, 'color');
|
|
752
1082
|
const icon = this._targetEl.querySelector('moni-icon, svg, [class*="icon"]');
|
|
@@ -782,6 +1112,14 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
782
1112
|
if (parts.iconTrailing)
|
|
783
1113
|
restore(parts.iconTrailing);
|
|
784
1114
|
}
|
|
1115
|
+
else if (this._targetEl.tagName === 'MONI-FAB') {
|
|
1116
|
+
const icon = this._targetEl.shadowRoot?.querySelector('.icon');
|
|
1117
|
+
const label = this._targetEl.shadowRoot?.querySelector('.label');
|
|
1118
|
+
if (icon)
|
|
1119
|
+
restore(icon);
|
|
1120
|
+
if (label)
|
|
1121
|
+
restore(label);
|
|
1122
|
+
}
|
|
785
1123
|
else {
|
|
786
1124
|
restore(this._targetEl);
|
|
787
1125
|
const icon = this._targetEl.querySelector('moni-icon, svg, [class*="icon"]');
|
|
@@ -812,6 +1150,10 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
812
1150
|
// LABEL FLIP HELPERS
|
|
813
1151
|
// =========================================================================
|
|
814
1152
|
_cleanupMorphElements() {
|
|
1153
|
+
if (this._targetSnapshot) {
|
|
1154
|
+
this._targetSnapshot.remove();
|
|
1155
|
+
this._targetSnapshot = null;
|
|
1156
|
+
}
|
|
815
1157
|
if (this._morphEls.text) {
|
|
816
1158
|
this._morphEls.text.remove();
|
|
817
1159
|
this._morphEls.text = null;
|
|
@@ -902,10 +1244,42 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
902
1244
|
return el;
|
|
903
1245
|
}
|
|
904
1246
|
_positionElement(el, rect) {
|
|
905
|
-
|
|
906
|
-
el.style.
|
|
907
|
-
el.style.
|
|
908
|
-
el.style.
|
|
1247
|
+
const localRect = this._toPanelCoordinateRect(rect);
|
|
1248
|
+
el.style.top = `${localRect.top}px`;
|
|
1249
|
+
el.style.left = `${localRect.left}px`;
|
|
1250
|
+
el.style.width = `${localRect.width}px`;
|
|
1251
|
+
el.style.height = `${localRect.height}px`;
|
|
1252
|
+
}
|
|
1253
|
+
_toPanelCoordinateRect(rect) {
|
|
1254
|
+
const ancestor = this.parentElement?.closest('.lab-canvas, [data-morph-coordinate-space]');
|
|
1255
|
+
if (!ancestor)
|
|
1256
|
+
return rect;
|
|
1257
|
+
const transform = getComputedStyle(ancestor).transform;
|
|
1258
|
+
if (!transform || transform === 'none')
|
|
1259
|
+
return rect;
|
|
1260
|
+
let scaleX = 1;
|
|
1261
|
+
let scaleY = 1;
|
|
1262
|
+
if (typeof DOMMatrix !== 'undefined') {
|
|
1263
|
+
const matrix = new DOMMatrix(transform);
|
|
1264
|
+
scaleX = Math.hypot(matrix.a, matrix.b) || 1;
|
|
1265
|
+
scaleY = Math.hypot(matrix.c, matrix.d) || 1;
|
|
1266
|
+
}
|
|
1267
|
+
else {
|
|
1268
|
+
const matrixMatch = transform.match(/^matrix\(([^)]+)\)$/);
|
|
1269
|
+
const scaleMatch = transform.match(/^scale\(([^)]+)\)$/);
|
|
1270
|
+
if (matrixMatch) {
|
|
1271
|
+
const values = matrixMatch[1].split(',').map(Number);
|
|
1272
|
+
scaleX = Math.hypot(values[0], values[1]) || 1;
|
|
1273
|
+
scaleY = Math.hypot(values[2], values[3]) || 1;
|
|
1274
|
+
}
|
|
1275
|
+
else if (scaleMatch) {
|
|
1276
|
+
const values = scaleMatch[1].split(/[,\s]+/).map(Number);
|
|
1277
|
+
scaleX = values[0] || 1;
|
|
1278
|
+
scaleY = values[1] || scaleX;
|
|
1279
|
+
}
|
|
1280
|
+
}
|
|
1281
|
+
const ancestorRect = ancestor.getBoundingClientRect();
|
|
1282
|
+
return new DOMRect((rect.left - ancestorRect.left) / scaleX, (rect.top - ancestorRect.top) / scaleY, rect.width / scaleX, rect.height / scaleY);
|
|
909
1283
|
}
|
|
910
1284
|
_getMoniButtonParts() {
|
|
911
1285
|
const sr = this._targetEl?.shadowRoot;
|
|
@@ -1070,16 +1444,10 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
1070
1444
|
return null;
|
|
1071
1445
|
}
|
|
1072
1446
|
_getTargetState(el) {
|
|
1073
|
-
|
|
1074
|
-
//
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
let visualEl = el;
|
|
1078
|
-
if (el.tagName === 'MONI-BUTTON') {
|
|
1079
|
-
const inner = el.shadowRoot?.querySelector('.button');
|
|
1080
|
-
if (inner)
|
|
1081
|
-
visualEl = inner;
|
|
1082
|
-
}
|
|
1447
|
+
// Los Web Components interactivos exponen un host transparente. El morph
|
|
1448
|
+
// debe usar la superficie pintada real dentro de su Shadow DOM.
|
|
1449
|
+
const visualEl = this._resolveVisualTarget(el);
|
|
1450
|
+
const rect = visualEl.getBoundingClientRect();
|
|
1083
1451
|
let bg = window.getComputedStyle(visualEl).backgroundColor;
|
|
1084
1452
|
// Si es transparente, intentamos buscar en pseudo-elementos (usado en botones Material 3)
|
|
1085
1453
|
if (this._isColorTransparent(bg)) {
|
|
@@ -1110,9 +1478,119 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
1110
1478
|
rect,
|
|
1111
1479
|
backgroundColor: bg,
|
|
1112
1480
|
color: computed.color || 'var(--on-surface)',
|
|
1113
|
-
borderRadius: computed.borderRadius || '1.25rem'
|
|
1481
|
+
borderRadius: computed.borderRadius || '1.25rem',
|
|
1482
|
+
boxShadow: computed.boxShadow || 'none'
|
|
1114
1483
|
};
|
|
1115
1484
|
}
|
|
1485
|
+
_resolveVisualTarget(el) {
|
|
1486
|
+
if (el.tagName === 'MONI-BUTTON') {
|
|
1487
|
+
return el.shadowRoot?.querySelector('.button') ?? el;
|
|
1488
|
+
}
|
|
1489
|
+
if (el.tagName === 'MONI-FAB') {
|
|
1490
|
+
return el.shadowRoot?.querySelector('button') ?? el;
|
|
1491
|
+
}
|
|
1492
|
+
if (el.tagName === 'MONI-FAB-MENU') {
|
|
1493
|
+
const trigger = el.shadowRoot?.querySelector('.trigger');
|
|
1494
|
+
return trigger?.shadowRoot?.querySelector('button') ?? trigger ?? el;
|
|
1495
|
+
}
|
|
1496
|
+
return el;
|
|
1497
|
+
}
|
|
1498
|
+
/**
|
|
1499
|
+
* Crea una copia visual inerte del árbol compuesto del target. Los `<slot>`
|
|
1500
|
+
* se sustituyen por sus nodos asignados, por lo que la captura incluye tanto
|
|
1501
|
+
* contenido light DOM como superficies internas de Web Components.
|
|
1502
|
+
*/
|
|
1503
|
+
_createTargetSnapshot(source, rect) {
|
|
1504
|
+
this._targetSnapshot?.remove();
|
|
1505
|
+
const snapshot = document.createElement('div');
|
|
1506
|
+
snapshot.className = 'morph-target-snapshot';
|
|
1507
|
+
snapshot.setAttribute('aria-hidden', 'true');
|
|
1508
|
+
const clone = this._cloneComposedNode(source);
|
|
1509
|
+
if (clone) {
|
|
1510
|
+
snapshot.appendChild(clone);
|
|
1511
|
+
// La geometría, el color y la elevación pertenecen al panel animado.
|
|
1512
|
+
// Repetirlos en el snapshot crea una segunda píldora encima del morph.
|
|
1513
|
+
// En medios visuales, en cambio, la propia superficie sí es contenido.
|
|
1514
|
+
if (clone instanceof HTMLElement &&
|
|
1515
|
+
!['IMG', 'VIDEO', 'CANVAS', 'SVG', 'PICTURE'].includes(source.tagName)) {
|
|
1516
|
+
Object.assign(clone.style, {
|
|
1517
|
+
background: 'transparent',
|
|
1518
|
+
backgroundColor: 'transparent',
|
|
1519
|
+
boxShadow: 'none',
|
|
1520
|
+
borderColor: 'transparent',
|
|
1521
|
+
outline: 'none',
|
|
1522
|
+
position: 'relative',
|
|
1523
|
+
inset: 'auto',
|
|
1524
|
+
transform: 'none',
|
|
1525
|
+
opacity: '1',
|
|
1526
|
+
visibility: 'visible',
|
|
1527
|
+
width: '100%',
|
|
1528
|
+
height: '100%'
|
|
1529
|
+
});
|
|
1530
|
+
if (source.tagName === 'BUTTON') {
|
|
1531
|
+
clone.style.whiteSpace = 'nowrap';
|
|
1532
|
+
clone.querySelectorAll('span, [part~="label"]').forEach((child) => {
|
|
1533
|
+
child.style.whiteSpace = 'nowrap';
|
|
1534
|
+
});
|
|
1535
|
+
}
|
|
1536
|
+
}
|
|
1537
|
+
}
|
|
1538
|
+
Object.assign(snapshot.style, {
|
|
1539
|
+
width: `${rect.width}px`,
|
|
1540
|
+
height: `${rect.height}px`,
|
|
1541
|
+
overflow: 'hidden',
|
|
1542
|
+
pointerEvents: 'none'
|
|
1543
|
+
});
|
|
1544
|
+
this._targetSnapshot = snapshot;
|
|
1545
|
+
return snapshot;
|
|
1546
|
+
}
|
|
1547
|
+
_cloneComposedNode(source) {
|
|
1548
|
+
if (source.nodeType === Node.TEXT_NODE)
|
|
1549
|
+
return source.cloneNode(false);
|
|
1550
|
+
if (!(source instanceof Element))
|
|
1551
|
+
return null;
|
|
1552
|
+
if (source instanceof HTMLSlotElement) {
|
|
1553
|
+
const fragment = document.createDocumentFragment();
|
|
1554
|
+
const nodes = source.assignedNodes({ flatten: true });
|
|
1555
|
+
for (const node of nodes.length ? nodes : Array.from(source.childNodes)) {
|
|
1556
|
+
const child = this._cloneComposedNode(node);
|
|
1557
|
+
if (child)
|
|
1558
|
+
fragment.appendChild(child);
|
|
1559
|
+
}
|
|
1560
|
+
return fragment;
|
|
1561
|
+
}
|
|
1562
|
+
// No clonamos directamente un Custom Element con Shadow DOM: su
|
|
1563
|
+
// constructor crearía una segunda sombra y duplicaría el render. Una
|
|
1564
|
+
// superficie neutra recibe en cambio el árbol visual ya compuesto.
|
|
1565
|
+
const clone = (source.shadowRoot
|
|
1566
|
+
? document.createElement('div')
|
|
1567
|
+
: source.cloneNode(false));
|
|
1568
|
+
if (source instanceof HTMLImageElement && clone instanceof HTMLImageElement) {
|
|
1569
|
+
// El snapshot vive menos de medio segundo: no puede depender de que el
|
|
1570
|
+
// lazy-loader observe nuevamente una imagen que ya estaba renderizada.
|
|
1571
|
+
clone.loading = 'eager';
|
|
1572
|
+
clone.decoding = 'sync';
|
|
1573
|
+
if (source.currentSrc)
|
|
1574
|
+
clone.src = source.currentSrc;
|
|
1575
|
+
}
|
|
1576
|
+
clone.removeAttribute('id');
|
|
1577
|
+
clone.removeAttribute('name');
|
|
1578
|
+
clone.setAttribute('aria-hidden', 'true');
|
|
1579
|
+
const computed = window.getComputedStyle(source);
|
|
1580
|
+
for (let index = 0; index < computed.length; index += 1) {
|
|
1581
|
+
const property = computed.item(index);
|
|
1582
|
+
clone.style.setProperty(property, computed.getPropertyValue(property), computed.getPropertyPriority(property));
|
|
1583
|
+
}
|
|
1584
|
+
const children = source.shadowRoot
|
|
1585
|
+
? Array.from(source.shadowRoot.childNodes).filter((node) => !(node instanceof HTMLStyleElement))
|
|
1586
|
+
: Array.from(source.childNodes);
|
|
1587
|
+
for (const node of children) {
|
|
1588
|
+
const child = this._cloneComposedNode(node);
|
|
1589
|
+
if (child)
|
|
1590
|
+
clone.appendChild(child);
|
|
1591
|
+
}
|
|
1592
|
+
return clone;
|
|
1593
|
+
}
|
|
1116
1594
|
_isColorTransparent(color) {
|
|
1117
1595
|
if (!color)
|
|
1118
1596
|
return true;
|
|
@@ -1123,6 +1601,47 @@ let MoniMorphModal = class MoniMorphModal extends MoniElement {
|
|
|
1123
1601
|
c.includes(',0)') ||
|
|
1124
1602
|
c.includes('/0)'));
|
|
1125
1603
|
}
|
|
1604
|
+
_readTransformState(el) {
|
|
1605
|
+
const transform = window.getComputedStyle(el).transform;
|
|
1606
|
+
if (!transform || transform === 'none') {
|
|
1607
|
+
return { rotation: 0, skewX: 0, scaleX: 1, scaleY: 1 };
|
|
1608
|
+
}
|
|
1609
|
+
try {
|
|
1610
|
+
const values = transform.match(/matrix(?:3d)?\(([^)]+)\)/)?.[1]
|
|
1611
|
+
.split(',')
|
|
1612
|
+
.map((value) => Number.parseFloat(value.trim()));
|
|
1613
|
+
let a;
|
|
1614
|
+
let b;
|
|
1615
|
+
let c;
|
|
1616
|
+
let d;
|
|
1617
|
+
if (values?.length === 6) {
|
|
1618
|
+
[a, b, c, d] = values;
|
|
1619
|
+
}
|
|
1620
|
+
else if (values?.length === 16) {
|
|
1621
|
+
a = values[0];
|
|
1622
|
+
b = values[1];
|
|
1623
|
+
c = values[4];
|
|
1624
|
+
d = values[5];
|
|
1625
|
+
}
|
|
1626
|
+
else {
|
|
1627
|
+
const matrix = new DOMMatrix(transform);
|
|
1628
|
+
({ a, b, c, d } = matrix);
|
|
1629
|
+
}
|
|
1630
|
+
const scaleX = Math.hypot(a, b) || 1;
|
|
1631
|
+
const determinant = a * d - b * c;
|
|
1632
|
+
const scaleY = determinant / scaleX || 1;
|
|
1633
|
+
return {
|
|
1634
|
+
rotation: Math.atan2(b, a) * (180 / Math.PI),
|
|
1635
|
+
skewX: Math.atan2(a * c + b * d, scaleX * scaleX) *
|
|
1636
|
+
(180 / Math.PI),
|
|
1637
|
+
scaleX,
|
|
1638
|
+
scaleY
|
|
1639
|
+
};
|
|
1640
|
+
}
|
|
1641
|
+
catch {
|
|
1642
|
+
return { rotation: 0, skewX: 0, scaleX: 1, scaleY: 1 };
|
|
1643
|
+
}
|
|
1644
|
+
}
|
|
1126
1645
|
_applyRect(el, rect) {
|
|
1127
1646
|
el.style.top = `${rect.top}px`;
|
|
1128
1647
|
el.style.left = `${rect.left}px`;
|
|
@@ -1512,6 +2031,9 @@ __decorate([
|
|
|
1512
2031
|
__decorate([
|
|
1513
2032
|
property({ type: Boolean, reflect: true, attribute: 'blur-content', converter: litBool })
|
|
1514
2033
|
], MoniMorphModal.prototype, "blurContent", void 0);
|
|
2034
|
+
__decorate([
|
|
2035
|
+
property({ type: Boolean, reflect: true, converter: litBool })
|
|
2036
|
+
], MoniMorphModal.prototype, "debug", void 0);
|
|
1515
2037
|
__decorate([
|
|
1516
2038
|
query('.panel')
|
|
1517
2039
|
], MoniMorphModal.prototype, "_panel", void 0);
|