@patternfly/elements 2.2.0 → 2.2.2
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/custom-elements.json +0 -20
- package/package.json +1 -1
- package/pf-popover/pf-popover.js +2 -1
- package/pf-popover/pf-popover.js.map +1 -1
- package/pf-tabs/BaseTabPanel.d.ts +0 -1
- package/pf-tabs/BaseTabPanel.js +1 -1
- package/pf-tabs/BaseTabPanel.js.map +1 -1
- package/pf-tabs/pf-tab.css +4 -0
- package/pf-tabs/pf-tab.js +1 -1
- package/pfe.min.js +30 -30
- package/pfe.min.js.map +2 -2
package/custom-elements.json
CHANGED
|
@@ -7176,18 +7176,6 @@
|
|
|
7176
7176
|
}
|
|
7177
7177
|
],
|
|
7178
7178
|
"members": [
|
|
7179
|
-
{
|
|
7180
|
-
"kind": "field",
|
|
7181
|
-
"name": "hidden",
|
|
7182
|
-
"type": {
|
|
7183
|
-
"text": "boolean"
|
|
7184
|
-
},
|
|
7185
|
-
"default": "true",
|
|
7186
|
-
"inheritedFrom": {
|
|
7187
|
-
"name": "BaseTabPanel",
|
|
7188
|
-
"module": "pf-tabs/BaseTabPanel.js"
|
|
7189
|
-
}
|
|
7190
|
-
},
|
|
7191
7179
|
{
|
|
7192
7180
|
"kind": "field",
|
|
7193
7181
|
"name": "#internals",
|
|
@@ -10959,14 +10947,6 @@
|
|
|
10959
10947
|
"description": "",
|
|
10960
10948
|
"name": "BaseTabPanel",
|
|
10961
10949
|
"members": [
|
|
10962
|
-
{
|
|
10963
|
-
"kind": "field",
|
|
10964
|
-
"name": "hidden",
|
|
10965
|
-
"type": {
|
|
10966
|
-
"text": "boolean"
|
|
10967
|
-
},
|
|
10968
|
-
"default": "true"
|
|
10969
|
-
},
|
|
10970
10950
|
{
|
|
10971
10951
|
"kind": "field",
|
|
10972
10952
|
"name": "#internals",
|
package/package.json
CHANGED
package/pf-popover/pf-popover.js
CHANGED
|
@@ -197,7 +197,6 @@ let PfPopover = PfPopover_1 = class PfPopover extends LitElement {
|
|
|
197
197
|
connectedCallback() {
|
|
198
198
|
super.connectedCallback();
|
|
199
199
|
this.addEventListener('keydown', this.onKeydown);
|
|
200
|
-
PfPopover_1.instances.add(this);
|
|
201
200
|
}
|
|
202
201
|
render() {
|
|
203
202
|
const { alignment, anchor, styles } = __classPrivateFieldGet(this, _PfPopover_float, "f");
|
|
@@ -321,6 +320,7 @@ let PfPopover = PfPopover_1 = class PfPopover extends LitElement {
|
|
|
321
320
|
});
|
|
322
321
|
this._popover?.show();
|
|
323
322
|
this.dispatchEvent(new PopoverShownEvent());
|
|
323
|
+
PfPopover_1.instances.add(this);
|
|
324
324
|
}
|
|
325
325
|
/**
|
|
326
326
|
* Closes the popover
|
|
@@ -330,6 +330,7 @@ let PfPopover = PfPopover_1 = class PfPopover extends LitElement {
|
|
|
330
330
|
await __classPrivateFieldGet(this, _PfPopover_float, "f").hide();
|
|
331
331
|
this._popover?.close();
|
|
332
332
|
this.dispatchEvent(new PopoverHiddenEvent());
|
|
333
|
+
PfPopover_1.instances.delete(this);
|
|
333
334
|
}
|
|
334
335
|
};
|
|
335
336
|
_PfPopover_referenceTrigger = new WeakMap();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pf-popover.js","sourceRoot":"","sources":["pf-popover.ts"],"names":[],"mappings":";;;AAAA,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AACjE,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,yBAAyB,CAAC;AAChD,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AACzD,OAAO,EAA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AK,CAAC,UAAU,CAAC;2CAAsC;AAC7B;IAA1B,KAAK,CAAC,UAAU,CAAC;kDAA8C;AACvC;IAAxB,KAAK,CAAC,QAAQ,CAAC;yCAAiC;AAwFlC;IAAd,KAAK;0CAcL;AA4BY;IAAZ,KAAK;uCAEL;AAKY;IAAZ,KAAK;qCAWL;AAKY;IAAZ,KAAK;qCAKL;AA7RU,SAAS;IADrB,aAAa,CAAC,YAAY,CAAC;GACf,SAAS,CA8RrB;SA9RY,SAAS","sourcesContent":["import { LitElement, nothing, html } from 'lit';\nimport { customElement } from 'lit/decorators/custom-element.js';\nimport { property } from 'lit/decorators/property.js';\nimport { query } from 'lit/decorators/query.js';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport { FloatingDOMController } from '@patternfly/pfe-core/controllers/floating-dom-controller.js';\nimport { SlotController } from '@patternfly/pfe-core/controllers/slot-controller.js';\nimport { bound } from '@patternfly/pfe-core/decorators/bound.js';\nimport { ComposedEvent, StringListConverter } from '@patternfly/pfe-core/core.js';\nimport { observed } from '@patternfly/pfe-core/decorators/observed.js';\nimport type { Placement } from '@patternfly/pfe-core/controllers/floating-dom-controller.js';\nimport '@patternfly/elements/pf-button/pf-button.js';\nimport styles from './pf-popover.css';\n\nconst headingLevels = [2, 3, 4, 5, 6] as const;\n\ntype HeadingLevel = (typeof headingLevels)[number];\n\ntype AlertSeverity = 'default' | 'info' | 'warning' | 'success' | 'danger';\n\nexport class PopoverHideEvent extends ComposedEvent {\n constructor() {\n super('hide');\n }\n}\n\nexport class PopoverHiddenEvent extends ComposedEvent {\n constructor() {\n super('hidden');\n }\n}\n\nexport class PopoverShowEvent extends ComposedEvent {\n constructor() {\n super('show');\n }\n}\n\nexport class PopoverShownEvent extends ComposedEvent {\n constructor() {\n super('shown');\n }\n}\n\n/**\n * A **Popover** displays content in a non-modal dialog and adds contextual information or provides resources via text and links.\n *\n * @summary Toggle the visibility of helpful or contextual information.\n *\n * @slot -\n * The default slot holds invoking element.\n * Typically this would be an icon, button, or other small sized element.\n * @slot heading\n * This slot renders the content that will be displayed inside of the header of the popover.\n * Typically this would be a heading element.\n * @slot icon\n * This slot renders the icon that will be displayed inside the header of the popover,\n * before the heading.\n * @slot body\n * This slot renders the content that will be displayed inside of the body of the popover.\n * @slot footer\n * This slot renders the content that will be displayed inside of the footer of the popover.\n *\n * @csspart container - The component wrapper\n * @csspart content - The content wrapper\n * @csspart header - The header element; only visible if both an icon annd heading are provided.\n * @csspart heading - The heading element\n * @csspart icon - The header icon\n * @csspart close-button - The close button\n * @csspart body - The container for the body content\n * @csspart footer - The container for the footer content\n *\n * @cssprop {<length>} --pf-c-popover__arrow--Height\n * Height of the arrow\n * {@default `1.5625rem`}\n * @cssprop {<length>} --pf-c-popover__arrow--Width\n * Width of the arrow\n * {@default `1.5625rem`}\n * @cssprop {<color>} --pf-c-popover__title-text--Color\n * Heading font color\n * {@default `inherit`}\n * @cssprop {<color>} --pf-c-popover__title-icon--Color\n * Heading icon font color\n * {@default `#151515`}\n * @cssprop {<color>} --pf-c-popover__arrow--BackgroundColor\n * Arrow background color\n * {@default `#fff`}\n * @cssprop --pf-c-popover__arrow--BoxShadow\n * Arrow box shadow\n * {@default `0 0.5rem 1rem 0 rgba(3, 3, 3, 0.16), 0 0 0.375rem 0 rgba(3, 3, 3, 0.08)`}\n * @cssprop --pf-c-popover--BoxShadow\n * Popover box shadow\n * {@default `0 0.5rem 1rem 0 rgba(3, 3, 3, 0.16), 0 0 0.375rem 0 rgba(3, 3, 3, 0.08)`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingTop\n * Popover top padding\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingRight\n * Popover right padding\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingBottom\n * Popover bottom padding\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingLeft\n * Popover left padding\n * {@default `1rem`}\n * @cssprop {<number>} --pf-c-popover--line-height\n * Popover line height\n * {@default `1.5`}\n * @cssprop {<length>} --pf-c-popover__content--FontSize\n * Popover font-size\n * {@default `0.875rem`}\n * @cssprop {<color>} --pf-c-popover__content--BackgroundColor\n * Popover background color\n * {@default `#fff`}\n * @cssprop {<length>} --pf-c-popover--MaxWidth\n * Popover max-width\n * {@default `20.75rem`}\n * @cssprop {<length>} --pf-c-popover--MinWidth\n * Popover min-width\n * {@default `20.75rem`}\n * @cssprop {<number>} --pf-c-popover--c-button--Right\n * Close button right position\n * {@default `0}\n * @cssprop {<number>} --pf-c-popover--c-button--Top\n * Close button top position\n * {@default `0`}\n * @cssprop {<length>} --pf-c-popover--c-button--sibling--PaddingRight\n * Padding between close button and its immediate sibling\n * {@default `3rem`}\n * @cssprop {<length>} --pf-c-popover__title-icon--MarginRight\n * Heading icon right margin\n * {@default `0.5rem`}\n * @cssprop {<length>} --pf-c-popover__title--FontSize\n * Header font-size\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-popover__title--MarginBottom\n * Header bottom margin\n * {@default `0.5rem`}\n * @cssprop {<number>} --pf-c-popover__title--LineHeight\n * Header line height\n * {@default `1.5`}\n * @cssprop {<string>} --pf-c-popover__title--FontFamily\n * Header font-family\n * {@default `'RedHatDisplay', 'Overpass', overpass, helvetica, arial, sans-serif`}\n * @cssprop {<length>} --pf-c-popover__footer--MarginTop\n * Footer top margin\n * {@default `1rem`}\n * @cssprop {<color>} --pf-c-popover--m-default__title-text--Color\n * Default alert heading color\n * {@default `#003737`}\n * @cssprop {<color>} --pf-c-popover--m-default__title-icon--Color\n * Default alert icon color\n * {@default `#009596`}\n * @cssprop {<color>} --pf-c-popover--m-info__title-text--Color\n * Default alert heading color\n * {@default `#002952`}\n * @cssprop {<color>} --pf-c-popover--m-info__title-icon--Color\n * Default alert icon color\n * {@default `#2b9af3`}\n * @cssprop {<color>} --pf-c-popover--m-warning__title-text--Color\n * Default alert heading color\n * {@default `#795600`}\n * @cssprop {<color>} --pf-c-popover--m-warning__title-icon--Color\n * Default alert icon color\n * {@default `#f0ab00`}\n * @cssprop {<color>} --pf-c-popover--m-success__title-text--Color\n * Default alert heading color\n * {@default `#1e4f18`}\n * @cssprop {<color>} --pf-c-popover--m-success__title-icon--Color\n * Default alert icon color\n * {@default `#3e8635`}\n * @cssprop {<color>} --pf-c-popover--m-danger__title-text--Color\n * Default alert heading color\n * {@default `#a30000`}\n * @cssprop {<color>} --pf-c-popover--m-danger__title-icon--Color\n * Default alert icon color\n * {@default `#c9190b`}\n */\n@customElement('pf-popover')\nexport class PfPopover extends LitElement {\n static readonly styles = [styles];\n\n private static instances = new Set<PfPopover>();\n\n private static alertIcons = new Map(Object.entries({\n default: 'bell',\n info: 'circle-info',\n success: 'circle-check',\n warning: 'triangle-exclamation',\n danger: 'circle-exclamation',\n } satisfies Record<AlertSeverity, string>) as [AlertSeverity, string][]);\n\n static {\n document.addEventListener('click', function(event) {\n for (const instance of PfPopover.instances) {\n if (!instance.noOutsideClick) {\n instance.#outsideClick(event);\n }\n }\n });\n }\n\n /**\n * Indicates the initial popover position.\n * There are 12 options: `top`, `bottom`, `left`, `right`, `top-start`, `top-end`,\n * `bottom-start`, `bottom-end`, `left-start`, `left-end`,`right-start`, `right-end`.\n * The default is `top`.\n */\n @property({ reflect: true }) position: Placement = 'top';\n\n /**\n * The content rendered in the popover's heading.\n */\n @property({ reflect: true }) heading?: string;\n\n /**\n * The content rendered in the popover's body.\n */\n @property({ reflect: true }) body?: string;\n\n /**\n * The content rendered in the popover's footer.\n */\n @property({ reflect: true }) footer?: string;\n\n /**\n * The icon placed before the popover's heading.\n */\n @property({ reflect: true }) icon?: string;\n\n /**\n * The accessible label for the popover. This is required if the no heading is set.\n */\n @property({ reflect: true }) label?: string;\n\n /**\n * The distance to set between the popover and its trigger element.\n */\n @property({ type: Number, reflect: true }) distance?: number;\n\n /**\n * The flip order when flip is enabled and the initial position is not possible.\n * There are 12 options: `top`, `bottom`, `left`, `right`, `top-start`, `top-end`,\n * `bottom-start`, `bottom-end`, `left-start`, `left-end`,`right-start`, `right-end`.\n * The default is [oppositePlacement], where only the opposite placement is tried.\n */\n @property({\n attribute: 'flip-behavior',\n converter: StringListConverter,\n }) flipBehavior?: Placement[];\n\n /**\n * Disable the flip behavior. The default is `false`.\n */\n @property({ type: Boolean, reflect: true, attribute: 'no-flip' }) noFlip = false;\n\n /**\n * The heading level to use for the popover's header. The default is `h6`.\n */\n @property({ type: Number, reflect: true, attribute: 'heading-level' }) headingLevel?: HeadingLevel;\n\n /**\n * Indicates which icon set to use for the header's icon.\n * The default is `fas` (Font Awesome Free Solid).\n */\n @property({ reflect: true, attribute: 'icon-set' }) iconSet?: string;\n\n /**\n * Hide the close button. The default is `false`.\n */\n @property({ type: Boolean, reflect: true, attribute: 'hide-close' }) hideClose?: boolean;\n\n /**\n * Indicates the severity variant to use for the alert popover.\n * There are five options: `default`, `info`, `warning`, `success`, and `danger`.\n */\n @property({ reflect: true, attribute: 'alert-severity' }) alertSeverity?: AlertSeverity;\n\n /**\n * The accessible label for the popover's close button. The default is `Close popover`.\n */\n @property({ reflect: true, attribute: 'close-label' }) closeButtonLabel?: string;\n\n /**\n * The text announced by the screen reader to indicate the popover's severity.\n * The default is `${alertSeverity} alert:`.\n */\n @property({ reflect: true, attribute: 'alert-severity-text' }) alertSeverityText?: string;\n\n /**\n * Don't hide the popover when clicking ouside of it.\n */\n @property({\n type: Boolean,\n reflect: true,\n attribute: 'no-outside-click',\n }) noOutsideClick?: boolean;\n\n /**\n * The ID of the element to attach the popover to.\n */\n @observed('triggerChanged')\n @property({ reflect: true }) trigger?: string;\n\n @query('#popover') private _popover!: HTMLDialogElement;\n @query('#trigger') private _slottedTrigger?: HTMLElement | null;\n @query('#arrow') private _arrow!: HTMLDivElement;\n\n #referenceTrigger?: HTMLElement | null = null;\n\n #float = new FloatingDOMController(this, {\n content: () => this._popover,\n arrow: () => this._arrow,\n invoker: () => this.#referenceTrigger || this._slottedTrigger,\n });\n\n #slots = new SlotController(this, null, 'icon', 'heading', 'body', 'footer');\n\n connectedCallback() {\n super.connectedCallback();\n this.addEventListener('keydown', this.onKeydown);\n PfPopover.instances.add(this);\n }\n\n render() {\n const { alignment, anchor, styles } = this.#float;\n const hasFooter = this.#slots.hasSlotted('footer') || !!this.footer;\n const hasHeading = this.#slots.hasSlotted('heading') || !!this.heading;\n const hasIcon = this.#slots.hasSlotted('icon') || !!this.icon || !!this.alertSeverity;\n\n // https://github.com/asyncLiz/minify-html-literals/issues/37\n let headingContent = html`<h6>${this.heading ?? ''}</h6>`;\n switch (this.headingLevel) {\n case 2: headingContent = html`<h2>${this.heading ?? ''}</h2>`; break;\n case 3: headingContent = html`<h3>${this.heading ?? ''}</h3>`; break;\n case 4: headingContent = html`<h4>${this.heading ?? ''}</h4>`; break;\n case 5: headingContent = html`<h5>${this.heading ?? ''}</h5>`; break;\n }\n\n const headingSlotWithFallback = html`\n <slot id=\"heading\" name=\"heading\" part=\"heading\" ?hidden=${!hasHeading}>${headingContent}</slot>\n `;\n\n const header = !(hasHeading && hasIcon) ? headingSlotWithFallback : html`\n <header part=\"header\">\n <span part=\"icon\">\n <slot name=\"icon\">\n <pf-icon icon=\"${this.icon ?? PfPopover.alertIcons.get(this.alertSeverity as AlertSeverity) ?? ''}\"\n set=\"${ifDefined(this.iconSet)}\"\n size=\"md\"></pf-icon>\n </slot>\n </span>${!this.alertSeverity ? nothing : html`\n <span class=\"visually-hidden\">${this.alertSeverityText ?? `${this.alertSeverity} alert:`}</span>`}\n ${headingSlotWithFallback}\n </header>\n `;\n\n return html`\n <div id=\"container\"\n style=\"${styleMap(styles)}\"\n class=\"${classMap({ [anchor]: !!anchor, [alignment]: !!alignment })}\">\n <slot id=\"trigger\" @keydown=${this.onKeydown} @click=${this.toggle}></slot>\n <dialog id=\"popover\" aria-labelledby=\"heading\" aria-describedby=\"body\" aria-label=${ifDefined(this.label)}>\n <div id=\"arrow\"></div>\n <div id=\"content\" part=\"content\">\n <pf-button id=\"close-button\"\n part=\"close-button\"\n plain\n label=\"${this.closeButtonLabel ?? 'Close popover'}\"\n @click=\"${this.hide}\"\n @keydown=\"${this.onKeydown}\"\n ?hidden=\"${this.hideClose}\">\n <svg fill=\"currentColor\" height=\"1em\" width=\"1em\" viewBox=\"0 0 352 512\">\n <path d=\"M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z\"/>\n </svg>\n </pf-button>\n ${header}\n <slot id=\"body\" part=\"body\" name=\"body\">${this.body ?? ''}</slot>\n <footer part=\"footer\" ?hidden=${!hasFooter}>\n <slot name=\"footer\">${this.footer}</slot>\n </footer>\n </div>\n </dialog>\n </div>\n `;\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n PfPopover.instances.delete(this);\n this.#referenceTrigger?.removeEventListener('click', this.show);\n this.#referenceTrigger?.removeEventListener('keydown', this.onKeydown);\n }\n\n @bound private onKeydown(event: KeyboardEvent) {\n switch (event.key) {\n case 'Escape':\n case 'Esc':\n event.preventDefault();\n this.hide();\n return;\n case 'Enter':\n if (event.target === this.#referenceTrigger || event.target === this._slottedTrigger) {\n event.preventDefault();\n this.show();\n }\n return;\n }\n }\n\n #outsideClick(event: MouseEvent) {\n const path = event.composedPath();\n if (!path.includes(this) && !path.includes(this.#referenceTrigger as HTMLElement)) {\n this.hide();\n }\n }\n\n /**\n * Removes event listeners from the old trigger element and attaches\n * them to the new trigger element.\n */\n triggerChanged(oldValue?: string, newValue?: string) {\n if (oldValue) {\n this.#referenceTrigger?.removeEventListener('click', this.show);\n this.#referenceTrigger?.removeEventListener('keydown', this.onKeydown);\n }\n if (newValue) {\n this.#referenceTrigger = (this.getRootNode() as Document | ShadowRoot).getElementById(newValue);\n this.#referenceTrigger?.addEventListener('click', this.show);\n this.#referenceTrigger?.addEventListener('keydown', this.onKeydown);\n }\n }\n\n /**\n * Toggle the popover\n */\n @bound async toggle() {\n this.#float.open ? this.hide() : this.show();\n }\n\n /**\n * Opens the popover\n */\n @bound async show() {\n this.dispatchEvent(new PopoverShowEvent());\n await this.updateComplete;\n await this.#float.show({\n offset: this.distance ?? 25,\n placement: this.position,\n flip: !this.noFlip,\n fallbackPlacements: this.flipBehavior,\n });\n this._popover?.show();\n this.dispatchEvent(new PopoverShownEvent());\n }\n\n /**\n * Closes the popover\n */\n @bound async hide() {\n this.dispatchEvent(new PopoverHideEvent());\n await this.#float.hide();\n this._popover?.close();\n this.dispatchEvent(new PopoverHiddenEvent());\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'pf-popover': PfPopover;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pf-popover.js","sourceRoot":"","sources":["pf-popover.ts"],"names":[],"mappings":";;;AAAA,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AACjE,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACtD,OAAO,EAAE,KAAK,EAAE,MAAM,yBAAyB,CAAC;AAChD,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AACzD,OAAO,EAAE,qBAAqB,EAAE,MAAM,6DAA6D,CAAC;AACpG,OAAO,EAAE,cAAc,EAAE,MAAM,qDAAqD,CAA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sC;AAC7B;IAA1B,KAAK,CAAC,UAAU,CAAC;kDAA8C;AACvC;IAAxB,KAAK,CAAC,QAAQ,CAAC;yCAAiC;AAuFlC;IAAd,KAAK;0CAcL;AA4BY;IAAZ,KAAK;uCAEL;AAKY;IAAZ,KAAK;qCAYL;AAKY;IAAZ,KAAK;qCAML;AA9RU,SAAS;IADrB,aAAa,CAAC,YAAY,CAAC;GACf,SAAS,CA+RrB;SA/RY,SAAS","sourcesContent":["import { LitElement, nothing, html } from 'lit';\nimport { customElement } from 'lit/decorators/custom-element.js';\nimport { property } from 'lit/decorators/property.js';\nimport { query } from 'lit/decorators/query.js';\nimport { styleMap } from 'lit/directives/style-map.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport { FloatingDOMController } from '@patternfly/pfe-core/controllers/floating-dom-controller.js';\nimport { SlotController } from '@patternfly/pfe-core/controllers/slot-controller.js';\nimport { bound } from '@patternfly/pfe-core/decorators/bound.js';\nimport { ComposedEvent, StringListConverter } from '@patternfly/pfe-core/core.js';\nimport { observed } from '@patternfly/pfe-core/decorators/observed.js';\nimport type { Placement } from '@patternfly/pfe-core/controllers/floating-dom-controller.js';\nimport '@patternfly/elements/pf-button/pf-button.js';\nimport styles from './pf-popover.css';\n\nconst headingLevels = [2, 3, 4, 5, 6] as const;\n\ntype HeadingLevel = (typeof headingLevels)[number];\n\ntype AlertSeverity = 'default' | 'info' | 'warning' | 'success' | 'danger';\n\nexport class PopoverHideEvent extends ComposedEvent {\n constructor() {\n super('hide');\n }\n}\n\nexport class PopoverHiddenEvent extends ComposedEvent {\n constructor() {\n super('hidden');\n }\n}\n\nexport class PopoverShowEvent extends ComposedEvent {\n constructor() {\n super('show');\n }\n}\n\nexport class PopoverShownEvent extends ComposedEvent {\n constructor() {\n super('shown');\n }\n}\n\n/**\n * A **Popover** displays content in a non-modal dialog and adds contextual information or provides resources via text and links.\n *\n * @summary Toggle the visibility of helpful or contextual information.\n *\n * @slot -\n * The default slot holds invoking element.\n * Typically this would be an icon, button, or other small sized element.\n * @slot heading\n * This slot renders the content that will be displayed inside of the header of the popover.\n * Typically this would be a heading element.\n * @slot icon\n * This slot renders the icon that will be displayed inside the header of the popover,\n * before the heading.\n * @slot body\n * This slot renders the content that will be displayed inside of the body of the popover.\n * @slot footer\n * This slot renders the content that will be displayed inside of the footer of the popover.\n *\n * @csspart container - The component wrapper\n * @csspart content - The content wrapper\n * @csspart header - The header element; only visible if both an icon annd heading are provided.\n * @csspart heading - The heading element\n * @csspart icon - The header icon\n * @csspart close-button - The close button\n * @csspart body - The container for the body content\n * @csspart footer - The container for the footer content\n *\n * @cssprop {<length>} --pf-c-popover__arrow--Height\n * Height of the arrow\n * {@default `1.5625rem`}\n * @cssprop {<length>} --pf-c-popover__arrow--Width\n * Width of the arrow\n * {@default `1.5625rem`}\n * @cssprop {<color>} --pf-c-popover__title-text--Color\n * Heading font color\n * {@default `inherit`}\n * @cssprop {<color>} --pf-c-popover__title-icon--Color\n * Heading icon font color\n * {@default `#151515`}\n * @cssprop {<color>} --pf-c-popover__arrow--BackgroundColor\n * Arrow background color\n * {@default `#fff`}\n * @cssprop --pf-c-popover__arrow--BoxShadow\n * Arrow box shadow\n * {@default `0 0.5rem 1rem 0 rgba(3, 3, 3, 0.16), 0 0 0.375rem 0 rgba(3, 3, 3, 0.08)`}\n * @cssprop --pf-c-popover--BoxShadow\n * Popover box shadow\n * {@default `0 0.5rem 1rem 0 rgba(3, 3, 3, 0.16), 0 0 0.375rem 0 rgba(3, 3, 3, 0.08)`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingTop\n * Popover top padding\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingRight\n * Popover right padding\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingBottom\n * Popover bottom padding\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-tooltip__content--PaddingLeft\n * Popover left padding\n * {@default `1rem`}\n * @cssprop {<number>} --pf-c-popover--line-height\n * Popover line height\n * {@default `1.5`}\n * @cssprop {<length>} --pf-c-popover__content--FontSize\n * Popover font-size\n * {@default `0.875rem`}\n * @cssprop {<color>} --pf-c-popover__content--BackgroundColor\n * Popover background color\n * {@default `#fff`}\n * @cssprop {<length>} --pf-c-popover--MaxWidth\n * Popover max-width\n * {@default `20.75rem`}\n * @cssprop {<length>} --pf-c-popover--MinWidth\n * Popover min-width\n * {@default `20.75rem`}\n * @cssprop {<number>} --pf-c-popover--c-button--Right\n * Close button right position\n * {@default `0}\n * @cssprop {<number>} --pf-c-popover--c-button--Top\n * Close button top position\n * {@default `0`}\n * @cssprop {<length>} --pf-c-popover--c-button--sibling--PaddingRight\n * Padding between close button and its immediate sibling\n * {@default `3rem`}\n * @cssprop {<length>} --pf-c-popover__title-icon--MarginRight\n * Heading icon right margin\n * {@default `0.5rem`}\n * @cssprop {<length>} --pf-c-popover__title--FontSize\n * Header font-size\n * {@default `1rem`}\n * @cssprop {<length>} --pf-c-popover__title--MarginBottom\n * Header bottom margin\n * {@default `0.5rem`}\n * @cssprop {<number>} --pf-c-popover__title--LineHeight\n * Header line height\n * {@default `1.5`}\n * @cssprop {<string>} --pf-c-popover__title--FontFamily\n * Header font-family\n * {@default `'RedHatDisplay', 'Overpass', overpass, helvetica, arial, sans-serif`}\n * @cssprop {<length>} --pf-c-popover__footer--MarginTop\n * Footer top margin\n * {@default `1rem`}\n * @cssprop {<color>} --pf-c-popover--m-default__title-text--Color\n * Default alert heading color\n * {@default `#003737`}\n * @cssprop {<color>} --pf-c-popover--m-default__title-icon--Color\n * Default alert icon color\n * {@default `#009596`}\n * @cssprop {<color>} --pf-c-popover--m-info__title-text--Color\n * Default alert heading color\n * {@default `#002952`}\n * @cssprop {<color>} --pf-c-popover--m-info__title-icon--Color\n * Default alert icon color\n * {@default `#2b9af3`}\n * @cssprop {<color>} --pf-c-popover--m-warning__title-text--Color\n * Default alert heading color\n * {@default `#795600`}\n * @cssprop {<color>} --pf-c-popover--m-warning__title-icon--Color\n * Default alert icon color\n * {@default `#f0ab00`}\n * @cssprop {<color>} --pf-c-popover--m-success__title-text--Color\n * Default alert heading color\n * {@default `#1e4f18`}\n * @cssprop {<color>} --pf-c-popover--m-success__title-icon--Color\n * Default alert icon color\n * {@default `#3e8635`}\n * @cssprop {<color>} --pf-c-popover--m-danger__title-text--Color\n * Default alert heading color\n * {@default `#a30000`}\n * @cssprop {<color>} --pf-c-popover--m-danger__title-icon--Color\n * Default alert icon color\n * {@default `#c9190b`}\n */\n@customElement('pf-popover')\nexport class PfPopover extends LitElement {\n static readonly styles = [styles];\n\n private static instances = new Set<PfPopover>();\n\n private static alertIcons = new Map(Object.entries({\n default: 'bell',\n info: 'circle-info',\n success: 'circle-check',\n warning: 'triangle-exclamation',\n danger: 'circle-exclamation',\n } satisfies Record<AlertSeverity, string>) as [AlertSeverity, string][]);\n\n static {\n document.addEventListener('click', function(event) {\n for (const instance of PfPopover.instances) {\n if (!instance.noOutsideClick) {\n instance.#outsideClick(event);\n }\n }\n });\n }\n\n /**\n * Indicates the initial popover position.\n * There are 12 options: `top`, `bottom`, `left`, `right`, `top-start`, `top-end`,\n * `bottom-start`, `bottom-end`, `left-start`, `left-end`,`right-start`, `right-end`.\n * The default is `top`.\n */\n @property({ reflect: true }) position: Placement = 'top';\n\n /**\n * The content rendered in the popover's heading.\n */\n @property({ reflect: true }) heading?: string;\n\n /**\n * The content rendered in the popover's body.\n */\n @property({ reflect: true }) body?: string;\n\n /**\n * The content rendered in the popover's footer.\n */\n @property({ reflect: true }) footer?: string;\n\n /**\n * The icon placed before the popover's heading.\n */\n @property({ reflect: true }) icon?: string;\n\n /**\n * The accessible label for the popover. This is required if the no heading is set.\n */\n @property({ reflect: true }) label?: string;\n\n /**\n * The distance to set between the popover and its trigger element.\n */\n @property({ type: Number, reflect: true }) distance?: number;\n\n /**\n * The flip order when flip is enabled and the initial position is not possible.\n * There are 12 options: `top`, `bottom`, `left`, `right`, `top-start`, `top-end`,\n * `bottom-start`, `bottom-end`, `left-start`, `left-end`,`right-start`, `right-end`.\n * The default is [oppositePlacement], where only the opposite placement is tried.\n */\n @property({\n attribute: 'flip-behavior',\n converter: StringListConverter,\n }) flipBehavior?: Placement[];\n\n /**\n * Disable the flip behavior. The default is `false`.\n */\n @property({ type: Boolean, reflect: true, attribute: 'no-flip' }) noFlip = false;\n\n /**\n * The heading level to use for the popover's header. The default is `h6`.\n */\n @property({ type: Number, reflect: true, attribute: 'heading-level' }) headingLevel?: HeadingLevel;\n\n /**\n * Indicates which icon set to use for the header's icon.\n * The default is `fas` (Font Awesome Free Solid).\n */\n @property({ reflect: true, attribute: 'icon-set' }) iconSet?: string;\n\n /**\n * Hide the close button. The default is `false`.\n */\n @property({ type: Boolean, reflect: true, attribute: 'hide-close' }) hideClose?: boolean;\n\n /**\n * Indicates the severity variant to use for the alert popover.\n * There are five options: `default`, `info`, `warning`, `success`, and `danger`.\n */\n @property({ reflect: true, attribute: 'alert-severity' }) alertSeverity?: AlertSeverity;\n\n /**\n * The accessible label for the popover's close button. The default is `Close popover`.\n */\n @property({ reflect: true, attribute: 'close-label' }) closeButtonLabel?: string;\n\n /**\n * The text announced by the screen reader to indicate the popover's severity.\n * The default is `${alertSeverity} alert:`.\n */\n @property({ reflect: true, attribute: 'alert-severity-text' }) alertSeverityText?: string;\n\n /**\n * Don't hide the popover when clicking ouside of it.\n */\n @property({\n type: Boolean,\n reflect: true,\n attribute: 'no-outside-click',\n }) noOutsideClick?: boolean;\n\n /**\n * The ID of the element to attach the popover to.\n */\n @observed('triggerChanged')\n @property({ reflect: true }) trigger?: string;\n\n @query('#popover') private _popover!: HTMLDialogElement;\n @query('#trigger') private _slottedTrigger?: HTMLElement | null;\n @query('#arrow') private _arrow!: HTMLDivElement;\n\n #referenceTrigger?: HTMLElement | null = null;\n\n #float = new FloatingDOMController(this, {\n content: () => this._popover,\n arrow: () => this._arrow,\n invoker: () => this.#referenceTrigger || this._slottedTrigger,\n });\n\n #slots = new SlotController(this, null, 'icon', 'heading', 'body', 'footer');\n\n connectedCallback() {\n super.connectedCallback();\n this.addEventListener('keydown', this.onKeydown);\n }\n\n render() {\n const { alignment, anchor, styles } = this.#float;\n const hasFooter = this.#slots.hasSlotted('footer') || !!this.footer;\n const hasHeading = this.#slots.hasSlotted('heading') || !!this.heading;\n const hasIcon = this.#slots.hasSlotted('icon') || !!this.icon || !!this.alertSeverity;\n\n // https://github.com/asyncLiz/minify-html-literals/issues/37\n let headingContent = html`<h6>${this.heading ?? ''}</h6>`;\n switch (this.headingLevel) {\n case 2: headingContent = html`<h2>${this.heading ?? ''}</h2>`; break;\n case 3: headingContent = html`<h3>${this.heading ?? ''}</h3>`; break;\n case 4: headingContent = html`<h4>${this.heading ?? ''}</h4>`; break;\n case 5: headingContent = html`<h5>${this.heading ?? ''}</h5>`; break;\n }\n\n const headingSlotWithFallback = html`\n <slot id=\"heading\" name=\"heading\" part=\"heading\" ?hidden=${!hasHeading}>${headingContent}</slot>\n `;\n\n const header = !(hasHeading && hasIcon) ? headingSlotWithFallback : html`\n <header part=\"header\">\n <span part=\"icon\">\n <slot name=\"icon\">\n <pf-icon icon=\"${this.icon ?? PfPopover.alertIcons.get(this.alertSeverity as AlertSeverity) ?? ''}\"\n set=\"${ifDefined(this.iconSet)}\"\n size=\"md\"></pf-icon>\n </slot>\n </span>${!this.alertSeverity ? nothing : html`\n <span class=\"visually-hidden\">${this.alertSeverityText ?? `${this.alertSeverity} alert:`}</span>`}\n ${headingSlotWithFallback}\n </header>\n `;\n\n return html`\n <div id=\"container\"\n style=\"${styleMap(styles)}\"\n class=\"${classMap({ [anchor]: !!anchor, [alignment]: !!alignment })}\">\n <slot id=\"trigger\" @keydown=${this.onKeydown} @click=${this.toggle}></slot>\n <dialog id=\"popover\" aria-labelledby=\"heading\" aria-describedby=\"body\" aria-label=${ifDefined(this.label)}>\n <div id=\"arrow\"></div>\n <div id=\"content\" part=\"content\">\n <pf-button id=\"close-button\"\n part=\"close-button\"\n plain\n label=\"${this.closeButtonLabel ?? 'Close popover'}\"\n @click=\"${this.hide}\"\n @keydown=\"${this.onKeydown}\"\n ?hidden=\"${this.hideClose}\">\n <svg fill=\"currentColor\" height=\"1em\" width=\"1em\" viewBox=\"0 0 352 512\">\n <path d=\"M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z\"/>\n </svg>\n </pf-button>\n ${header}\n <slot id=\"body\" part=\"body\" name=\"body\">${this.body ?? ''}</slot>\n <footer part=\"footer\" ?hidden=${!hasFooter}>\n <slot name=\"footer\">${this.footer}</slot>\n </footer>\n </div>\n </dialog>\n </div>\n `;\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n PfPopover.instances.delete(this);\n this.#referenceTrigger?.removeEventListener('click', this.show);\n this.#referenceTrigger?.removeEventListener('keydown', this.onKeydown);\n }\n\n @bound private onKeydown(event: KeyboardEvent) {\n switch (event.key) {\n case 'Escape':\n case 'Esc':\n event.preventDefault();\n this.hide();\n return;\n case 'Enter':\n if (event.target === this.#referenceTrigger || event.target === this._slottedTrigger) {\n event.preventDefault();\n this.show();\n }\n return;\n }\n }\n\n #outsideClick(event: MouseEvent) {\n const path = event.composedPath();\n if (!path.includes(this) && !path.includes(this.#referenceTrigger as HTMLElement)) {\n this.hide();\n }\n }\n\n /**\n * Removes event listeners from the old trigger element and attaches\n * them to the new trigger element.\n */\n triggerChanged(oldValue?: string, newValue?: string) {\n if (oldValue) {\n this.#referenceTrigger?.removeEventListener('click', this.show);\n this.#referenceTrigger?.removeEventListener('keydown', this.onKeydown);\n }\n if (newValue) {\n this.#referenceTrigger = (this.getRootNode() as Document | ShadowRoot).getElementById(newValue);\n this.#referenceTrigger?.addEventListener('click', this.show);\n this.#referenceTrigger?.addEventListener('keydown', this.onKeydown);\n }\n }\n\n /**\n * Toggle the popover\n */\n @bound async toggle() {\n this.#float.open ? this.hide() : this.show();\n }\n\n /**\n * Opens the popover\n */\n @bound async show() {\n this.dispatchEvent(new PopoverShowEvent());\n await this.updateComplete;\n await this.#float.show({\n offset: this.distance ?? 25,\n placement: this.position,\n flip: !this.noFlip,\n fallbackPlacements: this.flipBehavior,\n });\n this._popover?.show();\n this.dispatchEvent(new PopoverShownEvent());\n PfPopover.instances.add(this);\n }\n\n /**\n * Closes the popover\n */\n @bound async hide() {\n this.dispatchEvent(new PopoverHideEvent());\n await this.#float.hide();\n this._popover?.close();\n this.dispatchEvent(new PopoverHiddenEvent());\n PfPopover.instances.delete(this);\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'pf-popover': PfPopover;\n }\n}\n"]}
|
package/pf-tabs/BaseTabPanel.js
CHANGED
|
@@ -7,7 +7,6 @@ import { getRandomId } from '@patternfly/pfe-core/functions/random.js';
|
|
|
7
7
|
class BaseTabPanel extends LitElement {
|
|
8
8
|
constructor() {
|
|
9
9
|
super(...arguments);
|
|
10
|
-
this.hidden = true;
|
|
11
10
|
_BaseTabPanel_internals.set(this, this.attachInternals());
|
|
12
11
|
}
|
|
13
12
|
render() {
|
|
@@ -18,6 +17,7 @@ class BaseTabPanel extends LitElement {
|
|
|
18
17
|
connectedCallback() {
|
|
19
18
|
super.connectedCallback();
|
|
20
19
|
this.id || (this.id = getRandomId('pf-tab-panel'));
|
|
20
|
+
this.hidden ?? (this.hidden = true);
|
|
21
21
|
__classPrivateFieldGet(this, _BaseTabPanel_internals, "f").role = 'tabpanel';
|
|
22
22
|
/*
|
|
23
23
|
To make it easy for screen reader users to navigate from a tab
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseTabPanel.js","sourceRoot":"","sources":["BaseTabPanel.ts"],"names":[],"mappings":";;AAAA,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;;;AAIvC,OAAO,EAAE,WAAW,EAAE,MAAM,0CAA0C,CAAC;AAEvE,MAAsB,YAAa,SAAQ,UAAU;IAArD;;QAGE,
|
|
1
|
+
{"version":3,"file":"BaseTabPanel.js","sourceRoot":"","sources":["BaseTabPanel.ts"],"names":[],"mappings":";;AAAA,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;;;AAIvC,OAAO,EAAE,WAAW,EAAE,MAAM,0CAA0C,CAAC;AAEvE,MAAsB,YAAa,SAAQ,UAAU;IAArD;;QAGE,kCAAa,IAAI,CAAC,eAAe,EAAE,EAAC;IAyBtC,CAAC;IAvBC,MAAM;QACJ,OAAO,IAAI,CAAA;;KAEV,CAAC;IACJ,CAAC;IAED,iBAAiB;QACf,KAAK,CAAC,iBAAiB,EAAE,CAAC;QAC1B,IAAI,CAAC,EAAE,KAAP,IAAI,CAAC,EAAE,GAAK,WAAW,CAAC,cAAc,CAAC,EAAC;QACxC,IAAI,CAAC,MAAM,KAAX,IAAI,CAAC,MAAM,GAAK,IAAI,EAAC;QACrB,uBAAA,IAAI,+BAAW,CAAC,IAAI,GAAG,UAAU,CAAC;QAElC;;;;;;;;UAQE;QACF,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAC;IACpB,CAAC;;;AA1Be,mBAAM,GAAG,CAAC,KAAK,CAAC,AAAV,CAAW;SADb,YAAY","sourcesContent":["import { LitElement, html } from 'lit';\n\nimport style from './BaseTabPanel.css';\n\nimport { getRandomId } from '@patternfly/pfe-core/functions/random.js';\n\nexport abstract class BaseTabPanel extends LitElement {\n static readonly styles = [style];\n\n #internals = this.attachInternals();\n\n render() {\n return html`\n <slot></slot>\n `;\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.id ||= getRandomId('pf-tab-panel');\n this.hidden ??= true;\n this.#internals.role = 'tabpanel';\n\n /*\n To make it easy for screen reader users to navigate from a tab\n to the beginning of content in the active tabpanel, the tabpanel\n element has tabindex=\"0\" to include the panel in the page Tab sequence.\n It is recommended that all tabpanel elements in a tab set are focusable\n if there are any panels in the set that contain content where the first\n element in the panel is not focusable.\n https://www.w3.org/WAI/ARIA/apg/example-index/tabs/tabs-automatic\n */\n this.tabIndex = 0;\n }\n}\n"]}
|
package/pf-tabs/pf-tab.css
CHANGED
|
@@ -127,6 +127,10 @@ button:active {
|
|
|
127
127
|
display: flex !important;
|
|
128
128
|
}
|
|
129
129
|
|
|
130
|
+
[part="icon"][hidden] {
|
|
131
|
+
display: none !important;
|
|
132
|
+
}
|
|
133
|
+
|
|
130
134
|
:host([disabled][border-bottom="false"]) button,
|
|
131
135
|
:host([aria-disabled="true"][border-bottom="false"]) button {
|
|
132
136
|
--pf-c-tabs__link--before--BorderBottomWidth: 0;
|
package/pf-tabs/pf-tab.js
CHANGED
|
@@ -4,7 +4,7 @@ import { property } from 'lit/decorators/property.js';
|
|
|
4
4
|
import { observed } from '@patternfly/pfe-core/decorators.js';
|
|
5
5
|
import { BaseTab } from './BaseTab.js';
|
|
6
6
|
import { css } from "lit";
|
|
7
|
-
const styles = css `:host{scroll-snap-align:var(--pf-c-tabs__item--ScrollSnapAlign,end)}:host([active]){--pf-c-tabs__link--Color:var(--pf-c-tabs__item--m-current__link--Color, var(--pf-global--Color--100, #151515));--pf-c-tabs__link--after--BorderColor:var(--pf-c-tabs__item--m-current__link--after--BorderColor, var(--pf-global--active-color--100, #06c));--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__item--m-current__link--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}:host([box][active]){--pf-c-tabs__link--BackgroundColor:var(--pf-c-tabs__item--m-current__link--BackgroundColor, var(--pf-global--BackgroundColor--100, #ffffff));--pf-c-tabs__link--before--BorderBottomColor:var(--pf-c-tabs__link--BackgroundColor, transparent)}:host(.first[box][active]) #current::before{left:calc(var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)) * -1)}button{align-items:center;gap:var(--pf-c-tabs__link--child--MarginRight,var(--pf-global--spacer--md,1rem));line-height:var(--pf-global--LineHeight--md, 1.5);color:var(--pf-global--Color--100,#151515);padding:var(--pf-c-tabs__link--PaddingTop,var(--pf-global--spacer--sm,.5rem)) var(--pf-c-tabs__link--PaddingRight,var(--pf-global--spacer--md,1rem)) var(--pf-c-tabs__link--PaddingBottom,var(--pf-global--spacer--sm,.5rem)) var(--pf-c-tabs__link--PaddingLeft,var(--pf-global--spacer--md,1rem));font-size:var(--pf-c-tabs__link--FontSize, var(--pf-global--FontSize--md, 1rem));color:var(--pf-c-tabs__link--Color,var(--pf-global--Color--200,#6a6e73));outline-offset:var(--pf-c-tabs__link--OutlineOffset,calc(-1 * 0.375rem));--pf-c-tabs__link--after--BorderBottomWidth:var(--pf-c-tabs__link--after--BorderWidth, 0);background-color:var(--pf-c-tabs__link--BackgroundColor,transparent)}button::before{border-block-start-width:var(--pf-c-tabs__link--before--BorderTopWidth,0);border-inline-end-width:var(--pf-c-tabs__link--before--BorderRightWidth,0);border-block-end-width:var(--pf-c-tabs__link--before--BorderBottomWidth,0);border-inline-start-width:var(--pf-c-tabs__link--before--BorderLeftWidth,0);border-block-start-color:var(--pf-c-tabs__link--before--BorderTopColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)));border-inline-end-color:var(--pf-c-tabs__link--before--BorderRightColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)));border-block-end-color:var(--pf-c-tabs__link--before--BorderBottomColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)));border-inline-start-color:var(--pf-c-tabs__link--before--BorderLeftColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)))}button::after{top:var(--pf-c-tabs__link--after--Top,auto);right:var(--pf-c-tabs__link--after--Right,0);bottom:var(--pf-c-tabs__link--after--Bottom,0);left:var(--pf-c-tabs__link--before--Left,0);border-color:var(--pf-c-tabs__link--after--BorderColor,var(--pf-global--BorderColor--light-100,#b8bbbe));border-block-start-width:var(--pf-c-tabs__link--after--BorderTopWidth,0);border-inline-end-width:var(--pf-c-tabs__link--after--BorderRightWidth,0);border-block-end-width:var(--pf-c-tabs__link--after--BorderBottomWidth);border-inline-start-width:var(--pf-c-tabs__link--after--BorderLeftWidth)}button:hover{--pf-c-tabs__link-toggle-icon--Color:var(--pf-c-tabs__link--hover__toggle-icon--Color);--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__link--hover--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}button:focus,button:focus-visible{outline-color:var(--pf-c-tabs__link--after--BorderColor,#06c);--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__link--focus--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}button:active{--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__link--active--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}:host([box]) button{--pf-c-tabs__link--after--BorderTopWidth:var(--pf-c-tabs__link--after--BorderWidth, 0)}:host([box]) button,:host([vertical]) button{--pf-c-tabs__link--after--BorderBottomWidth:0}:host([vertical]) button{--pf-c-tabs__link--after--Bottom:0;--pf-c-tabs__link--after--BorderTopWidth:0;--pf-c-tabs__link--after--BorderLeftWidth:var(--pf-c-tabs__link--after--BorderWidth, 0);max-width:100%;text-align:left}:host([box][vertical]) button::after{top:calc(var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)) * -1)}:host(.first[box][vertical]) button::after,:host([box][vertical][active]) button::after{top:0}:host([box][vertical][active]) button::before{--pf-c-tabs__link--before--BorderRightColor:var(--pf-c-tabs__item--m-current__link--BackgroundColor, var(--pf-global--BackgroundColor--100, #ffffff));--pf-c-tabs__link--before--BorderBottomWidth:var(--pf-c-tabs__link--before--border-width--base, var(--pf-global--BorderWidth--sm, 1px));--pf-c-tabs__link--before--BorderBottomColor:var(--pf-c-tabs__link--before--border-color--base, var(--pf-global--BorderColor--100, #d2d2d2))}:host(.first[box][active]) button::before{border-block-start-width:var(--pf-c-tabs--m-box__item--m-current--first-child__link--before--BorderTopWidth,var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)));border-inline-start-width:var(--pf-c-tabs--m-box__item--m-current--first-child__link--before--BorderLeftWidth,var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)))}:host(.last[box][active]) button::before{border-inline-end-width:var(--pf-c-tabs--m-box__item--m-current--last-child__link--before--BorderRightWidth,var(--pf-c-tabs--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)))}:host([aria-disabled=true]) button,:host([disabled]) button{--pf-c-tabs__link--Color:var(--pf-c-tabs__link--disabled--Color, var(--pf-global--disabled-color--100, #6a6e73));--pf-c-tabs__link--BackgroundColor:var(--pf-c-tabs__link--disabled--BackgroundColor, var(--pf-global--palette--black-150, #f5f5f5));--pf-c-tabs__link--before--BorderRightWidth:var(--pf-c-tabs__link--disabled--before--BorderRightWidth, 0);--pf-c-tabs__link--before--BorderBottomWidth:var(--pf-c-tabs__link--disabled--before--BorderBottomWidth, var(--pf-c-tabs--before--border-width--base, var(--pf-global--BorderWidth--sm, 1px)));--pf-c-tabs__link--before--BorderLeftWidth:var(--pf-c-tabs__link--disabled--before--BorderLeftWidth, 0);--pf-c-tabs__link--after--BorderWidth:0}[part=icon]{display:flex!important}:host([aria-disabled=true][border-bottom=false]) button,:host([disabled][border-bottom=false]) button{--pf-c-tabs__link--before--BorderBottomWidth:0}`;
|
|
7
|
+
const styles = css `:host{scroll-snap-align:var(--pf-c-tabs__item--ScrollSnapAlign,end)}:host([active]){--pf-c-tabs__link--Color:var(--pf-c-tabs__item--m-current__link--Color, var(--pf-global--Color--100, #151515));--pf-c-tabs__link--after--BorderColor:var(--pf-c-tabs__item--m-current__link--after--BorderColor, var(--pf-global--active-color--100, #06c));--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__item--m-current__link--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}:host([box][active]){--pf-c-tabs__link--BackgroundColor:var(--pf-c-tabs__item--m-current__link--BackgroundColor, var(--pf-global--BackgroundColor--100, #ffffff));--pf-c-tabs__link--before--BorderBottomColor:var(--pf-c-tabs__link--BackgroundColor, transparent)}:host(.first[box][active]) #current::before{left:calc(var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)) * -1)}button{align-items:center;gap:var(--pf-c-tabs__link--child--MarginRight,var(--pf-global--spacer--md,1rem));line-height:var(--pf-global--LineHeight--md, 1.5);color:var(--pf-global--Color--100,#151515);padding:var(--pf-c-tabs__link--PaddingTop,var(--pf-global--spacer--sm,.5rem)) var(--pf-c-tabs__link--PaddingRight,var(--pf-global--spacer--md,1rem)) var(--pf-c-tabs__link--PaddingBottom,var(--pf-global--spacer--sm,.5rem)) var(--pf-c-tabs__link--PaddingLeft,var(--pf-global--spacer--md,1rem));font-size:var(--pf-c-tabs__link--FontSize, var(--pf-global--FontSize--md, 1rem));color:var(--pf-c-tabs__link--Color,var(--pf-global--Color--200,#6a6e73));outline-offset:var(--pf-c-tabs__link--OutlineOffset,calc(-1 * 0.375rem));--pf-c-tabs__link--after--BorderBottomWidth:var(--pf-c-tabs__link--after--BorderWidth, 0);background-color:var(--pf-c-tabs__link--BackgroundColor,transparent)}button::before{border-block-start-width:var(--pf-c-tabs__link--before--BorderTopWidth,0);border-inline-end-width:var(--pf-c-tabs__link--before--BorderRightWidth,0);border-block-end-width:var(--pf-c-tabs__link--before--BorderBottomWidth,0);border-inline-start-width:var(--pf-c-tabs__link--before--BorderLeftWidth,0);border-block-start-color:var(--pf-c-tabs__link--before--BorderTopColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)));border-inline-end-color:var(--pf-c-tabs__link--before--BorderRightColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)));border-block-end-color:var(--pf-c-tabs__link--before--BorderBottomColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)));border-inline-start-color:var(--pf-c-tabs__link--before--BorderLeftColor,var(--pf-c-tabs__link--before--border-color--base,var(--pf-global--BorderColor--100,#d2d2d2)))}button::after{top:var(--pf-c-tabs__link--after--Top,auto);right:var(--pf-c-tabs__link--after--Right,0);bottom:var(--pf-c-tabs__link--after--Bottom,0);left:var(--pf-c-tabs__link--before--Left,0);border-color:var(--pf-c-tabs__link--after--BorderColor,var(--pf-global--BorderColor--light-100,#b8bbbe));border-block-start-width:var(--pf-c-tabs__link--after--BorderTopWidth,0);border-inline-end-width:var(--pf-c-tabs__link--after--BorderRightWidth,0);border-block-end-width:var(--pf-c-tabs__link--after--BorderBottomWidth);border-inline-start-width:var(--pf-c-tabs__link--after--BorderLeftWidth)}button:hover{--pf-c-tabs__link-toggle-icon--Color:var(--pf-c-tabs__link--hover__toggle-icon--Color);--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__link--hover--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}button:focus,button:focus-visible{outline-color:var(--pf-c-tabs__link--after--BorderColor,#06c);--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__link--focus--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}button:active{--pf-c-tabs__link--after--BorderWidth:var(--pf-c-tabs__link--active--after--BorderWidth, var(--pf-global--BorderWidth--lg, 3px))}:host([box]) button{--pf-c-tabs__link--after--BorderTopWidth:var(--pf-c-tabs__link--after--BorderWidth, 0)}:host([box]) button,:host([vertical]) button{--pf-c-tabs__link--after--BorderBottomWidth:0}:host([vertical]) button{--pf-c-tabs__link--after--Bottom:0;--pf-c-tabs__link--after--BorderTopWidth:0;--pf-c-tabs__link--after--BorderLeftWidth:var(--pf-c-tabs__link--after--BorderWidth, 0);max-width:100%;text-align:left}:host([box][vertical]) button::after{top:calc(var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)) * -1)}:host(.first[box][vertical]) button::after,:host([box][vertical][active]) button::after{top:0}:host([box][vertical][active]) button::before{--pf-c-tabs__link--before--BorderRightColor:var(--pf-c-tabs__item--m-current__link--BackgroundColor, var(--pf-global--BackgroundColor--100, #ffffff));--pf-c-tabs__link--before--BorderBottomWidth:var(--pf-c-tabs__link--before--border-width--base, var(--pf-global--BorderWidth--sm, 1px));--pf-c-tabs__link--before--BorderBottomColor:var(--pf-c-tabs__link--before--border-color--base, var(--pf-global--BorderColor--100, #d2d2d2))}:host(.first[box][active]) button::before{border-block-start-width:var(--pf-c-tabs--m-box__item--m-current--first-child__link--before--BorderTopWidth,var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)));border-inline-start-width:var(--pf-c-tabs--m-box__item--m-current--first-child__link--before--BorderLeftWidth,var(--pf-c-tabs__link--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)))}:host(.last[box][active]) button::before{border-inline-end-width:var(--pf-c-tabs--m-box__item--m-current--last-child__link--before--BorderRightWidth,var(--pf-c-tabs--before--border-width--base,var(--pf-global--BorderWidth--sm,1px)))}:host([aria-disabled=true]) button,:host([disabled]) button{--pf-c-tabs__link--Color:var(--pf-c-tabs__link--disabled--Color, var(--pf-global--disabled-color--100, #6a6e73));--pf-c-tabs__link--BackgroundColor:var(--pf-c-tabs__link--disabled--BackgroundColor, var(--pf-global--palette--black-150, #f5f5f5));--pf-c-tabs__link--before--BorderRightWidth:var(--pf-c-tabs__link--disabled--before--BorderRightWidth, 0);--pf-c-tabs__link--before--BorderBottomWidth:var(--pf-c-tabs__link--disabled--before--BorderBottomWidth, var(--pf-c-tabs--before--border-width--base, var(--pf-global--BorderWidth--sm, 1px)));--pf-c-tabs__link--before--BorderLeftWidth:var(--pf-c-tabs__link--disabled--before--BorderLeftWidth, 0);--pf-c-tabs__link--after--BorderWidth:0}[part=icon]{display:flex!important}[part=icon][hidden]{display:none!important}:host([aria-disabled=true][border-bottom=false]) button,:host([disabled][border-bottom=false]) button{--pf-c-tabs__link--before--BorderBottomWidth:0}`;
|
|
8
8
|
/**
|
|
9
9
|
* Tab
|
|
10
10
|
*
|