@paperless/core 1.58.0 → 1.59.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 +22 -0
- package/dist/build/{p-5298190b.entry.js → p-00d4647f.entry.js} +2 -2
- package/dist/build/p-00d4647f.entry.js.map +1 -0
- package/dist/build/p-d40ee88e.entry.js +2 -0
- package/dist/build/p-d40ee88e.entry.js.map +1 -0
- package/dist/build/paperless.esm.js +1 -1
- package/dist/cjs/p-card-header.cjs.entry.js +6 -1
- package/dist/cjs/p-card-header.cjs.entry.js.map +1 -1
- package/dist/cjs/p-tooltip.cjs.entry.js +5 -1
- package/dist/cjs/p-tooltip.cjs.entry.js.map +1 -1
- package/dist/collection/components/atoms/card-header/card-header.component.js +6 -1
- package/dist/collection/components/atoms/card-header/card-header.component.js.map +1 -1
- package/dist/collection/components/atoms/tooltip/tooltip.component.js +5 -1
- package/dist/collection/components/atoms/tooltip/tooltip.component.js.map +1 -1
- package/dist/components/p-card-header.js +6 -1
- package/dist/components/p-card-header.js.map +1 -1
- package/dist/components/tooltip.component.js +5 -1
- package/dist/components/tooltip.component.js.map +1 -1
- package/dist/esm/p-card-header.entry.js +7 -2
- package/dist/esm/p-card-header.entry.js.map +1 -1
- package/dist/esm/p-tooltip.entry.js +5 -1
- package/dist/esm/p-tooltip.entry.js.map +1 -1
- package/dist/index.html +1 -1
- package/dist/paperless/{p-5298190b.entry.js → p-00d4647f.entry.js} +2 -2
- package/dist/paperless/p-00d4647f.entry.js.map +1 -0
- package/dist/paperless/p-d40ee88e.entry.js +2 -0
- package/dist/paperless/p-d40ee88e.entry.js.map +1 -0
- package/dist/paperless/paperless.esm.js +1 -1
- package/dist/sw.js +1 -1
- package/dist/sw.js.map +1 -1
- package/dist/types/components/atoms/card-header/card-header.component.d.ts +6 -0
- package/dist/types/components/atoms/tooltip/tooltip.component.d.ts +2 -0
- package/hydrate/index.js +11 -2
- package/package.json +1 -1
- package/dist/build/p-5298190b.entry.js.map +0 -1
- package/dist/build/p-f37781ca.entry.js +0 -2
- package/dist/build/p-f37781ca.entry.js.map +0 -1
- package/dist/paperless/p-5298190b.entry.js.map +0 -1
- package/dist/paperless/p-f37781ca.entry.js +0 -2
- package/dist/paperless/p-f37781ca.entry.js.map +0 -1
|
@@ -41,9 +41,11 @@ export declare class Tooltip {
|
|
|
41
41
|
* The host element
|
|
42
42
|
*/
|
|
43
43
|
private _el;
|
|
44
|
+
private _hasContentSlot;
|
|
44
45
|
private _loaded;
|
|
45
46
|
private _popover;
|
|
46
47
|
private _cleanup;
|
|
48
|
+
componentWillLoad(): void;
|
|
47
49
|
componentShouldUpdate(): void;
|
|
48
50
|
disconnectedCallback(): void;
|
|
49
51
|
render(): any;
|
package/hydrate/index.js
CHANGED
|
@@ -12039,13 +12039,18 @@ const cardHeaderComponentCss = ".mx-4{margin-left:1rem!important;margin-right:1r
|
|
|
12039
12039
|
class CardHeader {
|
|
12040
12040
|
constructor(hostRef) {
|
|
12041
12041
|
registerInstance(this, hostRef);
|
|
12042
|
+
this._hasContentSlot = false;
|
|
12042
12043
|
this.header = undefined;
|
|
12043
12044
|
this.arrow = false;
|
|
12044
12045
|
}
|
|
12046
|
+
componentWillLoad() {
|
|
12047
|
+
this._hasContentSlot = !!this._el.querySelector(':scope > [slot="slot"]');
|
|
12048
|
+
}
|
|
12045
12049
|
render() {
|
|
12046
12050
|
var _a, _b;
|
|
12047
|
-
return (hAsync(Host, { class: 'p-card-header' }, hAsync("slot", { name: 'prefix' }), (((_a = this.header) === null || _a === void 0 ? void 0 : _a.length) || this.arrow) && (hAsync("div", { class: 'title' }, hAsync("span", null, (_b = this.header) !== null && _b !== void 0 ? _b : ''), this.arrow && (hAsync("p-icon", { variant: 'arrow', class: 'group-hover:text-indigo' })))), hAsync("slot", { name: 'suffix' })));
|
|
12051
|
+
return (hAsync(Host, { class: 'p-card-header' }, hAsync("slot", { name: 'prefix' }), (((_a = this.header) === null || _a === void 0 ? void 0 : _a.length) || this.arrow) && (hAsync("div", { class: 'title' }, hAsync("span", null, ((_b = this.header) !== null && _b !== void 0 ? _b : this._hasContentSlot) ? (hAsync("slot", { name: 'content' })) : ('')), this.arrow && (hAsync("p-icon", { variant: 'arrow', class: 'group-hover:text-indigo' })))), hAsync("slot", { name: 'suffix' })));
|
|
12048
12052
|
}
|
|
12053
|
+
get _el() { return getElement(this); }
|
|
12049
12054
|
static get style() { return cardHeaderComponentCss; }
|
|
12050
12055
|
static get cmpMeta() { return {
|
|
12051
12056
|
"$flags$": 4,
|
|
@@ -23829,6 +23834,7 @@ class Tooltip {
|
|
|
23829
23834
|
constructor(hostRef) {
|
|
23830
23835
|
registerInstance(this, hostRef);
|
|
23831
23836
|
this.isOpen = createEvent(this, "isOpen", 3);
|
|
23837
|
+
this._hasContentSlot = false;
|
|
23832
23838
|
this._loaded = false;
|
|
23833
23839
|
this.variant = 'hover';
|
|
23834
23840
|
this.content = null;
|
|
@@ -23839,6 +23845,9 @@ class Tooltip {
|
|
|
23839
23845
|
this.show = false;
|
|
23840
23846
|
this.canManuallyClose = true;
|
|
23841
23847
|
}
|
|
23848
|
+
componentWillLoad() {
|
|
23849
|
+
this._hasContentSlot = !!this._el.querySelector(':scope > [slot="content"]');
|
|
23850
|
+
}
|
|
23842
23851
|
componentShouldUpdate() {
|
|
23843
23852
|
this._update();
|
|
23844
23853
|
}
|
|
@@ -23892,7 +23901,7 @@ class Tooltip {
|
|
|
23892
23901
|
if (!this._loaded) {
|
|
23893
23902
|
return;
|
|
23894
23903
|
}
|
|
23895
|
-
if (!((_a = this.content) === null || _a === void 0 ? void 0 : _a.length)) {
|
|
23904
|
+
if (!((_a = this.content) === null || _a === void 0 ? void 0 : _a.length) && !this._hasContentSlot) {
|
|
23896
23905
|
if (this._popover.hasAttribute('data-show')) {
|
|
23897
23906
|
this._hide();
|
|
23898
23907
|
}
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["tooltipComponentCss","Tooltip","this","_loaded","componentShouldUpdate","_update","disconnectedCallback","_cleanup","render","h","Host","class","name","variant","role","placement","strategy","ref","el","_load","content","clickHandler","enableUserInput","_popover","hasAttribute","_show","documentClickHandler","canManuallyClose","show","_hide","mouseEnterHandler","mouseLeaveHandler","onShowChange","_a","length","autoUpdate","_el","setAttribute","isOpen","emit","removeAttribute","popover","setTimeout","arrowEl","querySelector","computePosition","middleware","offset","flip","shift","arrow","element","padding","then","x","y","middlewareData","dataset","Object","assign","style","top","left","indexOf"],"sources":["src/components/atoms/tooltip/tooltip.component.scss?tag=p-tooltip&encapsulation=shadow","src/components/atoms/tooltip/tooltip.component.tsx"],"sourcesContent":[":host {\n\t@apply flex cursor-pointer;\n\n\t.popover-container {\n\t\t@apply relative h-0 w-0;\n\t\t.popover {\n\t\t\t@apply left-0 top-0 z-tooltip inline-block rounded bg-white px-3 py-2 text-xs font-medium opacity-0 drop-shadow-4 transition-opacity;\n\t\t\t@apply pointer-events-none;\n\t\t\twidth: max-content;\n\t\t\tmax-width: 14.5rem;\n\n\t\t\t&.variant-hover,\n\t\t\t&.variant-error,\n\t\t\t&.variant-error-element {\n\t\t\t\t@apply bg-storm py-1 text-white;\n\t\t\t}\n\n\t\t\t&.variant-error,\n\t\t\t&.variant-error-element {\n\t\t\t\t@apply bg-negative uppercase tracking-wider;\n\t\t\t}\n\n\t\t\t&[data-show] {\n\t\t\t\t@apply pointer-events-auto opacity-100;\n\t\t\t}\n\n\t\t\t.arrow,\n\t\t\t.arrow::before {\n\t\t\t\tbackground: inherit;\n\t\t\t\t@apply absolute h-2 w-2;\n\t\t\t}\n\n\t\t\t.arrow {\n\t\t\t\tvisibility: hidden;\n\n\t\t\t\t&::before {\n\t\t\t\t\t@apply visible rotate-45 transform;\n\t\t\t\t\tcontent: '';\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&[data-strategy='fixed'] {\n\t\t\t\t@apply fixed;\n\t\t\t}\n\n\t\t\t&[data-strategy='absolute'] {\n\t\t\t\t@apply absolute;\n\t\t\t}\n\n\t\t\t&[data-placement^='top'] > .arrow {\n\t\t\t\t@apply -bottom-1;\n\t\t\t}\n\n\t\t\t&[data-placement^='bottom'] > .arrow {\n\t\t\t\t@apply -top-1;\n\t\t\t}\n\n\t\t\t&[data-placement^='left'] > .arrow {\n\t\t\t\t@apply -right-1;\n\t\t\t}\n\n\t\t\t&[data-placement^='right'] > .arrow {\n\t\t\t\t@apply -left-1;\n\t\t\t}\n\t\t}\n\t}\n}\n","import {\n\tarrow,\n\tautoUpdate,\n\tcomputePosition,\n\tflip,\n\toffset,\n\tPlacement,\n\tshift,\n\tStrategy,\n} from '@floating-ui/dom';\nimport {\n\tComponent,\n\tElement,\n\tEvent,\n\tEventEmitter,\n\th,\n\tHost,\n\tListen,\n\tProp,\n\tWatch,\n} from '@stencil/core';\n\n@Component({\n\ttag: 'p-tooltip',\n\tstyleUrl: 'tooltip.component.scss',\n\tshadow: true,\n})\nexport class Tooltip {\n\t/**\n\t * The variant of the popover\n\t */\n\t@Prop() variant: 'hover' | 'click' | 'error' | 'error-element' = 'hover';\n\n\t/**\n\t * The content of the popover\n\t */\n\t@Prop() content: any = null;\n\n\t/**\n\t * The placement of the popover\n\t */\n\t@Prop() placement: Placement = 'top';\n\n\t/**\n\t * The offset of the popover\n\t */\n\t@Prop() offset: number = 8;\n\n\t/**\n\t * The strategy of the popover placement\n\t */\n\t@Prop() strategy: Strategy = 'absolute';\n\n\t/**\n\t * Wether the tooltip can be shown by user input\n\t */\n\t@Prop() enableUserInput: boolean = true;\n\n\t/**\n\t * Wether to show the popover\n\t */\n\t@Prop() show: boolean = false;\n\n\t/**\n\t * Wether to someone can manually close the popover\n\t */\n\t@Prop() canManuallyClose: boolean = true;\n\n\t/**\n\t * Open change event\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tisOpen: EventEmitter<boolean>;\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\tprivate _loaded = false;\n\tprivate _popover: HTMLElement;\n\tprivate _cleanup: () => void;\n\n\tcomponentShouldUpdate() {\n\t\tthis._update();\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-popover'>\n\t\t\t\t<slot name='trigger' />\n\t\t\t\t<div class='popover-container'>\n\t\t\t\t\t<div\n\t\t\t\t\t\tclass={`popover variant-${this.variant}`}\n\t\t\t\t\t\trole='popover'\n\t\t\t\t\t\tdata-placement={this.placement}\n\t\t\t\t\t\tdata-strategy={this.strategy}\n\t\t\t\t\t\tref={el => this._load(el)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.content ? this.content : <slot name='content' />}\n\t\t\t\t\t\t<div class='arrow'></div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t@Listen('click', { capture: true })\n\tprotected clickHandler() {\n\t\tif (this.variant === 'hover' || !this.enableUserInput) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._popover.hasAttribute('data-show')) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\t@Listen('click', { target: 'document', capture: true })\n\tprotected documentClickHandler() {\n\t\tif (this.variant === 'hover' || !this.canManuallyClose || this.show) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this._popover.hasAttribute('data-show')) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._hide();\n\t}\n\n\t@Listen('mouseenter')\n\t@Listen('focus')\n\tprotected mouseEnterHandler() {\n\t\tif (this.variant !== 'hover' || !this.enableUserInput) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\t@Listen('mouseleave')\n\t@Listen('blur')\n\tprotected mouseLeaveHandler() {\n\t\tif (this.show || this.variant !== 'hover' || !this.enableUserInput) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._hide();\n\t}\n\n\t@Watch('show')\n\tonShowChange(show: boolean) {\n\t\tif (show && !this._popover.hasAttribute('data-show')) {\n\t\t\treturn this._show();\n\t\t}\n\n\t\treturn this._hide();\n\t}\n\n\tprivate _show() {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this.content?.length) {\n\t\t\tif (this._popover.hasAttribute('data-show')) {\n\t\t\t\tthis._hide();\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tthis._cleanup = autoUpdate(this._el, this._popover, () => this._update());\n\t\t// Make the popover visible\n\t\tthis._popover.setAttribute('data-show', '');\n\n\t\t// Update its position\n\t\tthis.isOpen.emit(true);\n\t}\n\n\tprivate _hide() {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\n\t\t// Hide the popover\n\t\tthis._popover.removeAttribute('data-show');\n\t\tthis.isOpen.emit(false);\n\t}\n\n\tprivate _load(popover: HTMLElement) {\n\t\tthis._popover = popover;\n\t\tif (popover) {\n\t\t\tthis._update();\n\t\t\tthis._loaded = true;\n\n\t\t\tif (this.show) {\n\t\t\t\tsetTimeout(() => this._show(), 100);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _update() {\n\t\tif (!this._popover) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst arrowEl = this._popover.querySelector('.arrow') as HTMLElement;\n\t\tif (!arrowEl) {\n\t\t\treturn;\n\t\t}\n\n\t\tcomputePosition(this._el, this._popover, {\n\t\t\tplacement:\n\t\t\t\tthis.variant === 'error' || this.variant === 'error-element'\n\t\t\t\t\t? 'top-end'\n\t\t\t\t\t: this.placement,\n\t\t\tstrategy: this.strategy,\n\n\t\t\tmiddleware: [\n\t\t\t\toffset(this.variant === 'error' ? 14 : this.offset),\n\t\t\t\tflip(),\n\t\t\t\tshift(),\n\t\t\t\tarrow({ element: arrowEl, padding: 8 }),\n\t\t\t],\n\t\t}).then(({ x, y, placement, middlewareData }) => {\n\t\t\tthis._popover.dataset.placement = placement;\n\t\t\tObject.assign(this._popover.style, {\n\t\t\t\ttop: `${y}px`,\n\t\t\t\tleft: `${x}px`,\n\t\t\t});\n\n\t\t\tif (middlewareData.arrow) {\n\t\t\t\tconst { x, y } = middlewareData.arrow;\n\n\t\t\t\tObject.assign(arrowEl.style, {\n\t\t\t\t\tleft:\n\t\t\t\t\t\tthis.variant === 'error' || this.variant === 'error-element'\n\t\t\t\t\t\t\t? placement.indexOf('start') >= 0\n\t\t\t\t\t\t\t\t? '1rem'\n\t\t\t\t\t\t\t\t: 'calc(100% - 1rem)'\n\t\t\t\t\t\t\t: x != null\n\t\t\t\t\t\t\t? `${x}px`\n\t\t\t\t\t\t\t: '',\n\t\t\t\t\ttop: y != null ? `${y}px` : '',\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n}\n"],"mappings":"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"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as t,h as r,H as e}from"./p-e4d5e7a7.js";const o=".mx-4{margin-left:1rem!important;margin-right:1rem!important}.ml-2{margin-left:.5rem!important}.flex{display:flex!important}.h-14{height:3.5rem!important}.flex-1{flex:1 1 0%!important}.items-center{align-items:center!important}.gap-3{gap:.75rem!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.border-b{border-bottom-width:1px!important}.border-b-mystic-medium{--tw-border-opacity:1!important;border-bottom-color:rgb(227 236 243/var(--tw-border-opacity))!important}*{box-sizing:border-box}p-card-header{--tw-text-opacity:1;--tw-border-opacity:1!important;align-items:center;border-bottom-color:rgb(227 236 243/var(--tw-border-opacity))!important;border-bottom-width:1px!important;color:rgb(128 130 158/var(--tw-text-opacity));display:flex;flex-shrink:0;gap:.75rem;height:3.5rem;margin-left:1rem;margin-right:1rem}p-card-header .title{--tw-text-opacity:1;align-items:center;color:rgb(81 83 107/var(--tw-text-opacity));display:flex;flex:1 1 0%;font-weight:600;order:2;overflow:hidden}p-card-header .title>span{flex:1 1 0%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}p-card-header .title>p-icon{--tw-text-opacity:1;color:rgb(218 230 240/var(--tw-text-opacity));margin-left:.5rem}p-card-header [slot=prefix]{order:1}p-card-header [slot=suffix]{order:3}p-card-container.has-hover:hover p-card-header .title>p-icon{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}.static{position:static!important}.group:hover .group-hover\\:text-indigo{--tw-text-opacity:1!important;color:rgb(82 138 250/var(--tw-text-opacity))!important}";const i=class{constructor(r){t(this,r);this.header=undefined;this.arrow=false}render(){var t,o;return r(e,{class:"p-card-header"},r("slot",{name:"prefix"}),(((t=this.header)===null||t===void 0?void 0:t.length)||this.arrow)&&r("div",{class:"title"},r("span",null,(o=this.header)!==null&&o!==void 0?o:""),this.arrow&&r("p-icon",{variant:"arrow",class:"group-hover:text-indigo"})),r("slot",{name:"suffix"}))}};i.style=o;export{i as p_card_header};
|
|
2
|
-
//# sourceMappingURL=p-f37781ca.entry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["cardHeaderComponentCss","CardHeader","render","h","Host","class","name","_a","this","header","length","arrow","_b","variant"],"sources":["src/components/atoms/card-header/card-header.component.scss?tag=p-card-header","src/components/atoms/card-header/card-header.component.tsx"],"sourcesContent":["p-card-header {\n\t@apply mx-4 h-14 flex-shrink-0;\n\t@apply flex gap-3 items-center;\n\t@apply text-storm-medium;\n\t@apply border-b border-b-mystic-medium #{!important};\n\n\t.title {\n\t\t@apply order-2;\n\t\t@apply flex-1 overflow-hidden flex items-center text-storm;\n\t\t@apply font-semibold;\n\n\t\t> span {\n\t\t\t@apply flex-1 overflow-hidden text-ellipsis whitespace-nowrap;\n\t\t}\n\n\t\t> p-icon {\n\t\t\t@apply ml-2 text-mystic-dark;\n\t\t}\n\t}\n\n\t[slot='prefix'] {\n\t\t@apply order-1;\n\t}\n\n\t[slot='suffix'] {\n\t\t@apply order-3;\n\t}\n}\n\np-card-container.has-hover:hover {\n\tp-card-header {\n\t\t.title > p-icon {\n\t\t\t@apply text-indigo;\n\t\t}\n\t}\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n\ttag: 'p-card-header',\n\tstyleUrl: 'card-header.component.scss',\n})\nexport class CardHeader {\n\t/**\n\t * Content of the card header\n\t */\n\t@Prop() header: string;\n\n\t/**\n\t * Enable the title arrow\n\t */\n\t@Prop() arrow: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-card-header'>\n\t\t\t\t<slot name='prefix' />\n\n\t\t\t\t{(this.header?.length || this.arrow) && (\n\t\t\t\t\t<div class='title'>\n\t\t\t\t\t\t<span>{this.header ?? ''}</span>\n\t\t\t\t\t\t{this.arrow && (\n\t\t\t\t\t\t\t<p-icon\n\t\t\t\t\t\t\t\tvariant='arrow'\n\t\t\t\t\t\t\t\tclass='group-hover:text-indigo'\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\n\t\t\t\t<slot name='suffix' />\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"kDAAA,MAAMA,EAAyB,mkD,MCMlBC,EAAU,M,0DASG,K,CAEzB,MAAAC,G,QACC,OACCC,EAACC,EAAI,CAACC,MAAM,iBACXF,EAAA,QAAMG,KAAK,cAETC,EAAAC,KAAKC,UAAM,MAAAF,SAAA,SAAAA,EAAEG,SAAUF,KAAKG,QAC7BR,EAAA,OAAKE,MAAM,SACVF,EAAA,aAAOS,EAAAJ,KAAKC,UAAM,MAAAG,SAAA,EAAAA,EAAI,IACrBJ,KAAKG,OACLR,EAAA,UACCU,QAAQ,QACRR,MAAM,6BAMVF,EAAA,QAAMG,KAAK,W"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["tooltipComponentCss","Tooltip","this","_loaded","componentShouldUpdate","_update","disconnectedCallback","_cleanup","render","h","Host","class","name","variant","role","placement","strategy","ref","el","_load","content","clickHandler","enableUserInput","_popover","hasAttribute","_show","documentClickHandler","canManuallyClose","show","_hide","mouseEnterHandler","mouseLeaveHandler","onShowChange","_a","length","autoUpdate","_el","setAttribute","isOpen","emit","removeAttribute","popover","setTimeout","arrowEl","querySelector","computePosition","middleware","offset","flip","shift","arrow","element","padding","then","x","y","middlewareData","dataset","Object","assign","style","top","left","indexOf"],"sources":["src/components/atoms/tooltip/tooltip.component.scss?tag=p-tooltip&encapsulation=shadow","src/components/atoms/tooltip/tooltip.component.tsx"],"sourcesContent":[":host {\n\t@apply flex cursor-pointer;\n\n\t.popover-container {\n\t\t@apply relative h-0 w-0;\n\t\t.popover {\n\t\t\t@apply left-0 top-0 z-tooltip inline-block rounded bg-white px-3 py-2 text-xs font-medium opacity-0 drop-shadow-4 transition-opacity;\n\t\t\t@apply pointer-events-none;\n\t\t\twidth: max-content;\n\t\t\tmax-width: 14.5rem;\n\n\t\t\t&.variant-hover,\n\t\t\t&.variant-error,\n\t\t\t&.variant-error-element {\n\t\t\t\t@apply bg-storm py-1 text-white;\n\t\t\t}\n\n\t\t\t&.variant-error,\n\t\t\t&.variant-error-element {\n\t\t\t\t@apply bg-negative uppercase tracking-wider;\n\t\t\t}\n\n\t\t\t&[data-show] {\n\t\t\t\t@apply pointer-events-auto opacity-100;\n\t\t\t}\n\n\t\t\t.arrow,\n\t\t\t.arrow::before {\n\t\t\t\tbackground: inherit;\n\t\t\t\t@apply absolute h-2 w-2;\n\t\t\t}\n\n\t\t\t.arrow {\n\t\t\t\tvisibility: hidden;\n\n\t\t\t\t&::before {\n\t\t\t\t\t@apply visible rotate-45 transform;\n\t\t\t\t\tcontent: '';\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t&[data-strategy='fixed'] {\n\t\t\t\t@apply fixed;\n\t\t\t}\n\n\t\t\t&[data-strategy='absolute'] {\n\t\t\t\t@apply absolute;\n\t\t\t}\n\n\t\t\t&[data-placement^='top'] > .arrow {\n\t\t\t\t@apply -bottom-1;\n\t\t\t}\n\n\t\t\t&[data-placement^='bottom'] > .arrow {\n\t\t\t\t@apply -top-1;\n\t\t\t}\n\n\t\t\t&[data-placement^='left'] > .arrow {\n\t\t\t\t@apply -right-1;\n\t\t\t}\n\n\t\t\t&[data-placement^='right'] > .arrow {\n\t\t\t\t@apply -left-1;\n\t\t\t}\n\t\t}\n\t}\n}\n","import {\n\tarrow,\n\tautoUpdate,\n\tcomputePosition,\n\tflip,\n\toffset,\n\tPlacement,\n\tshift,\n\tStrategy,\n} from '@floating-ui/dom';\nimport {\n\tComponent,\n\tElement,\n\tEvent,\n\tEventEmitter,\n\th,\n\tHost,\n\tListen,\n\tProp,\n\tWatch,\n} from '@stencil/core';\n\n@Component({\n\ttag: 'p-tooltip',\n\tstyleUrl: 'tooltip.component.scss',\n\tshadow: true,\n})\nexport class Tooltip {\n\t/**\n\t * The variant of the popover\n\t */\n\t@Prop() variant: 'hover' | 'click' | 'error' | 'error-element' = 'hover';\n\n\t/**\n\t * The content of the popover\n\t */\n\t@Prop() content: any = null;\n\n\t/**\n\t * The placement of the popover\n\t */\n\t@Prop() placement: Placement = 'top';\n\n\t/**\n\t * The offset of the popover\n\t */\n\t@Prop() offset: number = 8;\n\n\t/**\n\t * The strategy of the popover placement\n\t */\n\t@Prop() strategy: Strategy = 'absolute';\n\n\t/**\n\t * Wether the tooltip can be shown by user input\n\t */\n\t@Prop() enableUserInput: boolean = true;\n\n\t/**\n\t * Wether to show the popover\n\t */\n\t@Prop() show: boolean = false;\n\n\t/**\n\t * Wether to someone can manually close the popover\n\t */\n\t@Prop() canManuallyClose: boolean = true;\n\n\t/**\n\t * Open change event\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tisOpen: EventEmitter<boolean>;\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\tprivate _loaded = false;\n\tprivate _popover: HTMLElement;\n\tprivate _cleanup: () => void;\n\n\tcomponentShouldUpdate() {\n\t\tthis._update();\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-popover'>\n\t\t\t\t<slot name='trigger' />\n\t\t\t\t<div class='popover-container'>\n\t\t\t\t\t<div\n\t\t\t\t\t\tclass={`popover variant-${this.variant}`}\n\t\t\t\t\t\trole='popover'\n\t\t\t\t\t\tdata-placement={this.placement}\n\t\t\t\t\t\tdata-strategy={this.strategy}\n\t\t\t\t\t\tref={el => this._load(el)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.content ? this.content : <slot name='content' />}\n\t\t\t\t\t\t<div class='arrow'></div>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t@Listen('click', { capture: true })\n\tprotected clickHandler() {\n\t\tif (this.variant === 'hover' || !this.enableUserInput) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._popover.hasAttribute('data-show')) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\t@Listen('click', { target: 'document', capture: true })\n\tprotected documentClickHandler() {\n\t\tif (this.variant === 'hover' || !this.canManuallyClose || this.show) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this._popover.hasAttribute('data-show')) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._hide();\n\t}\n\n\t@Listen('mouseenter')\n\t@Listen('focus')\n\tprotected mouseEnterHandler() {\n\t\tif (this.variant !== 'hover' || !this.enableUserInput) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\t@Listen('mouseleave')\n\t@Listen('blur')\n\tprotected mouseLeaveHandler() {\n\t\tif (this.show || this.variant !== 'hover' || !this.enableUserInput) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._hide();\n\t}\n\n\t@Watch('show')\n\tonShowChange(show: boolean) {\n\t\tif (show && !this._popover.hasAttribute('data-show')) {\n\t\t\treturn this._show();\n\t\t}\n\n\t\treturn this._hide();\n\t}\n\n\tprivate _show() {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this.content?.length) {\n\t\t\tif (this._popover.hasAttribute('data-show')) {\n\t\t\t\tthis._hide();\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tthis._cleanup = autoUpdate(this._el, this._popover, () => this._update());\n\t\t// Make the popover visible\n\t\tthis._popover.setAttribute('data-show', '');\n\n\t\t// Update its position\n\t\tthis.isOpen.emit(true);\n\t}\n\n\tprivate _hide() {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\n\t\t// Hide the popover\n\t\tthis._popover.removeAttribute('data-show');\n\t\tthis.isOpen.emit(false);\n\t}\n\n\tprivate _load(popover: HTMLElement) {\n\t\tthis._popover = popover;\n\t\tif (popover) {\n\t\t\tthis._update();\n\t\t\tthis._loaded = true;\n\n\t\t\tif (this.show) {\n\t\t\t\tsetTimeout(() => this._show(), 100);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _update() {\n\t\tif (!this._popover) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst arrowEl = this._popover.querySelector('.arrow') as HTMLElement;\n\t\tif (!arrowEl) {\n\t\t\treturn;\n\t\t}\n\n\t\tcomputePosition(this._el, this._popover, {\n\t\t\tplacement:\n\t\t\t\tthis.variant === 'error' || this.variant === 'error-element'\n\t\t\t\t\t? 'top-end'\n\t\t\t\t\t: this.placement,\n\t\t\tstrategy: this.strategy,\n\n\t\t\tmiddleware: [\n\t\t\t\toffset(this.variant === 'error' ? 14 : this.offset),\n\t\t\t\tflip(),\n\t\t\t\tshift(),\n\t\t\t\tarrow({ element: arrowEl, padding: 8 }),\n\t\t\t],\n\t\t}).then(({ x, y, placement, middlewareData }) => {\n\t\t\tthis._popover.dataset.placement = placement;\n\t\t\tObject.assign(this._popover.style, {\n\t\t\t\ttop: `${y}px`,\n\t\t\t\tleft: `${x}px`,\n\t\t\t});\n\n\t\t\tif (middlewareData.arrow) {\n\t\t\t\tconst { x, y } = middlewareData.arrow;\n\n\t\t\t\tObject.assign(arrowEl.style, {\n\t\t\t\t\tleft:\n\t\t\t\t\t\tthis.variant === 'error' || this.variant === 'error-element'\n\t\t\t\t\t\t\t? placement.indexOf('start') >= 0\n\t\t\t\t\t\t\t\t? '1rem'\n\t\t\t\t\t\t\t\t: 'calc(100% - 1rem)'\n\t\t\t\t\t\t\t: x != null\n\t\t\t\t\t\t\t? `${x}px`\n\t\t\t\t\t\t\t: '',\n\t\t\t\t\ttop: y != null ? `${y}px` : '',\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n}\n"],"mappings":"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"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as t,h as r,H as e}from"./p-e4d5e7a7.js";const o=".mx-4{margin-left:1rem!important;margin-right:1rem!important}.ml-2{margin-left:.5rem!important}.flex{display:flex!important}.h-14{height:3.5rem!important}.flex-1{flex:1 1 0%!important}.items-center{align-items:center!important}.gap-3{gap:.75rem!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.border-b{border-bottom-width:1px!important}.border-b-mystic-medium{--tw-border-opacity:1!important;border-bottom-color:rgb(227 236 243/var(--tw-border-opacity))!important}*{box-sizing:border-box}p-card-header{--tw-text-opacity:1;--tw-border-opacity:1!important;align-items:center;border-bottom-color:rgb(227 236 243/var(--tw-border-opacity))!important;border-bottom-width:1px!important;color:rgb(128 130 158/var(--tw-text-opacity));display:flex;flex-shrink:0;gap:.75rem;height:3.5rem;margin-left:1rem;margin-right:1rem}p-card-header .title{--tw-text-opacity:1;align-items:center;color:rgb(81 83 107/var(--tw-text-opacity));display:flex;flex:1 1 0%;font-weight:600;order:2;overflow:hidden}p-card-header .title>span{flex:1 1 0%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}p-card-header .title>p-icon{--tw-text-opacity:1;color:rgb(218 230 240/var(--tw-text-opacity));margin-left:.5rem}p-card-header [slot=prefix]{order:1}p-card-header [slot=suffix]{order:3}p-card-container.has-hover:hover p-card-header .title>p-icon{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}.static{position:static!important}.group:hover .group-hover\\:text-indigo{--tw-text-opacity:1!important;color:rgb(82 138 250/var(--tw-text-opacity))!important}";const i=class{constructor(r){t(this,r);this.header=undefined;this.arrow=false}render(){var t,o;return r(e,{class:"p-card-header"},r("slot",{name:"prefix"}),(((t=this.header)===null||t===void 0?void 0:t.length)||this.arrow)&&r("div",{class:"title"},r("span",null,(o=this.header)!==null&&o!==void 0?o:""),this.arrow&&r("p-icon",{variant:"arrow",class:"group-hover:text-indigo"})),r("slot",{name:"suffix"}))}};i.style=o;export{i as p_card_header};
|
|
2
|
-
//# sourceMappingURL=p-f37781ca.entry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["cardHeaderComponentCss","CardHeader","render","h","Host","class","name","_a","this","header","length","arrow","_b","variant"],"sources":["src/components/atoms/card-header/card-header.component.scss?tag=p-card-header","src/components/atoms/card-header/card-header.component.tsx"],"sourcesContent":["p-card-header {\n\t@apply mx-4 h-14 flex-shrink-0;\n\t@apply flex gap-3 items-center;\n\t@apply text-storm-medium;\n\t@apply border-b border-b-mystic-medium #{!important};\n\n\t.title {\n\t\t@apply order-2;\n\t\t@apply flex-1 overflow-hidden flex items-center text-storm;\n\t\t@apply font-semibold;\n\n\t\t> span {\n\t\t\t@apply flex-1 overflow-hidden text-ellipsis whitespace-nowrap;\n\t\t}\n\n\t\t> p-icon {\n\t\t\t@apply ml-2 text-mystic-dark;\n\t\t}\n\t}\n\n\t[slot='prefix'] {\n\t\t@apply order-1;\n\t}\n\n\t[slot='suffix'] {\n\t\t@apply order-3;\n\t}\n}\n\np-card-container.has-hover:hover {\n\tp-card-header {\n\t\t.title > p-icon {\n\t\t\t@apply text-indigo;\n\t\t}\n\t}\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n\ttag: 'p-card-header',\n\tstyleUrl: 'card-header.component.scss',\n})\nexport class CardHeader {\n\t/**\n\t * Content of the card header\n\t */\n\t@Prop() header: string;\n\n\t/**\n\t * Enable the title arrow\n\t */\n\t@Prop() arrow: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-card-header'>\n\t\t\t\t<slot name='prefix' />\n\n\t\t\t\t{(this.header?.length || this.arrow) && (\n\t\t\t\t\t<div class='title'>\n\t\t\t\t\t\t<span>{this.header ?? ''}</span>\n\t\t\t\t\t\t{this.arrow && (\n\t\t\t\t\t\t\t<p-icon\n\t\t\t\t\t\t\t\tvariant='arrow'\n\t\t\t\t\t\t\t\tclass='group-hover:text-indigo'\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\n\t\t\t\t<slot name='suffix' />\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"kDAAA,MAAMA,EAAyB,mkD,MCMlBC,EAAU,M,0DASG,K,CAEzB,MAAAC,G,QACC,OACCC,EAACC,EAAI,CAACC,MAAM,iBACXF,EAAA,QAAMG,KAAK,cAETC,EAAAC,KAAKC,UAAM,MAAAF,SAAA,SAAAA,EAAEG,SAAUF,KAAKG,QAC7BR,EAAA,OAAKE,MAAM,SACVF,EAAA,aAAOS,EAAAJ,KAAKC,UAAM,MAAAG,SAAA,EAAAA,EAAI,IACrBJ,KAAKG,OACLR,EAAA,UACCU,QAAQ,QACRR,MAAM,6BAMVF,EAAA,QAAMG,KAAK,W"}
|