@getflip/swirl-components-react 0.4.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{file-manager.entry.07628dad.js → file-manager.entry.d9f3d27a.js} +1 -1
- package/dist/{flip-action-list-item.entry.a330605c.js → flip-action-list-item.entry.1c128d88.js} +1 -1
- package/dist/{flip-action-list-section.entry.19091d98.js → flip-action-list-section.entry.334da9b3.js} +1 -1
- package/dist/{flip-action-list.entry.319f0192.js → flip-action-list.entry.4c21bf13.js} +1 -1
- package/dist/{flip-app-layout_5.entry.ac01996d.js → flip-app-layout_5.entry.347244e3.js} +16 -16
- package/dist/{flip-autocomplete.entry.21deedf2.js → flip-autocomplete.entry.cb35664c.js} +1 -1
- package/dist/{flip-avatar-group.entry.c2cc9526.js → flip-avatar-group.entry.0d05ee77.js} +1 -1
- package/dist/{flip-avatar.entry.7034b888.js → flip-avatar.entry.cda211fb.js} +1 -1
- package/dist/{flip-badge.entry.bc935c62.js → flip-badge.entry.dba6f4d0.js} +1 -1
- package/dist/{flip-banner.entry.d257835c.js → flip-banner.entry.6e98f9bb.js} +1 -1
- package/dist/{flip-button-group.entry.8ce7a3d4.js → flip-button-group.entry.5efab101.js} +1 -1
- package/dist/{flip-button.entry.eb07eb8a.js → flip-button.entry.7c41cd24.js} +12 -6
- package/dist/{flip-checkbox.entry.43a3832e.js → flip-checkbox.entry.3c5f9edd.js} +10 -7
- package/dist/{flip-chip.entry.a479c5b0.js → flip-chip.entry.c5182889.js} +1 -1
- package/dist/flip-console-layout.entry.68f44b8d.js +22 -0
- package/dist/{flip-date-input.entry.b98d662b.js → flip-date-input.entry.7bb78ec2.js} +6 -4
- package/dist/{flip-date-picker_2.entry.c2143459.js → flip-date-picker_2.entry.d02d7d18.js} +105 -103
- package/dist/{flip-description-list-item.entry.f1db6930.js → flip-description-list-item.entry.32818cd7.js} +1 -1
- package/dist/{flip-description-list.entry.0e214ec2.js → flip-description-list.entry.0024df2f.js} +1 -1
- package/dist/{flip-dialog.entry.24f62804.js → flip-dialog.entry.437ef265.js} +1 -1
- package/dist/{flip-file-uploader.entry.91b6ca52.js → flip-file-uploader.entry.ea3c7ead.js} +1 -1
- package/dist/{flip-file-viewer_7.entry.47a4ee0d.js → flip-file-viewer_7.entry.77ae38e2.js} +2 -2
- package/dist/flip-form-control.entry.9a1837a0.js +65 -0
- package/dist/{flip-form-group.entry.89c2a7a6.js → flip-form-group.entry.47e4c08c.js} +1 -1
- package/dist/flip-heading_2.entry.cb81a796.js +29 -0
- package/dist/{flip-icon-add-photo.entry.b5415432.js → flip-icon-add-photo.entry.a8a8d445.js} +1 -1
- package/dist/{flip-icon-add_4.entry.b525e436.js → flip-icon-add_4.entry.a1e5683b.js} +1 -1
- package/dist/{flip-icon-admin-panel-settings.entry.e416caa2.js → flip-icon-admin-panel-settings.entry.ee4119fe.js} +1 -1
- package/dist/{flip-icon-arrow-back.entry.3b24c3c4.js → flip-icon-arrow-back.entry.bba591b0.js} +1 -1
- package/dist/{flip-icon-arrow-forward.entry.c3577622.js → flip-icon-arrow-forward.entry.40958632.js} +1 -1
- package/dist/{flip-icon-arrow-left_3.entry.0e8c6ffd.js → flip-icon-arrow-left_3.entry.525685ca.js} +1 -1
- package/dist/{flip-icon-arrow-right-small.entry.36a480f8.js → flip-icon-arrow-right-small.entry.76263ee0.js} +1 -1
- package/dist/{flip-icon-attachment.entry.d44215f9.js → flip-icon-attachment.entry.04d1b5c8.js} +1 -1
- package/dist/{flip-icon-cancel_4.entry.90ff0e73.js → flip-icon-cancel_4.entry.a2265e64.js} +1 -1
- package/dist/{flip-icon-chat-bubble.entry.b8022c94.js → flip-icon-chat-bubble.entry.22d525da.js} +1 -1
- package/dist/{flip-icon-check-circle.entry.b59a0f63.js → flip-icon-check-circle.entry.182067b5.js} +1 -1
- package/dist/{flip-icon-check-small_3.entry.fd9f691c.js → flip-icon-check-small_3.entry.8a94f7b3.js} +10 -12
- package/dist/{flip-icon-check-strong.entry.cab3e061.js → flip-icon-check-strong.entry.6cb41e4f.js} +1 -1
- package/dist/{flip-icon-check.entry.f6231fc3.js → flip-icon-check.entry.a195ea64.js} +1 -1
- package/dist/{flip-icon-chevron-left.entry.cd972c85.js → flip-icon-chevron-left.entry.198a6c6e.js} +1 -1
- package/dist/{flip-icon-chevron-right.entry.b96a1ead.js → flip-icon-chevron-right.entry.1e2690e6.js} +1 -1
- package/dist/{flip-icon-close-small.entry.292f402f.js → flip-icon-close-small.entry.0f507ec2.js} +1 -1
- package/dist/{flip-icon-close.entry.a52651ec.js → flip-icon-close.entry.a1c2309c.js} +1 -1
- package/dist/{flip-icon-cloud-upload.entry.8c3de009.js → flip-icon-cloud-upload.entry.5327701c.js} +1 -1
- package/dist/{flip-icon-comment.entry.68e5198c.js → flip-icon-comment.entry.373b8991.js} +1 -1
- package/dist/{flip-icon-copy.entry.ea55301c.js → flip-icon-copy.entry.aec8a13e.js} +1 -1
- package/dist/{flip-icon-date-range.entry.78991d34.js → flip-icon-date-range.entry.fea1cf38.js} +1 -1
- package/dist/{flip-icon-delete.entry.addf184d.js → flip-icon-delete.entry.b7419f79.js} +1 -1
- package/dist/{flip-icon-description.entry.7688a64f.js → flip-icon-description.entry.8d67775f.js} +1 -1
- package/dist/{flip-icon-edit.entry.5df4b598.js → flip-icon-edit.entry.0eab03a3.js} +1 -1
- package/dist/{flip-icon-emoji-mood.entry.7772f2da.js → flip-icon-emoji-mood.entry.30a3429b.js} +1 -1
- package/dist/{flip-icon-emoji-satisfied.entry.3f11571c.js → flip-icon-emoji-satisfied.entry.63a2ae47.js} +1 -1
- package/dist/{flip-icon-error_3.entry.6d22b7a2.js → flip-icon-error_3.entry.45a74e75.js} +1 -1
- package/dist/{flip-icon-expand-more.entry.2ffa6f0c.js → flip-icon-expand-more.entry.73658fc0.js} +1 -1
- package/dist/{flip-icon-file.entry.517a75cc.js → flip-icon-file.entry.f65b6a2f.js} +1 -1
- package/dist/{flip-icon-folder-shared.entry.661494c2.js → flip-icon-folder-shared.entry.23738b25.js} +1 -1
- package/dist/{flip-icon-group-assign.entry.8131eb64.js → flip-icon-group-assign.entry.636e9998.js} +1 -1
- package/dist/{flip-icon-groups-custom.entry.f0086123.js → flip-icon-groups-custom.entry.f5c66a69.js} +1 -1
- package/dist/{flip-icon-groups.entry.2e076144.js → flip-icon-groups.entry.8e68cafb.js} +1 -1
- package/dist/flip-icon-help.entry.444d15a1.js +15 -0
- package/dist/{flip-icon-image.entry.d0482319.js → flip-icon-image.entry.316a344d.js} +1 -1
- package/dist/{flip-icon-info.entry.d16cf109.js → flip-icon-info.entry.af65e307.js} +1 -1
- package/dist/{flip-icon-inventory.entry.a209dd1e.js → flip-icon-inventory.entry.fbad218e.js} +1 -1
- package/dist/{flip-icon-like.entry.631333f8.js → flip-icon-like.entry.7d3db5ae.js} +1 -1
- package/dist/{flip-icon-link.entry.b67ce56a.js → flip-icon-link.entry.677e149f.js} +1 -1
- package/dist/{flip-icon-lock.entry.13f8fa54.js → flip-icon-lock.entry.11be61be.js} +1 -1
- package/dist/{flip-icon-logout.entry.79b91644.js → flip-icon-logout.entry.159c37fa.js} +1 -1
- package/dist/{flip-icon-mail.entry.62265dc6.js → flip-icon-mail.entry.d467f931.js} +1 -1
- package/dist/{flip-icon-manage-accounts.entry.e821e9df.js → flip-icon-manage-accounts.entry.75c892ba.js} +1 -1
- package/dist/{flip-icon-mention.entry.09ac190a.js → flip-icon-mention.entry.dcb88d21.js} +1 -1
- package/dist/{flip-icon-message.entry.06934900.js → flip-icon-message.entry.fa72a55b.js} +1 -1
- package/dist/{flip-icon-more-horizontal.entry.d1d97d3d.js → flip-icon-more-horizontal.entry.23928cc6.js} +1 -1
- package/dist/{flip-icon-more-vertikal.entry.d40ca8b0.js → flip-icon-more-vertikal.entry.f6fe806b.js} +1 -1
- package/dist/{flip-icon-notifications-active.entry.c38ee4bb.js → flip-icon-notifications-active.entry.7fb87055.js} +1 -1
- package/dist/{flip-icon-notifications-off.entry.02743a47.js → flip-icon-notifications-off.entry.06a2a9b1.js} +1 -1
- package/dist/{flip-icon-notifications.entry.4f873bc3.js → flip-icon-notifications.entry.6f36160e.js} +1 -1
- package/dist/{flip-icon-open-in-new.entry.cb673e42.js → flip-icon-open-in-new.entry.2b7f8934.js} +1 -1
- package/dist/{flip-icon-people-alt.entry.648a37d3.js → flip-icon-people-alt.entry.26e02431.js} +1 -1
- package/dist/{flip-icon-person-off.entry.3bc3e587.js → flip-icon-person-off.entry.ed8898eb.js} +1 -1
- package/dist/{flip-icon-person.entry.b269287a.js → flip-icon-person.entry.72939e0b.js} +1 -1
- package/dist/{flip-icon-phone.entry.89c67938.js → flip-icon-phone.entry.becf1ab9.js} +1 -1
- package/dist/{flip-icon-poll.entry.51bd2d6b.js → flip-icon-poll.entry.df7fe3c0.js} +1 -1
- package/dist/{flip-icon-print.entry.fcdc08c4.js → flip-icon-print.entry.54999b03.js} +1 -1
- package/dist/{flip-icon-recieved.entry.e52d5907.js → flip-icon-recieved.entry.8bc7429e.js} +1 -1
- package/dist/{flip-icon-search-strong.entry.f9f740dc.js → flip-icon-search-strong.entry.92a12b0d.js} +1 -1
- package/dist/{flip-icon-search.entry.530eb22a.js → flip-icon-search.entry.100c714d.js} +1 -1
- package/dist/{flip-icon-send.entry.1a1f6a9f.js → flip-icon-send.entry.13f0dd9b.js} +1 -1
- package/dist/{flip-icon-settings.entry.05357f2b.js → flip-icon-settings.entry.c7007498.js} +1 -1
- package/dist/{flip-icon-time-filled.entry.7dfefe00.js → flip-icon-time-filled.entry.942f7527.js} +1 -1
- package/dist/{flip-icon-time-outlined.entry.b309035e.js → flip-icon-time-outlined.entry.c526b8b2.js} +1 -1
- package/dist/{flip-icon-user-assign.entry.b595047d.js → flip-icon-user-assign.entry.a202c672.js} +1 -1
- package/dist/{flip-icon-video-camera.entry.08411542.js → flip-icon-video-camera.entry.d50960b4.js} +1 -1
- package/dist/{flip-icon-warning.entry.5d5e3ce9.js → flip-icon-warning.entry.3c7f17b0.js} +1 -1
- package/dist/{flip-lightbox.entry.d7a5b33f.js → flip-lightbox.entry.d0818fdd.js} +1 -1
- package/dist/{flip-link.entry.5415c5a4.js → flip-link.entry.e104fd62.js} +1 -1
- package/dist/{flip-list.entry.5ffbd0ef.js → flip-list.entry.62924a6e.js} +1 -1
- package/dist/{flip-modal.entry.8f99c357.js → flip-modal.entry.8ee1afb7.js} +1 -1
- package/dist/{flip-option-list-section.entry.1c46b667.js → flip-option-list-section.entry.90e3540e.js} +1 -1
- package/dist/{flip-pagination.entry.44ba4122.js → flip-pagination.entry.9f1e2b11.js} +1 -1
- package/dist/{flip-pdf-reader.entry.4fba8eda.js → flip-pdf-reader.entry.585cacc2.js} +2 -2
- package/dist/flip-popover.entry.4358f1ca.js +115 -0
- package/dist/{flip-progress-indicator.entry.98300d84.js → flip-progress-indicator.entry.bac7c479.js} +1 -1
- package/dist/{flip-radio-group.entry.3a737bc9.js → flip-radio-group.entry.fc16ef00.js} +1 -1
- package/dist/{flip-radio.entry.45be80ff.js → flip-radio.entry.c5d1ab8e.js} +8 -5
- package/dist/{flip-resource-list-file-item.entry.380c5dbe.js → flip-resource-list-file-item.entry.2e01187c.js} +1 -1
- package/dist/{flip-search.entry.6805dae6.js → flip-search.entry.8501c4b3.js} +1 -1
- package/dist/flip-select.entry.9e6fe095.js +48 -0
- package/dist/{flip-stack.entry.c7c6570a.js → flip-stack.entry.a8ee7905.js} +2 -2
- package/dist/{flip-switch.entry.d92b7292.js → flip-switch.entry.9983e3b6.js} +1 -1
- package/dist/{flip-tab.entry.e7a1ab1a.js → flip-tab.entry.9d13ff74.js} +1 -1
- package/dist/{flip-tabs.entry.16f909d5.js → flip-tabs.entry.1353be6c.js} +1 -1
- package/dist/{flip-tag.entry.8622ab43.js → flip-tag.entry.0846fe2b.js} +1 -1
- package/dist/{flip-text-input.entry.326d7e72.js → flip-text-input.entry.a6d65510.js} +10 -8
- package/dist/{flip-theme-provider.entry.bb6a10e3.js → flip-theme-provider.entry.5d46f8fb.js} +1 -1
- package/dist/{flip-thumbnail.entry.7e078ff9.js → flip-thumbnail.entry.11498fad.js} +1 -1
- package/dist/{flip-toast-provider.entry.442c1fb8.js → flip-toast-provider.entry.edb50e5e.js} +5 -3
- package/dist/{flip-toast.entry.696f6bd2.js → flip-toast.entry.6d97c755.js} +1 -1
- package/dist/{flip-tooltip.entry.0c1774a4.js → flip-tooltip.entry.b695fc31.js} +2 -2
- package/dist/{flip-video-thumbnail.entry.b6b896d0.js → flip-video-thumbnail.entry.058d8c16.js} +1 -1
- package/dist/{flip-visually-hidden.entry.58a19f2e.js → flip-visually-hidden.entry.0197105f.js} +1 -1
- package/dist/index.7e0e9911.js +1368 -0
- package/dist/stencil-generated/index.d.ts +3 -0
- package/dist/swirl-components-react.js +125 -122
- package/dist/swirl-components-react.umd.cjs +39 -36
- package/package.json +2 -2
- package/dist/flip-form-control.entry.82737412.js +0 -58
- package/dist/flip-heading.entry.00139b62.js +0 -18
- package/dist/flip-popover.entry.0f8879c7.js +0 -99
- package/dist/flip-text.entry.a01cf4bc.js +0 -18
- package/dist/index.b66ff9f0.js +0 -1365
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@getflip/swirl-components-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist"
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"build": "tsc && vite build"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@getflip/swirl-components": "^0.
|
|
21
|
+
"@getflip/swirl-components": "^0.6.1",
|
|
22
22
|
"react": "^18.2.0",
|
|
23
23
|
"react-dom": "^18.2.0"
|
|
24
24
|
},
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { r as e, h as t, H as i, g as l } from "./index.b66ff9f0.js";
|
|
2
|
-
import { c as n } from "./index-6d2e18c6.289636d4.js";
|
|
3
|
-
import "react";
|
|
4
|
-
import "react-dom";
|
|
5
|
-
import "./_commonjsHelpers-44457d8d.ba94af77.js";
|
|
6
|
-
const a = ".sc-flip-form-control-h{display:block;width:100%}.sc-flip-form-control-h *.sc-flip-form-control{box-sizing:border-box}.form-control.sc-flip-form-control{display:block;width:100%;line-height:var(--s-line-height-sm)}.form-control.form-control--has-focus.sc-flip-form-control:not(.form-control--disabled) .form-control__label.sc-flip-form-control{border-color:var(--s-border-highlight);box-shadow:0 0 0 var(--s-border-width-default) var(--s-border-highlight)}.form-control.sc-flip-form-control:not(.form-control--has-value):not(.form-control--has-focus) .form-control__input.sc-flip-form-control{overflow:hidden;max-height:0}.form-control.sc-flip-form-control:not(.form-control--has-value):not(.form-control--has-focus) .form-control__label-text.sc-flip-form-control{bottom:50%;font-size:var(--s-font-size-base);transform:translateY(50%)}.form-control--invalid.form-control--has-focus.sc-flip-form-control:not(.form-control--disabled) .form-control__label.sc-flip-form-control{border-color:var(--s-border-critical);box-shadow:0 0 0 var(--s-border-width-default) var(--s-border-critical)}.form-control--invalid.sc-flip-form-control .form-control__label.sc-flip-form-control{border-color:var(--s-border-critical)}.form-control--disabled.sc-flip-form-control .form-control__label.sc-flip-form-control{border-color:var(--s-border-disabled);color:var(--s-text-disabled)}.form-control--disabled.sc-flip-form-control .form-control__description.sc-flip-form-control{color:var(--s-text-disabled)}.form-control__label.sc-flip-form-control{position:relative;display:flex;width:100%;min-height:4.375rem;padding:calc(var(--s-space-12) + 1.25rem) var(--s-space-16) var(--s-space-12);justify-content:center;border:var(--s-border-width-default) solid var(--s-border-strong);border-radius:var(--s-border-radius-sm);color:var(--s-text-subdued);flex-direction:column;gap:var(--s-space-2)}.form-control__label-text.sc-flip-form-control{position:absolute;right:var(--s-space-16);bottom:calc(100% - 1.25rem - var(--s-space-12));left:var(--s-space-16);overflow:hidden;font-size:var(--s-font-size-sm);white-space:nowrap;text-overflow:ellipsis;transition:font-size 0.15s, transform 0.15s, top 0.15s;transform:none}.form-control__description.sc-flip-form-control{display:block;margin-top:var(--s-space-4);padding-left:var(--s-space-4);color:var(--s-text-subdued);font-size:var(--s-font-size-sm)}.form-control__error-message.sc-flip-form-control{display:block;margin-top:var(--s-space-4);padding-left:var(--s-space-4)}", c = class {
|
|
7
|
-
constructor(r) {
|
|
8
|
-
e(this, r), this.descriptionId = `form-control-description-${Math.round(Math.random() * 1e5)}`, this.listenToInputValueChanges = () => {
|
|
9
|
-
this.inputEl.addEventListener("valueChange", this.checkInputValue);
|
|
10
|
-
}, this.checkInputValue = () => {
|
|
11
|
-
var o;
|
|
12
|
-
this.inputValue = (o = this.inputEl) === null || o === void 0 ? void 0 : o.value;
|
|
13
|
-
}, this.onFocusIn = () => {
|
|
14
|
-
this.hasFocus = !0;
|
|
15
|
-
}, this.onFocusOut = (o) => {
|
|
16
|
-
Boolean(o.relatedTarget) && (this.hasFocus = !1);
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
componentWillLoad() {
|
|
20
|
-
this.inputEl = this.el.children[0], this.associateDescriptionWithInputElement(), this.setInputElementDisabledState(), this.setInputElementInvalidState(), this.checkInputValue(), this.listenToInputValueChanges();
|
|
21
|
-
}
|
|
22
|
-
associateDescriptionWithInputElement() {
|
|
23
|
-
!Boolean(this.description) || !Boolean(this.inputEl) || this.inputEl.setAttribute("flip-aria-describedby", this.descriptionId);
|
|
24
|
-
}
|
|
25
|
-
setInputElementDisabledState() {
|
|
26
|
-
!Boolean(this.inputEl) || (this.disabled ? this.inputEl.setAttribute("disabled", "true") : this.inputEl.removeAttribute("disabled"));
|
|
27
|
-
}
|
|
28
|
-
setInputElementInvalidState() {
|
|
29
|
-
!Boolean(this.inputEl) || (this.invalid ? this.inputEl.setAttribute("invalid", "true") : this.inputEl.removeAttribute("invalid"));
|
|
30
|
-
}
|
|
31
|
-
onWindowClick(r) {
|
|
32
|
-
const o = r.target;
|
|
33
|
-
this.el.contains(o) || (this.hasFocus = !1);
|
|
34
|
-
}
|
|
35
|
-
render() {
|
|
36
|
-
const r = Boolean(this.errorMessage), o = Boolean(this.description) && !r, s = n("form-control", {
|
|
37
|
-
"form-control--disabled": this.disabled,
|
|
38
|
-
"form-control--has-focus": this.hasFocus,
|
|
39
|
-
"form-control--has-value": Boolean(this.inputValue),
|
|
40
|
-
"form-control--invalid": this.invalid
|
|
41
|
-
});
|
|
42
|
-
return t(i, { onFocusin: this.onFocusIn, onFocusout: this.onFocusOut }, t("div", { class: s, role: "group" }, t("label", { class: "form-control__label" }, t("span", { class: "form-control__label-text" }, this.label), t("span", { class: "form-control__input" }, t("slot", null))), o && t("span", { class: "form-control__description", id: this.descriptionId }, this.description), r && t("span", { "aria-live": "polite", class: "form-control__error-message", id: this.descriptionId }, t("flip-inline-error", { message: this.errorMessage, size: "s" }))));
|
|
43
|
-
}
|
|
44
|
-
get el() {
|
|
45
|
-
return l(this);
|
|
46
|
-
}
|
|
47
|
-
static get watchers() {
|
|
48
|
-
return {
|
|
49
|
-
description: ["associateDescriptionWithInputElement"],
|
|
50
|
-
disabled: ["setInputElementDisabledState"],
|
|
51
|
-
invalid: ["setInputElementInvalidState"]
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
};
|
|
55
|
-
c.style = a;
|
|
56
|
-
export {
|
|
57
|
-
c as flip_form_control
|
|
58
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { r as n, h as e, H as s } from "./index.b66ff9f0.js";
|
|
2
|
-
import { c as a } from "./index-6d2e18c6.289636d4.js";
|
|
3
|
-
import "react";
|
|
4
|
-
import "react-dom";
|
|
5
|
-
import "./_commonjsHelpers-44457d8d.ba94af77.js";
|
|
6
|
-
const l = ".sc-flip-heading-h{display:block;width:100%}.sc-flip-heading-h *.sc-flip-heading{box-sizing:border-box}.heading.sc-flip-heading{display:block;width:100%;margin:0;padding:0;text-align:start}.heading--align-start.sc-flip-heading{text-align:start}.heading--align-center.sc-flip-heading{text-align:center}.heading--align-end.sc-flip-heading{text-align:end}.heading--level-1.sc-flip-heading{font-size:var(--s-font-size-2xl);font-weight:var(--s-font-weight-bold);line-height:var(--s-line-height-2xl);letter-spacing:var(--s-letter-spacing-tight)}.heading--level-2.sc-flip-heading{font-size:var(--s-font-size-xl);font-weight:var(--s-font-weight-bold);line-height:var(--s-line-height-xl)}.heading--level-3.sc-flip-heading{font-size:var(--s-font-size-lg);font-weight:var(--s-font-weight-semibold);line-height:var(--s-line-height-lg)}.heading--level-4.sc-flip-heading,.heading--level-5.sc-flip-heading,.heading--level-6.sc-flip-heading{font-size:var(--s-font-size-base);font-weight:var(--s-font-weight-semibold);line-height:var(--s-line-height-base)}", h = class {
|
|
7
|
-
constructor(i) {
|
|
8
|
-
n(this, i), this.align = "start", this.level = 1;
|
|
9
|
-
}
|
|
10
|
-
render() {
|
|
11
|
-
const i = this.as || `h${this.level}`, t = a("heading", `heading--align-${this.align}`, `heading--level-${this.level}`);
|
|
12
|
-
return e(s, null, e(i, { class: t, id: this.headingId }, this.text));
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
h.style = l;
|
|
16
|
-
export {
|
|
17
|
-
h as flip_heading
|
|
18
|
-
};
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { r as p, h as i, H as l, g as d } from "./index.b66ff9f0.js";
|
|
2
|
-
import { c, s as m, f as v, a as h } from "./floating-ui.dom.esm-1a4e8b8a.87557233.js";
|
|
3
|
-
import { e as a, d as f } from "./bodyScrollLock.esm-ce6356d8.2c600fb9.js";
|
|
4
|
-
import { c as u } from "./index-6d2e18c6.289636d4.js";
|
|
5
|
-
import { i as n, q as s } from "./utils-39b2afe8.37b54ba4.js";
|
|
6
|
-
import "react";
|
|
7
|
-
import "react-dom";
|
|
8
|
-
import "./_commonjsHelpers-44457d8d.ba94af77.js";
|
|
9
|
-
const g = ":host{position:relative;z-index:var(--s-z-40);display:inline-flex}:host *{box-sizing:border-box}.popover--active:not(.popover--closing) .popover__backdrop{-webkit-animation:0.15s popover-fade-in;animation:0.15s popover-fade-in}@media (prefers-reduced-motion){.popover--active:not(.popover--closing) .popover__backdrop{-webkit-animation:none;animation:none}}.popover--active:not(.popover--closing) .popover__content{-webkit-animation:0.15s popover-slide-in;animation:0.15s popover-slide-in}@media (min-width: 768px){.popover--active:not(.popover--closing) .popover__content{transform-origin:top left;-webkit-animation:0.15s popover-fade-scale-in;animation:0.15s popover-fade-scale-in}}@media (prefers-reduced-motion){.popover--active:not(.popover--closing) .popover__content{-webkit-animation:none;animation:none}}.popover--closing .popover__backdrop{-webkit-animation:0.15s popover-fade-out;animation:0.15s popover-fade-out;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}@media (prefers-reduced-motion){.popover--closing .popover__backdrop{-webkit-animation:none;animation:none}}.popover--closing .popover__content{-webkit-animation:0.15s popover-slide-out;animation:0.15s popover-slide-out;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}@media (min-width: 768px){.popover--closing .popover__content{-webkit-animation:0.15s popover-fade-out;animation:0.15s popover-fade-out}}@media (prefers-reduced-motion){.popover--closing .popover__content{-webkit-animation:none;animation:none}}.popover--inactive .popover__content{display:none}.popover__backdrop{position:fixed;z-index:0;background-color:rgba(0, 0, 0, 0.2);-webkit-animation:0.15s popover-backdrop-fade-in;animation:0.15s popover-backdrop-fade-in;inset:0}@media (prefers-reduced-motion){.popover__backdrop{-webkit-animation:none;animation:none}}@media (min-width: 768px){.popover__backdrop{display:none}}.popover__content{position:fixed;z-index:2;right:0;bottom:0;left:0;overflow:hidden;border-top-left-radius:var(--s-border-radius-xl);border-top-right-radius:var(--s-border-radius-xl);background-color:var(--s-surface-overlay-default)}@media (min-width: 768px){.popover__content{right:unset;bottom:unset;left:unset;max-width:22.5rem;border-radius:var(--s-border-radius-sm);-webkit-animation:none;animation:none;box-shadow:0.125rem 0.25rem 2.5rem rgba(0, 0, 0, 0.14)}}.popover__scroll-container{overflow-x:hidden;overflow-y:auto;width:100%;max-height:90vh;padding-top:var(--s-space-24);padding-bottom:var(--s-space-24);overscroll-behavior:contain}@media (min-width: 768px){.popover__scroll-container{max-height:22rem;padding-top:var(--s-space-8);padding-bottom:var(--s-space-8)}}.popover__handle{position:absolute;top:var(--s-space-8);left:50%;width:2.5rem;height:0.375rem;border-radius:0.1875rem;background-color:var(--s-border-default);transform:translatex(-50%)}@media (min-width: 768px){.popover__handle{display:none}}@-webkit-keyframes popover-slide-in{from{transform:translateY(100%)}to{transform:translateY(0)}}@keyframes popover-slide-in{from{transform:translateY(100%)}to{transform:translateY(0)}}@-webkit-keyframes popover-slide-out{from{transform:translateY(0)}to{transform:translateY(100%)}}@keyframes popover-slide-out{from{transform:translateY(0)}to{transform:translateY(100%)}}@-webkit-keyframes popover-fade-in{from{opacity:0}to{opacity:1}}@keyframes popover-fade-in{from{opacity:0}to{opacity:1}}@-webkit-keyframes popover-fade-out{from{opacity:1}to{opacity:0}}@keyframes popover-fade-out{from{opacity:1}to{opacity:0}}@-webkit-keyframes popover-fade-scale-in{from{transform:scale(0);opacity:0}to{transform:scale(1);opacity:1}}@keyframes popover-fade-scale-in{from{transform:scale(0);opacity:0}to{transform:scale(1);opacity:1}}", b = class {
|
|
10
|
-
constructor(o) {
|
|
11
|
-
p(this, o), this.placement = "bottom-start", this.active = !1, this.closing = !1, this.onFocusOut = (e) => {
|
|
12
|
-
if (!this.active)
|
|
13
|
-
return;
|
|
14
|
-
const t = e.relatedTarget || e.target;
|
|
15
|
-
!this.el.contains(t) && this.close();
|
|
16
|
-
}, this.toggle = (e) => {
|
|
17
|
-
e.stopPropagation(), this.active ? this.close() : this.open();
|
|
18
|
-
}, this.onKeydown = (e) => {
|
|
19
|
-
e.code === "Escape" && this.active && this.close();
|
|
20
|
-
}, this.reposition = async () => {
|
|
21
|
-
const e = n();
|
|
22
|
-
if (!(!Boolean(this.triggerEl) || !Boolean(this.contentContainer))) {
|
|
23
|
-
if (e) {
|
|
24
|
-
this.position = void 0;
|
|
25
|
-
return;
|
|
26
|
-
}
|
|
27
|
-
this.position = await c(this.triggerEl, this.contentContainer, {
|
|
28
|
-
middleware: [m(), v()],
|
|
29
|
-
placement: this.placement,
|
|
30
|
-
strategy: "fixed"
|
|
31
|
-
});
|
|
32
|
-
}
|
|
33
|
-
}, this.onCloseButtonClick = () => {
|
|
34
|
-
this.close();
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
componentDidLoad() {
|
|
38
|
-
this.connectTrigger(), this.updateChildMenuItems(), this.updateTriggerAttributes();
|
|
39
|
-
}
|
|
40
|
-
disconnectedCallback() {
|
|
41
|
-
a(this.scrollContainer);
|
|
42
|
-
}
|
|
43
|
-
onWindowClick(o) {
|
|
44
|
-
const e = o.target;
|
|
45
|
-
this.el.contains(e) || this.close();
|
|
46
|
-
}
|
|
47
|
-
async close() {
|
|
48
|
-
var o;
|
|
49
|
-
this.closing || !this.active || (this.disableAutoUpdate && this.disableAutoUpdate(), this.closing = !0, setTimeout(() => {
|
|
50
|
-
this.active = !1, this.closing = !1, this.updateTriggerAttributes();
|
|
51
|
-
}, 150), this.unlockBodyScroll(), (o = this.getNativeTriggerElement()) === null || o === void 0 || o.focus());
|
|
52
|
-
}
|
|
53
|
-
async open() {
|
|
54
|
-
this.active = !0, this.updateChildMenuItems(), this.updateTriggerAttributes(), requestAnimationFrame(async () => {
|
|
55
|
-
await this.reposition(), this.childMenuItems.length > 0 ? this.childMenuItems[0].focus() : this.contentContainer.focus(), this.disableAutoUpdate && this.disableAutoUpdate(), this.disableAutoUpdate = h(this.triggerEl, this.contentContainer, this.reposition), this.scrollContainer.scrollTop = 0, this.lockBodyScroll();
|
|
56
|
-
});
|
|
57
|
-
}
|
|
58
|
-
connectTrigger() {
|
|
59
|
-
this.triggerEl = s(document.body, `#${this.trigger}`)[0], Boolean(this.triggerEl) && this.triggerEl.addEventListener("click", this.toggle);
|
|
60
|
-
}
|
|
61
|
-
getNativeTriggerElement() {
|
|
62
|
-
var o, e, t;
|
|
63
|
-
return this.triggerEl.tagName.startsWith("FLIP-") ? ((o = this.triggerEl) === null || o === void 0 ? void 0 : o.children[0]) || ((t = (e = this.triggerEl) === null || e === void 0 ? void 0 : e.shadowRoot) === null || t === void 0 ? void 0 : t.children[0]) || this.triggerEl : this.triggerEl;
|
|
64
|
-
}
|
|
65
|
-
updateTriggerAttributes() {
|
|
66
|
-
if (!Boolean(this.triggerEl))
|
|
67
|
-
return;
|
|
68
|
-
const o = this.getNativeTriggerElement();
|
|
69
|
-
o.setAttribute("aria-controls", this.popoverId), o.setAttribute("aria-expanded", String(this.active)), o.setAttribute("aria-haspopup", "dialog");
|
|
70
|
-
}
|
|
71
|
-
updateChildMenuItems() {
|
|
72
|
-
this.childMenuItems = s(this.el, '[role="menuitem"]');
|
|
73
|
-
}
|
|
74
|
-
lockBodyScroll() {
|
|
75
|
-
!n() || f(this.scrollContainer);
|
|
76
|
-
}
|
|
77
|
-
unlockBodyScroll() {
|
|
78
|
-
a(this.scrollContainer);
|
|
79
|
-
}
|
|
80
|
-
render() {
|
|
81
|
-
var o, e;
|
|
82
|
-
const t = u("popover", {
|
|
83
|
-
"popover--closing": this.closing,
|
|
84
|
-
"popover--active": this.active,
|
|
85
|
-
"popover--inactive": !this.active
|
|
86
|
-
});
|
|
87
|
-
return i(l, { id: this.popoverId, onFocusout: this.onFocusOut }, i("div", { class: t, onKeyDown: this.onKeydown }, i("div", { "aria-hidden": this.active ? "false" : "true", "aria-label": this.label, class: "popover__content", role: "dialog", tabindex: "-1", ref: (r) => this.contentContainer = r, style: {
|
|
88
|
-
top: Boolean(this.position) ? `${(o = this.position) === null || o === void 0 ? void 0 : o.y}px` : "",
|
|
89
|
-
left: Boolean(this.position) ? `${(e = this.position) === null || e === void 0 ? void 0 : e.x}px` : ""
|
|
90
|
-
} }, i("span", { class: "popover__handle" }), i("div", { class: "popover__scroll-container", ref: (r) => this.scrollContainer = r }, i("slot", null))), this.active && i("div", { class: "popover__backdrop", onClick: this.onCloseButtonClick })));
|
|
91
|
-
}
|
|
92
|
-
get el() {
|
|
93
|
-
return d(this);
|
|
94
|
-
}
|
|
95
|
-
};
|
|
96
|
-
b.style = g;
|
|
97
|
-
export {
|
|
98
|
-
b as flip_popover
|
|
99
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { r as i, h as e, H as o } from "./index.b66ff9f0.js";
|
|
2
|
-
import { c as l } from "./index-6d2e18c6.289636d4.js";
|
|
3
|
-
import "react";
|
|
4
|
-
import "react-dom";
|
|
5
|
-
import "./_commonjsHelpers-44457d8d.ba94af77.js";
|
|
6
|
-
const n = ":host{display:block}:host *{box-sizing:border-box}.text{margin:0;padding:0}.text--align-start{text-align:start}.text--align-center{text-align:center}.text--align-end{text-align:end}.text--color-default{color:var(--s-text-default)}.text--color-subdued{color:var(--s-text-subdued)}.text--color-critical{color:var(--s-text-critical)}.text--color-success{color:var(--s-text-success)}.text--color-warning{color:var(--s-text-warning)}.text--size-sm{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm)}.text--size-base{font-size:var(--s-font-size-base);line-height:var(--s-line-height-base)}.text--size-lg{font-size:var(--s-font-size-lg);line-height:var(--s-line-height-lg)}.text--weight-normal{font-weight:var(--s-font-weight-normal)}.text--weight-medium{font-weight:var(--s-font-weight-medium)}.text--weight-semibold{font-weight:var(--s-font-weight-semibold)}.text--weight-bold{font-weight:var(--s-font-weight-bold)}.text--font-style-normal{font-style:normal}.text--font-style-italic{font-style:italic}", a = class {
|
|
7
|
-
constructor(t) {
|
|
8
|
-
i(this, t), this.align = "start", this.as = "p", this.color = "default", this.fontStyle = "normal", this.size = "base", this.weight = "normal";
|
|
9
|
-
}
|
|
10
|
-
render() {
|
|
11
|
-
const t = this.as, s = l("text", `text--align-${this.align}`, `text--color-${this.color}`, `text--font-style-${this.fontStyle}`, `text--size-${this.size}`, `text--weight-${this.weight}`);
|
|
12
|
-
return e(o, null, e(t, { class: s }, e("slot", null)));
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
a.style = n;
|
|
16
|
-
export {
|
|
17
|
-
a as flip_text
|
|
18
|
-
};
|