@solibo/solibo-ui 2.2.2 → 2.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/index.css +1 -1
- package/dist/assets/index11.css +1 -1
- package/dist/assets/index12.css +1 -1
- package/dist/assets/index38.css +1 -1
- package/dist/assets/index53.css +1 -1
- package/dist/components/croppable/index.cjs +1 -1
- package/dist/components/croppable/index.js +251 -238
- package/dist/components/loading/index.cjs +1 -1
- package/dist/components/loading/index.js +19 -17
- package/dist/components/page-layout/index.cjs +1 -1
- package/dist/components/page-layout/index.js +31 -28
- package/dist/components/panel/index.cjs +1 -1
- package/dist/components/panel/index.js +29 -20
- package/dist/index.d.ts +21 -8
- package/dist/tokens.json +1 -1
- package/package.json +8 -5
package/dist/assets/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@keyframes fade-in{0%{opacity:0}to{opacity:1}}@keyframes fade-out{0%{opacity:1}to{opacity:0}}@keyframes spin{to{transform:rotate(360deg)}}@keyframes stagger-in{0%{opacity:0;translate:0 4px}to{opacity:1;translate:0 0}}@media (prefers-reduced-motion: reduce){*{animation:none!important;opacity:1!important;transition:none!important;translate:none!important}}body:before{animation:fade-out calc(var(--utils-tokens-transition-duration) * 2) var(--utils-tokens-transition-timing-function) forwards;background:var(--colors-semantic-bg-page);content:"";top:0;right:0;bottom:0;left:0;pointer-events:none;position:fixed;will-change:opacity;z-index:var(--utils-tokens-z-max)}[data-animation=stagger]{--stagger-duration: var(--utils-tokens-transition-duration);--stagger-parent: var(--utils-tokens-transition-duration);--stagger-step: var(--utils-tokens-transition-duration)}[data-animation=stagger] *{--stagger-index: 0;--stagger-next: calc(var(--stagger-total) + var(--stagger-duration));--stagger-self: calc(var(--stagger-index) * var(--stagger-step));--stagger-total: calc(var(--stagger-parent) + var(--stagger-self));animation:stagger-in var(--stagger-duration) var(--utils-tokens-transition-timing-function) var(--utils-tokens-transition-delay) both;animation-delay:var(--stagger-total);opacity:0;translate:0 var(--scale-4);will-change:opacity,translate}[data-animation=stagger] *>*{--stagger-parent: var(--stagger-next)}[data-animation=stagger]>*:nth-child(1),[data-animation=stagger] *>*:nth-child(1){--stagger-index: 0}[data-animation=stagger]>*:nth-child(2),[data-animation=stagger] *>*:nth-child(2){--stagger-index: 1}[data-animation=stagger]>*:nth-child(3),[data-animation=stagger] *>*:nth-child(3){--stagger-index: 2}[data-animation=stagger]>*:nth-child(4),[data-animation=stagger] *>*:nth-child(4){--stagger-index: 3}[data-animation=stagger]>*:nth-child(5),[data-animation=stagger] *>*:nth-child(5){--stagger-index: 4}[data-animation=stagger]>*:nth-child(6),[data-animation=stagger] *>*:nth-child(6){--stagger-index: 5}[data-animation=stagger]>*:nth-child(7),[data-animation=stagger] *>*:nth-child(7){--stagger-index: 6}[data-animation=stagger]>*:nth-child(8),[data-animation=stagger] *>*:nth-child(8){--stagger-index: 7}[data-animation=stagger]>*:nth-child(9),[data-animation=stagger] *>*:nth-child(9){--stagger-index: 8}[data-animation=stagger]>*:nth-child(10),[data-animation=stagger] *>*:nth-child(10){--stagger-index: 9}[data-animation=stagger][data-stagger-step]{--stagger-step: attr(data-stagger-step time, 25ms)}[data-animation=stagger] [data-stagger-off],[data-animation=stagger] [data-stagger-off] *{--stagger-duration: 0ms;--stagger-parent: 0ms;--stagger-step: 0ms;animation:none!important;opacity:1!important;translate:none!important}@media print{@page{margin:1.5cm}*,*:before,*:after{animation:none!important;box-shadow:none!important;text-shadow:none!important;transition:none!important}html,body{background:#fff!important;color:#000!important;font:12pt/1.4 system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif!important}body{margin:0}nav,aside,button:not([data-print-content]),input,select,textarea,iframe,video,audio,body:before,[data-component=controls],[data-component=toolbar],[data-component=menu],[data-message-actions],[data-content=collapsible-indicator],[data-component=messages]>[data-component=editor],[data-component=messages]>[data-component=tooltip],.no-print,.print-hidden,[aria-hidden=true]{display:none!important}main,article,section,[data-component=appshell],[data-component=panel],[data-component=messages],[data-message-list],[data-component=list],[data-print-flow]{display:block!important;height:auto!important;max-height:none!important;min-height:0!important;min-width:0!important;overflow:visible!important;position:static!important;max-width:none!important;width:100%!important}main,article,section{margin:0!important;padding:0!important}article[data-component=card]{overflow:visible!important}[data-animation],[data-animation] *{opacity:1!important;translate:none!important}[data-message-type]{display:block!important;-moz-column-break-inside:auto;break-inside:auto;margin:0 0 1em!important;padding:0!important;background:transparent!important}[data-message-type]>*,[data-message-type] [data-appearance]{margin-inline:0!important;max-width:none!important;width:auto!important}[data-message-type] [data-appearance]{display:block!important;-webkit-line-clamp:unset!important;overflow:visible!important;padding:0!important;border:0!important;background:transparent!important;color:inherit!important;text-overflow:clip!important}[data-content=user-generated],html [data-content=user-generated] :is(p,table,th,td,tr),[data-component=file],[data-component=file] :is(a,button,span),[data-component=avatar] :is(strong,span){max-height:none!important;overflow:visible!important;text-overflow:clip!important;white-space:normal!important;overflow-wrap:anywhere}[data-component=file] button{color:#000!important}header,[data-component=message],[data-component=file]{color:#000!important}header :is(p,span,strong,b,em,time,h1,h2,h3,h4,h5,h6),[data-component=message] :is(p,span,strong,b,em,time,h1,h2,h3,h4,h5,h6),[data-component=file] :is(p,span,strong,b,em,time,h1,h2,h3,h4,h5,h6){color:inherit!important}[data-component=avatar] span,[data-component=file],[data-component=panel],[data-component=card],[data-component=messages]>ul{background-color:transparent!important}header{-moz-column-break-after:avoid;break-after:avoid}[data-component=card] :is(h1,h2,h3,h4,h5,h6){overflow:visible!important;white-space:normal!important}h1,h2,h3{-moz-column-break-after:avoid;break-after:avoid;page-break-after:avoid}p,h1,h2,h3,h4,h5,h6{orphans:3;widows:3}a{color:#000!important;text-decoration:underline}[data-component=file]>a[href]{flex-wrap:wrap}[data-component=file]>a[href]:after{flex-basis:100%}[data-content=user-generated] a[href^=http]:after,a[data-print-url][href^=http]:after,[data-component=file]>a[href]:not([href^="#"]):after{content:" (" attr(href) ")";font-size:90%;overflow-wrap:anywhere}table{border-collapse:collapse;page-break-inside:auto;width:100%}html [data-content=user-generated] table{table-layout:auto!important;width:100%!important}tr,img{-moz-column-break-inside:avoid;break-inside:avoid;page-break-inside:avoid}th,td{border:1px solid #000;padding:.25rem .4rem;vertical-align:top}thead{display:table-header-group}img,svg{height:auto!important;max-width:100%!important}pre,code{white-space:pre-wrap;word-break:break-word}pre,blockquote{-moz-column-break-inside:auto;break-inside:auto}.no-print,.print-hidden,[aria-hidden=true],[hidden]{display:none!important}}:root{--breakpoint-lg: 1024;--breakpoint-md: 768;--breakpoint-sm: 480;--colors-blue-100: #c9dcff;--colors-blue-200: var(--colors-new-brand-blue);--colors-blue-300: #6695ff;--colors-blue-400: #296afa;--colors-blue-50: var(--colors-new-brand-light-blue);--colors-blue-500: #0b4ad5;--colors-blue-600: #0c3797;--colors-blue-700: #0c2764;--colors-blue-800: #0b1938;--colors-blue-900: #090e1b;--colors-box-shadow: #0000001f;--colors-box-shadow-heavy: #0006;--colors-categories-bg-grey-1: #e3e4e6;--colors-categories-bg-grey-2: #d4dce5;--colors-categories-bg-pink-1: #e7e3ea;--colors-categories-bg-pink-2: #e3d2f0;--colors-categories-bg-pink-3: #d8bfe5;--colors-categories-bg-pink-4: #e0c3d8;--colors-categories-bg-pink-5: #e8c6d2;--colors-categories-bg-yellow-1: #d9cbaf;--colors-categories-bg-yellow-2: #d9c7c0;--colors-categories-bg-yellow-3: #cdb8ac;--colors-categories-content-on-grey: #3f444a;--colors-categories-content-on-pink: #783b65;--colors-categories-content-on-yellow: #65483f;--colors-green-100: #d9e0d7;--colors-green-200: #b8c7b3;--colors-green-300: #90aa88;--colors-green-400: #698c5f;--colors-green-50: #eff1ee;--colors-green-500: #4a6344;--colors-green-600: var(--colors-new-brand-shadow-green);--colors-green-700: var(--colors-new-brand-dark-green);--colors-green-800: #151b13;--colors-green-900: #0c0f0b;--colors-neutral-0: #fff;--colors-neutral-100: #ebebeb;--colors-neutral-200: #dfdfdf;--colors-neutral-300: #b3b3b3;--colors-neutral-400: #7b7b7b;--colors-neutral-50: #f5f5f5;--colors-neutral-500: #525252;--colors-neutral-600: #373737;--colors-neutral-700: #2a2a2a;--colors-neutral-800: #1c1c1c;--colors-neutral-900: #0b0b0b;--colors-new-brand-blue: #abc5ff;--colors-new-brand-dark-green: #202b1b;--colors-new-brand-light-blue: #e8f1ff;--colors-new-brand-light-yellow: #f8fac0;--colors-new-brand-nature-white: #f7f7e1;--colors-new-brand-shadow-green: #263821;--colors-new-brand-shadow-yellow: #7d8233;--colors-new-brand-yellow: #cde517;--colors-orange-100: #fbe7d3;--colors-orange-200: #f1cda7;--colors-orange-300: #e6b37a;--colors-orange-400: #dc9c50;--colors-orange-50: #fff5ea;--colors-orange-500: #cf8a33;--colors-orange-600: #a96f23;--colors-orange-700: #885716;--colors-orange-800: #633e0d;--colors-orange-900: #442a08;--colors-red-100: #f8e2de;--colors-red-200: #e9bbb3;--colors-red-300: #d1897e;--colors-red-400: #aa5449;--colors-red-50: #fff4f2;--colors-red-500: #862b22;--colors-red-600: #702018;--colors-red-700: #5a1610;--colors-red-800: #43100b;--colors-red-900: #2d0906;--colors-semantic-bg-backdrop: #000000d9;--colors-semantic-bg-disabled: var(--colors-neutral-50);--colors-semantic-bg-overlay: var(--colors-neutral-100);--colors-semantic-bg-page: var(--colors-neutral-50);--colors-semantic-bg-surface: var(--colors-neutral-0);--colors-semantic-border-active: var(--colors-neutral-800);--colors-semantic-border-default: var(--colors-neutral-200);--colors-semantic-border-destructive: var(--colors-red-600);--colors-semantic-border-disabled: var(--colors-neutral-100);--colors-semantic-border-focus: var(--colors-new-brand-shadow-yellow);--colors-semantic-border-on-color: var(--colors-neutral-0);--colors-semantic-border-strong: var(--colors-neutral-300);--colors-semantic-border-subtle: var(--colors-neutral-100);--colors-semantic-content-destructive: var(--colors-red-700);--colors-semantic-content-disabled: var(--colors-neutral-400);--colors-semantic-content-highlight: var(--colors-green-200);--colors-semantic-content-link: var(--colors-blue-500);--colors-semantic-content-link-hover: var(--colors-blue-700);--colors-semantic-content-link-visited: var(--colors-blue-600);--colors-semantic-content-on-color: var(--colors-semantic-primary-on-primary);--colors-semantic-content-primary: var(--colors-green-700);--colors-semantic-content-secondary: var(--colors-neutral-600);--colors-semantic-content-tertiary: var(--colors-neutral-500);--colors-semantic-interactive-destructive-bg: var(--colors-red-500);--colors-semantic-interactive-destructive-disabled: var(--colors-red-200);--colors-semantic-interactive-destructive-hover: var(--colors-red-600);--colors-semantic-interactive-disabled: var(--colors-neutral-200);--colors-semantic-interactive-hover: var(--colors-green-50);--colors-semantic-interactive-hover-overlay: #0000001f;--colors-semantic-interactive-hover-subtle: var(--colors-neutral-100);--colors-semantic-interactive-neutral: var(--colors-neutral-300);--colors-semantic-interactive-pressed: var(--colors-green-100);--colors-semantic-interactive-secondary-bg: var(--colors-green-100);--colors-semantic-interactive-secondary-destructive-hover: var(--colors-red-50);--colors-semantic-interactive-secondary-hover: var(--colors-green-200);--colors-semantic-interactive-selected: var(--colors-green-100);--colors-semantic-main-nav-admin-bg: var(--colors-red-800);--colors-semantic-main-nav-admin-content: var(--colors-red-100);--colors-semantic-main-nav-admin-content-active: var(--colors-neutral-0);--colors-semantic-main-nav-admin-hover: var(--colors-red-600);--colors-semantic-main-nav-admin-selected: var(--colors-red-600);--colors-semantic-main-nav-admin-selected-border: var(--colors-yellow-500);--colors-semantic-main-nav-admin-submenu-bg: var(--colors-neutral-900);--colors-semantic-main-nav-forvalt-bg: var(--colors-blue-800);--colors-semantic-main-nav-forvalt-content: var(--colors-blue-100);--colors-semantic-main-nav-forvalt-content-active: var(--colors-neutral-0);--colors-semantic-main-nav-forvalt-hover: var(--colors-blue-700);--colors-semantic-main-nav-forvalt-selected: var(--colors-blue-700);--colors-semantic-main-nav-forvalt-selected-border: var(--colors-yellow-500);--colors-semantic-main-nav-forvalt-submenu-bg: var(--colors-blue-900);--colors-semantic-main-nav-portal-bg: var(--colors-green-700);--colors-semantic-main-nav-portal-content: var(--colors-new-brand-light-yellow);--colors-semantic-main-nav-portal-content-active: var(--colors-neutral-0);--colors-semantic-main-nav-portal-hover: var(--colors-green-800);--colors-semantic-main-nav-portal-selected: var(--colors-green-800);--colors-semantic-main-nav-portal-selected-border: var(--colors-yellow-500);--colors-semantic-main-nav-portal-submenu-bg: var(--colors-green-900);--colors-semantic-primary-on-primary: var(--colors-new-brand-light-yellow);--colors-semantic-primary-on-primary-subtle: var(--colors-green-600);--colors-semantic-primary-primary: var(--colors-green-700);--colors-semantic-primary-primary-active: var(--colors-green-500);--colors-semantic-primary-primary-hover: var(--colors-green-600);--colors-semantic-primary-primary-subtle: var(--colors-green-100);--colors-semantic-primary-primary-subtle-border: var(--colors-green-300);--colors-semantic-roles-bg-board: var(--colors-new-brand-light-yellow);--colors-semantic-roles-bg-external: var(--colors-green-100);--colors-semantic-roles-bg-owner: var(--colors-blue-200);--colors-semantic-roles-bg-renter: var(--colors-blue-50);--colors-semantic-roles-bg-solibo: var(--colors-green-700);--colors-semantic-roles-content-board: var(--colors-green-700);--colors-semantic-roles-content-external: var(--colors-green-800);--colors-semantic-roles-content-owner: var(--colors-new-brand-dark-green);--colors-semantic-roles-content-renter: var(--colors-new-brand-dark-green);--colors-semantic-roles-content-solibo: var(--colors-new-brand-light-yellow);--colors-semantic-status-active-bg: var(--colors-new-brand-yellow);--colors-semantic-status-active-content: var(--colors-new-brand-dark-green);--colors-semantic-status-error-bg: var(--colors-red-50);--colors-semantic-status-error-border: var(--colors-red-300);--colors-semantic-status-error-content: var(--colors-red-800);--colors-semantic-status-error-content-inverse: var(--colors-neutral-0);--colors-semantic-status-info-bg: var(--colors-blue-50);--colors-semantic-status-info-border: var(--colors-blue-300);--colors-semantic-status-info-content: var(--colors-blue-800);--colors-semantic-status-info-content-inverse: var(--colors-neutral-0);--colors-semantic-status-pending-bg: var(--colors-neutral-200);--colors-semantic-status-pending-content: var(--colors-neutral-600);--colors-semantic-status-success-bg: var(--colors-green-100);--colors-semantic-status-success-border: var(--colors-green-300);--colors-semantic-status-success-content: var(--colors-green-800);--colors-semantic-status-success-content-inverse: var(--colors-neutral-0);--colors-semantic-status-warning-bg: var(--colors-orange-50);--colors-semantic-status-warning-border: var(--colors-orange-300);--colors-semantic-status-warning-content: var(--colors-orange-800);--colors-semantic-status-warning-content-inverse: var(--colors-neutral-0);--colors-translucent: #fff3;--colors-yellow-100: #f2f7a4;--colors-yellow-200: #e6f078;--colors-yellow-300: #daea46;--colors-yellow-400: var(--colors-new-brand-yellow);--colors-yellow-50: var(--colors-new-brand-light-yellow);--colors-yellow-500: #b0c62a;--colors-yellow-600: #96a439;--colors-yellow-700: var(--colors-new-brand-shadow-yellow);--colors-yellow-800: #50551c;--colors-yellow-900: #282b0d;--font-body: "Geist";--font-font-weight-bold: 700;--font-font-weight-medium: 500;--font-font-weight-regular: 400;--font-font-weight-semibold: 600;--font-headline: "Degular";--scale-0: 0px;--scale-1: 1px;--scale-12: 12px;--scale-14: 14px;--scale-16: 16px;--scale-18: 18px;--scale-2: 2px;--scale-20: 20px;--scale-24: 24px;--scale-28: 28px;--scale-32: 32px;--scale-4: 4px;--scale-40: 40px;--scale-48: 48px;--scale-56: 56px;--scale-64: 64px;--scale-72: 72px;--scale-8: 8px;--scale-80: 80px;--scale-88: 88px;--scale-96: 96px;--scale-negative-16: -16px;--shape-border-radius-radius-2xl: var(--scale-16);--shape-border-radius-radius-full: var(--scale-32);--shape-border-radius-radius-lg: var(--scale-8);--shape-border-radius-radius-md: var(--scale-4);--shape-border-radius-radius-none: var(--scale-0);--shape-border-radius-radius-sm: var(--scale-2);--shape-border-radius-radius-xl: var(--scale-12);--shape-border-width-default: 1px;--shape-border-width-thick: 2px;--shape-box-shadow-lg-blur: 12px;--shape-box-shadow-lg-color: var(--colors-box-shadow);--shape-box-shadow-lg-position-x: 0px;--shape-box-shadow-lg-position-y: 12px;--shape-box-shadow-lg-spread: -12px;--shape-box-shadow-md-blur: 8px;--shape-box-shadow-md-color: var(--colors-box-shadow);--shape-box-shadow-md-position-x: 0px;--shape-box-shadow-md-position-y: 8px;--shape-box-shadow-md-spread: -8px;--shape-box-shadow-sm-blur: 4px;--shape-box-shadow-sm-color: var(--colors-box-shadow);--shape-box-shadow-sm-position-x: 0px;--shape-box-shadow-sm-position-y: 4px;--shape-box-shadow-sm-spread: -4px;--shape-box-shadow-xl-blur: 16px;--shape-box-shadow-xl-color: var(--colors-box-shadow);--shape-box-shadow-xl-position-x: 0px;--shape-box-shadow-xl-position-y: 16px;--shape-box-shadow-xl-spread: -16px;--shape-box-shadow-xs-blur: 2px;--shape-box-shadow-xs-color: var(--colors-box-shadow);--shape-box-shadow-xs-position-x: 0px;--shape-box-shadow-xs-position-y: 1px;--shape-box-shadow-xs-spread: 0px;--shape-image-desktop-max-height: 400px;--shape-image-desktop-max-width: 320px;--shape-image-desktop-min-height: 96px;--shape-image-desktop-min-width: 96px;--shape-image-mobile-max-height: 320px;--shape-image-mobile-max-width: 240px;--shape-image-mobile-min-height: 96px;--shape-image-mobile-min-width: 96px;--shape-outline-focus: 3px;--shape-outline-selected: 1px;--shape-spacing-2xl: var(--scale-48);--shape-spacing-2xs: var(--scale-4);--shape-spacing-3xl: var(--scale-64);--shape-spacing-3xs: var(--scale-2);--shape-spacing-lg: var(--scale-24);--shape-spacing-md: var(--scale-16);--shape-spacing-none: var(--scale-0);--shape-spacing-sm: var(--scale-12);--shape-spacing-xl: var(--scale-32);--shape-spacing-xs: var(--scale-8);--shape-width-max: 480px;--shape-width-max-lg: 640px;--shape-width-sidebar: 240px;--typography-font-sizes-body-lg: var(--scale-18);--typography-font-sizes-body-md: var(--scale-16);--typography-font-sizes-body-sm: var(--scale-14);--typography-font-sizes-caption: var(--scale-12);--typography-font-sizes-display-lg: var(--scale-56);--typography-font-sizes-display-sm: var(--scale-48);--typography-font-sizes-h1: var(--scale-32);--typography-font-sizes-h2: var(--scale-28);--typography-font-sizes-h3: var(--scale-24);--typography-font-sizes-h4: var(--scale-20);--typography-font-sizes-label-lg: var(--scale-16);--typography-font-sizes-label-sm: var(--scale-14);--utils-tokens-blur-default: var(--scale-8);--utils-tokens-font-family-body: "Geist", "Arial", sans-serif;--utils-tokens-font-family-headline: "Degular", "Arial", sans-serif;--utils-tokens-gradient: linear-gradient(180deg, rgb(255 255 255 / 100%), transparent 50%);--utils-tokens-icon-large: var(--scale-32);--utils-tokens-icon-medium: var(--scale-24);--utils-tokens-icon-small: var(--scale-16);--utils-tokens-icon-tiny: var(--scale-12);--utils-tokens-negative-unit: var(--scale-negative-16);--utils-tokens-opacity-minimal: .5;--utils-tokens-transition-delay: 125ms;--utils-tokens-transition-duration: .25s;--utils-tokens-transition-timing-function: ease-out;--utils-tokens-unit: var(--scale-16);--utils-tokens-z-max: 2147483648}[data-theme=dark]{--colors-box-shadow: #000000e0;--colors-orange-100: #fdd7b0;--colors-orange-200: #fbc48a;--colors-orange-300: #faa954;--colors-orange-400: #f99933;--colors-orange-50: #fef2e6;--colors-orange-500: #f77f00;--colors-orange-600: #e17400;--colors-orange-700: #af5a00;--colors-orange-800: #884600;--colors-orange-900: #683500;--colors-red-100: #ebb2b1;--colors-red-200: #e28c8b;--colors-red-300: #d45856;--colors-red-400: #cc3835;--colors-red-50: #f9e6e6;--colors-red-500: #bf0603;--colors-red-600: #ae0503;--colors-red-700: #880402;--colors-red-800: #690302;--colors-red-900: #500301;--colors-semantic-bg-disabled: var(--colors-neutral-800);--colors-semantic-bg-overlay: var(--colors-neutral-600);--colors-semantic-bg-page: var(--colors-neutral-900);--colors-semantic-bg-surface: var(--colors-neutral-700);--colors-semantic-border-active: var(--colors-neutral-50);--colors-semantic-border-default: var(--colors-neutral-500);--colors-semantic-border-destructive: var(--colors-red-300);--colors-semantic-border-disabled: var(--colors-neutral-700);--colors-semantic-border-on-color: var(--colors-neutral-400);--colors-semantic-border-subtle: var(--colors-neutral-600);--colors-semantic-content-destructive: var(--colors-red-600);--colors-semantic-content-disabled: var(--colors-neutral-500);--colors-semantic-content-highlight: var(--colors-green-700);--colors-semantic-content-link: var(--colors-blue-400);--colors-semantic-content-link-hover: var(--colors-blue-600);--colors-semantic-content-on-color: var(--colors-neutral-0);--colors-semantic-content-primary: var(--colors-neutral-50);--colors-semantic-content-secondary: var(--colors-neutral-200);--colors-semantic-content-tertiary: var(--colors-neutral-300);--colors-semantic-interactive-destructive-bg: var(--colors-red-600);--colors-semantic-interactive-destructive-hover: var(--colors-red-700);--colors-semantic-interactive-disabled: var(--colors-neutral-500);--colors-semantic-interactive-hover: var(--colors-neutral-500);--colors-semantic-interactive-hover-subtle: var(--colors-neutral-600);--colors-semantic-interactive-neutral: var(--colors-neutral-400);--colors-semantic-interactive-pressed: var(--colors-green-700);--colors-semantic-interactive-secondary-bg: var(--colors-neutral-600);--colors-semantic-interactive-secondary-hover: var(--colors-neutral-500);--colors-semantic-interactive-selected: var(--colors-green-400);--colors-semantic-main-nav-admin-submenu-bg: var(--colors-red-900);--colors-semantic-main-nav-forvalt-hover: var(--colors-neutral-700);--colors-semantic-main-nav-forvalt-submenu-bg: var(--colors-neutral-900);--colors-semantic-primary-on-primary: var(--colors-neutral-0);--colors-semantic-primary-on-primary-subtle: var(--colors-green-200);--colors-semantic-primary-primary: var(--colors-green-300);--colors-semantic-primary-primary-active: var(--colors-green-50);--colors-semantic-primary-primary-hover: var(--colors-green-200);--colors-semantic-primary-primary-subtle: var(--colors-green-500);--colors-semantic-primary-primary-subtle-border: var(--colors-green-600);--colors-semantic-roles-content-owner: var(--colors-blue-800);--colors-semantic-roles-content-renter: var(--colors-blue-800);--colors-semantic-status-error-bg: var(--colors-red-200);--colors-semantic-status-info-bg: var(--colors-blue-200);--colors-semantic-status-info-border: var(--colors-blue-400);--colors-semantic-status-success-bg: var(--colors-green-200);--colors-semantic-status-warning-bg: var(--colors-orange-200);--colors-semantic-status-warning-border: var(--colors-orange-400)}@media (width <= 960px){:root{--typography-font-sizes-body-lg: var(--scale-16);--typography-font-sizes-display-lg: var(--scale-40);--typography-font-sizes-display-sm: var(--scale-32);--typography-font-sizes-h1: var(--scale-24);--typography-font-sizes-h2: var(--scale-20);--typography-font-sizes-h3: var(--scale-18);--typography-font-sizes-h4: var(--scale-16)}}*,:before,:after{box-sizing:border-box}:where(body,figure,input){margin:0}:where(img){display:block}:where(input,button,textarea,select){font:inherit}@media (prefers-reduced-motion: no-preference){@view-transition{navigation: auto;}:where(html,body){scroll-behavior:smooth}}:where(dt){font-weight:var(--font-font-weight-semibold);margin-top:var(--utils-tokens-unit)}:where(body){background-color:var(--colors-semantic-bg-page);font-family:var(--utils-tokens-font-family-body);font-size:var(--typography-font-sizes-body-md);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:where(:focus-visible){outline:solid var(--scale-2) var(--colors-semantic-border-focus);outline-offset:var(--shape-outline-offset, calc(var(--scale-2) * -1));border-radius:var(--shape-border-radius-radius-md)}:where(article a){color:var(--colors-semantic-content-link)}:where(b,strong){font-weight:var(--font-font-weight-bold)}:where(menu,ol,p,ul){margin-block:var(--utils-tokens-unit)}:where(menu,ol,ul){list-style:none;padding-inline-start:0}:where(small,sub){font-size:var(--typography-font-sizes-body-sm)}[data-content=screen-reader]{border:0;clip:rect(0,0,0,0);height:var(--scale-1);margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:var(--scale-1)}*[data-content=user-generated]{overflow-x:auto;word-break:break-word}*[data-content=user-generated] p{background-color:inherit!important;margin:0;max-width:100%;overflow:hidden;text-overflow:ellipsis}*[data-content=user-generated] p img{max-width:calc(100% - calc(2 * var(--utils-tokens-unit)))!important}*[data-content=user-generated] table{border-collapse:collapse;margin-bottom:var(--utils-tokens-unit);overflow:hidden!important;table-layout:fixed;text-overflow:ellipsis;width:auto!important}*[data-content=user-generated] table th,*[data-content=user-generated] table td,*[data-content=user-generated] table tr{max-width:calc(100% - calc(2 * var(--utils-tokens-unit)))!important;overflow:hidden;text-overflow:ellipsis;width:auto!important}*[data-content=user-generated] table th,*[data-content=user-generated] table td{border:var(--scale-1) solid var(--colors-semantic-border-default);padding:var(--scale-8) var(--utils-tokens-unit);text-align:left}*[data-content=user-generated] table th{background-color:var(--colors-semantic-bg-page)}*[data-content=user-generated] table th:first-child{border-top-left-radius:var(--shape-border-radius-radius-md)}*[data-content=user-generated] table th:last-child{border-top-right-radius:var(--shape-border-radius-radius-md)}*[data-content=user-generated] ul{margin-left:var(--scale-4)!important}*[data-content=user-generated] ul li{list-style:disc;margin-bottom:var(--scale-8);margin-left:var(--scale-16)}[data-required]{position:relative}[data-required]:after{color:var(--colors-semantic-status-error-content);content:"*";font-size:calc(var(--utils-tokens-unit) * 1.5);margin-left:var(--scale-2);position:absolute}[data-span=all]{-moz-column-span:all;column-span:all;grid-column:1 / -1}@supports (-moz-appearance: none){*{scrollbar-color:var(--colors-semantic-interactive-neutral) transparent}}::-webkit-scrollbar{height:var(--scale-8);width:var(--scale-8)}::-webkit-scrollbar-track,::-webkit-scrollbar-corner{background-color:transparent}::-webkit-scrollbar-thumb{background-color:var(--colors-semantic-interactive-neutral);border-radius:var(--shape-border-radius-radius-lg)}
|
|
1
|
+
@keyframes fade-in{0%{opacity:0}to{opacity:1}}@keyframes fade-out{0%{opacity:1}to{opacity:0}}@keyframes spin{to{transform:rotate(360deg)}}@keyframes stagger-in{0%{opacity:0;translate:0 4px}to{opacity:1;translate:0 0}}@media (prefers-reduced-motion: reduce){*{animation:none!important;opacity:1!important;transition:none!important;translate:none!important}}[data-animation=stagger]{--stagger-duration: var(--utils-tokens-transition-duration);--stagger-parent: var(--utils-tokens-transition-duration);--stagger-step: var(--utils-tokens-transition-duration)}[data-animation=stagger] *{--stagger-index: 0;--stagger-next: calc(var(--stagger-total) + var(--stagger-duration));--stagger-self: calc(var(--stagger-index) * var(--stagger-step));--stagger-total: calc(var(--stagger-parent) + var(--stagger-self));animation:stagger-in var(--stagger-duration) var(--utils-tokens-transition-timing-function) var(--utils-tokens-transition-delay) both;animation-delay:var(--stagger-total);opacity:0;translate:0 var(--scale-4);will-change:opacity,translate}[data-animation=stagger] *>*{--stagger-parent: var(--stagger-next)}[data-animation=stagger]>*:nth-child(1),[data-animation=stagger] *>*:nth-child(1){--stagger-index: 0}[data-animation=stagger]>*:nth-child(2),[data-animation=stagger] *>*:nth-child(2){--stagger-index: 1}[data-animation=stagger]>*:nth-child(3),[data-animation=stagger] *>*:nth-child(3){--stagger-index: 2}[data-animation=stagger]>*:nth-child(4),[data-animation=stagger] *>*:nth-child(4){--stagger-index: 3}[data-animation=stagger]>*:nth-child(5),[data-animation=stagger] *>*:nth-child(5){--stagger-index: 4}[data-animation=stagger]>*:nth-child(6),[data-animation=stagger] *>*:nth-child(6){--stagger-index: 5}[data-animation=stagger]>*:nth-child(7),[data-animation=stagger] *>*:nth-child(7){--stagger-index: 6}[data-animation=stagger]>*:nth-child(8),[data-animation=stagger] *>*:nth-child(8){--stagger-index: 7}[data-animation=stagger]>*:nth-child(9),[data-animation=stagger] *>*:nth-child(9){--stagger-index: 8}[data-animation=stagger]>*:nth-child(10),[data-animation=stagger] *>*:nth-child(10){--stagger-index: 9}[data-animation=stagger][data-stagger-step]{--stagger-step: attr(data-stagger-step time, 25ms)}[data-animation=stagger] [data-stagger-off],[data-animation=stagger] [data-stagger-off] *{--stagger-duration: 0ms;--stagger-parent: 0ms;--stagger-step: 0ms;animation:none!important;opacity:1!important;translate:none!important}@media print{@page{margin:1.5cm}*,*:before,*:after{animation:none!important;box-shadow:none!important;text-shadow:none!important;transition:none!important}html,body{background:#fff!important;color:#000!important;font:12pt/1.4 system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif!important}body{margin:0}nav,aside,button:not([data-print-content]),input,select,textarea,iframe,video,audio,body:before,[data-component=controls],[data-component=toolbar],[data-component=menu],[data-message-actions],[data-content=collapsible-indicator],[data-component=messages]>[data-component=editor],[data-component=messages]>[data-component=tooltip],.no-print,.print-hidden,[aria-hidden=true]{display:none!important}main,article,section,[data-component=appshell],[data-component=panel],[data-component=messages],[data-message-list],[data-component=list],[data-print-flow]{display:block!important;height:auto!important;max-height:none!important;min-height:0!important;min-width:0!important;overflow:visible!important;position:static!important;max-width:none!important;width:100%!important}main,article,section{margin:0!important;padding:0!important}article[data-component=card]{overflow:visible!important}[data-animation],[data-animation] *{opacity:1!important;translate:none!important}[data-message-type]{display:block!important;-moz-column-break-inside:auto;break-inside:auto;margin:0 0 1em!important;padding:0!important;background:transparent!important}[data-message-type]>*,[data-message-type] [data-appearance]{margin-inline:0!important;max-width:none!important;width:auto!important}[data-message-type] [data-appearance]{display:block!important;-webkit-line-clamp:unset!important;overflow:visible!important;padding:0!important;border:0!important;background:transparent!important;color:inherit!important;text-overflow:clip!important}[data-content=user-generated],html [data-content=user-generated] :is(p,table,th,td,tr),[data-component=file],[data-component=file] :is(a,button,span),[data-component=avatar] :is(strong,span){max-height:none!important;overflow:visible!important;text-overflow:clip!important;white-space:normal!important;overflow-wrap:anywhere}[data-component=file] button{color:#000!important}header,[data-component=message],[data-component=file]{color:#000!important}header :is(p,span,strong,b,em,time,h1,h2,h3,h4,h5,h6),[data-component=message] :is(p,span,strong,b,em,time,h1,h2,h3,h4,h5,h6),[data-component=file] :is(p,span,strong,b,em,time,h1,h2,h3,h4,h5,h6){color:inherit!important}[data-component=avatar] span,[data-component=file],[data-component=panel],[data-component=card],[data-component=messages]>ul{background-color:transparent!important}header{-moz-column-break-after:avoid;break-after:avoid}[data-component=card] :is(h1,h2,h3,h4,h5,h6){overflow:visible!important;white-space:normal!important}h1,h2,h3{-moz-column-break-after:avoid;break-after:avoid;page-break-after:avoid}p,h1,h2,h3,h4,h5,h6{orphans:3;widows:3}a{color:#000!important;text-decoration:underline}[data-component=file]>a[href]{flex-wrap:wrap}[data-component=file]>a[href]:after{flex-basis:100%}[data-content=user-generated] a[href^=http]:after,a[data-print-url][href^=http]:after,[data-component=file]>a[href]:not([href^="#"]):after{content:" (" attr(href) ")";font-size:90%;overflow-wrap:anywhere}table{border-collapse:collapse;page-break-inside:auto;width:100%}html [data-content=user-generated] table{table-layout:auto!important;width:100%!important}tr,img{-moz-column-break-inside:avoid;break-inside:avoid;page-break-inside:avoid}th,td{border:1px solid #000;padding:.25rem .4rem;vertical-align:top}thead{display:table-header-group}img,svg{height:auto!important;max-width:100%!important}pre,code{white-space:pre-wrap;word-break:break-word}pre,blockquote{-moz-column-break-inside:auto;break-inside:auto}.no-print,.print-hidden,[aria-hidden=true],[hidden]{display:none!important}}:root{--breakpoint-lg: 1024;--breakpoint-md: 768;--breakpoint-sm: 480;--colors-blue-100: #c9dcff;--colors-blue-200: var(--colors-new-brand-blue);--colors-blue-300: #6695ff;--colors-blue-400: #296afa;--colors-blue-50: var(--colors-new-brand-light-blue);--colors-blue-500: #0b4ad5;--colors-blue-600: #0c3797;--colors-blue-700: #0c2764;--colors-blue-800: #0b1938;--colors-blue-900: #090e1b;--colors-box-shadow: #0000001f;--colors-box-shadow-heavy: #0006;--colors-categories-bg-grey-1: #e3e4e6;--colors-categories-bg-grey-2: #d4dce5;--colors-categories-bg-pink-1: #e7e3ea;--colors-categories-bg-pink-2: #e3d2f0;--colors-categories-bg-pink-3: #d8bfe5;--colors-categories-bg-pink-4: #e0c3d8;--colors-categories-bg-pink-5: #e8c6d2;--colors-categories-bg-yellow-1: #d9cbaf;--colors-categories-bg-yellow-2: #d9c7c0;--colors-categories-bg-yellow-3: #cdb8ac;--colors-categories-content-on-grey: #3f444a;--colors-categories-content-on-pink: #783b65;--colors-categories-content-on-yellow: #65483f;--colors-green-100: #d9e0d7;--colors-green-200: #b8c7b3;--colors-green-300: #90aa88;--colors-green-400: #698c5f;--colors-green-50: #eff1ee;--colors-green-500: #4a6344;--colors-green-600: var(--colors-new-brand-shadow-green);--colors-green-700: var(--colors-new-brand-dark-green);--colors-green-800: #151b13;--colors-green-900: #0c0f0b;--colors-neutral-0: #fff;--colors-neutral-100: #ebebeb;--colors-neutral-200: #dfdfdf;--colors-neutral-300: #b3b3b3;--colors-neutral-400: #7b7b7b;--colors-neutral-50: #f5f5f5;--colors-neutral-500: #525252;--colors-neutral-600: #373737;--colors-neutral-700: #2a2a2a;--colors-neutral-800: #1c1c1c;--colors-neutral-900: #0b0b0b;--colors-new-brand-blue: #abc5ff;--colors-new-brand-dark-green: #202b1b;--colors-new-brand-light-blue: #e8f1ff;--colors-new-brand-light-yellow: #f8fac0;--colors-new-brand-nature-white: #f7f7e1;--colors-new-brand-shadow-green: #263821;--colors-new-brand-shadow-yellow: #7d8233;--colors-new-brand-yellow: #cde517;--colors-orange-100: #fbe7d3;--colors-orange-200: #f1cda7;--colors-orange-300: #e6b37a;--colors-orange-400: #dc9c50;--colors-orange-50: #fff5ea;--colors-orange-500: #cf8a33;--colors-orange-600: #a96f23;--colors-orange-700: #885716;--colors-orange-800: #633e0d;--colors-orange-900: #442a08;--colors-red-100: #f8e2de;--colors-red-200: #e9bbb3;--colors-red-300: #d1897e;--colors-red-400: #aa5449;--colors-red-50: #fff4f2;--colors-red-500: #862b22;--colors-red-600: #702018;--colors-red-700: #5a1610;--colors-red-800: #43100b;--colors-red-900: #2d0906;--colors-semantic-bg-backdrop: #000000d9;--colors-semantic-bg-disabled: var(--colors-neutral-50);--colors-semantic-bg-overlay: var(--colors-neutral-100);--colors-semantic-bg-page: var(--colors-neutral-50);--colors-semantic-bg-surface: var(--colors-neutral-0);--colors-semantic-border-active: var(--colors-neutral-800);--colors-semantic-border-default: var(--colors-neutral-200);--colors-semantic-border-destructive: var(--colors-red-600);--colors-semantic-border-disabled: var(--colors-neutral-100);--colors-semantic-border-focus: var(--colors-new-brand-shadow-yellow);--colors-semantic-border-on-color: var(--colors-neutral-0);--colors-semantic-border-strong: var(--colors-neutral-300);--colors-semantic-border-subtle: var(--colors-neutral-100);--colors-semantic-content-destructive: var(--colors-red-700);--colors-semantic-content-disabled: var(--colors-neutral-400);--colors-semantic-content-highlight: var(--colors-green-200);--colors-semantic-content-link: var(--colors-blue-500);--colors-semantic-content-link-hover: var(--colors-blue-700);--colors-semantic-content-link-visited: var(--colors-blue-600);--colors-semantic-content-on-color: var(--colors-semantic-primary-on-primary);--colors-semantic-content-primary: var(--colors-green-700);--colors-semantic-content-secondary: var(--colors-neutral-600);--colors-semantic-content-tertiary: var(--colors-neutral-500);--colors-semantic-interactive-destructive-bg: var(--colors-red-500);--colors-semantic-interactive-destructive-disabled: var(--colors-red-200);--colors-semantic-interactive-destructive-hover: var(--colors-red-600);--colors-semantic-interactive-disabled: var(--colors-neutral-200);--colors-semantic-interactive-hover: var(--colors-green-50);--colors-semantic-interactive-hover-overlay: #0000001f;--colors-semantic-interactive-hover-subtle: var(--colors-neutral-100);--colors-semantic-interactive-neutral: var(--colors-neutral-300);--colors-semantic-interactive-pressed: var(--colors-green-100);--colors-semantic-interactive-secondary-bg: var(--colors-green-100);--colors-semantic-interactive-secondary-destructive-hover: var(--colors-red-50);--colors-semantic-interactive-secondary-hover: var(--colors-green-200);--colors-semantic-interactive-selected: var(--colors-green-100);--colors-semantic-main-nav-admin-bg: var(--colors-red-800);--colors-semantic-main-nav-admin-content: var(--colors-red-100);--colors-semantic-main-nav-admin-content-active: var(--colors-neutral-0);--colors-semantic-main-nav-admin-hover: var(--colors-red-600);--colors-semantic-main-nav-admin-selected: var(--colors-red-600);--colors-semantic-main-nav-admin-selected-border: var(--colors-yellow-500);--colors-semantic-main-nav-admin-submenu-bg: var(--colors-neutral-900);--colors-semantic-main-nav-forvalt-bg: var(--colors-blue-800);--colors-semantic-main-nav-forvalt-content: var(--colors-blue-100);--colors-semantic-main-nav-forvalt-content-active: var(--colors-neutral-0);--colors-semantic-main-nav-forvalt-hover: var(--colors-blue-700);--colors-semantic-main-nav-forvalt-selected: var(--colors-blue-700);--colors-semantic-main-nav-forvalt-selected-border: var(--colors-yellow-500);--colors-semantic-main-nav-forvalt-submenu-bg: var(--colors-blue-900);--colors-semantic-main-nav-portal-bg: var(--colors-green-700);--colors-semantic-main-nav-portal-content: var(--colors-new-brand-light-yellow);--colors-semantic-main-nav-portal-content-active: var(--colors-neutral-0);--colors-semantic-main-nav-portal-hover: var(--colors-green-800);--colors-semantic-main-nav-portal-selected: var(--colors-green-800);--colors-semantic-main-nav-portal-selected-border: var(--colors-yellow-500);--colors-semantic-main-nav-portal-submenu-bg: var(--colors-green-900);--colors-semantic-primary-on-primary: var(--colors-new-brand-light-yellow);--colors-semantic-primary-on-primary-subtle: var(--colors-green-600);--colors-semantic-primary-primary: var(--colors-green-700);--colors-semantic-primary-primary-active: var(--colors-green-500);--colors-semantic-primary-primary-hover: var(--colors-green-600);--colors-semantic-primary-primary-subtle: var(--colors-green-100);--colors-semantic-primary-primary-subtle-border: var(--colors-green-300);--colors-semantic-roles-bg-board: var(--colors-new-brand-light-yellow);--colors-semantic-roles-bg-external: var(--colors-green-100);--colors-semantic-roles-bg-owner: var(--colors-blue-200);--colors-semantic-roles-bg-renter: var(--colors-blue-50);--colors-semantic-roles-bg-solibo: var(--colors-green-700);--colors-semantic-roles-content-board: var(--colors-green-700);--colors-semantic-roles-content-external: var(--colors-green-800);--colors-semantic-roles-content-owner: var(--colors-new-brand-dark-green);--colors-semantic-roles-content-renter: var(--colors-new-brand-dark-green);--colors-semantic-roles-content-solibo: var(--colors-new-brand-light-yellow);--colors-semantic-status-active-bg: var(--colors-new-brand-yellow);--colors-semantic-status-active-content: var(--colors-new-brand-dark-green);--colors-semantic-status-error-bg: var(--colors-red-50);--colors-semantic-status-error-border: var(--colors-red-300);--colors-semantic-status-error-content: var(--colors-red-800);--colors-semantic-status-error-content-inverse: var(--colors-neutral-0);--colors-semantic-status-info-bg: var(--colors-blue-50);--colors-semantic-status-info-border: var(--colors-blue-300);--colors-semantic-status-info-content: var(--colors-blue-800);--colors-semantic-status-info-content-inverse: var(--colors-neutral-0);--colors-semantic-status-pending-bg: var(--colors-neutral-200);--colors-semantic-status-pending-content: var(--colors-neutral-600);--colors-semantic-status-success-bg: var(--colors-green-100);--colors-semantic-status-success-border: var(--colors-green-300);--colors-semantic-status-success-content: var(--colors-green-800);--colors-semantic-status-success-content-inverse: var(--colors-neutral-0);--colors-semantic-status-warning-bg: var(--colors-orange-50);--colors-semantic-status-warning-border: var(--colors-orange-300);--colors-semantic-status-warning-content: var(--colors-orange-800);--colors-semantic-status-warning-content-inverse: var(--colors-neutral-0);--colors-translucent: #fff3;--colors-yellow-100: #f2f7a4;--colors-yellow-200: #e6f078;--colors-yellow-300: #daea46;--colors-yellow-400: var(--colors-new-brand-yellow);--colors-yellow-50: var(--colors-new-brand-light-yellow);--colors-yellow-500: #b0c62a;--colors-yellow-600: #96a439;--colors-yellow-700: var(--colors-new-brand-shadow-yellow);--colors-yellow-800: #50551c;--colors-yellow-900: #282b0d;--font-body: "Geist";--font-font-weight-bold: 700;--font-font-weight-medium: 500;--font-font-weight-regular: 400;--font-font-weight-semibold: 600;--font-headline: "Degular";--scale-0: 0px;--scale-1: 1px;--scale-12: 12px;--scale-14: 14px;--scale-16: 16px;--scale-18: 18px;--scale-2: 2px;--scale-20: 20px;--scale-24: 24px;--scale-28: 28px;--scale-32: 32px;--scale-4: 4px;--scale-40: 40px;--scale-48: 48px;--scale-56: 56px;--scale-64: 64px;--scale-72: 72px;--scale-8: 8px;--scale-80: 80px;--scale-88: 88px;--scale-96: 96px;--scale-negative-16: -16px;--shape-border-radius-radius-2xl: var(--scale-16);--shape-border-radius-radius-full: var(--scale-32);--shape-border-radius-radius-lg: var(--scale-8);--shape-border-radius-radius-md: var(--scale-4);--shape-border-radius-radius-none: var(--scale-0);--shape-border-radius-radius-sm: var(--scale-2);--shape-border-radius-radius-xl: var(--scale-12);--shape-border-width-default: 1px;--shape-border-width-thick: 2px;--shape-box-shadow-lg-blur: 12px;--shape-box-shadow-lg-color: var(--colors-box-shadow);--shape-box-shadow-lg-position-x: 0px;--shape-box-shadow-lg-position-y: 12px;--shape-box-shadow-lg-spread: -12px;--shape-box-shadow-md-blur: 8px;--shape-box-shadow-md-color: var(--colors-box-shadow);--shape-box-shadow-md-position-x: 0px;--shape-box-shadow-md-position-y: 8px;--shape-box-shadow-md-spread: -8px;--shape-box-shadow-sm-blur: 4px;--shape-box-shadow-sm-color: var(--colors-box-shadow);--shape-box-shadow-sm-position-x: 0px;--shape-box-shadow-sm-position-y: 4px;--shape-box-shadow-sm-spread: -4px;--shape-box-shadow-xl-blur: 16px;--shape-box-shadow-xl-color: var(--colors-box-shadow);--shape-box-shadow-xl-position-x: 0px;--shape-box-shadow-xl-position-y: 16px;--shape-box-shadow-xl-spread: -16px;--shape-box-shadow-xs-blur: 2px;--shape-box-shadow-xs-color: var(--colors-box-shadow);--shape-box-shadow-xs-position-x: 0px;--shape-box-shadow-xs-position-y: 1px;--shape-box-shadow-xs-spread: 0px;--shape-image-desktop-max-height: 400px;--shape-image-desktop-max-width: 320px;--shape-image-desktop-min-height: 96px;--shape-image-desktop-min-width: 96px;--shape-image-mobile-max-height: 320px;--shape-image-mobile-max-width: 240px;--shape-image-mobile-min-height: 96px;--shape-image-mobile-min-width: 96px;--shape-outline-focus: 3px;--shape-outline-selected: 1px;--shape-spacing-2xl: var(--scale-48);--shape-spacing-2xs: var(--scale-4);--shape-spacing-3xl: var(--scale-64);--shape-spacing-3xs: var(--scale-2);--shape-spacing-lg: var(--scale-24);--shape-spacing-md: var(--scale-16);--shape-spacing-none: var(--scale-0);--shape-spacing-sm: var(--scale-12);--shape-spacing-xl: var(--scale-32);--shape-spacing-xs: var(--scale-8);--shape-width-max: 480px;--shape-width-max-lg: 640px;--shape-width-sidebar: 240px;--typography-font-sizes-body-lg: var(--scale-18);--typography-font-sizes-body-md: var(--scale-16);--typography-font-sizes-body-sm: var(--scale-14);--typography-font-sizes-caption: var(--scale-12);--typography-font-sizes-display-lg: var(--scale-56);--typography-font-sizes-display-sm: var(--scale-48);--typography-font-sizes-h1: var(--scale-32);--typography-font-sizes-h2: var(--scale-28);--typography-font-sizes-h3: var(--scale-24);--typography-font-sizes-h4: var(--scale-20);--typography-font-sizes-label-lg: var(--scale-16);--typography-font-sizes-label-sm: var(--scale-14);--utils-tokens-blur-default: var(--scale-8);--utils-tokens-font-family-body: "Geist", "Arial", sans-serif;--utils-tokens-font-family-headline: "Degular", "Arial", sans-serif;--utils-tokens-gradient: linear-gradient(180deg, rgb(255 255 255 / 100%), transparent 50%);--utils-tokens-icon-large: var(--scale-32);--utils-tokens-icon-medium: var(--scale-24);--utils-tokens-icon-small: var(--scale-16);--utils-tokens-icon-tiny: var(--scale-12);--utils-tokens-negative-unit: var(--scale-negative-16);--utils-tokens-opacity-minimal: .5;--utils-tokens-transition-delay: 125ms;--utils-tokens-transition-duration: .25s;--utils-tokens-transition-timing-function: ease-out;--utils-tokens-unit: var(--scale-16);--utils-tokens-z-max: 2147483648}[data-theme=dark]{--colors-box-shadow: #000000e0;--colors-orange-100: #fdd7b0;--colors-orange-200: #fbc48a;--colors-orange-300: #faa954;--colors-orange-400: #f99933;--colors-orange-50: #fef2e6;--colors-orange-500: #f77f00;--colors-orange-600: #e17400;--colors-orange-700: #af5a00;--colors-orange-800: #884600;--colors-orange-900: #683500;--colors-red-100: #ebb2b1;--colors-red-200: #e28c8b;--colors-red-300: #d45856;--colors-red-400: #cc3835;--colors-red-50: #f9e6e6;--colors-red-500: #bf0603;--colors-red-600: #ae0503;--colors-red-700: #880402;--colors-red-800: #690302;--colors-red-900: #500301;--colors-semantic-bg-disabled: var(--colors-neutral-800);--colors-semantic-bg-overlay: var(--colors-neutral-600);--colors-semantic-bg-page: var(--colors-neutral-900);--colors-semantic-bg-surface: var(--colors-neutral-700);--colors-semantic-border-active: var(--colors-neutral-50);--colors-semantic-border-default: var(--colors-neutral-500);--colors-semantic-border-destructive: var(--colors-red-300);--colors-semantic-border-disabled: var(--colors-neutral-700);--colors-semantic-border-on-color: var(--colors-neutral-400);--colors-semantic-border-subtle: var(--colors-neutral-600);--colors-semantic-content-destructive: var(--colors-red-600);--colors-semantic-content-disabled: var(--colors-neutral-500);--colors-semantic-content-highlight: var(--colors-green-700);--colors-semantic-content-link: var(--colors-blue-400);--colors-semantic-content-link-hover: var(--colors-blue-600);--colors-semantic-content-on-color: var(--colors-neutral-0);--colors-semantic-content-primary: var(--colors-neutral-50);--colors-semantic-content-secondary: var(--colors-neutral-200);--colors-semantic-content-tertiary: var(--colors-neutral-300);--colors-semantic-interactive-destructive-bg: var(--colors-red-600);--colors-semantic-interactive-destructive-hover: var(--colors-red-700);--colors-semantic-interactive-disabled: var(--colors-neutral-500);--colors-semantic-interactive-hover: var(--colors-neutral-500);--colors-semantic-interactive-hover-subtle: var(--colors-neutral-600);--colors-semantic-interactive-neutral: var(--colors-neutral-400);--colors-semantic-interactive-pressed: var(--colors-green-700);--colors-semantic-interactive-secondary-bg: var(--colors-neutral-600);--colors-semantic-interactive-secondary-hover: var(--colors-neutral-500);--colors-semantic-interactive-selected: var(--colors-green-400);--colors-semantic-main-nav-admin-submenu-bg: var(--colors-red-900);--colors-semantic-main-nav-forvalt-hover: var(--colors-neutral-700);--colors-semantic-main-nav-forvalt-submenu-bg: var(--colors-neutral-900);--colors-semantic-primary-on-primary: var(--colors-neutral-0);--colors-semantic-primary-on-primary-subtle: var(--colors-green-200);--colors-semantic-primary-primary: var(--colors-green-300);--colors-semantic-primary-primary-active: var(--colors-green-50);--colors-semantic-primary-primary-hover: var(--colors-green-200);--colors-semantic-primary-primary-subtle: var(--colors-green-500);--colors-semantic-primary-primary-subtle-border: var(--colors-green-600);--colors-semantic-roles-content-owner: var(--colors-blue-800);--colors-semantic-roles-content-renter: var(--colors-blue-800);--colors-semantic-status-error-bg: var(--colors-red-200);--colors-semantic-status-info-bg: var(--colors-blue-200);--colors-semantic-status-info-border: var(--colors-blue-400);--colors-semantic-status-success-bg: var(--colors-green-200);--colors-semantic-status-warning-bg: var(--colors-orange-200);--colors-semantic-status-warning-border: var(--colors-orange-400)}@media (width <= 960px){:root{--typography-font-sizes-body-lg: var(--scale-16);--typography-font-sizes-display-lg: var(--scale-40);--typography-font-sizes-display-sm: var(--scale-32);--typography-font-sizes-h1: var(--scale-24);--typography-font-sizes-h2: var(--scale-20);--typography-font-sizes-h3: var(--scale-18);--typography-font-sizes-h4: var(--scale-16)}}*,:before,:after{box-sizing:border-box}:where(body,figure,input){margin:0}:where(img){display:block}:where(input,button,textarea,select){font:inherit}@media (prefers-reduced-motion: no-preference){@view-transition{navigation: auto;}:where(html,body){scroll-behavior:smooth}}:where(dt){font-weight:var(--font-font-weight-semibold);margin-top:var(--utils-tokens-unit)}:where(body){background-color:var(--colors-semantic-bg-page);font-family:var(--utils-tokens-font-family-body);font-size:var(--typography-font-sizes-body-md);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:where(:focus-visible){outline:solid var(--scale-2) var(--colors-semantic-border-focus);outline-offset:var(--shape-outline-offset, calc(var(--scale-2) * -1));border-radius:var(--shape-border-radius-radius-md)}:where(article a){color:var(--colors-semantic-content-link)}:where(b,strong){font-weight:var(--font-font-weight-bold)}:where(menu,ol,p,ul){margin-block:var(--utils-tokens-unit)}:where(menu,ol,ul){list-style:none;padding-inline-start:0}:where(small,sub){font-size:var(--typography-font-sizes-body-sm)}[data-content=screen-reader]{border:0;clip:rect(0,0,0,0);height:var(--scale-1);margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:var(--scale-1)}*[data-content=user-generated]{overflow-x:auto;word-break:break-word}*[data-content=user-generated] p{background-color:inherit!important;margin:0;max-width:100%;overflow:hidden;text-overflow:ellipsis}*[data-content=user-generated] p img{max-width:calc(100% - calc(2 * var(--utils-tokens-unit)))!important}*[data-content=user-generated] table{border-collapse:collapse;margin-bottom:var(--utils-tokens-unit);overflow:hidden!important;table-layout:fixed;text-overflow:ellipsis;width:auto!important}*[data-content=user-generated] table th,*[data-content=user-generated] table td,*[data-content=user-generated] table tr{max-width:calc(100% - calc(2 * var(--utils-tokens-unit)))!important;overflow:hidden;text-overflow:ellipsis;width:auto!important}*[data-content=user-generated] table th,*[data-content=user-generated] table td{border:var(--scale-1) solid var(--colors-semantic-border-default);padding:var(--scale-8) var(--utils-tokens-unit);text-align:left}*[data-content=user-generated] table th{background-color:var(--colors-semantic-bg-page)}*[data-content=user-generated] table th:first-child{border-top-left-radius:var(--shape-border-radius-radius-md)}*[data-content=user-generated] table th:last-child{border-top-right-radius:var(--shape-border-radius-radius-md)}*[data-content=user-generated] ul{margin-left:var(--scale-4)!important}*[data-content=user-generated] ul li{list-style:disc;margin-bottom:var(--scale-8);margin-left:var(--scale-16)}[data-required]{position:relative}[data-required]:after{color:var(--colors-semantic-status-error-content);content:"*";font-size:calc(var(--utils-tokens-unit) * 1.5);margin-left:var(--scale-2);position:absolute}[data-span=all]{-moz-column-span:all;column-span:all;grid-column:1 / -1}@supports (-moz-appearance: none){*{scrollbar-color:var(--colors-semantic-interactive-neutral) transparent}}::-webkit-scrollbar{height:var(--scale-8);width:var(--scale-8)}::-webkit-scrollbar-track,::-webkit-scrollbar-corner{background-color:transparent}::-webkit-scrollbar-thumb{background-color:var(--colors-semantic-interactive-neutral);border-radius:var(--shape-border-radius-radius-lg)}
|
package/dist/assets/index11.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._panel_1c69h_1{display:flex;flex:1;flex-direction:column;min-height:0;min-width:0;overflow:hidden;position:relative}._default_1c69h_11{padding:var(--shape-spacing-md)}._none_1c69h_15{padding:0}._page_1c69h_19{padding:var(--shape-spacing-md) var(--shape-spacing-lg)}@media (width <= 1024px){._page_1c69h_19{padding:var(--shape-spacing-md)}}._scrollable_1c69h_27{display:block;overflow:auto}._surface_1c69h_32{background-color:var(--colors-semantic-bg-surface)}._panel_1c69h_1._loading_1c69h_36{align-items:center;display:flex;justify-content:center;overflow:hidden}
|
package/dist/assets/index12.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._layout_1nh7z_1{margin:0 auto;padding:var(--shape-spacing-xl) var(--shape-spacing-2xl);width:100%}._constrained_1nh7z_7>article{max-width:var(--page-content-max-width);width:100%}._reading_1nh7z_12>article{min-width:0}._reading_1nh7z_12>article>:not(header,[data-component=controls],[data-span=all]){max-width:min(100%,var(--page-content-max-width, var(--shape-width-max-lg)))}._reading_1nh7z_12>article [data-component=emptystate]{margin-inline:0}._with-sidebar_1nh7z_24{display:grid;grid-template-columns:var(--shape-width-sidebar) minmax(0,1fr);padding:0}._with-sidebar_1nh7z_24>article:not([data-component=panel]){padding:var(--shape-spacing-md) var(--shape-spacing-lg)}._fill-viewport_1nh7z_34{height:100dvh;min-height:0;overflow:hidden}._loading_1nh7z_40{display:grid}._loading_1nh7z_40:not(._fill-viewport_1nh7z_34){min-height:100dvh}._loading-content_1nh7z_48{align-items:center;display:flex;justify-content:center;min-height:0;min-width:0}@media (width <= 1024px){._layout_1nh7z_1{padding:calc(var(--utils-tokens-unit) * 4) var(--utils-tokens-unit)}._with-sidebar_1nh7z_24{padding:0}._with-sidebar_1nh7z_24>article:not([data-component=panel]){padding:var(--shape-spacing-md)}._fill-viewport_1nh7z_34{height:calc(100dvh - var(--shape-spacing-3xl))}._loading_1nh7z_40:not(._fill-viewport_1nh7z_34){min-height:calc(100dvh - var(--shape-spacing-3xl))}}@media (width <= 768px){._with-sidebar_1nh7z_24{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr)}}._layout_1nh7z_1._without-padding_1nh7z_87{padding:0}
|
package/dist/assets/index38.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
._croppable_1tvcl_1{align-items:center;background-color:var(--colors-semantic-bg-overlay);display:flex;justify-content:center;position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:100%}._croppable_1tvcl_1 input[type=file]{display:none}._empty_1tvcl_15{align-items:center;display:flex;flex-direction:column;gap:var(--utils-tokens-unit);text-align:center}._drop-target_1tvcl_23{outline:var(--scale-2) solid var(--colors-semantic-border-focus);outline-offset:calc(-1 * var(--scale-2))}._action_1tvcl_28{align-items:center;display:inline-flex;flex-direction:column;padding:var(--shape-spacing-2xs);vertical-align:bottom}._caption_1tvcl_36{color:var(--colors-semantic-content-secondary);font-size:var(--typography-font-sizes-caption);line-height:1.4;text-align:center}._media_1tvcl_43{align-items:center;display:flex;height:100%;top:0;right:0;bottom:0;left:0;justify-content:center;position:absolute;transform:translate(var(--croppable-x, 0),var(--croppable-y, 0));width:100%}._viewport_1tvcl_54{align-items:center;display:flex;height:var(--croppable-height, calc(12 * var(--utils-tokens-unit)));justify-content:center;overflow:hidden;overscroll-behavior:none;position:relative;touch-action:none;width:100%}._draggable_1tvcl_66{cursor:move}._dragging_1tvcl_70{cursor:grabbing}._inner_1tvcl_74{height:var(--croppable-image-height, 100%);transform:scale(var(--croppable-zoom, 1));transform-origin:center;width:var(--croppable-image-width, 100%)}._inner_1tvcl_74 img,._inner_1tvcl_74 picture,._inner_1tvcl_74 video{-webkit-user-drag:none;height:100%;user-drag:none;width:100%}._standalone_1tvcl_90{border-radius:var(--shape-border-radius-radius-md)}
|
package/dist/assets/index53.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@keyframes
|
|
1
|
+
@keyframes _ping_1jrs1_52{0%{opacity:1;transform:scale(0)}to{opacity:0;transform:scale(1)}}@keyframes _spin_1jrs1_1{0%{transform:rotate(0)}to{transform:rotate(360deg)}}._loading_1jrs1_23{display:inline-block;line-height:0;overflow:hidden}._default_1jrs1_29{animation:_spin_1jrs1_1 1s linear infinite;border:var(--scale-4) solid var(--colors-semantic-primary-primary-subtle-border);border-bottom-color:var(--colors-semantic-primary-primary-hover);border-radius:50%;box-sizing:border-box;display:inline-block;height:var(--utils-tokens-icon-medium);width:var(--utils-tokens-icon-medium)}._small_1jrs1_40{border-width:calc(var(--scale-4) - var(--scale-1));height:var(--utils-tokens-icon-small);width:var(--utils-tokens-icon-small)}._large_1jrs1_46{border-width:calc(var(--scale-4) + var(--scale-1));height:var(--utils-tokens-icon-large);width:var(--utils-tokens-icon-large)}._ping_1jrs1_52{display:inline-block;height:var(--utils-tokens-icon-medium);position:relative;width:var(--utils-tokens-icon-medium)}._ping_1jrs1_52:after,._ping_1jrs1_52:before{animation:_ping_1jrs1_52 2s linear infinite;border:var(--scale-4) solid var(--colors-semantic-primary-primary);border-radius:50%;box-sizing:border-box;content:"";height:var(--utils-tokens-icon-medium);left:0;position:absolute;top:0;width:var(--utils-tokens-icon-medium)}._ping_1jrs1_52:after{animation-delay:1s;opacity:0}._fullscreen_1jrs1_78,._fullscreen_1jrs1_78:after,._fullscreen_1jrs1_78:before{border-width:clamp(var(--scale-4),1.25vmin,var(--scale-16));height:min(15vw,15dvh);width:min(15vw,15dvh)}._sticky_1jrs1_86{position:absolute;top:0}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index38.css');const a=require("react/jsx-runtime"),ht=require("classix"),o=require("react"),Zt=require("../toolbar/index.cjs"),et=require("../button/index.cjs"),qt=require("../figure/index.cjs"),$t=require("../icon/index.cjs"),A=10,Z=.1,Gt=.92,y=(i,d,x)=>Math.min(x,Math.max(d,i)),Ft=i=>new Promise((d,x)=>{const z=URL.createObjectURL(i),s=new globalThis.Image;s.onload=()=>{URL.revokeObjectURL(z),d(s)},s.onerror=()=>{URL.revokeObjectURL(z),x(new Error("croppable-image-load-failed"))},s.src=z}),Jt=async({file:i,fill:d,transform:x,viewport:z})=>{const s=await Ft(i),D=z.width/s.naturalWidth,W=z.height/s.naturalHeight,O=Math.max(D,W),q=s.naturalWidth*O,H=s.naturalHeight*O,j=d==="width"?Math.max(Z,D/O):d==="height"?Math.max(Z,W/O):Z,S=y(x.zoom,j,A),R=O*S,v=q*S,M=H*S,nt=(z.width-v)/2+x.offset.x,P=(z.height-M)/2+x.offset.y,b=y(-nt/R,0,s.naturalWidth),_=y(-P/R,0,s.naturalHeight),$=y(z.width/R,1,Math.max(1,s.naturalWidth-b)),g=y(z.height/R,1,Math.max(1,s.naturalHeight-_)),h=document.createElement("canvas"),L=h.getContext("2d");if(!L)throw new Error("croppable-image-context-missing");h.width=Math.max(1,Math.round($)),h.height=Math.max(1,Math.round(g)),L.drawImage(s,b,_,$,g,0,0,h.width,h.height);const E=i.type.startsWith("image/")?i.type:"image/jpeg",U=await new Promise(u=>{h.toBlob(u,E,Gt)});if(!U)throw new Error("croppable-image-export-failed");return new globalThis.File([U],i.name,{lastModified:Date.now(),type:U.type||E})},Kt="_croppable_sjc2z_1",Qt="_empty_sjc2z_15",Vt="_action_sjc2z_23",Ct="_caption_sjc2z_31",te="_media_sjc2z_38",ee="_viewport_sjc2z_49",ne="_draggable_sjc2z_61",re="_dragging_sjc2z_65",ce="_inner_sjc2z_69",oe="_standalone_sjc2z_85",f={croppable:Kt,empty:Qt,action:Vt,caption:Ct,media:te,viewport:ee,draggable:ne,dragging:re,inner:ce,standalone:oe},se=192,T={offset:{x:0,y:0},zoom:1},Ut=(i,d)=>(i==null?void 0:i.file)===d.file&&(i==null?void 0:i.source)===d.source&&(i==null?void 0:i.settings)===d.settings,ie=({cancelLabel:i,children:d,fill:x="none",height:z,image:s,deleteLabel:D,saveLabel:W,uploadLabel:O,onCroppableChange:q,onDelete:H,onFileChange:j,onImageChange:S,onSave:R,onTransformChange:v,transform:M,standalone:nt})=>{const P=o.useRef(null),b=o.useRef(null),_=o.useRef(null),$=o.useRef(null),g=o.useRef(S),h=o.useRef(null),L=o.useRef(null),E=o.useRef(null),U=o.useRef(new Map),u=o.useRef(T),rt=o.useRef(null),[w,J]=o.useState(null),[ct,ot]=o.useState(null),[ft,K]=o.useState(!1),[Ot,st]=o.useState(T),[N,it]=o.useState(null),[m,St]=o.useState({width:0,height:0}),[pt,at]=o.useState(null),[G,Q]=o.useState(null),F=(()=>{const t=m.width,n=m.height;if(!t||!n)return{width:0,height:0,minZoom:Z};if(!w)return{width:t,height:n,minZoom:Z};const r=t/w.width,e=n/w.height,c=Math.max(r,e),l=x==="width"?r/c:x==="height"?e/c:0;return{width:w.width*c,height:w.height*c,minZoom:Math.max(Z,l)}})(),B=F.minZoom,X=M??Ot,Y=y(X.zoom,B,A),V=ct??s??null,mt=!d&&!!s&&!ct&&!N,C=!mt,xt=d??(V?a.jsx("img",{alt:"",draggable:!1,onLoad:t=>{const n=t.currentTarget;n.naturalWidth&&n.naturalHeight&&J({width:n.naturalWidth,height:n.naturalHeight})},src:V}):null),I=xt==null,ut={file:N,source:ct,settings:JSON.stringify([x,Y,X.offset.x,X.offset.y,m.width,m.height])};o.useEffect(()=>{!G||!s||s===G.image&&s!==G.crop.source||(at(G.crop),Q(null))},[s,G]);const lt=(t,n)=>{const{maxX:r,maxY:e}=wt(n);return{x:y(t.x,-r,r),y:y(t.y,-e,e)}},gt=(t,n)=>{const r=rt.current;if(!r)return null;const e=r.getBoundingClientRect(),c=t-e.left-e.width/2,l=n-e.top-e.height/2;return{x:c,y:l}},vt=(t,n,r,e)=>{const c=y(n,B,A),l=y(r,B,A);if(c===0)return t;const p=l/c;return{x:(1-p)*e.x+p*t.x,y:(1-p)*e.y+p*t.y}},Pt=(t,n,r)=>{const e=u.current.zoom,c=y(t,B,A),l=u.current.offset,p=r?vt(l,e,c,r):n,k=lt(p,c);u.current={zoom:c,offset:k},M||st({zoom:c,offset:k}),v==null||v({zoom:c,offset:k})},tt=(t,n,r)=>{L.current={zoom:t,offset:n,anchor:r??null},b.current==null&&(b.current=window.requestAnimationFrame(()=>{b.current=null;const e=L.current;L.current=null;const c=(e==null?void 0:e.zoom)??u.current.zoom,l=(e==null?void 0:e.offset)??u.current.offset,p=(e==null?void 0:e.anchor)??null;Pt(c,l,p)}))},It=t=>{if(I||!C)return;const n=t.ctrlKey?.001:25e-5,r=u.current.zoom*Math.exp(-t.deltaY*n),e=gt(t.clientX,t.clientY);tt(r,u.current.offset,e)},wt=t=>{const n=m.width,r=m.height;if(!n||!r)return{maxX:0,maxY:0};const e=y(t,B,A),c=F.width*e,l=F.height*e,p=Math.max(0,(c-n)/2),k=Math.max(0,(l-r)/2);return{maxX:p,maxY:k}},Tt=t=>{var c;Q(null),at(null);const n=t.target,r=((c=n.files)==null?void 0:c[0])??null;if(h.current&&(URL.revokeObjectURL(h.current),h.current=null),!r){ot(null),it(null),j==null||j(null),n.value="";return}const e=URL.createObjectURL(r);h.current=e,ot(e),J(null),it(r),tt(T.zoom,T.offset),u.current=T,j==null||j(r),n.value=""},yt=()=>{Q(null),at(null),b.current!=null&&(window.cancelAnimationFrame(b.current),b.current=null),L.current=null,P.current=null,_.current=null,E.current=null,U.current.clear(),K(!1),h.current&&(URL.revokeObjectURL(h.current),h.current=null),ot(null),J(null),it(null),u.current=T,st(T),v==null||v(T),j==null||j(null)},Lt=t=>{t.stopPropagation(),yt()},Nt=t=>{t.stopPropagation(),yt(),H==null||H()},Xt=t=>{if(!(I||!C||t.pointerType==="mouse"&&t.button!==0)){if(t.currentTarget.setPointerCapture(t.pointerId),t.pointerType==="touch"){const n=U.current;if(n.set(t.pointerId,{x:t.clientX,y:t.clientY}),n.size===2){_.current=null,P.current=null,K(!1);const[r,e]=Array.from(n.values());E.current=Math.hypot(r.x-e.x,r.y-e.y);return}}P.current=t.pointerId,_.current={x:t.clientX,y:t.clientY,originX:u.current.offset.x,originY:u.current.offset.y}}},Yt=t=>{if(I||!C)return;if(t.pointerType==="touch"){const c=U.current;if(!c.has(t.pointerId))return;if(c.set(t.pointerId,{x:t.clientX,y:t.clientY}),c.size===2){const[l,p]=Array.from(c.values()),k=l.x-p.x,Dt=l.y-p.y,Mt=Math.hypot(k,Dt),Et={x:(l.x+p.x)/2,y:(l.y+p.y)/2};if(E.current){const Wt=Mt/E.current,Ht=u.current.zoom*Wt,Bt=gt(Et.x,Et.y);tt(Ht,u.current.offset,Bt)}E.current=Mt;return}}if(P.current!==t.pointerId||!_.current||!dt)return;const n=t.clientX-_.current.x,r=t.clientY-_.current.y,e=Math.abs(n)+Math.abs(r);!ft&&e>2&&K(!0),!(e<=1)&&tt(u.current.zoom,{x:_.current.originX+n,y:_.current.originY+r})},zt=t=>{t.pointerType==="touch"&&(U.current.delete(t.pointerId),U.current.size<2&&(E.current=null)),P.current===t.pointerId&&(P.current=null,_.current=null,K(!1))};o.useEffect(()=>{if(!M)return;const t=y(M.zoom,B,A);u.current={zoom:t,offset:lt(M.offset,t)}},[M,m.width,m.height,w==null?void 0:w.width,w==null?void 0:w.height]),o.useEffect(()=>()=>{h.current&&URL.revokeObjectURL(h.current)},[]),o.useEffect(()=>{const t=rt.current;if(!t)return;const n=()=>{const c=t.getBoundingClientRect();St(l=>l.width===c.width&&l.height===c.height?l:{width:c.width,height:c.height}),q&&q(c)};n();const r=()=>n();if(window.addEventListener("scroll",r,!0),typeof ResizeObserver>"u"){const c=()=>n();return window.addEventListener("resize",c),()=>{window.removeEventListener("resize",c),window.removeEventListener("scroll",r,!0)}}const e=new ResizeObserver(()=>n());return e.observe(t),()=>{e.disconnect(),window.removeEventListener("scroll",r,!0)}},[q]),o.useEffect(()=>{if(M)return;const t=u.current.offset,n=lt(t,Y);t.x===n.x&&t.y===n.y||(u.current={zoom:u.current.zoom,offset:n},st(r=>({...r,offset:n})))},[Y,w,m.width,m.height]),o.useEffect(()=>{V||J(null)},[V]),o.useEffect(()=>{g.current=S},[S]),o.useEffect(()=>{var r;if(!S)return;if(!N||!m.width||!m.height||d){(r=g.current)==null||r.call(g,null);return}let t=!0;const n=window.setTimeout(()=>{Jt({file:N,fill:x,transform:{zoom:Y,offset:X.offset},viewport:m}).then(e=>{var c;t&&((c=g.current)==null||c.call(g,e))}).catch(()=>{var e;t&&((e=g.current)==null||e.call(g,null))})},75);return()=>{t=!1,window.clearTimeout(n)}},[d,Y,X.offset,x,N,m]),o.useEffect(()=>()=>{b.current!=null&&(window.cancelAnimationFrame(b.current),b.current=null)},[]);const bt=wt(Y),dt=!I&&C&&(bt.maxX>0||bt.maxY>0),_t=!I&&!mt&&!!R&&!Ut(pt,ut),jt=!!s&&!d&&!!N&&!Ut(pt,ut),kt=!jt&&!I&&!!(N||H),Rt=()=>{var t;return(t=$.current)==null?void 0:t.click()},At=t=>{t.preventDefault(),t.stopPropagation(),Rt()};return a.jsxs("div",{className:ht(f.croppable,nt&&f.standalone),onClick:()=>{I&&Rt()},"data-component":"croppable",children:[a.jsx("input",{accept:"image/*",onChange:Tt,ref:$,type:"file"}),a.jsx("div",{className:f.viewport,ref:rt,onDragStart:t=>t.preventDefault(),onPointerDown:Xt,onPointerMove:Yt,onPointerUp:zt,onPointerCancel:zt,onWheel:It,style:{"--croppable-height":`${z??se}px`,"--croppable-zoom":Y,"--croppable-x":`${X.offset.x}px`,"--croppable-y":`${X.offset.y}px`,...w?{"--croppable-image-width":`${F.width}px`,"--croppable-image-height":`${F.height}px`}:null},children:I?a.jsx("div",{className:f.empty,children:a.jsx(qt.Figure,{children:a.jsx($t.Icon,{name:"Image",size:"large"})})}):a.jsx("div",{className:ht(f.media,dt&&f.draggable,dt&&ft&&f.dragging),children:a.jsx("div",{className:ht(f.inner),children:xt})})}),a.jsxs(Zt.Toolbar,{children:[_t&&a.jsxs("span",{className:f.action,children:[a.jsx(et.Button,{"aria-label":W??"Save image",icon:"FloppyDisk",onClick:()=>{Q({image:s,crop:ut}),R==null||R()},variant:"primary"}),W&&a.jsx("span",{className:f.caption,children:W})]}),!_t&&a.jsxs("span",{className:f.action,children:[a.jsx(et.Button,{"aria-label":O,icon:"UploadSimple",onClick:At,variant:"secondary"}),a.jsx("span",{className:f.caption,children:O})]}),jt&&a.jsxs("span",{className:f.action,children:[a.jsx(et.Button,{"aria-label":i??"Cancel changes",icon:"X",onClick:Lt,variant:"secondary"}),i&&a.jsx("span",{className:f.caption,children:i})]}),kt&&a.jsxs("span",{className:f.action,children:[a.jsx(et.Button,{"aria-label":D??"Delete image",icon:"Trash",intent:"danger",onClick:Nt,variant:"secondary"}),D&&a.jsx("span",{className:f.caption,children:D})]})]})]})};exports.Croppable=ie;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index38.css');const i=require("react/jsx-runtime"),gt=require("classix"),c=require("react"),Vt=require("../toolbar/index.cjs"),ot=require("../button/index.cjs"),Ct=require("../figure/index.cjs"),te=require("../icon/index.cjs"),X=10,Z=.1,ee=.92,y=(s,d,R)=>Math.min(R,Math.max(d,s)),ne=s=>new Promise((d,R)=>{const f=URL.createObjectURL(s),h=new globalThis.Image;h.onload=()=>{URL.revokeObjectURL(f),d(h)},h.onerror=()=>{URL.revokeObjectURL(f),R(new Error("croppable-image-load-failed"))},h.src=f}),re=async({file:s,fill:d,transform:R,viewport:f})=>{const h=await ne(s),z=f.width/h.naturalWidth,Q=f.height/h.naturalHeight,j=Math.max(z,Q),q=h.naturalWidth*j,k=h.naturalHeight*j,M=d==="width"?Math.max(Z,z/j):d==="height"?Math.max(Z,Q/j):Z,P=y(R.zoom,M,X),D=j*P,O=q*P,$=k*P,ct=(f.width-O)/2+R.offset.x,E=(f.height-$)/2+R.offset.y,F=y(-ct/D,0,h.naturalWidth),v=y(-E/D,0,h.naturalHeight),_=y(f.width/D,1,Math.max(1,h.naturalWidth-F)),b=y(f.height/D,1,Math.max(1,h.naturalHeight-v)),T=document.createElement("canvas"),U=T.getContext("2d");if(!U)throw new Error("croppable-image-context-missing");T.width=Math.max(1,Math.round(_)),T.height=Math.max(1,Math.round(b)),U.drawImage(h,F,v,_,b,0,0,T.width,T.height);const g=s.type.startsWith("image/")?s.type:"image/jpeg",x=await new Promise(Y=>{T.toBlob(Y,g,ee)});if(!x)throw new Error("croppable-image-export-failed");return new globalThis.File([x],s.name,{lastModified:Date.now(),type:x.type||g})},oe="_croppable_1tvcl_1",ce="_empty_1tvcl_15",se="_action_1tvcl_28",ie="_caption_1tvcl_36",ae="_media_1tvcl_43",ue="_viewport_1tvcl_54",le="_draggable_1tvcl_66",de="_dragging_1tvcl_70",fe="_inner_1tvcl_74",he="_standalone_1tvcl_90",l={croppable:oe,empty:ce,"drop-target":"_drop-target_1tvcl_23",action:se,caption:ie,media:ae,viewport:ue,draggable:le,dragging:de,inner:fe,standalone:he},pe=192,L={offset:{x:0,y:0},zoom:1},It=(s,d)=>(s==null?void 0:s.file)===d.file&&(s==null?void 0:s.source)===d.source&&(s==null?void 0:s.settings)===d.settings,me=({cancelLabel:s,children:d,deleteLabel:R,fill:f="none",height:h,image:z,isDeleting:Q,isSaving:j,onCroppableChange:q,onDelete:k,onFileChange:M,onImageChange:P,onSave:D,onTransformChange:O,saveLabel:$,standalone:ct,transform:E,uploadLabel:F})=>{const v=c.useRef(null),_=c.useRef(null),b=c.useRef(null),T=c.useRef(null),U=c.useRef(0),g=c.useRef(P),x=c.useRef(null),Y=c.useRef(null),H=c.useRef(null),G=c.useRef(new Map),u=c.useRef(L),st=c.useRef(null),[w,V]=c.useState(null),[it,at]=c.useState(null),[xt,C]=c.useState(!1),[Lt,ut]=c.useState(!1),[St,lt]=c.useState(L),[S,dt]=c.useState(null),[m,At]=c.useState({width:0,height:0}),[wt,ft]=c.useState(null),[J,tt]=c.useState(null),K=(()=>{const t=m.width,e=m.height;if(!t||!e)return{width:0,height:0,minZoom:Z};if(!w)return{width:t,height:e,minZoom:Z};const r=t/w.width,n=e/w.height,o=Math.max(r,n),a=f==="width"?r/o:f==="height"?n/o:0;return{width:w.width*o,height:w.height*o,minZoom:Math.max(Z,a)}})(),B=K.minZoom,A=E??St,N=y(A.zoom,B,X),et=it??z??null,yt=!d&&!!z&&!it&&!S,nt=!yt,_t=d??(et?i.jsx("img",{alt:"",draggable:!1,onLoad:t=>{const e=t.currentTarget;e.naturalWidth&&e.naturalHeight&&V({width:e.naturalWidth,height:e.naturalHeight})},src:et}):null),I=_t==null,ht={file:S,source:it,settings:JSON.stringify([f,N,A.offset.x,A.offset.y,m.width,m.height])};c.useEffect(()=>{!J||!z||z===J.image&&z!==J.crop.source||(ft(J.crop),tt(null))},[z,J]);const pt=(t,e)=>{const{maxX:r,maxY:n}=Rt(e);return{x:y(t.x,-r,r),y:y(t.y,-n,n)}},bt=(t,e)=>{const r=st.current;if(!r)return null;const n=r.getBoundingClientRect(),o=t-n.left-n.width/2,a=e-n.top-n.height/2;return{x:o,y:a}},Nt=(t,e,r,n)=>{const o=y(e,B,X),a=y(r,B,X);if(o===0)return t;const p=a/o;return{x:(1-p)*n.x+p*t.x,y:(1-p)*n.y+p*t.y}},Wt=(t,e,r)=>{const n=u.current.zoom,o=y(t,B,X),a=u.current.offset,p=r?Nt(a,n,o,r):e,W=pt(p,o);u.current={zoom:o,offset:W},E||lt({zoom:o,offset:W}),O==null||O({zoom:o,offset:W})},rt=(t,e,r)=>{Y.current={zoom:t,offset:e,anchor:r??null},_.current==null&&(_.current=window.requestAnimationFrame(()=>{_.current=null;const n=Y.current;Y.current=null;const o=(n==null?void 0:n.zoom)??u.current.zoom,a=(n==null?void 0:n.offset)??u.current.offset,p=(n==null?void 0:n.anchor)??null;Wt(o,a,p)}))},Xt=t=>{if(I||!nt)return;const e=t.ctrlKey?.001:25e-5,r=u.current.zoom*Math.exp(-t.deltaY*e),n=bt(t.clientX,t.clientY);rt(r,u.current.offset,n)},Rt=t=>{const e=m.width,r=m.height;if(!e||!r)return{maxX:0,maxY:0};const n=y(t,B,X),o=K.width*n,a=K.height*n,p=Math.max(0,(o-e)/2),W=Math.max(0,(a-r)/2);return{maxX:p,maxY:W}},zt=t=>{if(tt(null),ft(null),x.current&&(URL.revokeObjectURL(x.current),x.current=null),!t){at(null),dt(null),M==null||M(null);return}const e=URL.createObjectURL(t);x.current=e,at(e),V(null),dt(t),rt(L.zoom,L.offset),u.current=L,M==null||M(t)},kt=t=>{var e;zt(((e=t.target.files)==null?void 0:e[0])??null),t.target.value=""},Mt=t=>!j&&(Array.from(t.items??[]).some(e=>e.kind==="file"&&e.type.startsWith("image/"))||Array.from(t.files??[]).some(e=>e.type.startsWith("image/"))),Yt=t=>{if(t.preventDefault(),t.stopPropagation(),U.current=0,ut(!1),j)return;const e=Array.from(t.dataTransfer.files).find(r=>r.type.startsWith("image/"));e&&zt(e)},jt=()=>{tt(null),ft(null),_.current!=null&&(window.cancelAnimationFrame(_.current),_.current=null),Y.current=null,v.current=null,b.current=null,H.current=null,G.current.clear(),C(!1),x.current&&(URL.revokeObjectURL(x.current),x.current=null),at(null),V(null),dt(null),u.current=L,lt(L),O==null||O(L),M==null||M(null)},Ht=t=>{t.stopPropagation(),jt()},Bt=t=>{t.stopPropagation(),jt(),k==null||k()},Zt=t=>{if(!(I||!nt||t.pointerType==="mouse"&&t.button!==0)){if(t.currentTarget.setPointerCapture(t.pointerId),t.pointerType==="touch"){const e=G.current;if(e.set(t.pointerId,{x:t.clientX,y:t.clientY}),e.size===2){b.current=null,v.current=null,C(!1);const[r,n]=Array.from(e.values());H.current=Math.hypot(r.x-n.x,r.y-n.y);return}}v.current=t.pointerId,b.current={x:t.clientX,y:t.clientY,originX:u.current.offset.x,originY:u.current.offset.y}}},qt=t=>{if(I||!nt)return;if(t.pointerType==="touch"){const o=G.current;if(!o.has(t.pointerId))return;if(o.set(t.pointerId,{x:t.clientX,y:t.clientY}),o.size===2){const[a,p]=Array.from(o.values()),W=a.x-p.x,Gt=a.y-p.y,Ot=Math.hypot(W,Gt),Ut={x:(a.x+p.x)/2,y:(a.y+p.y)/2};if(H.current){const Jt=Ot/H.current,Kt=u.current.zoom*Jt,Qt=bt(Ut.x,Ut.y);rt(Kt,u.current.offset,Qt)}H.current=Ot;return}}if(v.current!==t.pointerId||!b.current||!mt)return;const e=t.clientX-b.current.x,r=t.clientY-b.current.y,n=Math.abs(e)+Math.abs(r);!xt&&n>2&&C(!0),!(n<=1)&&rt(u.current.zoom,{x:b.current.originX+e,y:b.current.originY+r})},Dt=t=>{t.pointerType==="touch"&&(G.current.delete(t.pointerId),G.current.size<2&&(H.current=null)),v.current===t.pointerId&&(v.current=null,b.current=null,C(!1))};c.useEffect(()=>{if(!E)return;const t=y(E.zoom,B,X);u.current={zoom:t,offset:pt(E.offset,t)}},[E,m.width,m.height,w==null?void 0:w.width,w==null?void 0:w.height]),c.useEffect(()=>()=>{x.current&&URL.revokeObjectURL(x.current)},[]),c.useEffect(()=>{const t=st.current;if(!t)return;const e=()=>{const o=t.getBoundingClientRect();At(a=>a.width===o.width&&a.height===o.height?a:{width:o.width,height:o.height}),q&&q(o)};e();const r=()=>e();if(window.addEventListener("scroll",r,!0),typeof ResizeObserver>"u"){const o=()=>e();return window.addEventListener("resize",o),()=>{window.removeEventListener("resize",o),window.removeEventListener("scroll",r,!0)}}const n=new ResizeObserver(()=>e());return n.observe(t),()=>{n.disconnect(),window.removeEventListener("scroll",r,!0)}},[q]),c.useEffect(()=>{if(E)return;const t=u.current.offset,e=pt(t,N);t.x===e.x&&t.y===e.y||(u.current={zoom:u.current.zoom,offset:e},lt(r=>({...r,offset:e})))},[N,w,m.width,m.height]),c.useEffect(()=>{et||V(null)},[et]),c.useEffect(()=>{g.current=P},[P]),c.useEffect(()=>{var r;if(!P)return;if(!S||!m.width||!m.height||d){(r=g.current)==null||r.call(g,null);return}let t=!0;const e=window.setTimeout(()=>{re({file:S,fill:f,transform:{zoom:N,offset:A.offset},viewport:m}).then(n=>{var o;t&&((o=g.current)==null||o.call(g,n))}).catch(()=>{var n;t&&((n=g.current)==null||n.call(g,null))})},75);return()=>{t=!1,window.clearTimeout(e)}},[d,N,A.offset,f,S,m]),c.useEffect(()=>()=>{_.current!=null&&(window.cancelAnimationFrame(_.current),_.current=null)},[]);const Et=Rt(N),mt=!I&&nt&&(Et.maxX>0||Et.maxY>0),vt=!I&&!yt&&!!D&&!It(wt,ht),Tt=!!z&&!d&&!!S&&!It(wt,ht),$t=!Tt&&!I&&!!(S||k),Pt=()=>{var t;return(t=T.current)==null?void 0:t.click()},Ft=t=>{t.preventDefault(),t.stopPropagation(),Pt()};return i.jsxs("div",{className:gt(l.croppable,ct&&l.standalone,Lt&&l["drop-target"]),onDragEnter:t=>{t.preventDefault(),t.stopPropagation(),U.current+=1,ut(Mt(t.dataTransfer))},onDragOver:t=>{t.preventDefault(),t.stopPropagation(),t.dataTransfer.dropEffect=Mt(t.dataTransfer)?"copy":"none"},onDragLeave:t=>{t.preventDefault(),t.stopPropagation(),U.current=Math.max(0,U.current-1),U.current||ut(!1)},onDrop:Yt,onClick:()=>{I&&Pt()},"data-component":"croppable",children:[i.jsx("input",{accept:"image/*",onChange:kt,ref:T,type:"file"}),i.jsx("div",{className:l.viewport,ref:st,onDragStart:t=>t.preventDefault(),onPointerDown:Zt,onPointerMove:qt,onPointerUp:Dt,onPointerCancel:Dt,onWheel:Xt,style:{"--croppable-height":`${h??pe}px`,"--croppable-zoom":N,"--croppable-x":`${A.offset.x}px`,"--croppable-y":`${A.offset.y}px`,...w?{"--croppable-image-width":`${K.width}px`,"--croppable-image-height":`${K.height}px`}:null},children:I?i.jsx("div",{className:l.empty,children:i.jsx(Ct.Figure,{children:i.jsx(te.Icon,{name:"Image",size:"large"})})}):i.jsx("div",{className:gt(l.media,mt&&l.draggable,mt&&xt&&l.dragging),children:i.jsx("div",{className:gt(l.inner),children:_t})})}),i.jsxs(Vt.Toolbar,{children:[vt&&i.jsxs("span",{className:l.action,children:[i.jsx(ot.Button,{isLoading:j,"aria-label":$??"Save image",icon:"FloppyDisk",onClick:()=>{tt({image:z,crop:ht}),D==null||D()},variant:"primary"}),$&&i.jsx("span",{className:l.caption,children:$})]}),!vt&&i.jsxs("span",{className:l.action,children:[i.jsx(ot.Button,{"aria-label":F,icon:"UploadSimple",onClick:Ft,variant:"secondary"}),i.jsx("span",{className:l.caption,children:F})]}),Tt&&i.jsxs("span",{className:l.action,children:[i.jsx(ot.Button,{"aria-label":s??"Cancel changes",icon:"X",onClick:Ht,variant:"secondary"}),s&&i.jsx("span",{className:l.caption,children:s})]}),$t&&i.jsxs("span",{className:l.action,children:[i.jsx(ot.Button,{"aria-label":R??"Delete image",icon:"Trash",intent:"danger",isLoading:Q,onClick:Bt,variant:"secondary"}),R&&i.jsx("span",{className:l.caption,children:R})]})]})]})};exports.Croppable=me;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,359 +1,372 @@
|
|
|
1
|
-
import { jsxs as q, jsx as
|
|
2
|
-
import
|
|
3
|
-
import { useRef as
|
|
4
|
-
import { Toolbar as
|
|
5
|
-
import { Button as
|
|
6
|
-
import { Figure as
|
|
7
|
-
import { Icon as
|
|
8
|
-
import '../../assets/index38.css';const
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
URL.revokeObjectURL(
|
|
12
|
-
},
|
|
13
|
-
URL.revokeObjectURL(
|
|
14
|
-
},
|
|
15
|
-
}),
|
|
16
|
-
file:
|
|
1
|
+
import { jsxs as q, jsx as p } from "react/jsx-runtime";
|
|
2
|
+
import xt from "classix";
|
|
3
|
+
import { useRef as _, useState as O, useEffect as I } from "react";
|
|
4
|
+
import { Toolbar as rr } from "../toolbar/index.js";
|
|
5
|
+
import { Button as it } from "../button/index.js";
|
|
6
|
+
import { Figure as nr } from "../figure/index.js";
|
|
7
|
+
import { Icon as er } from "../icon/index.js";
|
|
8
|
+
import '../../assets/index38.css';const j = 10, F = 0.1, or = 0.92, y = (c, l, z) => Math.min(z, Math.max(l, c)), cr = (c) => new Promise((l, z) => {
|
|
9
|
+
const u = URL.createObjectURL(c), d = new globalThis.Image();
|
|
10
|
+
d.onload = () => {
|
|
11
|
+
URL.revokeObjectURL(u), l(d);
|
|
12
|
+
}, d.onerror = () => {
|
|
13
|
+
URL.revokeObjectURL(u), z(new Error("croppable-image-load-failed"));
|
|
14
|
+
}, d.src = u;
|
|
15
|
+
}), sr = async ({
|
|
16
|
+
file: c,
|
|
17
17
|
fill: l,
|
|
18
|
-
transform:
|
|
19
|
-
viewport:
|
|
18
|
+
transform: z,
|
|
19
|
+
viewport: u
|
|
20
20
|
}) => {
|
|
21
|
-
const
|
|
22
|
-
if (!
|
|
21
|
+
const d = await cr(c), M = u.width / d.naturalWidth, tt = u.height / d.naturalHeight, D = Math.max(M, tt), G = d.naturalWidth * D, Z = d.naturalHeight * D, R = l === "width" ? Math.max(F, M / D) : l === "height" ? Math.max(F, tt / D) : F, L = y(z.zoom, R, j), v = D * L, E = G * L, J = Z * L, at = (u.width - E) / 2 + z.offset.x, T = (u.height - J) / 2 + z.offset.y, K = y(-at / v, 0, d.naturalWidth), P = y(-T / v, 0, d.naturalHeight), x = y(u.width / v, 1, Math.max(1, d.naturalWidth - K)), b = y(u.height / v, 1, Math.max(1, d.naturalHeight - P)), U = document.createElement("canvas"), A = U.getContext("2d");
|
|
22
|
+
if (!A)
|
|
23
23
|
throw new Error("croppable-image-context-missing");
|
|
24
|
-
|
|
25
|
-
const
|
|
26
|
-
|
|
24
|
+
U.width = Math.max(1, Math.round(x)), U.height = Math.max(1, Math.round(b)), A.drawImage(d, K, P, x, b, 0, 0, U.width, U.height);
|
|
25
|
+
const f = c.type.startsWith("image/") ? c.type : "image/jpeg", g = await new Promise((S) => {
|
|
26
|
+
U.toBlob(S, f, or);
|
|
27
27
|
});
|
|
28
|
-
if (!
|
|
28
|
+
if (!g)
|
|
29
29
|
throw new Error("croppable-image-export-failed");
|
|
30
|
-
return new globalThis.File([
|
|
30
|
+
return new globalThis.File([g], c.name, {
|
|
31
31
|
lastModified: Date.now(),
|
|
32
|
-
type:
|
|
32
|
+
type: g.type || f
|
|
33
33
|
});
|
|
34
|
-
},
|
|
35
|
-
croppable:
|
|
36
|
-
empty:
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
34
|
+
}, ir = "_croppable_1tvcl_1", ar = "_empty_1tvcl_15", lr = "_action_1tvcl_28", ur = "_caption_1tvcl_36", dr = "_media_1tvcl_43", pr = "_viewport_1tvcl_54", hr = "_draggable_1tvcl_66", mr = "_dragging_1tvcl_70", fr = "_inner_1tvcl_74", gr = "_standalone_1tvcl_90", a = {
|
|
35
|
+
croppable: ir,
|
|
36
|
+
empty: ar,
|
|
37
|
+
"drop-target": "_drop-target_1tvcl_23",
|
|
38
|
+
action: lr,
|
|
39
|
+
caption: ur,
|
|
40
|
+
media: dr,
|
|
41
|
+
viewport: pr,
|
|
42
|
+
draggable: hr,
|
|
43
|
+
dragging: mr,
|
|
44
|
+
inner: fr,
|
|
45
|
+
standalone: gr
|
|
46
|
+
}, wr = 192, W = {
|
|
46
47
|
offset: {
|
|
47
48
|
x: 0,
|
|
48
49
|
y: 0
|
|
49
50
|
},
|
|
50
51
|
zoom: 1
|
|
51
|
-
},
|
|
52
|
-
cancelLabel:
|
|
52
|
+
}, Wt = (c, l) => (c == null ? void 0 : c.file) === l.file && (c == null ? void 0 : c.source) === l.source && (c == null ? void 0 : c.settings) === l.settings, vr = ({
|
|
53
|
+
cancelLabel: c,
|
|
53
54
|
children: l,
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
onCroppableChange:
|
|
61
|
-
onDelete:
|
|
62
|
-
onFileChange:
|
|
63
|
-
onImageChange:
|
|
64
|
-
onSave:
|
|
55
|
+
deleteLabel: z,
|
|
56
|
+
fill: u = "none",
|
|
57
|
+
height: d,
|
|
58
|
+
image: M,
|
|
59
|
+
isDeleting: tt,
|
|
60
|
+
isSaving: D,
|
|
61
|
+
onCroppableChange: G,
|
|
62
|
+
onDelete: Z,
|
|
63
|
+
onFileChange: R,
|
|
64
|
+
onImageChange: L,
|
|
65
|
+
onSave: v,
|
|
65
66
|
onTransformChange: E,
|
|
66
|
-
|
|
67
|
-
standalone:
|
|
67
|
+
saveLabel: J,
|
|
68
|
+
standalone: at,
|
|
69
|
+
transform: T,
|
|
70
|
+
uploadLabel: K
|
|
68
71
|
}) => {
|
|
69
|
-
const
|
|
72
|
+
const P = _(null), x = _(null), b = _(null), U = _(null), A = _(0), f = _(L), g = _(null), S = _(null), B = _(null), Q = _(/* @__PURE__ */ new Map()), i = _(W), lt = _(null), [w, rt] = O(null), [ut, dt] = O(null), [bt, nt] = O(!1), [Xt, pt] = O(!1), [kt, ht] = O(W), [X, mt] = O(null), [m, Yt] = O({
|
|
70
73
|
width: 0,
|
|
71
74
|
height: 0
|
|
72
|
-
}), [
|
|
73
|
-
const t = m.width,
|
|
74
|
-
if (!t || !
|
|
75
|
+
}), [_t, ft] = O(null), [V, et] = O(null), C = (() => {
|
|
76
|
+
const t = m.width, r = m.height;
|
|
77
|
+
if (!t || !r) return {
|
|
75
78
|
width: 0,
|
|
76
79
|
height: 0,
|
|
77
|
-
minZoom:
|
|
80
|
+
minZoom: F
|
|
78
81
|
};
|
|
79
|
-
if (!
|
|
82
|
+
if (!w) return {
|
|
80
83
|
width: t,
|
|
81
|
-
height:
|
|
82
|
-
minZoom:
|
|
84
|
+
height: r,
|
|
85
|
+
minZoom: F
|
|
83
86
|
};
|
|
84
|
-
const
|
|
87
|
+
const e = t / w.width, n = r / w.height, o = Math.max(e, n), s = u === "width" ? e / o : u === "height" ? n / o : 0;
|
|
85
88
|
return {
|
|
86
|
-
width:
|
|
87
|
-
height:
|
|
88
|
-
minZoom: Math.max(
|
|
89
|
+
width: w.width * o,
|
|
90
|
+
height: w.height * o,
|
|
91
|
+
minZoom: Math.max(F, s)
|
|
89
92
|
};
|
|
90
|
-
})(), $ =
|
|
91
|
-
const
|
|
92
|
-
|
|
93
|
-
width:
|
|
94
|
-
height:
|
|
93
|
+
})(), $ = C.minZoom, k = T ?? kt, Y = y(k.zoom, $, j), ot = ut ?? M ?? null, zt = !l && !!M && !ut && !X, ct = !zt, Mt = l ?? (ot ? /* @__PURE__ */ p("img", { alt: "", draggable: !1, onLoad: (t) => {
|
|
94
|
+
const r = t.currentTarget;
|
|
95
|
+
r.naturalWidth && r.naturalHeight && rt({
|
|
96
|
+
width: r.naturalWidth,
|
|
97
|
+
height: r.naturalHeight
|
|
95
98
|
});
|
|
96
|
-
}, src:
|
|
97
|
-
file:
|
|
98
|
-
source:
|
|
99
|
-
settings: JSON.stringify([
|
|
99
|
+
}, src: ot }) : null), N = Mt == null, gt = {
|
|
100
|
+
file: X,
|
|
101
|
+
source: ut,
|
|
102
|
+
settings: JSON.stringify([u, Y, k.offset.x, k.offset.y, m.width, m.height])
|
|
100
103
|
};
|
|
101
|
-
|
|
102
|
-
!
|
|
103
|
-
}, [
|
|
104
|
-
const
|
|
104
|
+
I(() => {
|
|
105
|
+
!V || !M || M === V.image && M !== V.crop.source || (ft(V.crop), et(null));
|
|
106
|
+
}, [M, V]);
|
|
107
|
+
const wt = (t, r) => {
|
|
105
108
|
const {
|
|
106
|
-
maxX:
|
|
109
|
+
maxX: e,
|
|
107
110
|
maxY: n
|
|
108
|
-
} =
|
|
111
|
+
} = Dt(r);
|
|
109
112
|
return {
|
|
110
|
-
x:
|
|
111
|
-
y:
|
|
113
|
+
x: y(t.x, -e, e),
|
|
114
|
+
y: y(t.y, -n, n)
|
|
112
115
|
};
|
|
113
|
-
},
|
|
114
|
-
const
|
|
115
|
-
if (!
|
|
116
|
-
const n =
|
|
116
|
+
}, Rt = (t, r) => {
|
|
117
|
+
const e = lt.current;
|
|
118
|
+
if (!e) return null;
|
|
119
|
+
const n = e.getBoundingClientRect(), o = t - n.left - n.width / 2, s = r - n.top - n.height / 2;
|
|
117
120
|
return {
|
|
118
121
|
x: o,
|
|
119
|
-
y:
|
|
122
|
+
y: s
|
|
120
123
|
};
|
|
121
|
-
},
|
|
122
|
-
const o =
|
|
124
|
+
}, Ht = (t, r, e, n) => {
|
|
125
|
+
const o = y(r, $, j), s = y(e, $, j);
|
|
123
126
|
if (o === 0) return t;
|
|
124
|
-
const
|
|
127
|
+
const h = s / o;
|
|
125
128
|
return {
|
|
126
|
-
x: (1 -
|
|
127
|
-
y: (1 -
|
|
129
|
+
x: (1 - h) * n.x + h * t.x,
|
|
130
|
+
y: (1 - h) * n.y + h * t.y
|
|
128
131
|
};
|
|
129
|
-
},
|
|
130
|
-
const n = i.current.zoom, o =
|
|
132
|
+
}, jt = (t, r, e) => {
|
|
133
|
+
const n = i.current.zoom, o = y(t, $, j), s = i.current.offset, h = e ? Ht(s, n, o, e) : r, H = wt(h, o);
|
|
131
134
|
i.current = {
|
|
132
135
|
zoom: o,
|
|
133
|
-
offset:
|
|
134
|
-
},
|
|
136
|
+
offset: H
|
|
137
|
+
}, T || ht({
|
|
135
138
|
zoom: o,
|
|
136
|
-
offset:
|
|
139
|
+
offset: H
|
|
137
140
|
}), E == null || E({
|
|
138
141
|
zoom: o,
|
|
139
|
-
offset:
|
|
142
|
+
offset: H
|
|
140
143
|
});
|
|
141
|
-
},
|
|
142
|
-
|
|
144
|
+
}, st = (t, r, e) => {
|
|
145
|
+
S.current = {
|
|
143
146
|
zoom: t,
|
|
144
|
-
offset:
|
|
145
|
-
anchor:
|
|
146
|
-
},
|
|
147
|
-
|
|
148
|
-
const n =
|
|
149
|
-
|
|
150
|
-
const o = (n == null ? void 0 : n.zoom) ?? i.current.zoom,
|
|
151
|
-
|
|
147
|
+
offset: r,
|
|
148
|
+
anchor: e ?? null
|
|
149
|
+
}, x.current == null && (x.current = window.requestAnimationFrame(() => {
|
|
150
|
+
x.current = null;
|
|
151
|
+
const n = S.current;
|
|
152
|
+
S.current = null;
|
|
153
|
+
const o = (n == null ? void 0 : n.zoom) ?? i.current.zoom, s = (n == null ? void 0 : n.offset) ?? i.current.offset, h = (n == null ? void 0 : n.anchor) ?? null;
|
|
154
|
+
jt(o, s, h);
|
|
152
155
|
}));
|
|
153
|
-
},
|
|
154
|
-
if (N || !
|
|
155
|
-
const
|
|
156
|
-
|
|
157
|
-
},
|
|
158
|
-
const
|
|
159
|
-
if (!
|
|
156
|
+
}, Zt = (t) => {
|
|
157
|
+
if (N || !ct) return;
|
|
158
|
+
const r = t.ctrlKey ? 1e-3 : 25e-5, e = i.current.zoom * Math.exp(-t.deltaY * r), n = Rt(t.clientX, t.clientY);
|
|
159
|
+
st(e, i.current.offset, n);
|
|
160
|
+
}, Dt = (t) => {
|
|
161
|
+
const r = m.width, e = m.height;
|
|
162
|
+
if (!r || !e) return {
|
|
160
163
|
maxX: 0,
|
|
161
164
|
maxY: 0
|
|
162
165
|
};
|
|
163
|
-
const n =
|
|
166
|
+
const n = y(t, $, j), o = C.width * n, s = C.height * n, h = Math.max(0, (o - r) / 2), H = Math.max(0, (s - e) / 2);
|
|
164
167
|
return {
|
|
165
|
-
maxX:
|
|
166
|
-
maxY:
|
|
168
|
+
maxX: h,
|
|
169
|
+
maxY: H
|
|
167
170
|
};
|
|
168
|
-
},
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
const e = t.target, r = ((o = e.files) == null ? void 0 : o[0]) ?? null;
|
|
172
|
-
if (u.current && (URL.revokeObjectURL(u.current), u.current = null), !r) {
|
|
173
|
-
at(null), ut(null), _ == null || _(null), e.value = "";
|
|
171
|
+
}, vt = (t) => {
|
|
172
|
+
if (et(null), ft(null), g.current && (URL.revokeObjectURL(g.current), g.current = null), !t) {
|
|
173
|
+
dt(null), mt(null), R == null || R(null);
|
|
174
174
|
return;
|
|
175
175
|
}
|
|
176
|
-
const
|
|
177
|
-
|
|
178
|
-
},
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
t.
|
|
184
|
-
|
|
185
|
-
|
|
176
|
+
const r = URL.createObjectURL(t);
|
|
177
|
+
g.current = r, dt(r), rt(null), mt(t), st(W.zoom, W.offset), i.current = W, R == null || R(t);
|
|
178
|
+
}, St = (t) => {
|
|
179
|
+
var r;
|
|
180
|
+
vt(((r = t.target.files) == null ? void 0 : r[0]) ?? null), t.target.value = "";
|
|
181
|
+
}, Tt = (t) => !D && (Array.from(t.items ?? []).some((r) => r.kind === "file" && r.type.startsWith("image/")) || Array.from(t.files ?? []).some((r) => r.type.startsWith("image/"))), Bt = (t) => {
|
|
182
|
+
if (t.preventDefault(), t.stopPropagation(), A.current = 0, pt(!1), D) return;
|
|
183
|
+
const r = Array.from(t.dataTransfer.files).find((e) => e.type.startsWith("image/"));
|
|
184
|
+
r && vt(r);
|
|
185
|
+
}, Pt = () => {
|
|
186
|
+
et(null), ft(null), x.current != null && (window.cancelAnimationFrame(x.current), x.current = null), S.current = null, P.current = null, b.current = null, B.current = null, Q.current.clear(), nt(!1), g.current && (URL.revokeObjectURL(g.current), g.current = null), dt(null), rt(null), mt(null), i.current = W, ht(W), E == null || E(W), R == null || R(null);
|
|
187
|
+
}, $t = (t) => {
|
|
188
|
+
t.stopPropagation(), Pt();
|
|
189
|
+
}, qt = (t) => {
|
|
190
|
+
t.stopPropagation(), Pt(), Z == null || Z();
|
|
191
|
+
}, Ft = (t) => {
|
|
192
|
+
if (!(N || !ct || t.pointerType === "mouse" && t.button !== 0)) {
|
|
186
193
|
if (t.currentTarget.setPointerCapture(t.pointerId), t.pointerType === "touch") {
|
|
187
|
-
const
|
|
188
|
-
if (
|
|
194
|
+
const r = Q.current;
|
|
195
|
+
if (r.set(t.pointerId, {
|
|
189
196
|
x: t.clientX,
|
|
190
197
|
y: t.clientY
|
|
191
|
-
}),
|
|
192
|
-
b.current = null,
|
|
193
|
-
const [
|
|
194
|
-
|
|
198
|
+
}), r.size === 2) {
|
|
199
|
+
b.current = null, P.current = null, nt(!1);
|
|
200
|
+
const [e, n] = Array.from(r.values());
|
|
201
|
+
B.current = Math.hypot(e.x - n.x, e.y - n.y);
|
|
195
202
|
return;
|
|
196
203
|
}
|
|
197
204
|
}
|
|
198
|
-
|
|
205
|
+
P.current = t.pointerId, b.current = {
|
|
199
206
|
x: t.clientX,
|
|
200
207
|
y: t.clientY,
|
|
201
208
|
originX: i.current.offset.x,
|
|
202
209
|
originY: i.current.offset.y
|
|
203
210
|
};
|
|
204
211
|
}
|
|
205
|
-
},
|
|
206
|
-
if (N || !
|
|
212
|
+
}, Gt = (t) => {
|
|
213
|
+
if (N || !ct) return;
|
|
207
214
|
if (t.pointerType === "touch") {
|
|
208
|
-
const o =
|
|
215
|
+
const o = Q.current;
|
|
209
216
|
if (!o.has(t.pointerId)) return;
|
|
210
217
|
if (o.set(t.pointerId, {
|
|
211
218
|
x: t.clientX,
|
|
212
219
|
y: t.clientY
|
|
213
220
|
}), o.size === 2) {
|
|
214
|
-
const [
|
|
215
|
-
x: (
|
|
216
|
-
y: (
|
|
221
|
+
const [s, h] = Array.from(o.values()), H = s.x - h.x, Qt = s.y - h.y, At = Math.hypot(H, Qt), Nt = {
|
|
222
|
+
x: (s.x + h.x) / 2,
|
|
223
|
+
y: (s.y + h.y) / 2
|
|
217
224
|
};
|
|
218
|
-
if (
|
|
219
|
-
const
|
|
220
|
-
|
|
225
|
+
if (B.current) {
|
|
226
|
+
const Vt = At / B.current, Ct = i.current.zoom * Vt, tr = Rt(Nt.x, Nt.y);
|
|
227
|
+
st(Ct, i.current.offset, tr);
|
|
221
228
|
}
|
|
222
|
-
|
|
229
|
+
B.current = At;
|
|
223
230
|
return;
|
|
224
231
|
}
|
|
225
232
|
}
|
|
226
|
-
if (
|
|
227
|
-
const
|
|
228
|
-
!
|
|
229
|
-
x: b.current.originX +
|
|
230
|
-
y: b.current.originY +
|
|
233
|
+
if (P.current !== t.pointerId || !b.current || !yt) return;
|
|
234
|
+
const r = t.clientX - b.current.x, e = t.clientY - b.current.y, n = Math.abs(r) + Math.abs(e);
|
|
235
|
+
!bt && n > 2 && nt(!0), !(n <= 1) && st(i.current.zoom, {
|
|
236
|
+
x: b.current.originX + r,
|
|
237
|
+
y: b.current.originY + e
|
|
231
238
|
});
|
|
232
|
-
},
|
|
233
|
-
t.pointerType === "touch" && (
|
|
239
|
+
}, Ut = (t) => {
|
|
240
|
+
t.pointerType === "touch" && (Q.current.delete(t.pointerId), Q.current.size < 2 && (B.current = null)), P.current === t.pointerId && (P.current = null, b.current = null, nt(!1));
|
|
234
241
|
};
|
|
235
|
-
|
|
236
|
-
if (!
|
|
237
|
-
const t =
|
|
242
|
+
I(() => {
|
|
243
|
+
if (!T) return;
|
|
244
|
+
const t = y(T.zoom, $, j);
|
|
238
245
|
i.current = {
|
|
239
246
|
zoom: t,
|
|
240
|
-
offset:
|
|
247
|
+
offset: wt(T.offset, t)
|
|
241
248
|
};
|
|
242
|
-
}, [
|
|
243
|
-
|
|
244
|
-
}, []),
|
|
245
|
-
const t =
|
|
249
|
+
}, [T, m.width, m.height, w == null ? void 0 : w.width, w == null ? void 0 : w.height]), I(() => () => {
|
|
250
|
+
g.current && URL.revokeObjectURL(g.current);
|
|
251
|
+
}, []), I(() => {
|
|
252
|
+
const t = lt.current;
|
|
246
253
|
if (!t) return;
|
|
247
|
-
const
|
|
254
|
+
const r = () => {
|
|
248
255
|
const o = t.getBoundingClientRect();
|
|
249
|
-
|
|
256
|
+
Yt((s) => s.width === o.width && s.height === o.height ? s : {
|
|
250
257
|
width: o.width,
|
|
251
258
|
height: o.height
|
|
252
|
-
}),
|
|
259
|
+
}), G && G(o);
|
|
253
260
|
};
|
|
254
|
-
|
|
255
|
-
const
|
|
256
|
-
if (window.addEventListener("scroll",
|
|
257
|
-
const o = () =>
|
|
261
|
+
r();
|
|
262
|
+
const e = () => r();
|
|
263
|
+
if (window.addEventListener("scroll", e, !0), typeof ResizeObserver > "u") {
|
|
264
|
+
const o = () => r();
|
|
258
265
|
return window.addEventListener("resize", o), () => {
|
|
259
|
-
window.removeEventListener("resize", o), window.removeEventListener("scroll",
|
|
266
|
+
window.removeEventListener("resize", o), window.removeEventListener("scroll", e, !0);
|
|
260
267
|
};
|
|
261
268
|
}
|
|
262
|
-
const n = new ResizeObserver(() =>
|
|
269
|
+
const n = new ResizeObserver(() => r());
|
|
263
270
|
return n.observe(t), () => {
|
|
264
|
-
n.disconnect(), window.removeEventListener("scroll",
|
|
271
|
+
n.disconnect(), window.removeEventListener("scroll", e, !0);
|
|
265
272
|
};
|
|
266
|
-
}, [
|
|
267
|
-
if (
|
|
268
|
-
const t = i.current.offset,
|
|
269
|
-
t.x ===
|
|
273
|
+
}, [G]), I(() => {
|
|
274
|
+
if (T) return;
|
|
275
|
+
const t = i.current.offset, r = wt(t, Y);
|
|
276
|
+
t.x === r.x && t.y === r.y || (i.current = {
|
|
270
277
|
zoom: i.current.zoom,
|
|
271
|
-
offset:
|
|
272
|
-
},
|
|
273
|
-
...
|
|
274
|
-
offset:
|
|
278
|
+
offset: r
|
|
279
|
+
}, ht((e) => ({
|
|
280
|
+
...e,
|
|
281
|
+
offset: r
|
|
275
282
|
})));
|
|
276
|
-
}, [
|
|
277
|
-
|
|
278
|
-
}, [
|
|
279
|
-
|
|
280
|
-
}, [
|
|
281
|
-
var
|
|
282
|
-
if (!
|
|
283
|
-
if (!
|
|
284
|
-
(
|
|
283
|
+
}, [Y, w, m.width, m.height]), I(() => {
|
|
284
|
+
ot || rt(null);
|
|
285
|
+
}, [ot]), I(() => {
|
|
286
|
+
f.current = L;
|
|
287
|
+
}, [L]), I(() => {
|
|
288
|
+
var e;
|
|
289
|
+
if (!L) return;
|
|
290
|
+
if (!X || !m.width || !m.height || l) {
|
|
291
|
+
(e = f.current) == null || e.call(f, null);
|
|
285
292
|
return;
|
|
286
293
|
}
|
|
287
294
|
let t = !0;
|
|
288
|
-
const
|
|
289
|
-
|
|
290
|
-
file:
|
|
291
|
-
fill:
|
|
295
|
+
const r = window.setTimeout(() => {
|
|
296
|
+
sr({
|
|
297
|
+
file: X,
|
|
298
|
+
fill: u,
|
|
292
299
|
transform: {
|
|
293
|
-
zoom:
|
|
294
|
-
offset:
|
|
300
|
+
zoom: Y,
|
|
301
|
+
offset: k.offset
|
|
295
302
|
},
|
|
296
303
|
viewport: m
|
|
297
304
|
}).then((n) => {
|
|
298
305
|
var o;
|
|
299
|
-
t && ((o =
|
|
306
|
+
t && ((o = f.current) == null || o.call(f, n));
|
|
300
307
|
}).catch(() => {
|
|
301
308
|
var n;
|
|
302
|
-
t && ((n =
|
|
309
|
+
t && ((n = f.current) == null || n.call(f, null));
|
|
303
310
|
});
|
|
304
311
|
}, 75);
|
|
305
312
|
return () => {
|
|
306
|
-
t = !1, window.clearTimeout(
|
|
313
|
+
t = !1, window.clearTimeout(r);
|
|
307
314
|
};
|
|
308
|
-
}, [l,
|
|
309
|
-
|
|
315
|
+
}, [l, Y, k.offset, u, X, m]), I(() => () => {
|
|
316
|
+
x.current != null && (window.cancelAnimationFrame(x.current), x.current = null);
|
|
310
317
|
}, []);
|
|
311
|
-
const
|
|
318
|
+
const Ot = Dt(Y), yt = !N && ct && (Ot.maxX > 0 || Ot.maxY > 0), It = !N && !zt && !!v && !Wt(_t, gt), Lt = !!M && !l && !!X && !Wt(_t, gt), Jt = !Lt && !N && !!(X || Z), Et = () => {
|
|
312
319
|
var t;
|
|
313
|
-
return (t =
|
|
314
|
-
},
|
|
315
|
-
t.preventDefault(), t.stopPropagation(),
|
|
320
|
+
return (t = U.current) == null ? void 0 : t.click();
|
|
321
|
+
}, Kt = (t) => {
|
|
322
|
+
t.preventDefault(), t.stopPropagation(), Et();
|
|
316
323
|
};
|
|
317
|
-
return /* @__PURE__ */ q("div", { className:
|
|
318
|
-
|
|
324
|
+
return /* @__PURE__ */ q("div", { className: xt(a.croppable, at && a.standalone, Xt && a["drop-target"]), onDragEnter: (t) => {
|
|
325
|
+
t.preventDefault(), t.stopPropagation(), A.current += 1, pt(Tt(t.dataTransfer));
|
|
326
|
+
}, onDragOver: (t) => {
|
|
327
|
+
t.preventDefault(), t.stopPropagation(), t.dataTransfer.dropEffect = Tt(t.dataTransfer) ? "copy" : "none";
|
|
328
|
+
}, onDragLeave: (t) => {
|
|
329
|
+
t.preventDefault(), t.stopPropagation(), A.current = Math.max(0, A.current - 1), A.current || pt(!1);
|
|
330
|
+
}, onDrop: Bt, onClick: () => {
|
|
331
|
+
N && Et();
|
|
319
332
|
}, "data-component": "croppable", children: [
|
|
320
|
-
/* @__PURE__ */
|
|
321
|
-
/* @__PURE__ */
|
|
322
|
-
"--croppable-height": `${
|
|
323
|
-
"--croppable-zoom":
|
|
324
|
-
"--croppable-x": `${
|
|
325
|
-
"--croppable-y": `${
|
|
326
|
-
...
|
|
327
|
-
"--croppable-image-width": `${
|
|
328
|
-
"--croppable-image-height": `${
|
|
333
|
+
/* @__PURE__ */ p("input", { accept: "image/*", onChange: St, ref: U, type: "file" }),
|
|
334
|
+
/* @__PURE__ */ p("div", { className: a.viewport, ref: lt, onDragStart: (t) => t.preventDefault(), onPointerDown: Ft, onPointerMove: Gt, onPointerUp: Ut, onPointerCancel: Ut, onWheel: Zt, style: {
|
|
335
|
+
"--croppable-height": `${d ?? wr}px`,
|
|
336
|
+
"--croppable-zoom": Y,
|
|
337
|
+
"--croppable-x": `${k.offset.x}px`,
|
|
338
|
+
"--croppable-y": `${k.offset.y}px`,
|
|
339
|
+
...w ? {
|
|
340
|
+
"--croppable-image-width": `${C.width}px`,
|
|
341
|
+
"--croppable-image-height": `${C.height}px`
|
|
329
342
|
} : null
|
|
330
|
-
}, children: N ? /* @__PURE__ */
|
|
331
|
-
/* @__PURE__ */ q(
|
|
332
|
-
|
|
333
|
-
/* @__PURE__ */
|
|
334
|
-
|
|
335
|
-
image:
|
|
336
|
-
crop:
|
|
337
|
-
}),
|
|
343
|
+
}, children: N ? /* @__PURE__ */ p("div", { className: a.empty, children: /* @__PURE__ */ p(nr, { children: /* @__PURE__ */ p(er, { name: "Image", size: "large" }) }) }) : /* @__PURE__ */ p("div", { className: xt(a.media, yt && a.draggable, yt && bt && a.dragging), children: /* @__PURE__ */ p("div", { className: xt(a.inner), children: Mt }) }) }),
|
|
344
|
+
/* @__PURE__ */ q(rr, { children: [
|
|
345
|
+
It && /* @__PURE__ */ q("span", { className: a.action, children: [
|
|
346
|
+
/* @__PURE__ */ p(it, { isLoading: D, "aria-label": J ?? "Save image", icon: "FloppyDisk", onClick: () => {
|
|
347
|
+
et({
|
|
348
|
+
image: M,
|
|
349
|
+
crop: gt
|
|
350
|
+
}), v == null || v();
|
|
338
351
|
}, variant: "primary" }),
|
|
339
|
-
|
|
352
|
+
J && /* @__PURE__ */ p("span", { className: a.caption, children: J })
|
|
340
353
|
] }),
|
|
341
|
-
!
|
|
342
|
-
/* @__PURE__ */
|
|
343
|
-
/* @__PURE__ */
|
|
354
|
+
!It && /* @__PURE__ */ q("span", { className: a.action, children: [
|
|
355
|
+
/* @__PURE__ */ p(it, { "aria-label": K, icon: "UploadSimple", onClick: Kt, variant: "secondary" }),
|
|
356
|
+
/* @__PURE__ */ p("span", { className: a.caption, children: K })
|
|
344
357
|
] }),
|
|
345
|
-
|
|
346
|
-
/* @__PURE__ */
|
|
347
|
-
|
|
358
|
+
Lt && /* @__PURE__ */ q("span", { className: a.action, children: [
|
|
359
|
+
/* @__PURE__ */ p(it, { "aria-label": c ?? "Cancel changes", icon: "X", onClick: $t, variant: "secondary" }),
|
|
360
|
+
c && /* @__PURE__ */ p("span", { className: a.caption, children: c })
|
|
348
361
|
] }),
|
|
349
|
-
|
|
350
|
-
/* @__PURE__ */
|
|
351
|
-
|
|
362
|
+
Jt && /* @__PURE__ */ q("span", { className: a.action, children: [
|
|
363
|
+
/* @__PURE__ */ p(it, { "aria-label": z ?? "Delete image", icon: "Trash", intent: "danger", isLoading: tt, onClick: qt, variant: "secondary" }),
|
|
364
|
+
z && /* @__PURE__ */ p("span", { className: a.caption, children: z })
|
|
352
365
|
] })
|
|
353
366
|
] })
|
|
354
367
|
] });
|
|
355
368
|
};
|
|
356
369
|
export {
|
|
357
|
-
|
|
370
|
+
vr as Croppable
|
|
358
371
|
};
|
|
359
372
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index53.css');const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index53.css');const l=require("react/jsx-runtime"),e=require("classix"),t="_loading_1jrs1_23",r="_spin_1jrs1_1",o="_small_1jrs1_40",_="_large_1jrs1_46",d="_ping_1jrs1_52",g="_fullscreen_1jrs1_78",u="_sticky_1jrs1_86",s={loading:t,default:"_default_1jrs1_29",spin:r,small:o,large:_,ping:d,fullscreen:g,sticky:u},m={fullscreen:s.fullscreen,large:s.large,medium:s.medium,small:s.small},j=({variant:n="default",size:a="medium",sticky:c=!1,...i})=>l.jsx("div",{className:e.cx(s.loading,c&&s.sticky),"data-component":"loading",children:l.jsx("span",{className:e.cx(s.loading,s[n],m[a]),...i})});exports.Loading=j;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,24 +1,26 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
|
-
import { cx as
|
|
3
|
-
import '../../assets/index53.css';const
|
|
4
|
-
loading:
|
|
5
|
-
default: "
|
|
6
|
-
spin:
|
|
7
|
-
small:
|
|
8
|
-
large:
|
|
9
|
-
ping:
|
|
10
|
-
|
|
11
|
-
|
|
2
|
+
import { cx as n } from "classix";
|
|
3
|
+
import '../../assets/index53.css';const c = "_loading_1jrs1_23", o = "_spin_1jrs1_1", t = "_small_1jrs1_40", _ = "_large_1jrs1_46", m = "_ping_1jrs1_52", d = "_fullscreen_1jrs1_78", g = "_sticky_1jrs1_86", s = {
|
|
4
|
+
loading: c,
|
|
5
|
+
default: "_default_1jrs1_29",
|
|
6
|
+
spin: o,
|
|
7
|
+
small: t,
|
|
8
|
+
large: _,
|
|
9
|
+
ping: m,
|
|
10
|
+
fullscreen: d,
|
|
11
|
+
sticky: g
|
|
12
|
+
}, u = {
|
|
13
|
+
fullscreen: s.fullscreen,
|
|
12
14
|
large: s.large,
|
|
13
15
|
medium: s.medium,
|
|
14
16
|
small: s.small
|
|
15
|
-
},
|
|
16
|
-
variant:
|
|
17
|
-
size:
|
|
18
|
-
sticky:
|
|
19
|
-
...
|
|
20
|
-
}) => /* @__PURE__ */ l("div", { className:
|
|
17
|
+
}, j = ({
|
|
18
|
+
variant: e = "default",
|
|
19
|
+
size: a = "medium",
|
|
20
|
+
sticky: r = !1,
|
|
21
|
+
...i
|
|
22
|
+
}) => /* @__PURE__ */ l("div", { className: n(s.loading, r && s.sticky), "data-component": "loading", children: /* @__PURE__ */ l("span", { className: n(s.loading, s[e], u[a]), ...i }) });
|
|
21
23
|
export {
|
|
22
|
-
|
|
24
|
+
j as Loading
|
|
23
25
|
};
|
|
24
26
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index12.css');const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index12.css');const e=require("react/jsx-runtime"),y=require("classix"),p=require("../loading/index.cjs"),w="_layout_1nh7z_1",f="_constrained_1nh7z_7",z="_reading_1nh7z_12",m="_loading_1nh7z_40",n={layout:w,constrained:f,reading:z,"with-sidebar":"_with-sidebar_1nh7z_24","fill-viewport":"_fill-viewport_1nh7z_34",loading:m,"loading-content":"_loading-content_1nh7z_48","without-padding":"_without-padding_1nh7z_87"},b=({"aria-busy":l,children:s,className:d,contentLayout:t="default",contentMaxWidth:i,fillViewport:r=!1,loading:a=!1,loadingLabel:_="Loading",padding:c="default",sidebar:o,style:u,...g})=>{const h={...u,"--page-content-max-width":i};return e.jsxs("main",{"aria-busy":l??(a||void 0),className:y(n.layout,!!o&&n["with-sidebar"],r&&n["fill-viewport"],i&&t==="default"&&n.constrained,t==="reading"&&n.reading,c==="none"&&n["without-padding"],a&&n.loading,d),style:h,...g,"data-component":"pagelayout",children:[o,a?e.jsx("div",{className:n["loading-content"],role:"status","aria-label":_,children:e.jsx(p.Loading,{size:"large"})}):s]})};exports.PageLayout=b;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,36 +1,39 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
"
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
"
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
1
|
+
import { jsxs as p, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import f from "classix";
|
|
3
|
+
import { Loading as m } from "../loading/index.js";
|
|
4
|
+
import '../../assets/index12.css';const y = "_layout_1nh7z_1", w = "_constrained_1nh7z_7", z = "_reading_1nh7z_12", b = "_loading_1nh7z_40", a = {
|
|
5
|
+
layout: y,
|
|
6
|
+
constrained: w,
|
|
7
|
+
reading: z,
|
|
8
|
+
"with-sidebar": "_with-sidebar_1nh7z_24",
|
|
9
|
+
"fill-viewport": "_fill-viewport_1nh7z_34",
|
|
10
|
+
loading: b,
|
|
11
|
+
"loading-content": "_loading-content_1nh7z_48",
|
|
12
|
+
"without-padding": "_without-padding_1nh7z_87"
|
|
13
|
+
}, L = ({
|
|
14
|
+
"aria-busy": l,
|
|
15
|
+
children: d,
|
|
16
|
+
className: r,
|
|
17
|
+
contentLayout: t = "default",
|
|
18
|
+
contentMaxWidth: o,
|
|
19
|
+
fillViewport: s = !1,
|
|
20
|
+
loading: n = !1,
|
|
21
|
+
loadingLabel: _ = "Loading",
|
|
22
|
+
padding: c = "default",
|
|
23
|
+
sidebar: i,
|
|
24
|
+
style: g,
|
|
25
|
+
...h
|
|
23
26
|
}) => {
|
|
24
27
|
const u = {
|
|
25
|
-
...
|
|
26
|
-
"--page-content-max-width":
|
|
28
|
+
...g,
|
|
29
|
+
"--page-content-max-width": o
|
|
27
30
|
};
|
|
28
|
-
return /* @__PURE__ */
|
|
29
|
-
|
|
30
|
-
|
|
31
|
+
return /* @__PURE__ */ p("main", { "aria-busy": l ?? (n || void 0), className: f(a.layout, !!i && a["with-sidebar"], s && a["fill-viewport"], o && t === "default" && a.constrained, t === "reading" && a.reading, c === "none" && a["without-padding"], n && a.loading, r), style: u, ...h, "data-component": "pagelayout", children: [
|
|
32
|
+
i,
|
|
33
|
+
n ? /* @__PURE__ */ e("div", { className: a["loading-content"], role: "status", "aria-label": _, children: /* @__PURE__ */ e(m, { size: "large" }) }) : d
|
|
31
34
|
] });
|
|
32
35
|
};
|
|
33
36
|
export {
|
|
34
|
-
|
|
37
|
+
L as PageLayout
|
|
35
38
|
};
|
|
36
39
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index11.css');const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index11.css');const n=require("react/jsx-runtime"),d=require("classix"),p=require("react"),f=require("../loading/index.cjs"),g="_panel_1c69h_1",h="_none_1c69h_15",b="_page_1c69h_19",m="_scrollable_1c69h_27",x="_surface_1c69h_32",y="_loading_1c69h_36",e={panel:g,default:"_default_1c69h_11",none:h,page:b,scrollable:m,surface:x,loading:y},j=({"aria-busy":l,as:c="div",children:s,className:o,loading:a=!1,loadingLabel:t="Loading",padding:r="default",scroll:_="hidden",surface:i=!1,...u})=>p.createElement(c,{...u,"aria-busy":a||l,children:a?n.jsx("div",{role:"status","aria-label":t,children:n.jsx(f.Loading,{})}):s,className:d(e.panel,e[r],_==="auto"&&e.scrollable,i&&e.surface,a&&e.loading,o),"data-component":"panel"});exports.Panel=j;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,25 +1,34 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
1
|
+
import { jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import p from "classix";
|
|
3
|
+
import { createElement as f } from "react";
|
|
4
|
+
import { Loading as m } from "../loading/index.js";
|
|
5
|
+
import '../../assets/index11.css';const u = "_panel_1c69h_1", h = "_none_1c69h_15", b = "_page_1c69h_19", g = "_scrollable_1c69h_27", x = "_surface_1c69h_32", y = "_loading_1c69h_36", a = {
|
|
6
|
+
panel: u,
|
|
7
|
+
default: "_default_1c69h_11",
|
|
8
|
+
none: h,
|
|
9
|
+
page: b,
|
|
10
|
+
scrollable: g,
|
|
11
|
+
surface: x,
|
|
12
|
+
loading: y
|
|
13
|
+
}, N = ({
|
|
14
|
+
"aria-busy": o,
|
|
15
|
+
as: n = "div",
|
|
16
|
+
children: c,
|
|
17
|
+
className: s,
|
|
18
|
+
loading: e = !1,
|
|
19
|
+
loadingLabel: r = "Loading",
|
|
20
|
+
padding: t = "default",
|
|
21
|
+
scroll: _ = "hidden",
|
|
22
|
+
surface: i = !1,
|
|
23
|
+
...d
|
|
24
|
+
}) => f(n, {
|
|
25
|
+
...d,
|
|
26
|
+
"aria-busy": e || o,
|
|
27
|
+
children: e ? /* @__PURE__ */ l("div", { role: "status", "aria-label": r, children: /* @__PURE__ */ l(m, {}) }) : c,
|
|
28
|
+
className: p(a.panel, a[t], _ === "auto" && a.scrollable, i && a.surface, e && a.loading, s),
|
|
20
29
|
"data-component": "panel"
|
|
21
30
|
});
|
|
22
31
|
export {
|
|
23
|
-
|
|
32
|
+
N as Panel
|
|
24
33
|
};
|
|
25
34
|
//# sourceMappingURL=index.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -13,12 +13,15 @@ import { FocusEventHandler } from 'react';
|
|
|
13
13
|
import { ImgHTMLAttributes } from 'react';
|
|
14
14
|
import { InputEventHandler } from 'react';
|
|
15
15
|
import { JSX } from 'react/jsx-runtime';
|
|
16
|
+
import { JSXElementConstructor } from 'react';
|
|
16
17
|
import { Key } from 'react';
|
|
17
18
|
import { KeyboardEventHandler } from 'react';
|
|
18
19
|
import { MouseEventHandler } from 'react';
|
|
19
20
|
import { PointerEventHandler } from 'react';
|
|
21
|
+
import { ReactElement } from 'react';
|
|
20
22
|
import { ReactEventHandler } from 'react';
|
|
21
23
|
import { ReactNode } from 'react';
|
|
24
|
+
import { ReactPortal } from 'react';
|
|
22
25
|
import { Ref } from 'react';
|
|
23
26
|
import { SubmitEventHandler } from 'react';
|
|
24
27
|
import { ToggleEventHandler } from 'react';
|
|
@@ -186,25 +189,27 @@ export declare type ControlsProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
186
189
|
variant?: keyof typeof variants_5;
|
|
187
190
|
};
|
|
188
191
|
|
|
189
|
-
export declare const Croppable: ({ cancelLabel, children, fill, height, image,
|
|
192
|
+
export declare const Croppable: ({ cancelLabel, children, deleteLabel, fill, height, image, isDeleting, isSaving, onCroppableChange, onDelete, onFileChange, onImageChange, onSave, onTransformChange, saveLabel, standalone, transform, uploadLabel, }: CroppableProps) => JSX.Element;
|
|
190
193
|
|
|
191
194
|
declare type CroppableProps = {
|
|
192
195
|
cancelLabel?: string;
|
|
193
196
|
children?: default_2.ReactNode;
|
|
197
|
+
deleteLabel?: string;
|
|
194
198
|
fill?: 'width' | 'height' | 'none';
|
|
195
199
|
height?: number;
|
|
196
200
|
image?: string | null;
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
uploadLabel: string;
|
|
201
|
+
isDeleting?: boolean;
|
|
202
|
+
isSaving?: boolean;
|
|
200
203
|
onCroppableChange?: (rect: DOMRect) => void;
|
|
201
204
|
onDelete?: () => void;
|
|
202
205
|
onFileChange?: (file: File | null) => void;
|
|
203
206
|
onImageChange?: (file: File | null) => void;
|
|
204
207
|
onSave?: () => void;
|
|
205
208
|
onTransformChange?: (transform: CroppableTransform) => void;
|
|
209
|
+
saveLabel?: string;
|
|
206
210
|
standalone?: boolean;
|
|
207
211
|
transform?: CroppableTransform;
|
|
212
|
+
uploadLabel: string;
|
|
208
213
|
};
|
|
209
214
|
|
|
210
215
|
declare type CroppableTransform = {
|
|
@@ -859,18 +864,23 @@ declare type ObjectProps = Omit<ComponentPropsWithoutRef<'object'>, 'data' | 'ty
|
|
|
859
864
|
url: string;
|
|
860
865
|
};
|
|
861
866
|
|
|
862
|
-
export declare const PageLayout: ({ "aria-busy": ariaBusy, children, className, contentLayout, contentMaxWidth, fillViewport, loading, padding, sidebar, style, ...props }: PageLayoutProps) => JSX.Element;
|
|
867
|
+
export declare const PageLayout: ({ "aria-busy": ariaBusy, children, className, contentLayout, contentMaxWidth, fillViewport, loading, loadingLabel, padding, sidebar, style, ...props }: PageLayoutProps) => JSX.Element;
|
|
863
868
|
|
|
864
869
|
export declare type PageLayoutProps = React.ComponentPropsWithoutRef<'main'> & {
|
|
865
870
|
contentMaxWidth?: string;
|
|
866
871
|
contentLayout?: 'default' | 'reading';
|
|
867
872
|
fillViewport?: boolean;
|
|
873
|
+
/** Replace page content with a centered indicator while keeping the sidebar visible. */
|
|
868
874
|
loading?: boolean;
|
|
875
|
+
/** Accessible, localizable name for the loading indicator. */
|
|
876
|
+
loadingLabel?: string;
|
|
869
877
|
padding?: 'default' | 'none';
|
|
870
878
|
sidebar?: React.ReactNode;
|
|
871
879
|
};
|
|
872
880
|
|
|
873
|
-
export declare const Panel: ({ as, className, padding, scroll, surface, ...props }: PanelProps) => DetailedReactHTMLElement< {
|
|
881
|
+
export declare const Panel: ({ "aria-busy": ariaBusy, as, children, className, loading, loadingLabel, padding, scroll, surface, ...props }: PanelProps) => DetailedReactHTMLElement< {
|
|
882
|
+
'aria-busy': (boolean | "true" | "false") | undefined;
|
|
883
|
+
children: string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | ReactPortal | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | JSX.Element | null | undefined;
|
|
874
884
|
className: string;
|
|
875
885
|
ref?: Ref<HTMLElement> | undefined;
|
|
876
886
|
key?: Key | null | undefined;
|
|
@@ -933,7 +943,6 @@ part?: string | undefined;
|
|
|
933
943
|
"aria-autocomplete"?: "none" | "inline" | "list" | "both" | undefined;
|
|
934
944
|
"aria-braillelabel"?: string | undefined;
|
|
935
945
|
"aria-brailleroledescription"?: string | undefined;
|
|
936
|
-
"aria-busy"?: (boolean | "true" | "false") | undefined;
|
|
937
946
|
"aria-checked"?: boolean | "false" | "mixed" | "true" | undefined;
|
|
938
947
|
"aria-colcount"?: number | undefined;
|
|
939
948
|
"aria-colindex"?: number | undefined;
|
|
@@ -981,7 +990,6 @@ part?: string | undefined;
|
|
|
981
990
|
"aria-valuemin"?: number | undefined;
|
|
982
991
|
"aria-valuenow"?: number | undefined;
|
|
983
992
|
"aria-valuetext"?: string | undefined;
|
|
984
|
-
children?: ReactNode | undefined;
|
|
985
993
|
dangerouslySetInnerHTML?: {
|
|
986
994
|
__html: string | TrustedHTML;
|
|
987
995
|
} | undefined;
|
|
@@ -1157,6 +1165,10 @@ onTransitionStartCapture?: TransitionEventHandler<HTMLElement> | undefined;
|
|
|
1157
1165
|
|
|
1158
1166
|
export declare type PanelProps = React.ComponentPropsWithRef<'article'> & {
|
|
1159
1167
|
as?: 'article' | 'div' | 'section';
|
|
1168
|
+
/** Replace the panel contents with a centered loading indicator. */
|
|
1169
|
+
loading?: boolean;
|
|
1170
|
+
/** Accessible, localizable name for the loading indicator. */
|
|
1171
|
+
loadingLabel?: string;
|
|
1160
1172
|
padding?: 'default' | 'none' | 'page';
|
|
1161
1173
|
scroll?: 'auto' | 'hidden';
|
|
1162
1174
|
surface?: boolean;
|
|
@@ -1275,6 +1287,7 @@ declare const sizes_2: {
|
|
|
1275
1287
|
};
|
|
1276
1288
|
|
|
1277
1289
|
declare const sizes_3: {
|
|
1290
|
+
fullscreen: string;
|
|
1278
1291
|
large: string;
|
|
1279
1292
|
medium: string;
|
|
1280
1293
|
small: string;
|
package/dist/tokens.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@solibo/solibo-ui",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": [
|
|
6
6
|
"./dist/index.js",
|
|
@@ -10,22 +10,25 @@
|
|
|
10
10
|
"scripts": {
|
|
11
11
|
"dev": "pnpm run tokens:build && vite build --config vite.config.ts --watch",
|
|
12
12
|
"build": "pnpm run tokens:build && tsc -b && vite build --config vite.config.ts && pnpm run tokens:dist",
|
|
13
|
+
"check": "pnpm lint && pnpm stories:audit && pnpm test:ci && pnpm test:scripts && pnpm build && pnpm storybook:build",
|
|
13
14
|
"coverage": "vitest run --config vite.config.ts --coverage",
|
|
14
15
|
"format": "prettier --check .",
|
|
15
16
|
"format:fix": "prettier --write .",
|
|
16
17
|
"icons:build": "node scripts/icons.mjs",
|
|
17
|
-
"lint": "
|
|
18
|
-
"lint:
|
|
18
|
+
"lint": "pnpm lint:js && pnpm stylelint",
|
|
19
|
+
"lint:js": "eslint .",
|
|
20
|
+
"lint:fix": "eslint . --fix && pnpm stylelint:fix",
|
|
19
21
|
"open": "node scripts/open-storybook.mjs",
|
|
20
22
|
"prepare": "git config core.hooksPath .githooks || true",
|
|
21
23
|
"prepublishOnly": "vitest run --config vite.config.ts && pnpm run build",
|
|
22
24
|
"storybook": "storybook dev -p 6006",
|
|
23
25
|
"storybook:build": "storybook build",
|
|
24
26
|
"stories:audit": "tsc --project tsconfig.stories.json",
|
|
25
|
-
"stylelint": "stylelint **/*.css",
|
|
26
|
-
"stylelint:fix": "stylelint **/*.css --fix",
|
|
27
|
+
"stylelint": "stylelint \"**/*.css\"",
|
|
28
|
+
"stylelint:fix": "stylelint \"**/*.css\" --fix",
|
|
27
29
|
"test": "vitest --config vite.config.ts --ui --coverage.enabled=true",
|
|
28
30
|
"test:ci": "vitest run --config vite.config.ts",
|
|
31
|
+
"test:scripts": "node --test scripts/*.tests.mjs",
|
|
29
32
|
"tokens:audit": "node scripts/design-tokens.mjs audit",
|
|
30
33
|
"tokens:build": "node scripts/design-tokens.mjs build",
|
|
31
34
|
"tokens:dist": "node scripts/design-tokens.mjs dist",
|