@limetech/lime-crm-building-blocks 1.86.2 → 1.87.0
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/CHANGELOG.md +7 -0
- package/dist/cjs/{highlight-item.handler-99d5a0b6.js → highlight-item.handler-584ab58a.js} +2 -2
- package/dist/cjs/{index-3da101cc.js → index-ff255a0d.js} +3 -28
- package/dist/cjs/{index.esm-d6513e37.js → index.esm-9effb196.js} +1 -1
- package/dist/cjs/lime-crm-building-blocks.cjs.js +1 -1
- package/dist/cjs/limebb-browser.cjs.entry.js +2 -2
- package/dist/cjs/limebb-chat-item_2.cjs.entry.js +8 -3
- package/dist/cjs/limebb-chat-list.cjs.entry.js +34 -16
- package/dist/cjs/limebb-component-config.cjs.entry.js +5 -3
- package/dist/cjs/limebb-component-picker.cjs.entry.js +2 -2
- package/dist/cjs/limebb-currency-picker.cjs.entry.js +3 -3
- package/dist/cjs/limebb-dashboard-widget.cjs.entry.js +1 -1
- package/dist/cjs/limebb-date-picker.cjs.entry.js +5 -5
- package/dist/cjs/limebb-date-range.cjs.entry.js +1 -1
- package/dist/cjs/limebb-empty-state.cjs.entry.js +1 -1
- package/dist/cjs/limebb-feed-timeline-item.cjs.entry.js +4 -5
- package/dist/cjs/limebb-feed.cjs.entry.js +4 -4
- package/dist/cjs/limebb-icon-picker.cjs.entry.js +10 -6
- package/dist/cjs/limebb-info-tile-currency-format.cjs.entry.js +1 -1
- package/dist/cjs/limebb-info-tile-date-format.cjs.entry.js +2 -2
- package/dist/cjs/limebb-info-tile-decimal-format.cjs.entry.js +1 -1
- package/dist/cjs/limebb-info-tile-format.cjs.entry.js +2 -1
- package/dist/cjs/limebb-info-tile-relative-date-format.cjs.entry.js +1 -1
- package/dist/cjs/limebb-info-tile-unit-format.cjs.entry.js +2 -2
- package/dist/cjs/limebb-info-tile.cjs.entry.js +21 -22
- package/dist/cjs/limebb-kanban-group.cjs.entry.js +3 -3
- package/dist/cjs/limebb-kanban-item.cjs.entry.js +3 -3
- package/dist/cjs/limebb-kanban.cjs.entry.js +1 -1
- package/dist/cjs/limebb-limeobject-file-viewer.cjs.entry.js +4 -4
- package/dist/cjs/limebb-loader.cjs.entry.js +3 -3
- package/dist/cjs/limebb-locale-picker.cjs.entry.js +14 -6
- package/dist/cjs/limebb-mention-group-counter.cjs.entry.js +1 -1
- package/dist/cjs/limebb-mention.cjs.entry.js +5 -6
- package/dist/cjs/limebb-navigation-button_2.cjs.entry.js +5 -5
- package/dist/cjs/limebb-notification-item.cjs.entry.js +2 -2
- package/dist/cjs/limebb-notification-list.cjs.entry.js +31 -14
- package/dist/cjs/limebb-percentage-visualizer.cjs.entry.js +7 -8
- package/dist/cjs/limebb-text-editor-picker.cjs.entry.js +1 -1
- package/dist/cjs/limebb-text-editor.cjs.entry.js +42 -39
- package/dist/cjs/limebb-trend-indicator.cjs.entry.js +8 -8
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{non-null-b8d9b4b4.js → non-null-3bf14aa1.js} +5 -0
- package/dist/cjs/{percentage-class-9decca4f.js → percentage-class-e4f0a52d.js} +2 -2
- package/dist/collection/components/chat-list/chat-item/chat-item.css +4 -0
- package/dist/collection/components/chat-list/chat-item/chat-item.js +5 -0
- package/dist/collection/components/chat-list/chat-list.js +11 -7
- package/dist/collection/components/chat-list/{processChatItems.js → process-chat-items.js} +22 -8
- package/dist/collection/components/component-command-picker/component-config/component-config.js +3 -1
- package/dist/collection/components/date-picker/to-server-date.js +3 -3
- package/dist/collection/components/feed/feed-item/feed-timeline-item.css +4 -4
- package/dist/collection/components/feed/feed-item/feed-timeline-item.js +1 -2
- package/dist/collection/components/feed/feed.js +1 -1
- package/dist/collection/components/feed/highlight-item/highlight-item.handler.js +2 -2
- package/dist/collection/components/icon-picker/search.js +9 -0
- package/dist/collection/components/info-tile/format/config/info-tile-date-format.js +1 -1
- package/dist/collection/components/info-tile/format/config/info-tile-format.js +1 -0
- package/dist/collection/components/info-tile/format/config/info-tile-unit-format.js +1 -1
- package/dist/collection/components/info-tile/format/date-time.js +12 -11
- package/dist/collection/components/info-tile/format/number.js +3 -3
- package/dist/collection/components/info-tile/format/relative-date-time.js +2 -4
- package/dist/collection/components/info-tile/info-tile.js +2 -2
- package/dist/collection/components/kanban/kanban-group/kanban-group.css +4 -4
- package/dist/collection/components/kanban/kanban-item/kanban-item.css +4 -4
- package/dist/collection/components/limeobject/file-viewer/file-viewer.js +2 -2
- package/dist/collection/components/locale-picker/language.js +10 -1
- package/dist/collection/components/locale-picker/locale-picker.js +2 -3
- package/dist/collection/components/mention/mention.js +0 -1
- package/dist/collection/components/navigation-button/navigation-button.css +4 -3
- package/dist/collection/components/notification-list/notification-list.css +2 -2
- package/dist/collection/components/notification-list/notification-list.js +7 -4
- package/dist/collection/components/notification-list/{processNotificationItems.js → process-notification-items.js} +22 -8
- package/dist/collection/components/percentage-visualizer/percentage-visualizer.js +5 -6
- package/dist/collection/components/summary-popover/summary-popover.js +3 -3
- package/dist/collection/components/text-editor/mentions.js +6 -8
- package/dist/collection/components/text-editor/text-editor.js +2 -4
- package/dist/collection/components/text-editor/uploader/building-blocks-upload-handler.js +8 -9
- package/dist/collection/components/text-editor/uploader/building-blocks-uploader.js +1 -1
- package/dist/collection/components/text-editor/utils/searcher-utils.js +5 -0
- package/dist/collection/components/trend-indicator/trend-indicator.js +6 -6
- package/dist/collection/util/dom.js +3 -3
- package/dist/collection/util/limetype.js +11 -11
- package/dist/collection/util/non-null.js +5 -0
- package/dist/collection/util/percentage-class.js +2 -2
- package/dist/collection/util/random-string.js +6 -3
- package/dist/components/chat-item.js +6 -1
- package/dist/components/date-picker.js +3 -3
- package/dist/components/feed-timeline-item.js +2 -3
- package/dist/components/highlight-item.handler.js +2 -2
- package/dist/components/kanban-group.js +1 -1
- package/dist/components/kanban-item.js +1 -1
- package/dist/components/limebb-chat-list.js +32 -14
- package/dist/components/limebb-component-config.js +3 -1
- package/dist/components/limebb-feed.js +1 -1
- package/dist/components/limebb-icon-picker.js +9 -5
- package/dist/components/limebb-info-tile-date-format.js +1 -1
- package/dist/components/limebb-info-tile-format.js +1 -0
- package/dist/components/limebb-info-tile-unit-format.js +1 -1
- package/dist/components/limebb-info-tile.js +19 -20
- package/dist/components/limebb-limeobject-file-viewer.js +2 -2
- package/dist/components/limebb-locale-picker.js +12 -4
- package/dist/components/limebb-mention.js +3 -4
- package/dist/components/limebb-notification-list.js +29 -12
- package/dist/components/limebb-percentage-visualizer.js +5 -6
- package/dist/components/limebb-text-editor.js +39 -36
- package/dist/components/limebb-trend-indicator.js +6 -6
- package/dist/components/navigation-button.js +1 -1
- package/dist/components/non-null.js +5 -0
- package/dist/components/percentage-class.js +2 -2
- package/dist/components/summary-popover.js +3 -3
- package/dist/esm/{highlight-item.handler-96b59c20.js → highlight-item.handler-dfbf11c0.js} +2 -2
- package/dist/esm/{index-cdbbc18d.js → index-96dd111f.js} +3 -28
- package/dist/esm/{index.esm-5e14dac9.js → index.esm-10a8f67c.js} +1 -1
- package/dist/esm/lime-crm-building-blocks.js +2 -2
- package/dist/esm/limebb-browser.entry.js +2 -2
- package/dist/esm/limebb-chat-item_2.entry.js +8 -3
- package/dist/esm/limebb-chat-list.entry.js +34 -16
- package/dist/esm/limebb-component-config.entry.js +5 -3
- package/dist/esm/limebb-component-picker.entry.js +2 -2
- package/dist/esm/limebb-currency-picker.entry.js +3 -3
- package/dist/esm/limebb-dashboard-widget.entry.js +1 -1
- package/dist/esm/limebb-date-picker.entry.js +5 -5
- package/dist/esm/limebb-date-range.entry.js +1 -1
- package/dist/esm/limebb-empty-state.entry.js +1 -1
- package/dist/esm/limebb-feed-timeline-item.entry.js +4 -5
- package/dist/esm/limebb-feed.entry.js +4 -4
- package/dist/esm/limebb-icon-picker.entry.js +10 -6
- package/dist/esm/limebb-info-tile-currency-format.entry.js +1 -1
- package/dist/esm/limebb-info-tile-date-format.entry.js +2 -2
- package/dist/esm/limebb-info-tile-decimal-format.entry.js +1 -1
- package/dist/esm/limebb-info-tile-format.entry.js +2 -1
- package/dist/esm/limebb-info-tile-relative-date-format.entry.js +1 -1
- package/dist/esm/limebb-info-tile-unit-format.entry.js +2 -2
- package/dist/esm/limebb-info-tile.entry.js +21 -22
- package/dist/esm/limebb-kanban-group.entry.js +3 -3
- package/dist/esm/limebb-kanban-item.entry.js +3 -3
- package/dist/esm/limebb-kanban.entry.js +1 -1
- package/dist/esm/limebb-limeobject-file-viewer.entry.js +4 -4
- package/dist/esm/limebb-loader.entry.js +3 -3
- package/dist/esm/limebb-locale-picker.entry.js +14 -6
- package/dist/esm/limebb-mention-group-counter.entry.js +1 -1
- package/dist/esm/limebb-mention.entry.js +5 -6
- package/dist/esm/limebb-navigation-button_2.entry.js +5 -5
- package/dist/esm/limebb-notification-item.entry.js +2 -2
- package/dist/esm/limebb-notification-list.entry.js +31 -14
- package/dist/esm/limebb-percentage-visualizer.entry.js +7 -8
- package/dist/esm/limebb-text-editor-picker.entry.js +1 -1
- package/dist/esm/limebb-text-editor.entry.js +42 -39
- package/dist/esm/limebb-trend-indicator.entry.js +8 -8
- package/dist/esm/loader.js +2 -2
- package/dist/esm/non-null-5a66a269.js +10 -0
- package/dist/esm/{percentage-class-78377c1e.js → percentage-class-1e4748e8.js} +2 -2
- package/dist/lime-crm-building-blocks/lime-crm-building-blocks.esm.js +1 -1
- package/dist/lime-crm-building-blocks/{p-38eec842.entry.js → p-013b852a.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-01cff04f.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-ccc748a1.entry.js → p-0f925b3d.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-29e90714.entry.js → p-10ac8b3e.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-1556b545.js +2 -0
- package/dist/lime-crm-building-blocks/p-1ff94c41.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-b8d49d3e.entry.js → p-218b7f38.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-235aec61.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-ebbd8784.entry.js → p-25e1a434.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-e38afb31.entry.js → p-292631ea.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-67e1ea69.entry.js → p-302e0feb.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-305a14bf.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-99be75d5.entry.js → p-3a406a20.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-3dce616c.entry.js → p-3bd02e86.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-ca79dc23.entry.js → p-4aac81ef.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-eab00e3c.entry.js → p-4caa8bbe.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-d0ce5a35.entry.js → p-568b7520.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-0a331c84.entry.js → p-5f0d0df3.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-66352a1e.js +1 -0
- package/dist/lime-crm-building-blocks/p-6b1a6487.entry.js +1 -0
- package/dist/lime-crm-building-blocks/p-6c56121c.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-1eb8fb75.entry.js → p-70ab5db7.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-75abe3ad.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-58faab30.entry.js → p-8491aaa1.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-8bf72bb4.entry.js +1 -0
- package/dist/lime-crm-building-blocks/p-8e316957.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-3b9766cc.js → p-9b6ec98b.js} +1 -1
- package/dist/lime-crm-building-blocks/p-a9b0d2e5.entry.js +1 -0
- package/dist/lime-crm-building-blocks/p-ad52e723.entry.js +1 -0
- package/dist/lime-crm-building-blocks/p-af8c22c4.entry.js +1 -0
- package/dist/lime-crm-building-blocks/p-b107fe24.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-27786967.entry.js → p-b5f15f73.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-af6e6696.entry.js → p-c45be80e.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-c5d79dd5.entry.js +1 -0
- package/dist/lime-crm-building-blocks/{p-adcb57c6.entry.js → p-dd0370cd.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-0779e2b4.entry.js → p-e1e5f461.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/{p-bf322752.entry.js → p-e2128caf.entry.js} +1 -1
- package/dist/lime-crm-building-blocks/p-f820c983.entry.js +1 -0
- package/dist/test/setup.js +15 -5
- package/dist/types/components/chat-list/{processChatItems.d.ts → process-chat-items.d.ts} +17 -5
- package/dist/types/components/date-picker/to-server-date.d.ts +3 -3
- package/dist/types/components/icon-picker/search.d.ts +9 -0
- package/dist/types/components/locale-picker/language.d.ts +9 -0
- package/dist/types/components/notification-list/{processNotificationItems.d.ts → process-notification-items.d.ts} +17 -5
- package/dist/types/components/text-editor/mentions.d.ts +2 -2
- package/dist/types/components/text-editor/uploader/building-blocks-upload-handler.d.ts +8 -8
- package/dist/types/components/text-editor/utils/searcher-utils.d.ts +5 -0
- package/dist/types/home/runner/work/lime-crm-building-blocks/lime-crm-building-blocks/.stencil/test/setup.d.ts +10 -0
- package/dist/types/util/dom.d.ts +3 -3
- package/dist/types/util/limetype.d.ts +11 -11
- package/dist/types/util/non-null.d.ts +4 -0
- package/dist/types/util/percentage-class.d.ts +2 -2
- package/package.json +8 -25
- package/dist/esm/non-null-d9b0b630.js +0 -5
- package/dist/lime-crm-building-blocks/p-06839012.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-10452278.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-2b8bfe92.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-2e496d18.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-31a55daa.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-37e0254e.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-3d961c1b.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-43c76027.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-46bf22fa.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-506dfcff.js +0 -1
- package/dist/lime-crm-building-blocks/p-51e87162.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-a581f635.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-acce6160.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-c4e6dcf4.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-cf06416b.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-d312f578.entry.js +0 -1
- package/dist/lime-crm-building-blocks/p-d736c794.js +0 -2
- /package/dist/lime-crm-building-blocks/{p-2b0ec58c.js → p-10e16feb.js} +0 -0
- /package/dist/lime-crm-building-blocks/{p-6fd28e32.js → p-1484e300.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as r,H as a}from"./p-1556b545.js";import{g as l}from"./p-10e16feb.js";const t=1e-4,o=class{valueChanged(e){this.numValue=this.parseValue(e)}constructor(a){e(this,a),this.rangeMax=100,this.rangeMin=0,this.multiplier=1,this.reducePresence=!0,this.displayPercentageColors=!1,this.labelId="label-"+crypto.randomUUID(),this.helperTextId="helper-text-"+crypto.randomUUID(),this.zeroPointId="zero-point-"+crypto.randomUUID(),this.renderHelperLine=()=>{if(this.hasHelperText())return r("limel-helper-line",{helperTextId:this.helperTextId,helperText:this.helperText,invalid:this.invalid})},this.hasHelperText=()=>null!=this.helperText,this.numValue=this.parseValue(this.value)}componentDidLoad(){this.triggerRangeWarning()}componentWillUpdate(){this.triggerRangeWarning()}triggerRangeWarning(){this.rangeMin>=this.rangeMax&&console.warn(`[limebb-percentage-visualizer] Invalid range: rangeMin (${this.rangeMin}) must be less than rangeMax (${this.rangeMax}). Visualization may not appear as expected.`)}render(){const e=this.getNormalizedValue(),l=this.getZeroPointPosition();return r(a,{key:"454366891b8fe6860a43efaf8c1b96c9a4689962",class:this.getContainerClassList(),style:{"--limebb-percentage-visualizer-zero-point-position":`${l}%`,"--limebb-percentage-visualizer-width":`${Math.abs(e)}%`,"--limebb-percentage-visualizer-rotate":e>=0?"0deg":"180deg"}},r("limel-notched-outline",{key:"c827cb818ed190f6a7b6fa33e6b1c878b5682e42",tabIndex:0,role:"meter","aria-valuemin":this.rangeMin,"aria-valuemax":this.rangeMax,"aria-valuenow":this.numValue,"aria-labelledby":this.labelId,"aria-describedby":this.helperTextId,label:this.label,labelId:this.labelId,invalid:this.invalid,required:this.required,hasValue:!0,hasFloatingLabel:!0,"aria-controls":this.helperTextId},r("div",{key:"7c6dcc138c4bca114d4d83af026c93f8611339b5",slot:"content"},this.renderVisualization())),this.renderHelperLine())}renderVisualization(){if(!this.reducePresence||0!==this.numValue&&this.hasValue())return this.hasValue()?[r("div",{class:"percentage-bar"},r("div",{class:"percentage-fill"}),this.renderZeroPoint()),r("span",{class:"percentage-text"},this.formatValue(this.numValue),r("span",{class:"percent-sign"},"%"))]:r("span",{class:"no-value"},"–")}renderZeroPoint(){if(!(this.rangeMin>=0||this.rangeMax<=0))return[r("div",{id:this.zeroPointId,class:"zero-point"}),r("limel-tooltip",{elementId:this.zeroPointId,openDirection:"top",label:"0"})]}hasValue(){return null!=this.value&&""!==this.value}getContainerClassList(){if(!this.hasValue())return;const e=this.roundValue(this.multiplyByMultiplier(this.numValue)),r=l(e);return Object.assign({},r&&{[r]:!0})}getZeroPointPosition(){const e=this.rangeMax-this.rangeMin;return e<=0?0:(0-this.rangeMin)/e*100}getNormalizedValue(){const e=this.roundValue(this.multiplyByMultiplier(this.numValue)),r=this.rangeMax-this.rangeMin;if(r<=0)return 0;const a=(0-this.rangeMin)/r*100;return e>=0?e/Math.max(this.rangeMax,t)*(100-a):e/Math.max(Math.abs(this.rangeMin),t)*a}multiplyByMultiplier(e){return e*this.multiplier}roundValue(e){return Math.round(10*e)/10}unifyMinusSign(e){return e.replaceAll("−","-")}convertToUnicodeMinus(e){return e.replaceAll("-","−")}parseValue(e){return"string"==typeof e?Number.parseFloat(this.unifyMinusSign(e)):e}formatValue(e){const r=this.roundValue(this.multiplyByMultiplier(e)),a=`${r}`;return r<0?this.convertToUnicodeMinus(a):a}static get watchers(){return{value:["valueChanged"]}}};o.style='@charset "UTF-8";*,::before,::after{box-sizing:border-box}:host(limebb-percentage-visualizer){width:100%}limel-notched-outline:not([invalid]:not([invalid=false])) .limel-notched-outline--outlines{--limel-notched-outline-border-color:transparent}div[slot=content]{display:flex;align-items:center;gap:0.5rem;border-radius:inherit;background-color:transparent !important}div[slot=content]:focus{outline:none}div[slot=content]:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}:host(limebb-percentage-visualizer[invalid]:not([invalid=false])) div[slot=content]{border-color:rgb(var(--color-red-default))}:host(limebb-percentage-visualizer):has(label) div[slot=content]{min-height:2.5rem;padding:0 0.375rem 0 1rem}.percentage-text{flex-shrink:0;min-width:2.5rem}:host([range-min^="-"]) .percentage-text{min-width:3.75rem}.percent-sign{opacity:0.4}.zero-point{content:"";position:absolute;transform:translateX(-50%);left:var(--limebb-percentage-visualizer-zero-point-position);height:0.25rem;width:0.25rem;border-radius:50%;box-shadow:0 0 0 0.125rem var(--limebb-percentage-visualizer-zero-point-color, rgb(var(--contrast-1200), 0.3));background-color:var(--limebb-percentage-visualizer-zero-point-color, rgb(var(--contrast-200), 0.9))}.percentage-bar{overflow:hidden;flex-grow:1;position:relative;display:flex;align-items:center;height:0.5rem;min-width:2rem;border-radius:0.5rem;background-color:rgb(var(--contrast-800), 0.6)}.percentage-fill{transition:width 0.2s ease;position:absolute;margin:auto;left:var(--limebb-percentage-visualizer-zero-point-position, 0);rotate:var(--limebb-percentage-visualizer-rotate, 0deg);transform-origin:left center;width:var(--limebb-percentage-visualizer-width);height:100%;border-radius:0.5rem}:host(limebb-percentage-visualizer:focus),:host(limebb-percentage-visualizer:focus-visible),:host(limebb-percentage-visualizer:focus-within){--limel-h-l-grid-template-rows-transition-speed:0.46s;--limel-h-l-grid-template-rows:1fr}:host(limebb-percentage-visualizer){--limel-h-l-grid-template-rows-transition-speed:0.3s;--limel-h-l-grid-template-rows:0fr}:host(limebb-percentage-visualizer:focus) limel-helper-line,:host(limebb-percentage-visualizer:focus-visible) limel-helper-line,:host(limebb-percentage-visualizer:focus-within) limel-helper-line,:host(limebb-percentage-visualizer:hover) limel-helper-line{will-change:grid-template-rows}.percentage-fill{background-color:var(--percentage-visualizer-color, var(--limebb-percentage-visualizer-color, var(--mdc-theme-primary)))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-200or-larger-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-red-darker))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-200to100-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-red-dark))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-100to90-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-red-dark))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-90to80-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-red-dark))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-80to70-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-red-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-70to60-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-red-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-60to50-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-coral-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-50to40-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-coral-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-40to30-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-orange-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-30to20-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-orange-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-20to10-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-amber-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-10to0-negative) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-amber-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-0) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--contrast-800))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-0to10-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-yellow-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-10to20-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-yellow-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-20to30-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-grass-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-30to40-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-grass-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-40to50-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-lime-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-50to60-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-lime-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-60to70-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-70to80-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-default))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-80to90-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-dark))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-90to100-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-dark))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-100to200-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-dark))}:host([range-min^="-"][display-percentage-colors]:not([display-percentage-colors=false]).has-value-200or-larger-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-darker))}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-0) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--contrast-800))}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-0to10-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--0to10)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-10to20-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--10to20)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-20to30-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--20to30)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-30to40-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--30to40)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-40to50-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--40to50)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-50to60-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--50to60)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-60to70-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--60to70)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-70to80-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--70to80)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-80to90-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--80to90)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-90to100-positive) .percentage-fill{--limebb-percentage-visualizer-color:var(--color-percent--90to100)}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-100to200-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-dark))}:host([display-percentage-colors]:not([display-percentage-colors=false]).has-value-200or-larger-positive) .percentage-fill{--limebb-percentage-visualizer-color:rgb(var(--color-teal-darker))}';export{o as limebb_percentage_visualizer}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as t}from"./p-d736c794.js";const n={Route:"route"};function r(t){return t&&["belongsto","hasone","hasmany","hasandbelongstomany"].includes(t.type)}function i(t){return t&&["belongsto","hasone"].includes(t.type)}n.LimeTypeRepository="state.limetypes";var o=function(t,n){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])})(t,n)};function e(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}o(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}function u(t){var n="function"==typeof Symbol&&Symbol.iterator,r=n&&t[n],i=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function c(t,n){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var i,o,e=r.call(t),u=[];try{for(;(void 0===n||n-- >0)&&!(i=e.next()).done;)u.push(i.value)}catch(t){o={error:t}}finally{try{i&&!i.done&&(r=e.return)&&r.call(e)}finally{if(o)throw o.error}}return u}function s(t,n,r){if(r||2===arguments.length)for(var i,o=0,e=n.length;o<e;o++)(i||!(o in n))&&(i||(i=Array.prototype.slice.call(n,0,o)),i[o]=n[o]);return t.concat(i||Array.prototype.slice.call(n))}function f(t){return"function"==typeof t}function a(t){var n=t((function(t){Error.call(t),t.stack=(new Error).stack}));return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var h=a((function(t){return function(n){t(this),this.message=n?n.length+" errors occurred during unsubscription:\n"+n.map((function(t,n){return n+1+") "+t.toString()})).join("\n "):"",this.name="UnsubscriptionError",this.errors=n}}));function l(t,n){if(t){var r=t.indexOf(n);0<=r&&t.splice(r,1)}}var v=function(){function t(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return t.prototype.unsubscribe=function(){var t,n,r,i,o;if(!this.closed){this.closed=!0;var e=this._parentage;if(e)if(this._parentage=null,Array.isArray(e))try{for(var a=u(e),l=a.next();!l.done;l=a.next())l.value.remove(this)}catch(n){t={error:n}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else e.remove(this);var v=this.initialTeardown;if(f(v))try{v()}catch(t){o=t instanceof h?t.errors:[t]}var y=this._finalizers;if(y){this._finalizers=null;try{for(var d=u(y),m=d.next();!m.done;m=d.next()){var w=m.value;try{b(w)}catch(t){o=o??[],t instanceof h?o=s(s([],c(o)),c(t.errors)):o.push(t)}}}catch(t){r={error:t}}finally{try{m&&!m.done&&(i=d.return)&&i.call(d)}finally{if(r)throw r.error}}}if(o)throw new h(o)}},t.prototype.add=function(n){var r;if(n&&n!==this)if(this.closed)b(n);else{if(n instanceof t){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=null!==(r=this._finalizers)&&void 0!==r?r:[]).push(n)}},t.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},t.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},t.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&l(n,t)},t.prototype.remove=function(n){var r=this._finalizers;r&&l(r,n),n instanceof t&&n._removeParent(this)},t.EMPTY=((n=new t).closed=!0,n),t;var n}(),y=v.EMPTY;function d(t){return t instanceof v||t&&"closed"in t&&f(t.remove)&&f(t.add)&&f(t.unsubscribe)}function b(t){f(t)?t():t.unsubscribe()}var m=function(t,n){for(var r=[],i=2;i<arguments.length;i++)r[i-2]=arguments[i];return setTimeout.apply(void 0,s([t,n],c(r)))};function w(){}function p(t){t()}var g=function(t){function n(n){var r=t.call(this)||this;return r.isStopped=!1,n?(r.destination=n,d(n)&&n.add(r)):r.destination=A,r}return e(n,t),n.create=function(t,n,r){return new O(t,n,r)},n.prototype.next=function(t){this.isStopped||this._next(t)},n.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},n.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},n.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this),this.destination=null)},n.prototype._next=function(t){this.destination.next(t)},n.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},n.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},n}(v),j=function(){function t(t){this.partialObserver=t}return t.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(t){S(t)}},t.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(t){S(t)}else S(t)},t.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(t){S(t)}},t}(),O=function(t){function n(n,r,i){var o,e=t.call(this)||this;return o=f(n)||!n?{next:n??void 0,error:r??void 0,complete:i??void 0}:n,e.destination=new j(o),e}return e(n,t),n}(g);function S(t){!function(t){m((function(){throw t}))}(t)}var A={closed:!0,next:w,error:function(t){throw t},complete:w},E="function"==typeof Symbol&&Symbol.observable||"@@observable";function x(t){return t}var P=function(){function t(t){t&&(this._subscribe=t)}return t.prototype.lift=function(n){var r=new t;return r.source=this,r.operator=n,r},t.prototype.subscribe=function(t,n,r){var i=this,o=function(t){return t&&t instanceof g||function(t){return t&&f(t.next)&&f(t.error)&&f(t.complete)}(t)&&d(t)}(t)?t:new O(t,n,r);return p((function(){var t=i.operator,n=i.source;o.add(t?t.call(o,n):n?i._subscribe(o):i._trySubscribe(o))})),o},t.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},t.prototype.forEach=function(t,n){var r=this;return new(n=T(n))((function(n,i){var o=new O({next:function(n){try{t(n)}catch(t){i(t),o.unsubscribe()}},error:i,complete:n});r.subscribe(o)}))},t.prototype._subscribe=function(t){var n;return null===(n=this.source)||void 0===n?void 0:n.subscribe(t)},t.prototype[E]=function(){return this},t.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return function(t){return 0===t.length?x:1===t.length?t[0]:function(n){return t.reduce((function(t,n){return n(t)}),n)}}(t)(this)},t.prototype.toPromise=function(t){var n=this;return new(t=T(t))((function(t,r){var i;n.subscribe((function(t){return i=t}),(function(t){return r(t)}),(function(){return t(i)}))}))},t.create=function(n){return new t(n)},t}();function T(t){var n;return null!==(n=t??undefined)&&void 0!==n?n:Promise}var M=a((function(t){return function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}})),k=function(t){function n(){var n=t.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return e(n,t),n.prototype.lift=function(t){var n=new R(this,this);return n.operator=t,n},n.prototype._throwIfClosed=function(){if(this.closed)throw new M},n.prototype.next=function(t){var n=this;p((function(){var r,i;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var o=u(n.currentObservers),e=o.next();!e.done;e=o.next())e.value.next(t)}catch(t){r={error:t}}finally{try{e&&!e.done&&(i=o.return)&&i.call(o)}finally{if(r)throw r.error}}}}))},n.prototype.error=function(t){var n=this;p((function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=t;for(var r=n.observers;r.length;)r.shift().error(t)}}))},n.prototype.complete=function(){var t=this;p((function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var n=t.observers;n.length;)n.shift().complete()}}))},n.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(n.prototype,"observed",{get:function(){var t;return(null===(t=this.observers)||void 0===t?void 0:t.length)>0},enumerable:!1,configurable:!0}),n.prototype._trySubscribe=function(n){return this._throwIfClosed(),t.prototype._trySubscribe.call(this,n)},n.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},n.prototype._innerSubscribe=function(t){var n=this,r=this,i=r.observers;return r.hasError||r.isStopped?y:(this.currentObservers=null,i.push(t),new v((function(){n.currentObservers=null,l(i,t)})))},n.prototype._checkFinalizedStatuses=function(t){var n=this,r=n.isStopped;n.hasError?t.error(n.thrownError):r&&t.complete()},n.prototype.asObservable=function(){var t=new P;return t.source=this,t},n.create=function(t,n){return new R(t,n)},n}(P),R=function(t){function n(n,r){var i=t.call(this)||this;return i.destination=n,i.source=r,i}return e(n,t),n.prototype.next=function(t){var n,r;null===(r=null===(n=this.destination)||void 0===n?void 0:n.next)||void 0===r||r.call(n,t)},n.prototype.error=function(t){var n,r;null===(r=null===(n=this.destination)||void 0===n?void 0:n.error)||void 0===r||r.call(n,t)},n.prototype.complete=function(){var t,n;null===(n=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===n||n.call(t)},n.prototype._subscribe=function(t){var n,r;return null!==(r=null===(n=this.source)||void 0===n?void 0:n.subscribe(t))&&void 0!==r?r:y},n}(k),C=function(t){function n(n){var r=t.call(this)||this;return r._value=n,r}return e(n,t),Object.defineProperty(n.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),n.prototype._subscribe=function(n){var r=t.prototype._subscribe.call(this,n);return!r.closed&&n.next(this._value),r},n.prototype.getValue=function(){var t=this,n=t._value;if(t.hasError)throw t.thrownError;return this._throwIfClosed(),n},n.prototype.next=function(n){t.prototype.next.call(this,this._value=n)},n}(k);function U(t){return t}function D(t,n){return(r,i)=>{const o=function(t,n,r,i){let o=G.get(t);return o||(o=[],G.set(t,o)),o.push({options:r,name:n,optionFactory:i.optionFactory||U,service:{name:i.name,method:i.method||"subscribe"}}),o}(r,i,t,n);1===o.length&&function(t,n){t.connectedCallback=F(t.connectedCallback,n),t.componentWillLoad=function(t,n){return async function(...r){return!0===_.get(this)?(await L(this),t?t.apply(this,r):void 0):F(t,n).apply(this,r)}}(t.componentWillLoad,n),t.componentDidUnload=H(t.componentDidUnload),t.disconnectedCallback=H(t.disconnectedCallback)}(r,o)}}const G=new WeakMap,W=new WeakMap,_=new WeakMap;function F(n,r){return async function(...i){_.set(this,!0),W.set(this,[]),await L(this);const o=new C(this.context);if(function(n,r,i){const o=t(n),{get:e,set:u}=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(o),r);Object.defineProperty(o,r,{configurable:!0,get:e,set:function(t){u.call(this,t),i.next(t)}})}(this,"context",o),r.forEach((t=>{t.options=t.optionFactory(t.options,this),function(t){return"context"in t}(t.options)&&(t.options.context=o),function(t,n){const r=function(t,n){const r={...n.options};!function(t,n){t.filter&&(t.filter=t.filter.map((t=>t.bind(n)))),t.map&&(t.map=t.map.map((t=>t.bind(n))))}(r,t);const i=n.service.name,o=t.platform;if(!o.has(i))throw new Error(`Service ${i} does not exist`);return o.get(i)[n.service.method](function(t,n){return r=>{t[n]=r}}(t,n.name),r)}(t,n);"function"==typeof r&&W.get(t).push(r)}(this,t)})),n)return n.apply(this,i)}}function H(t){return async function(...n){let r;return t&&(r=t.apply(this,n)),function(t){W.get(t).forEach((t=>t())),W.set(t,[])}(this),r}}function L(t){const n=[];return t.platform||n.push(N(t,"platform")),t.context||n.push(N(t,"context")),n.length?Promise.all(n):Promise.resolve()}function N(n,r){const i=t(n);return new Promise((t=>{Object.defineProperty(i,r,{configurable:!0,set:n=>{delete i[r],i[r]=n,t()}})}))}function q(t={}){return D(t,{name:n.LimeTypeRepository})}function B(t={}){const r={name:n.LimeTypeRepository};return t.map=[I,...t.map||[]],t.context=null,D(t,r)}function I(t){const{limetype:n}=this.context;return t[n]}function K(t={}){const r={name:n.LimeObjectRepository};return t.map=[V,...t.map||[]],t.context=null,D(t,r)}function V(t){const{limetype:n,id:r}=this.context;if(t[n])return t[n].find((t=>t.id===r))}function X(t){return n=>{(function(t,n){t.commandId=n})(n,t.id),function(t,n){Object.defineProperty(t,Symbol.hasInstance,{value:t=>function(t){let n,r=[],i=t;for(;n=Y(i);)r=[...r,n],i=Object.getPrototypeOf(i);return Array.from(new Set(r))}(t).includes(n)})}(n,t.id)}}function Y(t){return"string"==typeof t?t:t&&t.constructor&&t.constructor.commandId?t.constructor.commandId:t&&t.commandId?t.commandId:null}n.LimeObjectRepository="state.limeobjects",n.CommandBus="commandBus";let $=class{};$=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.bulk-create-dialog"})],$);let z=class{constructor(){this.route=!1}};z=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.create-dialog"})],z);let J=class{};J=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.delete-object"})],J);let Q=class{};Q=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.object-access"})],Q);let Z=class{constructor(){this.route=!1}};Z=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.save-object"})],Z);const tt={Count:"COUNT",Sum:"SUM",Average:"AVG",Maximum:"MAX",Minimum:"MIN"};n.Query="query";const nt={Get:"GET",Post:"POST",Put:"PUT",Delete:"DELETE",Patch:"PATCH"};n.Http="http",n.EventDispatcher="eventDispatcher",n.Translate="translate",n.Dialog="dialog",n.KeybindingRegistry="keybindingRegistry",n.Navigator="navigator";let rt=class{};function it(t){return D(t,{name:n.ConfigRepository})}function ot(t={}){return D(t,{name:n.FilterRepository})}rt=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"navigator.navigate"})],rt),n.Notification="notifications",n.RouteRegistry="routeRegistry",n.TaskRepository="state.tasks",n.ConfigRepository="state.configs",n.Device="state.device",n.FilterRepository="state.filters",n.UserDataRepository="state.user-data",n.Application="state.application",n.UserPreferencesRepository="userPreferences",n.DateTimeFormatter="datetimeformatter",n.ConditionRegistry="conditionRegistry",n.ViewFactoryRegistry="viewFactoryRegistry",n.WebComponentRegistry="webComponentRegistry",n.NotificationRepository="state.notifications",n.PollerFactory="pollerFactory";export{r as D,K as G,nt as H,ot as K,B as L,i as M,q as T,tt as W,it as Y,n as c,X as h}
|
|
1
|
+
import{g as t}from"./p-1556b545.js";const n={Route:"route"};function r(t){return t&&["belongsto","hasone","hasmany","hasandbelongstomany"].includes(t.type)}function i(t){return t&&["belongsto","hasone"].includes(t.type)}n.LimeTypeRepository="state.limetypes";var o=function(t,n){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])})(t,n)};function e(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}o(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}function u(t){var n="function"==typeof Symbol&&Symbol.iterator,r=n&&t[n],i=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function c(t,n){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var i,o,e=r.call(t),u=[];try{for(;(void 0===n||n-- >0)&&!(i=e.next()).done;)u.push(i.value)}catch(t){o={error:t}}finally{try{i&&!i.done&&(r=e.return)&&r.call(e)}finally{if(o)throw o.error}}return u}function s(t,n,r){if(r||2===arguments.length)for(var i,o=0,e=n.length;o<e;o++)(i||!(o in n))&&(i||(i=Array.prototype.slice.call(n,0,o)),i[o]=n[o]);return t.concat(i||Array.prototype.slice.call(n))}function f(t){return"function"==typeof t}function a(t){var n=t((function(t){Error.call(t),t.stack=(new Error).stack}));return n.prototype=Object.create(Error.prototype),n.prototype.constructor=n,n}var h=a((function(t){return function(n){t(this),this.message=n?n.length+" errors occurred during unsubscription:\n"+n.map((function(t,n){return n+1+") "+t.toString()})).join("\n "):"",this.name="UnsubscriptionError",this.errors=n}}));function l(t,n){if(t){var r=t.indexOf(n);0<=r&&t.splice(r,1)}}var v=function(){function t(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return t.prototype.unsubscribe=function(){var t,n,r,i,o;if(!this.closed){this.closed=!0;var e=this._parentage;if(e)if(this._parentage=null,Array.isArray(e))try{for(var a=u(e),l=a.next();!l.done;l=a.next())l.value.remove(this)}catch(n){t={error:n}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}else e.remove(this);var v=this.initialTeardown;if(f(v))try{v()}catch(t){o=t instanceof h?t.errors:[t]}var y=this._finalizers;if(y){this._finalizers=null;try{for(var d=u(y),m=d.next();!m.done;m=d.next()){var w=m.value;try{b(w)}catch(t){o=o??[],t instanceof h?o=s(s([],c(o)),c(t.errors)):o.push(t)}}}catch(t){r={error:t}}finally{try{m&&!m.done&&(i=d.return)&&i.call(d)}finally{if(r)throw r.error}}}if(o)throw new h(o)}},t.prototype.add=function(n){var r;if(n&&n!==this)if(this.closed)b(n);else{if(n instanceof t){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=null!==(r=this._finalizers)&&void 0!==r?r:[]).push(n)}},t.prototype._hasParent=function(t){var n=this._parentage;return n===t||Array.isArray(n)&&n.includes(t)},t.prototype._addParent=function(t){var n=this._parentage;this._parentage=Array.isArray(n)?(n.push(t),n):n?[n,t]:t},t.prototype._removeParent=function(t){var n=this._parentage;n===t?this._parentage=null:Array.isArray(n)&&l(n,t)},t.prototype.remove=function(n){var r=this._finalizers;r&&l(r,n),n instanceof t&&n._removeParent(this)},t.EMPTY=((n=new t).closed=!0,n),t;var n}(),y=v.EMPTY;function d(t){return t instanceof v||t&&"closed"in t&&f(t.remove)&&f(t.add)&&f(t.unsubscribe)}function b(t){f(t)?t():t.unsubscribe()}var m=function(t,n){for(var r=[],i=2;i<arguments.length;i++)r[i-2]=arguments[i];return setTimeout.apply(void 0,s([t,n],c(r)))};function w(){}function p(t){t()}var g=function(t){function n(n){var r=t.call(this)||this;return r.isStopped=!1,n?(r.destination=n,d(n)&&n.add(r)):r.destination=A,r}return e(n,t),n.create=function(t,n,r){return new O(t,n,r)},n.prototype.next=function(t){this.isStopped||this._next(t)},n.prototype.error=function(t){this.isStopped||(this.isStopped=!0,this._error(t))},n.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},n.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this),this.destination=null)},n.prototype._next=function(t){this.destination.next(t)},n.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},n.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},n}(v),j=function(){function t(t){this.partialObserver=t}return t.prototype.next=function(t){var n=this.partialObserver;if(n.next)try{n.next(t)}catch(t){S(t)}},t.prototype.error=function(t){var n=this.partialObserver;if(n.error)try{n.error(t)}catch(t){S(t)}else S(t)},t.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(t){S(t)}},t}(),O=function(t){function n(n,r,i){var o,e=t.call(this)||this;return o=f(n)||!n?{next:n??void 0,error:r??void 0,complete:i??void 0}:n,e.destination=new j(o),e}return e(n,t),n}(g);function S(t){!function(t){m((function(){throw t}))}(t)}var A={closed:!0,next:w,error:function(t){throw t},complete:w},E="function"==typeof Symbol&&Symbol.observable||"@@observable";function x(t){return t}var P=function(){function t(t){t&&(this._subscribe=t)}return t.prototype.lift=function(n){var r=new t;return r.source=this,r.operator=n,r},t.prototype.subscribe=function(t,n,r){var i=this,o=function(t){return t&&t instanceof g||function(t){return t&&f(t.next)&&f(t.error)&&f(t.complete)}(t)&&d(t)}(t)?t:new O(t,n,r);return p((function(){var t=i.operator,n=i.source;o.add(t?t.call(o,n):n?i._subscribe(o):i._trySubscribe(o))})),o},t.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(n){t.error(n)}},t.prototype.forEach=function(t,n){var r=this;return new(n=T(n))((function(n,i){var o=new O({next:function(n){try{t(n)}catch(t){i(t),o.unsubscribe()}},error:i,complete:n});r.subscribe(o)}))},t.prototype._subscribe=function(t){var n;return null===(n=this.source)||void 0===n?void 0:n.subscribe(t)},t.prototype[E]=function(){return this},t.prototype.pipe=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return function(t){return 0===t.length?x:1===t.length?t[0]:function(n){return t.reduce((function(t,n){return n(t)}),n)}}(t)(this)},t.prototype.toPromise=function(t){var n=this;return new(t=T(t))((function(t,r){var i;n.subscribe((function(t){return i=t}),(function(t){return r(t)}),(function(){return t(i)}))}))},t.create=function(n){return new t(n)},t}();function T(t){var n;return null!==(n=t??undefined)&&void 0!==n?n:Promise}var M=a((function(t){return function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}})),k=function(t){function n(){var n=t.call(this)||this;return n.closed=!1,n.currentObservers=null,n.observers=[],n.isStopped=!1,n.hasError=!1,n.thrownError=null,n}return e(n,t),n.prototype.lift=function(t){var n=new R(this,this);return n.operator=t,n},n.prototype._throwIfClosed=function(){if(this.closed)throw new M},n.prototype.next=function(t){var n=this;p((function(){var r,i;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var o=u(n.currentObservers),e=o.next();!e.done;e=o.next())e.value.next(t)}catch(t){r={error:t}}finally{try{e&&!e.done&&(i=o.return)&&i.call(o)}finally{if(r)throw r.error}}}}))},n.prototype.error=function(t){var n=this;p((function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=t;for(var r=n.observers;r.length;)r.shift().error(t)}}))},n.prototype.complete=function(){var t=this;p((function(){if(t._throwIfClosed(),!t.isStopped){t.isStopped=!0;for(var n=t.observers;n.length;)n.shift().complete()}}))},n.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(n.prototype,"observed",{get:function(){var t;return(null===(t=this.observers)||void 0===t?void 0:t.length)>0},enumerable:!1,configurable:!0}),n.prototype._trySubscribe=function(n){return this._throwIfClosed(),t.prototype._trySubscribe.call(this,n)},n.prototype._subscribe=function(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)},n.prototype._innerSubscribe=function(t){var n=this,r=this,i=r.observers;return r.hasError||r.isStopped?y:(this.currentObservers=null,i.push(t),new v((function(){n.currentObservers=null,l(i,t)})))},n.prototype._checkFinalizedStatuses=function(t){var n=this,r=n.isStopped;n.hasError?t.error(n.thrownError):r&&t.complete()},n.prototype.asObservable=function(){var t=new P;return t.source=this,t},n.create=function(t,n){return new R(t,n)},n}(P),R=function(t){function n(n,r){var i=t.call(this)||this;return i.destination=n,i.source=r,i}return e(n,t),n.prototype.next=function(t){var n,r;null===(r=null===(n=this.destination)||void 0===n?void 0:n.next)||void 0===r||r.call(n,t)},n.prototype.error=function(t){var n,r;null===(r=null===(n=this.destination)||void 0===n?void 0:n.error)||void 0===r||r.call(n,t)},n.prototype.complete=function(){var t,n;null===(n=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===n||n.call(t)},n.prototype._subscribe=function(t){var n,r;return null!==(r=null===(n=this.source)||void 0===n?void 0:n.subscribe(t))&&void 0!==r?r:y},n}(k),C=function(t){function n(n){var r=t.call(this)||this;return r._value=n,r}return e(n,t),Object.defineProperty(n.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),n.prototype._subscribe=function(n){var r=t.prototype._subscribe.call(this,n);return!r.closed&&n.next(this._value),r},n.prototype.getValue=function(){var t=this,n=t._value;if(t.hasError)throw t.thrownError;return this._throwIfClosed(),n},n.prototype.next=function(n){t.prototype.next.call(this,this._value=n)},n}(k);function U(t){return t}function D(t,n){return(r,i)=>{const o=function(t,n,r,i){let o=G.get(t);return o||(o=[],G.set(t,o)),o.push({options:r,name:n,optionFactory:i.optionFactory||U,service:{name:i.name,method:i.method||"subscribe"}}),o}(r,i,t,n);1===o.length&&function(t,n){t.connectedCallback=F(t.connectedCallback,n),t.componentWillLoad=function(t,n){return async function(...r){return!0===_.get(this)?(await L(this),t?t.apply(this,r):void 0):F(t,n).apply(this,r)}}(t.componentWillLoad,n),t.componentDidUnload=H(t.componentDidUnload),t.disconnectedCallback=H(t.disconnectedCallback)}(r,o)}}const G=new WeakMap,W=new WeakMap,_=new WeakMap;function F(n,r){return async function(...i){_.set(this,!0),W.set(this,[]),await L(this);const o=new C(this.context);if(function(n,r,i){const o=t(n),{get:e,set:u}=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(o),r);Object.defineProperty(o,r,{configurable:!0,get:e,set:function(t){u.call(this,t),i.next(t)}})}(this,"context",o),r.forEach((t=>{t.options=t.optionFactory(t.options,this),function(t){return"context"in t}(t.options)&&(t.options.context=o),function(t,n){const r=function(t,n){const r={...n.options};!function(t,n){t.filter&&(t.filter=t.filter.map((t=>t.bind(n)))),t.map&&(t.map=t.map.map((t=>t.bind(n))))}(r,t);const i=n.service.name,o=t.platform;if(!o.has(i))throw new Error(`Service ${i} does not exist`);return o.get(i)[n.service.method](function(t,n){return r=>{t[n]=r}}(t,n.name),r)}(t,n);"function"==typeof r&&W.get(t).push(r)}(this,t)})),n)return n.apply(this,i)}}function H(t){return async function(...n){let r;return t&&(r=t.apply(this,n)),function(t){W.get(t).forEach((t=>t())),W.set(t,[])}(this),r}}function L(t){const n=[];return t.platform||n.push(N(t,"platform")),t.context||n.push(N(t,"context")),n.length?Promise.all(n):Promise.resolve()}function N(n,r){const i=t(n);return new Promise((t=>{Object.defineProperty(i,r,{configurable:!0,set:n=>{delete i[r],i[r]=n,t()}})}))}function q(t={}){return D(t,{name:n.LimeTypeRepository})}function B(t={}){const r={name:n.LimeTypeRepository};return t.map=[I,...t.map||[]],t.context=null,D(t,r)}function I(t){const{limetype:n}=this.context;return t[n]}function K(t={}){const r={name:n.LimeObjectRepository};return t.map=[V,...t.map||[]],t.context=null,D(t,r)}function V(t){const{limetype:n,id:r}=this.context;if(t[n])return t[n].find((t=>t.id===r))}function X(t){return n=>{(function(t,n){t.commandId=n})(n,t.id),function(t,n){Object.defineProperty(t,Symbol.hasInstance,{value:t=>function(t){let n,r=[],i=t;for(;n=Y(i);)r=[...r,n],i=Object.getPrototypeOf(i);return Array.from(new Set(r))}(t).includes(n)})}(n,t.id)}}function Y(t){return"string"==typeof t?t:t&&t.constructor&&t.constructor.commandId?t.constructor.commandId:t&&t.commandId?t.commandId:null}n.LimeObjectRepository="state.limeobjects",n.CommandBus="commandBus";let $=class{};$=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.bulk-create-dialog"})],$);let z=class{constructor(){this.route=!1}};z=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.create-dialog"})],z);let J=class{};J=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.delete-object"})],J);let Q=class{};Q=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.object-access"})],Q);let Z=class{constructor(){this.route=!1}};Z=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"limeobject.save-object"})],Z);const tt={Count:"COUNT",Sum:"SUM",Average:"AVG",Maximum:"MAX",Minimum:"MIN"};n.Query="query";const nt={Get:"GET",Post:"POST",Put:"PUT",Delete:"DELETE",Patch:"PATCH"};n.Http="http",n.EventDispatcher="eventDispatcher",n.Translate="translate",n.Dialog="dialog",n.KeybindingRegistry="keybindingRegistry",n.Navigator="navigator";let rt=class{};function it(t){return D(t,{name:n.ConfigRepository})}function ot(t={}){return D(t,{name:n.FilterRepository})}rt=((t,n)=>{for(var r,i=n,o=t.length-1;o>=0;o--)(r=t[o])&&(i=r(i)||i);return i})([X({id:"navigator.navigate"})],rt),n.Notification="notifications",n.RouteRegistry="routeRegistry",n.TaskRepository="state.tasks",n.ConfigRepository="state.configs",n.Device="state.device",n.FilterRepository="state.filters",n.UserDataRepository="state.user-data",n.Application="state.application",n.UserPreferencesRepository="userPreferences",n.DateTimeFormatter="datetimeformatter",n.ConditionRegistry="conditionRegistry",n.ViewFactoryRegistry="viewFactoryRegistry",n.WebComponentRegistry="webComponentRegistry",n.NotificationRepository="state.notifications",n.PollerFactory="pollerFactory";export{r as D,K as G,nt as H,ot as K,B as L,i as M,q as T,tt as W,it as Y,n as c,X as h}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,h as e}from"./p-1556b545.js";import{c as r,Y as i,K as s,W as o}from"./p-9b6ec98b.js";import{i as n,a,b as l,c as u,g as h,d as c,e as f}from"./p-5322fd19.js";import{i as d}from"./p-b31772c8.js";var v=Object.prototype.hasOwnProperty;class p{constructor(t,e=[]){this.platform=t,this.filters=e}async load(t,e){let r;return r=this.isObjectIdentifier(e)?await this.loadLimeObjectInfoTile(t,e):await this.loadBasicInfoTile(t),r}async loadBasicInfoTile(t){const e=this.getFilter(t.filter);if(!e)throw new Error(`Filter "${t.filter}" not found`);return(await this.query.execute({limetype:e.limetype,responseFormat:{aggregates:{infotiles:{value:{op:t.operator,key:t.name}}}},filter:e.filter})).aggregates.infotiles[0].value}async loadLimeObjectInfoTile(t,e){await this.objectRepository.loadObject(e.limetype,e.id,{properties:[t]});const r=this.objectRepository.getObject(e.limetype,e.id);return null==r?void 0:r.getValue([t.name,t.key].join("."))}isObjectIdentifier(t){return Boolean((null==t?void 0:t.limetype)&&(null==t?void 0:t.id))}getFilter(t){return this.filters.find((e=>e.id===t))}get query(){return this.platform.get(r.Query)}get objectRepository(){return this.platform.get(r.LimeObjectRepository)}}class b{constructor(t){this.locale=t}format(t){let e=String(t);return"number"==typeof t?e=new Intl.NumberFormat(this.locale).format(t):new Date(t).getTime()&&(e=new Intl.DateTimeFormat(this.locale).format(new Date(t))),{value:e}}}class g{constructor(t){this.locale=t}format(t,e){const r=new Date(t);return{prefix:this.formatAffix("prefix",r,e),value:this.formatValue(r,e),suffix:this.formatAffix("suffix",r,e)}}formatValue(t,e){const r=Object.assign({},e.options);if(e.prefix)for(const t of e.prefix)delete r[t];if(e.suffix)for(const t of e.suffix)delete r[t];return new Intl.DateTimeFormat(this.locale,r).format(t)}formatAffix(t,e,r){const i=Object.assign({},r.options);for(const e of Object.keys(i))"hour12"!==e&&((r[t]||[]).includes(e)||delete i[e]);if(0!==Object.values(i).filter(Boolean).length)return new Intl.DateTimeFormat(this.locale,i).format(e)}}class m{constructor(t){this.locale=t}format(t,e){var r,i;const s=new Intl.NumberFormat(this.locale,e.options),o=s.formatToParts(t);let n="",a="",l="";for(const t of o)(null===(r=e.prefix)||void 0===r?void 0:r.includes(t.type))?n+=t.value:(null===(i=e.suffix)||void 0===i?void 0:i.includes(t.type))?l+=t.value:a+=t.value;return a||(a=s.format(t),n="",l=""),{prefix:n,value:a,suffix:l}}}class w{constructor(t){this.locale=t}format(t,e){const r=new Intl.RelativeTimeFormat(this.locale,e.options),{value:i,unit:s}=this.getRelativeTime(t),o=r.formatToParts(i,s);let n="",a="",l="";for(const t of o)"literal"!==t.type||a?"literal"===t.type&&a?l+=t.value:a+=t.value:n+=t.value;return a||(a=n||l,n="",l=""),{prefix:n,value:a,suffix:l}}getRelativeTime(t){const e=new Date(t),r=new Date,i=e.getTime()-r.getTime(),s=[{unit:"year",value:31536e6},{unit:"month",value:2592e6},{unit:"week",value:6048e5},{unit:"day",value:864e5},{unit:"hour",value:36e5},{unit:"minute",value:6e4},{unit:"second",value:1e3}];for(const t of s){const e=i/t.value;if(Math.abs(e)>=1)return{value:Math.round(e),unit:t.unit}}return{value:0,unit:"second"}}}class y{constructor(t){this.locale=t}createFormatter(t,e){return"number"===(null==t?void 0:t.type)&&"number"==typeof e?new m(this.locale):"date"===(null==t?void 0:t.type)&&"string"==typeof e?new g(this.locale):"relative-date"===(null==t?void 0:t.type)&&"string"==typeof e?new w(this.locale):new b(this.locale)}}var j=function(t,e,r,i){var s,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,r,i);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(n=(o<3?s(n):o>3?s(e,r,n):s(e,r))||n);return o>3&&n&&Object.defineProperty(e,r,n),n};const O=class{constructor(e){t(this,e),this.aggregateOperator=o.Count,this.loading=!1,this.error=!1}componentWillLoad(){this.loadInfoTileValue()}watchFilterId(){this.loadInfoTileValue()}watchPropertyName(){this.loadInfoTileValue()}watchAggregateOperator(){this.loadInfoTileValue()}async loadInfoTileValue(){if(this.loading=!0,this.error=!1,this.getFilter()){try{const t={key:this.getKey(),name:this.propertyName,operator:this.aggregateOperator,filter:this.filterId};this.value=await this.loader.load(t,this.context)}catch(t){console.error(t),this.error=!0}this.loading=!1}else this.error=!0}getKey(){return Math.random().toString(36).slice(2)}render(){var t,r;const i=this.getFilter(),s=this.getFormattedValue(),o={disabled:this.disabled,icon:this.icon,prefix:(null===(t=null==s?void 0:s.prefix)||void 0===t?void 0:t.trim())||this.prefix,suffix:(null===(r=null==s?void 0:s.suffix)||void 0===r?void 0:r.trim())||this.suffix},n=Object.assign(Object.assign({},o),{icon:"error",prefix:"ERROR",loading:!0,label:this.getLabel(i)}),a=Object.assign(Object.assign({},o),{label:this.getLabel(i),link:this.getLink(i),loading:this.loading,value:null==s?void 0:s.value.trim()});return e("limel-info-tile",Object.assign({key:"9d8d11498cba43ea63f18f6a6a72148d39966d5c",class:{error:!i||this.error}},!i||this.error?n:a))}getFormattedValue(){if(!this.value&&0!==this.value)return{value:""};try{return this.getFormatter(this.value).format(this.value,this.format)}catch(t){return new b(this.language).format(this.value)}}getLabel(t){return t?"string"==typeof this.label?this.translator.get(this.label):this.getLocalizedString(this.label&&"object"==typeof this.label?this.label:t.name):"No filter set is selected"}getLocalizedString(t){if(function(t){if(null==t)return!0;if(n(t)&&(d(t)||"string"==typeof t||"function"==typeof t.splice||a(t)||l(t)||u(t)))return!t.length;var e=h(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(c(t))return!f(t).length;for(var r in t)if(v.call(t,r))return!1;return!0}(t))return"";let e=t[this.language];return e||(e=t.en||t.en_us||Object.values(null!=e?e:{}).find((t=>!!t))),null!=e?e:""}getLink(t){return t?{href:["explorer",t.limetype,t.id].join("/")}:{href:"#"}}getFilter(){var t;return null===(t=this.filters)||void 0===t?void 0:t.find((t=>t.id===this.filterId))}getFormatter(t){return new y(this.language).createFormatter(this.format,t)}get translator(){return this.platform.get(r.Translate)}get language(){return this.platform.get(r.Application).getLanguage()}get loader(){return new p(this.platform,this.filters)}static get watchers(){return{filterId:["watchFilterId"],propertyName:["watchPropertyName"],aggregateOperator:["watchAggregateOperator"]}}};j([i({})],O.prototype,"config",void 0),j([s()],O.prototype,"filters",void 0),O.style=":host(limebb-info-tile){display:block;overflow:visible !important;background-color:transparent !important}limel-info-tile.error{--info-tile-icon-color:rgb(var(--color-red-dark));border:1px dashed rgb(var(--contrast-500));border-radius:var(--info-tile-border-radius, 1rem)}";export{O as limebb_info_tile}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,h as e}from"./p-1556b545.js";import{G as i,L as r,c as o}from"./p-9b6ec98b.js";import{n as s}from"./p-7c9484b1.js";const n=["edit","view"],l=["ai","aspx","doc","docm","docx","dotm","dotx","emf","html","htm","obj","potm","potx","ppsm","ppsx","ppt","pptm","pptx","psd","rtf","tif","tiff","txt","wmf","xls","xlsx","zip"];var c=function(t,e,i,r){var o,s=arguments.length,n=s<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,i,r);else for(var l=t.length-1;l>=0;l--)(o=t[l])&&(n=(s<3?o(n):s>3?o(e,i,n):o(e,i))||n);return s>3&&n&&Object.defineProperty(e,i,n),n};const h=class{constructor(e){t(this,e),this.fileTypes=["view","contents","download"]}render(){const t=this.getFile();return t?this.isLiveDocsFile(t)?this.renderLiveDocs(t):this.renderFileViewer(t):this.renderNotFound()}renderLiveDocs(t){const i=this.getLiveDocsUrl(t);return i?e("iframe",{src:i,frameBorder:0,marginHeight:0,marginWidth:0}):this.renderNotFound()}renderFileViewer(t){const i=t.filename,r=this.getFileUrl(t);return r?e("limel-file-viewer",{filename:i,url:r,allowDownload:!0,allowFullscreen:!0}):this.renderNotFound()}renderNotFound(){return[e("section",{class:"not-found"},e("limel-icon",{name:"error",size:"large"}),e("h2",null,this.translator.get("not-found")),e("p",null,this.translator.get("no-files-attached",{object:this.getDescriptive(this.limeobject)})))]}getLiveDocsUrl(t){return this.fileTypes.filter(this.isLiveDocsType).map((e=>t.getUrl(e))).find(Boolean)}getFileUrl(t){return this.fileTypes.filter(s(this.isLiveDocsType)).map((e=>t.getUrl(e))).find(Boolean)}getFile(){const t=this.fileProperty;if(t)return this.limeobject.getFile(t.name)}isLiveDocsFile(t){return l.includes(t.extension)&&n.some((e=>t.getUrl(e)))}isLiveDocsType(t){return n.includes(t)}getDescriptive(t){var e;let i="";return(null==t?void 0:t.descriptive)&&(i=t.descriptive),i||(i=null===(e=this.limetype)||void 0===e?void 0:e.localname.singular),i||(i=this.translator.get("object")),i}get fileProperty(){if(this.limeobject){if(this.property){const t=this.limeobject.getLimetype().getProperty(this.property);if("file"===t.type)return t}return Object.values(this.limeobject.getLimetype().properties).find((t=>"file"===t.type))}}get translator(){return this.platform.get(o.Translate)}};c([i()],h.prototype,"limeobject",void 0),c([r()],h.prototype,"limetype",void 0),h.style=".not-found{display:flex;flex-direction:column;height:100%;align-items:center;justify-content:center;line-height:1rem;color:rgb(var(--contrast-1100))}.not-found limel-icon{color:rgb(var(--color-red-default))}iframe{height:100%;width:100%}";export{h as limebb_limeobject_file_viewer}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as o,h as r,H as e}from"./p-1556b545.js";import{g as t}from"./p-10e16feb.js";const a=class{valueChanged(o){this.numValue=this.parseValue(o)}constructor(e){o(this,e),this.suffix="%",this.reducePresence=!0,this.labelId="a"+crypto.randomUUID(),this.tooltipId="a"+crypto.randomUUID(),this.helperTextId="a"+crypto.randomUUID(),this.renderHelperLine=()=>{if(this.hasHelperText())return r("limel-helper-line",{helperTextId:this.helperTextId,helperText:this.helperText,invalid:this.invalid})},this.hasHelperText=()=>null!=this.helperText,this.numValue=this.parseValue(this.value)}render(){return r(e,{key:"99a6428199d7843edfc5474d2be1da7dce35f4b6",class:this.getContainerClassList()},r("limel-notched-outline",{key:"4a07c8ea4754d91be60c30658ea54fc6b803df77",id:this.tooltipId,label:this.label,labelId:this.labelId,invalid:this.invalid,required:this.required,hasValue:!0,hasFloatingLabel:!0,"aria-labelledby":this.labelId,"aria-describedby":this.helperTextId,"aria-controls":this.helperTextId},r("div",{key:"329d041335fcee7838e7e1eb7948952e71861c86",slot:"content",tabIndex:0},this.renderVisualization())),this.renderHelperLine(),this.renderTooltip())}renderVisualization(){if(!this.reducePresence||0!==this.numValue&&this.hasValue())return this.hasValue()?[this.getArrowIcon(),r("span",null,this.renderGrowthPercentage(),this.renderGrowthAmount())]:r("span",{class:"no-value"},"–")}renderTooltip(){if(void 0===this.formerValue)return;const o=`${this.value} - ${this.formerValue>0?this.formerValue:"("+this.formerValue+")"} = ${this.calculateGrowth()} ${this.suffix} `,e=this.calculatePercentage();return r("limel-tooltip",{openDirection:"top-start",elementId:this.tooltipId,label:e+"%",helperLabel:o})}renderGrowthPercentage(){if(void 0===this.formerValue)return this.formatValue(this.numValue,this.suffix);const o=this.calculatePercentage();return null!==o?this.formatValue(o,"%"):void 0}renderGrowthAmount(){if(void 0===this.formerValue)return;const o=this.calculateGrowth();return r("span",{class:"growth-unit"},"( ",this.formatValue(o,this.suffix)," )")}hasValue(){return null!=this.value&&""!==this.value}getContainerClassList(){if(!this.hasValue())return;const o=this.getPercentage(),r=t(o);return Object.assign({},r&&{[r]:!0})}getPercentage(){return void 0===this.formerValue?this.numValue:this.calculatePercentage()}calculateGrowth(){return this.numValue-this.formerValue}calculatePercentage(){if(0===this.formerValue)return null;const o=((this.numValue-this.formerValue)/Math.abs(this.formerValue)*100).toFixed(2);return Number.parseFloat(o)}unifyMinusSign(o){return o.replaceAll("−","-")}convertToUnicodeMinus(o){return o.replaceAll("-","−")}parseValue(o){return"string"==typeof o?Number.parseFloat(this.unifyMinusSign(o)):o}formatValue(o,r){const e=`${o} ${r}`;return o>0?"+"+e:this.convertToUnicodeMinus(e)}getArrowIcon(){return r("limel-icon",{class:"icon",name:"right","aria-hidden":"true",role:"presentation"})}static get watchers(){return{value:["valueChanged"]}}};a.style='@charset "UTF-8";*{box-sizing:border-box}:host(limebb-trend-indicator){position:relative;display:block;height:100%;width:100%}limel-notched-outline:not([invalid]:not([invalid=false])) .limel-notched-outline--outlines{--limel-notched-outline-border-color:transparent}div[slot=content]{display:flex;align-items:center;gap:0.5rem;border-radius:inherit;background-color:transparent !important}div[slot=content]:focus{outline:none}div[slot=content]:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}:host(limebb-trend-indicator):has(label) div[slot=content]{min-height:2.5rem;padding:0 0.375rem 0 1rem}:host(limebb-trend-indicator[former-value]) div[slot=content]{cursor:help}div[slot=content] span{flex-shrink:0}.icon{flex-shrink:0;display:flex;transition-property:color, background-color, transform;transition-duration:0.4s;transition-timing-function:ease;width:1.25rem;height:1.25rem;border-radius:50%;padding:0.12rem;color:rgb(var(--color-white));background-color:rgb(var(--color-gray-default), 0.5)}:host(.has-value-40to30-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-30to20-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-20to10-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-10to0-negative) .icon{color:rgb(var(--color-gray-darker))}:host(.has-value-0to10-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-10to20-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-20to30-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-30to40-positive) .icon{color:rgb(var(--color-gray-dark))}:host(.has-value-200or-larger-negative) .icon{background-color:rgb(var(--color-red-darker));transform:rotate(90deg)}:host(.has-value-200to100-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(90deg)}:host(.has-value-100to90-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(90deg)}:host(.has-value-90to80-negative) .icon{background-color:rgb(var(--color-red-dark));transform:rotate(81deg)}:host(.has-value-80to70-negative) .icon{background-color:rgb(var(--color-red-default));transform:rotate(72deg)}:host(.has-value-70to60-negative) .icon{background-color:rgb(var(--color-red-default));transform:rotate(63deg)}:host(.has-value-60to50-negative) .icon{background-color:rgb(var(--color-coral-default));transform:rotate(54deg)}:host(.has-value-50to40-negative) .icon{background-color:rgb(var(--color-coral-default));transform:rotate(45deg)}:host(.has-value-40to30-negative) .icon{background-color:rgb(var(--color-orange-default));transform:rotate(36deg)}:host(.has-value-30to20-negative) .icon{background-color:rgb(var(--color-orange-default));transform:rotate(27deg)}:host(.has-value-20to10-negative) .icon{background-color:rgb(var(--color-amber-default));transform:rotate(18deg)}:host(.has-value-10to0-negative) .icon{background-color:rgb(var(--color-amber-default));transform:rotate(9deg)}:host(.has-value-0) .icon{background-color:rgb(var(--color-gray-default));transform:rotate(0deg)}:host(.has-value-0to10-positive) .icon{background-color:rgb(var(--color-yellow-default));transform:rotate(-9deg)}:host(.has-value-10to20-positive) .icon{background-color:rgb(var(--color-yellow-default));transform:rotate(-18deg)}:host(.has-value-20to30-positive) .icon{background-color:rgb(var(--color-grass-default));transform:rotate(-27deg)}:host(.has-value-30to40-positive) .icon{background-color:rgb(var(--color-grass-default));transform:rotate(-36deg)}:host(.has-value-40to50-positive) .icon{background-color:rgb(var(--color-lime-default));transform:rotate(-45deg)}:host(.has-value-50to60-positive) .icon{background-color:rgb(var(--color-lime-default));transform:rotate(-54deg)}:host(.has-value-60to70-positive) .icon{background-color:rgb(var(--color-teal-default));transform:rotate(-63deg)}:host(.has-value-70to80-positive) .icon{background-color:rgb(var(--color-teal-default));transform:rotate(-72deg)}:host(.has-value-80to90-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-81deg)}:host(.has-value-90to100-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-90deg)}:host(.has-value-100to200-positive) .icon{background-color:rgb(var(--color-teal-dark));transform:rotate(-90deg)}:host(.has-value-200or-larger-positive) .icon{background-color:rgb(var(--color-teal-darker));transform:rotate(-90deg)}:host(.has-value-0) .icon{background-color:rgb(var(--color-gray-default), 0.5);transform:rotate(0deg)}:host(.has-value-0) .icon polyline{color:transparent}:host(.has-value-200or-larger-negative) .icon:after,:host(.has-value-200or-larger-negative) .icon:before,:host(.has-value-200to100-negative) .icon:after,:host(.has-value-200to100-negative) .icon:before,:host(.has-value-100to200-positive) .icon:after,:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:after,:host(.has-value-200or-larger-positive) .icon:before{transition:border-color 0.6s ease;content:"";position:absolute;inset:0;margin:auto;border:1px solid transparent;border-radius:50%}:host(.has-value-200or-larger-negative) .icon:before,:host(.has-value-200to100-negative) .icon:before,:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:before{transform:scale(1.2)}:host(.has-value-200or-larger-negative) .icon:after,:host(.has-value-200to100-negative) .icon:after,:host(.has-value-100to200-positive) .icon:after,:host(.has-value-200or-larger-positive) .icon:after{transform:scale(1.4);opacity:0.4}:host(.has-value-200to100-negative) .icon:before,:host(.has-value-200or-larger-negative) .icon:before{border-color:rgb(var(--color-red-dark))}:host(.has-value-200or-larger-negative) .icon:after{border-color:rgb(var(--color-red-darker))}:host(.has-value-100to200-positive) .icon:before,:host(.has-value-200or-larger-positive) .icon:before{border-color:rgb(var(--color-teal-dark))}:host(.has-value-200or-larger-positive) .icon:after{border-color:rgb(var(--color-teal-darker))}.no-value{transform:translateY(0.5rem)}.growth-unit{padding-left:0.5rem;opacity:0.5}:host(limebb-trend-indicator:focus),:host(limebb-trend-indicator:focus-visible),:host(limebb-trend-indicator:focus-within){--limel-h-l-grid-template-rows-transition-speed:0.46s;--limel-h-l-grid-template-rows:1fr}:host(limebb-trend-indicator){--limel-h-l-grid-template-rows-transition-speed:0.3s;--limel-h-l-grid-template-rows:0fr}:host(limebb-trend-indicator:focus) limel-helper-line,:host(limebb-trend-indicator:focus-visible) limel-helper-line,:host(limebb-trend-indicator:focus-within) limel-helper-line,:host(limebb-trend-indicator:hover) limel-helper-line{will-change:grid-template-rows}';export{a as limebb_trend_indicator}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as t,H as i}from"./p-1556b545.js";import{c as r}from"./p-9b6ec98b.js";function a(e){for(const t of e.items)e.processedItems.push({type:"chat",item:t});return e}function o(e){const t=[];let i=e.newItemIndicatorInserted;for(const r of e.processedItems)"chat"===r.type&&e.lastVisitedTimestamp&&!i&&new Date(r.item.timestamp)<=e.lastVisitedTimestamp&&e.hasUnseenNotifications&&(t.push({type:"newItemIndicator"}),i=!0),t.push(r);return e.processedItems=t,e.newItemIndicatorInserted=i,e}function n(e){const t=[];let i=null,r=null;for(const a of e.processedItems)if("chat"===a.type){const o=new Date(a.item.timestamp),n=e.dateTimeFormatter.format(o,"date");n!==r&&(i&&t.push(i),i={type:"group",groupType:"dateGroup",heading:n,items:[]},r=n),i&&i.items.push(a)}else"newItemIndicator"===a.type&&(i?i.items.push(a):t.push(a));return i&&t.push(i),Object.assign(Object.assign({},e),{processedItems:t})}const s=class{constructor(t){e(this,t),this.items=[],this.order="oldest-on-top",this.processedItems=[]}handleItemsChange(){let e=null;var t,i,r,s;this.lastVisitedTimestamp&&(e="string"==typeof(s=this.lastVisitedTimestamp)?new Date(Date.parse(s)):new Date(s)),this.processedItems=(r={items:t=this.items,processedItems:[],lastVisitedTimestamp:i=e,dateTimeFormatter:this.dateTimeFormatter,newItemIndicatorInserted:!1,lastProcessedDate:null,hasUnseenNotifications:t.some((e=>i&&new Date(e.timestamp)>i))},[a,o,n].reduce(((e,t)=>t(e)),r)).processedItems}componentWillLoad(){this.handleItemsChange()}render(){return t(i,{key:"3412d92c13b51ad457ec2b070de46cd29372ce0b",class:{"is-empty":0===this.items.length&&!this.isTypingIndicatorVisible},"aria-busy":this.isBusy(),role:"log"},this.renderSpinner(),t("div",{key:"5d87e57a497b5eeae2e2765a1d594aa54222dc0d",class:"typing-indicator-height-animation"},t("div",{key:"6c430baf03095c83e032cc9c6680d2a897132cb0"},this.renderTypingIndicator())),this.renderChatItems())}renderSpinner(){if(this.loading)return t("limel-spinner",null)}renderTypingIndicator(){if(this.isTypingIndicatorVisible)return t("limebb-typing-indicator",null)}renderChatItems(){return this.processedItems.map((e=>{switch(e.type){case"group":return this.renderGroup(e);case"newItemIndicator":return this.renderIndicator();default:return null}}))}renderGroup(e){const i=e.items.map((e=>"chat"===e.type?this.renderChatItem(e.item):"newItemIndicator"===e.type?this.renderIndicator():void 0)),r="date-group-"+crypto.randomUUID(),a=`heading-${r}`,o=t("a",{id:a,class:"date-heading",role:"heading","aria-level":2},e.heading);return"oldest-on-top"===this.order?t("section",{class:"date-group",key:r,"aria-labelledby":a},i,o):t("section",{class:"date-group",key:r,"aria-labelledby":a},o,i)}renderChatItem(e){return t("limebb-chat-item",{platform:this.platform,context:this.context,item:e,helperText:e.helperText,hasError:e.hasError,key:e.id})}renderIndicator(){return t("div",{class:"new-items-indicator",role:"separator"},t("hr",null),t("h3",null,this.translator.get("webclient.new")))}isBusy(){return this.loading||this.isTypingIndicatorVisible?"true":"false"}get dateTimeFormatter(){return this.platform.get(r.DateTimeFormatter)}get translator(){return this.platform.get(r.Translate)}static get watchers(){return{items:["handleItemsChange"]}}};s.style='@charset "UTF-8";:host(limebb-chat-list){--limel-top-edge-fade-height:0.75rem;isolation:isolate;--limel-overflow-mask-vertical:linear-gradient(\n to bottom,\n transparent 0%,\n black calc(0% + var(--limel-top-edge-fade-height, 1rem)),\n black calc(100% - var(--limel-bottom-edge-fade-height, 1rem)),\n transparent 100%\n );-webkit-mask-image:var(--limel-overflow-mask-vertical);mask-image:var(--limel-overflow-mask-vertical);padding-top:var(--limel-top-edge-fade-height, 1rem);padding-bottom:var(--limel-bottom-edge-fade-height, 1rem);box-sizing:border-box;display:flex;gap:0.5rem;height:100%;width:100%;min-width:0;min-height:0;padding:var(--limel-top-edge-fade-height) 0.5rem;overflow:hidden auto}:host(limebb-chat-list.is-empty){padding:0}:host(limebb-chat-list[order=oldest-on-top]){flex-direction:column-reverse}:host(limebb-chat-list[order=newest-on-top]){flex-direction:column}*{box-sizing:border-box}limel-spinner{align-self:center;justify-self:center;margin:auto}.date-group{isolation:isolate;display:flex;flex-direction:inherit;gap:0.5rem}.date-heading{position:sticky;z-index:1;top:0.25rem;display:flex;border-radius:9rem;padding:0.25rem 0.5rem;margin:0 auto;width:fit-content;font-size:0.75rem;line-height:1;color:rgb(var(--contrast-900));backdrop-filter:blur(0.5rem);-webkit-backdrop-filter:blur(0.5rem);transition:color 0.2s ease, border-color 0.4s ease}.date-heading:hover{color:rgb(var(--contrast-1000));border-color:rgb(var(--contrast-500))}.date-heading:hover:before{opacity:1}.date-heading:before{transition:opacity 0.2s ease;content:"";position:absolute;z-index:-1;inset:0;opacity:0.6;border-radius:inherit;background-color:rgb(var(--contrast-100))}.new-items-indicator{position:relative;isolation:isolate;display:flex;align-items:center;justify-content:flex-end;margin:0.25rem 0}.new-items-indicator hr{border:none;position:absolute;width:100%;height:1px;background-color:rgb(var(--color-red-lighter))}.new-items-indicator h3{z-index:1;padding:0 0.5rem;border-radius:1rem;margin:0 1rem;font-size:small;line-height:0.75rem;text-transform:lowercase;color:rgb(var(--color-red-default));background-color:rgb(var(--contrast-100))}.typing-indicator-height-animation{--limebb-chat-typing-opacity-transition-speed:0.1s;--limebb-chat-typing-opacity-transition-delay:0s;--limebb-chat-typing-grid-template-rows-transition-speed:0.3s;position:sticky;top:0;z-index:1;transition:grid-template-rows var(--limebb-chat-typing-grid-template-rows-transition-speed) ease;display:grid;grid-template-rows:0}.typing-indicator-height-animation div{transition:opacity var(--limebb-chat-typing-opacity-transition-speed) ease var(--limebb-chat-typing-opacity-transition-delay);overflow:hidden;opacity:0}:host(limebb-chat-list[is-typing-indicator-visible]) .typing-indicator-height-animation{--limebb-chat-typing-opacity-transition-speed:0.4s;--limebb-chat-typing-opacity-transition-delay:0.3s;--limebb-chat-typing-grid-template-rows-transition-speed:0.46s;grid-template-rows:1.5rem}:host(limebb-chat-list[is-typing-indicator-visible]) .typing-indicator-height-animation div{opacity:1}.date-group limebb-chat-item{--limebb-promoted-action-bar-grid-template-rows:0fr}:host(limebb-chat-list[order=oldest-on-top]) .date-group:first-of-type limebb-chat-item:first-of-type{--limebb-promoted-action-bar-grid-template-rows:1fr}:host(limebb-chat-list[order=newest-on-top]) .date-group:first-of-type limebb-chat-item:first-of-type{--limebb-promoted-action-bar-grid-template-rows:1fr}';export{s as limebb_chat_list}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as t,r as o,c as e}from"./p-
|
|
1
|
+
import{h as t,r as o,c as e}from"./p-1556b545.js";import{c as i}from"./p-9b6ec98b.js";import{g as n}from"./p-8044ffbd.js";import"./p-b31772c8.js";import"./p-c40a3f4b.js";const r=(o,e)=>t(o.name,Object.assign({class:o.class},function(t){let o={};return t.props&&(o=Object.assign({},t.props)),Object.assign({context:t.context,platform:t.platform},o)}(o),{key:o.key}),e),s=class{constructor(t){o(this,t),this.change=e(this,"change",7),this.value={},this.type="component",this.configViewType="code",this.findConfigComponent=t=>{var o,e;return"component"===this.type?null===(o=this.registry.getAll().find((o=>o.name===t)))||void 0===o?void 0:o.configComponent:"command"===this.type?null===(e=this.commandbus.getAll().find((o=>o.id===t)))||void 0===e?void 0:e.configComponent:void 0},this.handleChangeMode=t=>{t.stopPropagation(),this.configViewType=t.detail.id},this.handleCodeEditorChange=t=>{t.stopPropagation();try{const o=JSON.parse(t.detail);this.change.emit(o)}catch(t){}}}componentWillLoad(){this.configComponent=this.getComponentName()}componentShouldUpdate(t,o,e){return"formInfo"!==e}watchFormInfo(){this.configComponent=this.getComponentName()}watchconfigComponent(t,o){t&&!o&&(this.configViewType="config"),t||(this.configViewType="code")}getComponentName(){var t,o,e;const i=[...null!==(o=null===(t=this.formInfo)||void 0===t?void 0:t.schemaPath.slice(0,-1))&&void 0!==o?o:[],this.getNameField()],r=n(null===(e=this.formInfo)||void 0===e?void 0:e.rootValue,i),s=this.findConfigComponent(r);if(s&&customElements.get(s.name))return s}render(){return[this.renderHeader(),this.renderContent()]}renderHeader(){let o=[];return this.configComponent&&(o=[{id:"config",title:"Config",selected:"config"===this.configViewType},{id:"code",title:"Code",selected:"code"===this.configViewType}]),t("limel-header",{icon:"edit_property",heading:this.label,subheading:this.helperText},t("limel-button-group",{slot:"actions",value:o,onChange:this.handleChangeMode}))}renderContent(){return"config"===this.configViewType?this.renderConfigComponent():this.renderCodeEditor()}renderCodeEditor(){return t("limel-code-editor",{value:JSON.stringify(this.value,null,"\t"),language:"json",readonly:this.readonly,lineNumbers:!0,fold:!0,lint:!0,onChange:this.handleCodeEditorChange})}renderConfigComponent(){var o,e;return t(r,{class:"config-component",platform:this.platform,context:this.context,name:null===(o=this.configComponent)||void 0===o?void 0:o.name,props:Object.assign(Object.assign({},null===(e=this.configComponent)||void 0===e?void 0:e.props),{value:this.value,required:this.required,readonly:this.readonly,disabled:this.disabled,label:this.label,helperText:this.helperText,formInfo:this.formInfo})})}getNameField(){return this.nameField?this.nameField:{component:"name",command:"id"}[this.type]}get registry(){return this.platform.get(i.WebComponentRegistry)}get commandbus(){return this.platform.get(i.CommandBus)}static get watchers(){return{formInfo:["watchFormInfo"],configComponent:["watchconfigComponent"]}}};s.style=":host(*){--header-background-color:rgb(var(--contrast-600));display:flex;flex-direction:column;border:1px dashed rgb(var(--contrast-700));overflow:clip;border-radius:0.75rem;background-color:rgb(var(--contrast-500))}*{box-sizing:border-box}.label{margin-top:1rem;margin-bottom:1rem}.config-component{display:grid;column-gap:1rem;row-gap:1rem;margin:1rem;grid-template-columns:repeat(3, minmax(0, 1fr))}";export{s as limebb_component_config}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,g as o,h as r}from"./p-
|
|
1
|
+
import{r as t,g as o,h as r}from"./p-1556b545.js";import{c as e}from"./p-9b6ec98b.js";function i(t,o){if(o(t))return t;let r=t.parentElement||t.parentNode;var e;return(null==(e=r)?void 0:e.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&(r=r.host),r?i(r,o):void 0}const n=class{constructor(o){t(this,o)}connectedCallback(){const t=i(o(this),this.hasPlatform);t&&this.loadLimeObject(t.platform)}hasPlatform(t){return"platform"in t&&!!t.platform&&"object"==typeof t.platform}async loadLimeObject(t){const o=t.get(e.LimeObjectRepository);if(this.limeobject=o.getObject(this.limetype,this.objectid),!this.limeobject){try{await o.loadObject(this.limetype,this.objectid)}catch(t){console.error("Could not load mentioned object")}this.limeobject=o.getObject(this.limetype,this.objectid)}}render(){return this.limeobject?this.renderLimeObject(this.limeobject):this.renderSlot()}renderLimeObject(t){return r("a",{href:`object/${this.limetype}/${this.objectid}`},t.descriptive,this.renderSlot({hidden:!0}))}renderSlot(t={}){return r("span",Object.assign({},t),r("slot",null))}};n.style=':host(limebb-mention){display:inline}a{transition:background-color 0.2s ease;white-space:normal;overflow-wrap:break-word;word-break:break-word;padding:0 0.125rem;border-radius:0.25rem;text-decoration:none;color:rgb(var(--color-blue-default));background-color:rgb(var(--color-blue-default), 0.06)}a:hover{background-color:rgb(var(--color-blue-default), 0.16)}a:before,span:before{content:"@";opacity:0.7}';export{n as limebb_mention}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as e}from"./p-1556b545.js";import{h as o,c}from"./p-9b6ec98b.js";import{H as s}from"./p-66352a1e.js";let i=class{constructor(t){this.itemId=t}};i=function(t,e,o,c){var s,i=arguments.length,l=i<3?e:null===c?c=Object.getOwnPropertyDescriptor(e,o):c;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)l=Reflect.decorate(t,e,o,c);else for(var n=t.length-1;n>=0;n--)(s=t[n])&&(l=(i<3?s(l):i>3?s(e,o,l):s(e,o))||l);return i>3&&l&&Object.defineProperty(e,o,l),l}([o({id:"limebb-feed.highlight-item"})],i);const l=class{constructor(o){t(this,o),this.loaded=e(this,"loaded",7)}connectedCallback(){}async componentWillLoad(){const t=new s;this.platform.register(s.SERVICE_NAME,t),this.commandBus.register(i,t),this.loaded.emit()}componentWillUpdate(){}disconnectedCallback(){}get commandBus(){return this.platform.get(c.CommandBus)}};export{l as limebb_loader}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,c as r,h as o,H as i}from"./p-
|
|
1
|
+
import{r as e,c as r,h as o,H as i}from"./p-1556b545.js";import{c as s}from"./p-9b6ec98b.js";const a=class{constructor(i){e(this,i),this.interact=r(this,"interact",7),this.renderRelations=()=>{var e,r,i;if(null===(r=null===(e=this.item)||void 0===e?void 0:e.relations)||void 0===r?void 0:r.length)return o("limel-chip-set",{value:null===(i=this.item)||void 0===i?void 0:i.relations})},this.renderAssigneesAvatar=e=>e.picture?o("img",{loading:"lazy",src:e.picture,alt:e.name.text}):o("limel-icon",{name:e.icon.name,style:{color:`${e.icon.color}`,"background-color":`${e.icon.backgroundColor}`}}),this.createMenuItem=e=>{var r,o;return"separator"in e?e:{value:e,text:null!==(r=e.label)&&void 0!==r?r:"",secondaryText:e.description,disabled:e.disabled,icon:null!==(o=e.icon)&&void 0!==o?o:""}},this.handleMenuItemSelect=e=>{var r;e.stopPropagation();const o=null===(r=e.detail.value)||void 0===r?void 0:r.command;o&&this.commandbus.handle(o)},this.handleKanbanItemClick=()=>{this.interact.emit(this.item)}}render(){var e,r;return o(i,{key:"dd22e6855c6a5a72a02fb1edd17b2baf3f94020d",id:this.item.id.toString(),class:{"has-unpromoted-actions":!!(null===(e=this.item.unpromotedActions)||void 0===e?void 0:e.length),"is-selected":!!(null===(r=this.item)||void 0===r?void 0:r.selected)},style:{"--limebb-kanban-item-color-code":`${this.item.color}`},onClick:this.handleKanbanItemClick},this.renderHeader(),this.renderContent(),this.renderFooter())}renderHeader(){return o("div",{class:"header"},this.renderIcon(),this.renderHeading(),this.renderUnpromotedActionsMenu())}renderIcon(){var e,r,i,s;if(this.item.icon)return o("limel-icon",{class:"icon",badge:!0,name:null!==(r=null===(e=this.item.icon)||void 0===e?void 0:e.name)&&void 0!==r?r:"dot_circle",style:{color:`${null===(i=this.item.icon)||void 0===i?void 0:i.color}`,"background-color":`${null===(s=this.item.icon)||void 0===s?void 0:s.backgroundColor}`}})}renderContent(){return o("div",{class:"content"},this.renderValue(),this.renderRelations())}renderHeading(){if(this.item.heading)return o("limel-markdown",{class:"heading",value:this.item.heading})}renderValue(){if(this.item.value)return o("limel-markdown",{class:"body",value:this.item.value})}renderUnpromotedActionsMenu(){var e,r;if(!(null===(e=this.item.unpromotedActions)||void 0===e?void 0:e.length))return;const i=this.item.unpromotedActions.map(this.createMenuItem);return o("limel-menu",{class:"unpromoted-actions-menu",items:i,openDirection:"bottom-end",onSelect:this.handleMenuItemSelect},o("limel-icon",{class:"actions",name:"menu_2",slot:"trigger",size:"small",id:"item-actions-tooltip"}),o("limel-tooltip",{elementId:"item-actions-tooltip",label:null===(r=this.translator)||void 0===r?void 0:r.get("webclient.more-actions"),openDirection:"top-end"}))}renderFooter(){var e;if(null===(e=this.item.assignees)||void 0===e?void 0:e.length)return o("div",{class:"footer"},this.renderAssignees())}renderAssignees(){var e;if(null===(e=this.item.assignees)||void 0===e?void 0:e.length)return o("div",{class:"assignees"},this.item.assignees.map((e=>{var r;return o("limebb-summary-popover",Object.assign({icon:null===(r=e.icon)||void 0===r?void 0:r.name},e.picture&&{image:{src:e.picture,alt:e.name.text||""}},{heading:e.name.text,value:this.createLinkToAssignee(e)}),o("a",{slot:"trigger",class:"assignee",href:e.name.href,title:e.name.text},this.renderAssigneesAvatar(e),o("span",null,e.name.text)))})))}createLinkToAssignee(e){const r=this.translator.get("webclient.actions.goto-object",{limetype:": <br><b>"+e.name.text+"</b>"});return`<a class="author" href="${e.name.href}" title="${e.name.text}">${r}</a>`}get translator(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(s.Translate)}get commandbus(){var e;return null===(e=this.platform)||void 0===e?void 0:e.get(s.CommandBus)}};a.style='@charset "UTF-8";*,*:before,*:after{box-sizing:border-box}:host(limebb-kanban-item){position:relative;box-sizing:border-box;display:flex;flex-direction:column;border-radius:0.5rem}:host(limebb-kanban-item):before{content:"";display:block;position:absolute;top:1rem;bottom:1rem;right:0;transform:translateX(50%);width:0.25rem;border-radius:1rem;background-color:var(--limebb-kanban-item-color-code)}.content{padding-top:0.25rem;min-height:3rem}.header{display:flex;align-items:flex-start;gap:0.5rem;min-height:1.75rem;padding:0.25rem 0.5rem;border-radius:0.5rem 0.5rem 0 0;background-color:rgb(var(--contrast-300))}.header a{position:relative;cursor:pointer;transition:color 0.2s ease;color:var(--mdc-theme-primary);text-decoration:none}.header a:before{transition:opacity 0.2s ease, transform 0.3s ease-out;content:"";position:absolute;inset:auto 0 0 0;width:calc(100% - 0.5rem);margin:auto;height:0.125rem;border-radius:1rem;background-color:currentColor;opacity:0;transform:scale(0.6)}.header a:hover{color:rgb(var(--color-teal-light))}.header a:hover:before{opacity:0.3;transform:scale(1)}.heading{--markdown-hyperlink-color:var(--mdc-theme-primary);--markdown-hyperlink-color--hovered:rgb(var(--color-teal-light))}.unpromoted-actions-menu{margin:-0.5rem -0.5rem -0.25rem auto}.body{display:block;padding:0.5rem;padding-top:0;color:rgb(var(--contrast-1100))}limel-chip-set{--limel-chip-size:1.5rem;display:block;margin-left:-0.5rem;margin-right:0.5rem;padding-bottom:0.5rem}.footer{position:relative;display:flex;align-items:center;gap:0.5rem;padding:0.25rem 0.25rem 0.125rem;margin:0 0.25rem;border-top:1px dashed rgb(var(--contrast-300))}.header limel-icon,.footer limel-icon{flex-shrink:0;width:1.25rem;height:1.25rem}.header .actions{margin:0.5rem 0.25rem 0}.header .actions:hover{transition:color var(--limel-clickable-transition-speed, 0.4s) ease, background-color var(--limel-clickable-transition-speed, 0.4s) ease, box-shadow var(--limel-clickable-transform-speed, 0.4s) ease, transform var(--limel-clickable-transform-speed, 0.4s) var(--limel-clickable-transform-timing-function, ease);cursor:pointer;color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-normal)}.header .actions:hover:hover,.header .actions:hover:focus,.header .actions:hover:focus-visible{will-change:color, background-color, box-shadow, transform}.header .actions:hover:hover{transform:translate3d(0, -0.04rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}.header .actions:hover:active{--limel-clickable-transform-timing-function:cubic-bezier(\n 0.83,\n -0.15,\n 0.49,\n 1.16\n );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}.header .actions:hover:hover,.header .actions:hover:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}.footer img{border-radius:50%;object-fit:cover;box-shadow:0 0 0 1px rgb(var(--contrast-800), 0.4);flex-shrink:0;width:1.25rem;height:1.25rem}.assignees{display:flex;align-items:center;gap:0.25rem}.assignees:has(>:nth-child(2)) span{display:none}.assignees:has(>:nth-child(2)) img,.assignees:has(>:nth-child(2)) limel-icon{margin-right:-0.5rem}.assignees:hover img,.assignees:hover limel-icon,.assignees:focus-within img,.assignees:focus-within limel-icon{margin-right:0rem}.assignees:hover .assignee:not(:hover):not(:focus-visible) img,.assignees:hover .assignee:not(:hover):not(:focus-visible) limel-icon,.assignees:focus-within .assignee:not(:hover):not(:focus-visible) img,.assignees:focus-within .assignee:not(:hover):not(:focus-visible) limel-icon{filter:grayscale(1);opacity:0.6}.assignee{transition:color var(--limel-clickable-transition-speed, 0.4s) ease, background-color var(--limel-clickable-transition-speed, 0.4s) ease, box-shadow var(--limel-clickable-transform-speed, 0.4s) ease, transform var(--limel-clickable-transform-speed, 0.4s) var(--limel-clickable-transform-timing-function, ease);cursor:pointer;color:var(--limel-theme-on-surface-color);background-color:transparent;display:flex;align-items:center;text-decoration:none;gap:0.25rem;margin-left:0;border-radius:1rem}.assignee:hover,.assignee:focus,.assignee:focus-visible{will-change:color, background-color, box-shadow, transform}.assignee:hover{transform:translate3d(0, 0.01rem, 0);color:var(--limel-theme-on-surface-color);background-color:var(--lime-elevated-surface-background-color);box-shadow:var(--button-shadow-hovered)}.assignee:active{--limel-clickable-transform-timing-function:cubic-bezier(\n 0.83,\n -0.15,\n 0.49,\n 1.16\n );transform:translate3d(0, 0.05rem, 0);box-shadow:var(--button-shadow-pressed)}.assignee:hover,.assignee:active{--limel-clickable-transition-speed:0.2s;--limel-clickable-transform-speed:0.16s}.assignee:focus{outline:none}.assignee:focus-visible{outline:none;box-shadow:var(--shadow-depth-8-focused)}.assignee limel-icon,.assignee img{transition:margin 0.2s ease, opacity 0.2s ease, filter 0.2s ease}.assignee limel-icon{padding:0.125rem;box-shadow:0 0 0 1px rgb(var(--contrast-800), 0.4);background-color:rgb(var(--contrast-100))}.assignee span{font-size:0.75rem;color:rgb(var(--contrast-900));padding-right:0.5rem;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}';export{a as limebb_kanban_item}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as e,h as i}from"./p-
|
|
1
|
+
import{r as t,c as e,h as i}from"./p-1556b545.js";const l=class{constructor(i){t(this,i),this.change=e(this,"change",7),this.handleChangeType=t=>{t.stopPropagation();const e=t.detail.id;"none"===e?this.change.emit():this.change.emit("date"===e||"relative-date"===e?{type:e}:"percent"===e?{type:"number",options:{style:"percent"},suffix:["percentSign"]}:{type:"number",options:{style:e}})},this.isValidButton=t=>!this.type||"none"===t.id||"none"!==this.type&&("date"===this.type?t.id.includes("date"):!t.id.includes("date"))}render(){var t,e,l,n,o,d,s,r,a,u,c;const m=[{id:"none",title:"No formatting",selected:!(null===(t=this.value)||void 0===t?void 0:t.type)},{id:"currency",title:"Currency",selected:"number"===(null===(e=this.value)||void 0===e?void 0:e.type)&&"currency"===(null===(l=this.value.options)||void 0===l?void 0:l.style)},{id:"decimal",title:"Decimal",selected:"number"===(null===(n=this.value)||void 0===n?void 0:n.type)&&"decimal"===(null===(o=this.value.options)||void 0===o?void 0:o.style)},{id:"percent",title:"Percent",selected:"number"===(null===(d=this.value)||void 0===d?void 0:d.type)&&"percent"===(null===(s=this.value.options)||void 0===s?void 0:s.style)},{id:"unit",title:"Unit",selected:"number"===(null===(r=this.value)||void 0===r?void 0:r.type)&&"unit"===(null===(a=this.value.options)||void 0===a?void 0:a.style)},{id:"date",title:"Date",selected:"date"===(null===(u=this.value)||void 0===u?void 0:u.type)},{id:"relative-date",title:"Relative date",selected:"relative-date"===(null===(c=this.value)||void 0===c?void 0:c.type)}];return[i("limel-button-group",{key:"b1448fef0bbb3cd7cf667fc7a064166cb3ccbd3e",value:m.filter(this.isValidButton),onChange:this.handleChangeType}),this.renderFormatConfig()]}renderFormatConfig(){var t,e;if(!(null===(t=this.value)||void 0===t?void 0:t.type))return;let l=this.value.type;this.isNumberFormat(this.value)&&(l=null===(e=this.value.options)||void 0===e?void 0:e.style);const n=`limebb-info-tile-${l}-format`;return customElements.get(n)?i(n,{platform:this.platform,context:this.context,class:"format",value:this.value}):void 0}isNumberFormat(t){return"number"===(null==t?void 0:t.type)}};l.style=":host(limebb-info-tile-format){display:grid;gap:1rem}limel-button-group{grid-column:1/-1}.format{display:grid;gap:0.5rem;grid-template-columns:repeat(auto-fit, minmax(8rem, 1fr))}";export{l as limebb_info_tile_format}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as i,h as
|
|
1
|
+
import{r as t,c as i,h as e,g as s}from"./p-1556b545.js";import{c as r}from"./p-9b6ec98b.js";import{E as o}from"./p-463d3174.js";import{n as a}from"./p-7c9484b1.js";const h=class{constructor(e){t(this,e),this.change=i(this,"change",7),this.layout="grid",this.handleChangeFilter=t=>{t.stopPropagation(),this.filter=t.detail},this.isIncluded=(t,i)=>this.isSeparator(t)?!(0===i&&!t.text):!this.filter||t.text.toLocaleLowerCase().includes(this.filter.toLocaleLowerCase()),this.isEmptyGroup=(t,i,e)=>{if(!this.isSeparator(t))return!1;const s=e[i+1];return!s||this.isSeparator(s)},this.handleChange=t=>{t.preventDefault(),this.handleItemChange(t.detail)},this.handleKeyDown=t=>{var i;if(t.key!==o)return;const e=null===(i=this.host.shadowRoot)||void 0===i?void 0:i.querySelector("limel-list"),s=this.getItems().filter(a(this.isSeparator));e&&s.length>0&&(e.focus(),this.handleItemChange(s[0]))}}render(){return[e("limel-input-field",{key:"c2b0217009767c5ad1362993e0ca6f5543672ec2",tabIndex:0,value:this.filter,type:"search","leading-icon":"search",placeholder:this.translator.get("webclient.global-search-route"),onChange:this.handleChangeFilter,onKeyDown:this.handleKeyDown}),e("limel-list",{key:"5b39efeb64b3ba67c5efdd9c278795364dfbdbaa",items:this.getItems(),type:"selectable",class:{"has-grid-layout":"grid"===this.layout},onChange:this.handleChange})]}isSeparator(t){return!!t&&"object"==typeof t&&"separator"in t}get navigator(){return this.platform.get(r.Navigator)}get translator(){var t;return null===(t=this.platform)||void 0===t?void 0:t.get(r.Translate)}handleItemChange(t){this.change.emit(t),this.filter=void 0,this.navigator.navigate(t.path)}getItems(){return this.items.filter(this.isIncluded).filter(a(this.isEmptyGroup))}static get delegatesFocus(){return!0}get host(){return s(this)}};h.style=":host(limebb-browser){isolation:isolate;display:flex;flex-direction:column;background-color:rgba(var(--contrast-100))}limel-input-field{position:sticky;top:0;z-index:1;padding:0.5rem 0.75rem;background-color:rgba(var(--contrast-100), 0.75);backdrop-filter:blur(0.25rem);-webkit-backdrop-filter:blur(0.25rem)}";export{h as limebb_browser}
|