litos-ui 0.23.1 → 0.24.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/lib/base.d.ts +3 -2
- package/lib/base.js +11 -8
- package/lib/button/index.d.ts +21 -5
- package/lib/button/index.js +115 -62
- package/lib/button/index.less_inline.js +2 -3
- package/lib/button/style.js +1 -2
- package/lib/calendar/index.js +22 -24
- package/lib/calendar/index.less_inline.js +1 -2
- package/lib/calendar/langs.js +1 -2
- package/lib/card/index.js +8 -9
- package/lib/card/index.less_inline.js +1 -2
- package/lib/carousel/index.js +10 -11
- package/lib/carousel/index.less_inline.js +1 -2
- package/lib/carousel/item.js +1 -2
- package/lib/carousel/item.less_inline.js +1 -2
- package/lib/carousel/timer.js +1 -2
- package/lib/check/check.d.ts +40 -8
- package/lib/check/check.js +200 -65
- package/lib/check/check.less_inline.js +2 -3
- package/lib/check/checkbox.js +2 -3
- package/lib/check/checkbox.less_inline.js +2 -3
- package/lib/check/checkbox_group.js +1 -2
- package/lib/check/index.d.ts +28 -8
- package/lib/check/index.js +151 -46
- package/lib/check/index.less_inline.js +1 -2
- package/lib/check/radio.js +2 -3
- package/lib/check/radio.less_inline.js +1 -2
- package/lib/check/radio_group.js +2 -3
- package/lib/collapse/index.d.ts +12 -4
- package/lib/collapse/index.js +80 -46
- package/lib/collapse/index.less_inline.js +2 -3
- package/lib/collapse/item.d.ts +35 -9
- package/lib/collapse/item.js +219 -57
- package/lib/collapse/item.less_inline.js +2 -3
- package/lib/collapse/types.d.ts +17 -3
- package/lib/color_picker/index.d.ts +4 -2
- package/lib/color_picker/index.js +26 -17
- package/lib/color_picker/index.less_inline.js +1 -2
- package/lib/date_picker/index.d.ts +5 -1
- package/lib/date_picker/index.js +39 -23
- package/lib/date_picker/index.less_inline.js +1 -2
- package/lib/date_picker_ori/index.d.ts +7 -2
- package/lib/date_picker_ori/index.js +123 -47
- package/lib/date_picker_ori/index.less_inline.js +1 -2
- package/lib/description_panel/index.js +2 -10
- package/lib/description_panel/index.less_inline.js +1 -2
- package/lib/dialog/dialog_box.js +28 -29
- package/lib/dialog/dialog_container.css_inline.js +1 -2
- package/lib/dialog/dialog_container.js +13 -14
- package/lib/dialog/dialog_container_style.js +1 -2
- package/lib/dialog/index.js +1 -2
- package/lib/dropdown/index.d.ts +39 -0
- package/lib/dropdown/index.js +98 -0
- package/lib/entries/base.js +1 -2
- package/lib/entries/button.js +5 -6
- package/lib/entries/calendar.js +5 -6
- package/lib/entries/card.js +5 -6
- package/lib/entries/carousel-item.js +5 -6
- package/lib/entries/carousel.js +5 -6
- package/lib/entries/checkbox-group.js +5 -6
- package/lib/entries/checkbox.js +5 -6
- package/lib/entries/collapse-item.d.ts +0 -1
- package/lib/entries/collapse-item.js +6 -6
- package/lib/entries/collapse.d.ts +0 -1
- package/lib/entries/collapse.js +11 -6
- package/lib/entries/color-picker.js +5 -6
- package/lib/entries/date-picker-ori.js +5 -6
- package/lib/entries/date-picker.js +5 -6
- package/lib/entries/description-panel.js +5 -6
- package/lib/entries/dialog-box.js +1 -2
- package/lib/entries/dialog-container.js +5 -6
- package/lib/entries/dialog.js +1 -2
- package/lib/entries/dropdown.d.ts +2 -0
- package/lib/entries/dropdown.js +1 -0
- package/lib/entries/form-item.js +5 -6
- package/lib/entries/form.js +5 -6
- package/lib/entries/icon-arrow-down.js +5 -6
- package/lib/entries/icon-arrow-left.js +5 -6
- package/lib/entries/icon-arrow-right.js +5 -6
- package/lib/entries/icon-arrow-up.js +5 -6
- package/lib/entries/icon-base.js +5 -6
- package/lib/entries/icon-calendar.js +5 -6
- package/lib/entries/icon-caret-bottom.js +5 -6
- package/lib/entries/icon-caret-top.js +5 -6
- package/lib/entries/icon-close-filled.js +5 -6
- package/lib/entries/icon-close.js +5 -6
- package/lib/entries/icon-copy.js +5 -6
- package/lib/entries/icon-d-arrow-left.js +5 -6
- package/lib/entries/icon-d-arrow-right.js +5 -6
- package/lib/entries/icon-delete.js +5 -6
- package/lib/entries/icon-eye-outline.js +5 -6
- package/lib/entries/icon-font-icon.js +5 -6
- package/lib/entries/icon-info.js +5 -6
- package/lib/entries/icon-loading.js +5 -6
- package/lib/entries/icon-minus.js +5 -6
- package/lib/entries/icon-moon.js +5 -6
- package/lib/entries/icon-more.js +5 -6
- package/lib/entries/icon-picture.js +5 -6
- package/lib/entries/icon-plus.js +5 -6
- package/lib/entries/icon-reduction.js +5 -6
- package/lib/entries/icon-refresh-left.js +5 -6
- package/lib/entries/icon-refresh-right.js +5 -6
- package/lib/entries/icon-refresh.js +5 -6
- package/lib/entries/icon-search.js +5 -6
- package/lib/entries/icon-select.js +5 -6
- package/lib/entries/icon-sort.js +5 -6
- package/lib/entries/icon-success.js +5 -6
- package/lib/entries/icon-sun.js +5 -6
- package/lib/entries/icon-theme-default.js +5 -6
- package/lib/entries/icon-warn.js +5 -6
- package/lib/entries/icon-zoom-in.js +5 -6
- package/lib/entries/icon-zoom-out.js +5 -6
- package/lib/entries/image-preview.js +5 -6
- package/lib/entries/image.js +5 -6
- package/lib/entries/input-number.js +5 -6
- package/lib/entries/input.js +5 -6
- package/lib/entries/list.js +5 -6
- package/lib/entries/loading.js +1 -2
- package/lib/entries/mask.js +5 -6
- package/lib/entries/md-input.js +5 -6
- package/lib/entries/menu.js +5 -6
- package/lib/entries/message.js +1 -2
- package/lib/entries/modal-box.js +1 -2
- package/lib/entries/modal.js +5 -6
- package/lib/entries/notification-box.js +1 -2
- package/lib/entries/notification.js +1 -2
- package/lib/entries/page-header.js +5 -6
- package/lib/entries/pagination.js +5 -6
- package/lib/entries/polygon.js +5 -6
- package/lib/entries/popconfirm.js +1 -2
- package/lib/entries/popover.js +1 -2
- package/lib/entries/qrcode.js +5 -6
- package/lib/entries/radio-group.js +5 -6
- package/lib/entries/radio.js +5 -6
- package/lib/entries/select-ori.js +5 -6
- package/lib/entries/select.js +5 -6
- package/lib/entries/space.js +5 -6
- package/lib/entries/switch.js +5 -6
- package/lib/entries/tabbar-item.js +5 -6
- package/lib/entries/tabbar.js +5 -6
- package/lib/entries/table.js +5 -6
- package/lib/entries/tabs.js +1 -2
- package/lib/entries/tag.js +5 -6
- package/lib/entries/theme-color.js +5 -6
- package/lib/entries/theme.js +5 -6
- package/lib/entries/transition.js +1 -2
- package/lib/entries/upload.js +5 -6
- package/lib/entries/utils.js +1 -3
- package/lib/form/accessibility.d.ts +15 -0
- package/lib/form/accessibility.js +56 -0
- package/lib/form/autocomplete.d.ts +21 -0
- package/lib/form/autocomplete.js +59 -0
- package/lib/form/context.d.ts +157 -0
- package/lib/form/context.js +88 -0
- package/lib/form/form_inner.d.ts +99 -24
- package/lib/form/form_inner.js +424 -72
- package/lib/form/form_item.d.ts +35 -11
- package/lib/form/form_item.js +210 -78
- package/lib/form/form_item.less_inline.js +2 -3
- package/lib/form/form_item_style.d.ts +3 -0
- package/lib/form/form_item_style.js +7 -0
- package/lib/form/index.d.ts +69 -15
- package/lib/form/index.js +501 -101
- package/lib/form/index.less_inline.js +1 -2
- package/lib/form/owner.d.ts +78 -0
- package/lib/form/owner.js +138 -0
- package/lib/form/style.d.ts +3 -0
- package/lib/form/style.js +7 -0
- package/lib/icon/arrow_down.js +1 -2
- package/lib/icon/arrow_left.js +1 -2
- package/lib/icon/arrow_right.js +1 -2
- package/lib/icon/arrow_up.js +1 -2
- package/lib/icon/base.js +1 -2
- package/lib/icon/calendar.js +1 -2
- package/lib/icon/caret_bottom.js +1 -2
- package/lib/icon/caret_top.js +1 -2
- package/lib/icon/close.js +1 -2
- package/lib/icon/close_filled.js +1 -2
- package/lib/icon/copy.js +1 -2
- package/lib/icon/d_arrow_left.js +1 -2
- package/lib/icon/d_arrow_right.js +1 -2
- package/lib/icon/delete.js +1 -2
- package/lib/icon/eye_outline.js +1 -2
- package/lib/icon/font_icon.js +1 -2
- package/lib/icon/icon_style.js +1 -2
- package/lib/icon/index.less_inline.js +1 -2
- package/lib/icon/info.js +1 -2
- package/lib/icon/loading.js +1 -2
- package/lib/icon/minus.js +1 -2
- package/lib/icon/moon.js +1 -2
- package/lib/icon/more.js +1 -2
- package/lib/icon/picture.js +1 -2
- package/lib/icon/plus.js +1 -2
- package/lib/icon/reduction.js +1 -2
- package/lib/icon/refresh.js +1 -2
- package/lib/icon/refresh_left.js +1 -2
- package/lib/icon/refresh_right.js +1 -2
- package/lib/icon/search.js +1 -2
- package/lib/icon/select.js +1 -2
- package/lib/icon/sort.js +1 -2
- package/lib/icon/success.js +1 -2
- package/lib/icon/sun.js +1 -2
- package/lib/icon/theme_default.js +1 -2
- package/lib/icon/warn.js +1 -2
- package/lib/icon/zoom_in.js +1 -2
- package/lib/icon/zoom_out.js +1 -2
- package/lib/image/image_preview.js +1 -2
- package/lib/image/image_preview.less_inline.js +1 -2
- package/lib/image/index.js +1 -2
- package/lib/image/index.less_inline.js +1 -2
- package/lib/index.d.ts +2 -1
- package/lib/index.js +91 -91
- package/lib/input/index.d.ts +14 -0
- package/lib/input/index.js +126 -31
- package/lib/input/index.less_inline.js +2 -3
- package/lib/input/input_inner.less_inline.js +1 -2
- package/lib/input/style.d.ts +1 -0
- package/lib/input/style.js +5 -7
- package/lib/input_number/index.d.ts +7 -0
- package/lib/input_number/index.js +70 -48
- package/lib/input_number/index.less_inline.js +1 -2
- package/lib/input_number/style.js +1 -2
- package/lib/list/index.js +4 -5
- package/lib/list/index.less_inline.js +1 -2
- package/lib/loading/index.js +1 -2
- package/lib/mask/index.js +2 -7
- package/lib/mask/index.less_inline.js +1 -2
- package/lib/md_input/index.d.ts +11 -2
- package/lib/md_input/index.js +63 -27
- package/lib/md_input/index.less_inline.js +2 -3
- package/lib/menu/index.js +2 -7
- package/lib/menu/index.less_inline.js +1 -2
- package/lib/message/index.js +1 -2
- package/lib/modal/index.js +15 -16
- package/lib/modal/index.less_inline.js +1 -2
- package/lib/modal/modal_box.js +24 -25
- package/lib/notification/index.js +15 -29
- package/lib/notification/index.less_inline.js +1 -2
- package/lib/notification/notification_box.js +2 -3
- package/lib/notification/placement.js +1 -2
- package/lib/notification/style.js +1 -2
- package/lib/page_header/index.js +1 -2
- package/lib/page_header/index.less_inline.js +1 -2
- package/lib/pagination/index.js +2 -7
- package/lib/pagination/index.less_inline.js +1 -2
- package/lib/polygon/index.js +1 -2
- package/lib/polygon/index.less_inline.js +1 -2
- package/lib/qrcode/index.js +1 -2
- package/lib/qrcode/index.less_inline.js +1 -2
- package/lib/select/index.d.ts +19 -2
- package/lib/select/index.js +128 -74
- package/lib/select/index.less_inline.js +1 -2
- package/lib/select_ori/index.d.ts +9 -1
- package/lib/select_ori/index.js +36 -24
- package/lib/select_ori/index.less_inline.js +1 -2
- package/lib/space/index.js +1 -2
- package/lib/space/index.less_inline.js +1 -2
- package/lib/styles/animation/index.css_inline.js +1 -2
- package/lib/styles/animation/index.js +1 -2
- package/lib/styles/mask/index.css_inline.js +1 -2
- package/lib/styles/mask/index.js +1 -2
- package/lib/switch/index.d.ts +6 -0
- package/lib/switch/index.js +31 -16
- package/lib/switch/index.less_inline.js +1 -2
- package/lib/tabbar/index.js +1 -2
- package/lib/tabbar/index.less_inline.js +1 -2
- package/lib/tabbar/item.js +1 -2
- package/lib/tabbar/item.less_inline.js +1 -2
- package/lib/table/index.js +1 -2
- package/lib/table/index.less_inline.js +1 -2
- package/lib/tabs/index.js +1 -2
- package/lib/tag/index.d.ts +11 -3
- package/lib/tag/index.js +25 -24
- package/lib/tag/index.less_inline.js +2 -3
- package/lib/theme/appearance.d.ts +5 -0
- package/lib/theme/appearance.js +34 -0
- package/lib/theme/index.js +83 -39
- package/lib/theme/index.less_inline.js +1 -2
- package/lib/theme/theme_color.js +1 -2
- package/lib/upload/index.js +28 -41
- package/lib/upload/index.less_inline.js +2 -3
- package/lib/upload/style.js +1 -2
- package/lib/utils/clickoutside.js +1 -2
- package/lib/utils/event.js +1 -2
- package/lib/utils/index.d.ts +27 -6
- package/lib/utils/index.js +26 -6
- package/lib/utils/popover.js +7 -16
- package/lib/utils/transition.js +1 -2
- package/package.json +16 -13
- package/styles/dark.css +10 -2
- package/styles/dropdown.css +46 -0
- package/styles/reset.css +0 -1
- package/styles/select.css +5 -0
- package/styles/themes/apple.css +47 -0
- package/styles/{theme-coral.css → themes/coral.css} +5 -3
- package/styles/themes/deep-sea-blue.css +12 -0
- package/styles/themes/gamboge.css +15 -0
- package/styles/{theme-jade.css → themes/jade.css} +5 -3
- package/styles/themes/lotus-seed.css +12 -0
- package/styles/{theme-tangerine.css → themes/tangerine.css} +5 -3
- package/styles/themes.css +8 -0
- package/styles/vars.css +8 -2
- package/types/preact.d.ts +42 -0
- package/lib/form/types.d.ts +0 -7
- package/lib/utils/context_provide.d.ts +0 -10
- package/lib/utils/context_provide.js +0 -22
- package/lib/utils/locale.d.ts +0 -6
- package/lib/utils/locale.js +0 -34
- package/lib/utils/signal_types.d.ts +0 -5
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/form/index.less?inline
|
|
2
2
|
var e = ":host{display:block}.l-form{gap:var(--l-form-gap,20px);flex-flow:column;display:flex}.l-form-inline{gap:var(--l-form-gap,20px);flex-flow:wrap;display:flex}.l-form.l-form-inline{--l-form-item-display:flex}.l-form.l-form--left{--l-form-label-align:left}.l-form.l-form--top{--l-form-item-display:grid;--l-form-label-align:left;--l-form-label-empty-display:none;grid-template-columns:1fr}";
|
|
3
|
-
//#endregion
|
|
4
3
|
export { e as default };
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 表单原生所有权管理的内部原语:创建辅助 form,并协调同一 DOM 树内的字段关联。
|
|
3
|
+
* 当前使用位置:tests/form-lifecycle.fixture.html,通过 scripts/check-form-owner.mjs
|
|
4
|
+
* 提供的 /owner.js 加载并验证。生产 Form 在 T340 接入;由 Form 持有本管理器,FormInner 不直接依赖它。
|
|
5
|
+
* vite.config.ts 将它排除出独立组件入口扫描;不属于公开导入 API。
|
|
6
|
+
* 宿主接入后必须在连接/断开生命周期调用 start/stop;不穿透额外 ShadowRoot。
|
|
7
|
+
*/
|
|
8
|
+
/** selectFields 回调与内部关联集合使用的字段类型;调用方只能返回真正参与表单的宿主。 */
|
|
9
|
+
export interface OwnedFormField extends HTMLElement {
|
|
10
|
+
}
|
|
11
|
+
/** Shadow DOM 按钮不能充当外部 form 的原生 submitter。 */
|
|
12
|
+
export declare function requestSubmitFromButton(form: HTMLFormElement, source: HTMLElement): void;
|
|
13
|
+
/** 一个原生 form 只有一个提交桥,按实际提交按钮归属选中库表单。 */
|
|
14
|
+
export declare function listenFormSubmit(form: HTMLFormElement, host: HTMLElement, ownsForm: boolean, submit: () => void): () => void;
|
|
15
|
+
/**
|
|
16
|
+
* 单个 l-form 的所有权控制器,当前由生命周期浏览器样例实例化。
|
|
17
|
+
* 由生产 Form 持有,字段注册/升级后可主动 refresh;不负责上下文或校验规则。
|
|
18
|
+
* 无原生祖先 form 时使用空的隐藏辅助 form;有祖先时复用,字段显式 form 始终优先。
|
|
19
|
+
* 嵌套 l-form 明确拒绝;多个宿主复用同一原生 form 时不承诺原生提交/重置隔离。
|
|
20
|
+
* 仅管理关联属性和自身辅助节点,从不移动、重建或清空应用内容。
|
|
21
|
+
*/
|
|
22
|
+
export declare class FormOwner {
|
|
23
|
+
/** 管理器自行创建的空辅助 form;stop 移除,不包含用户字段。 */
|
|
24
|
+
private auxiliary?;
|
|
25
|
+
/** 只观察当前宿主子树的结构和 form/id,不全局监听 document。 */
|
|
26
|
+
private observer?;
|
|
27
|
+
/** 只记录本管理器写入的字段及 ID,用于安全恢复原本缺省的 form 属性。 */
|
|
28
|
+
private readonly managed;
|
|
29
|
+
/** start/stop 的幂等状态。 */
|
|
30
|
+
private active;
|
|
31
|
+
/** refresh 重入保护;属性不同才写入,避免观察器循环更新。 */
|
|
32
|
+
private refreshing;
|
|
33
|
+
private refreshScheduled;
|
|
34
|
+
/** 对外 form getter 的当前结果,可为辅助 form 或应用原生祖先 form。 */
|
|
35
|
+
private current?;
|
|
36
|
+
/**
|
|
37
|
+
* 由 Form 初始化及浏览器样例的宿主 connectedCallback 创建。
|
|
38
|
+
* @param host 所属 l-form 宿主;本构造函数不修改 DOM,随后显式 start。
|
|
39
|
+
* @param selectFields 返回当前候选字段,refresh 每次重新读取;不能返回辅助 input。
|
|
40
|
+
*/
|
|
41
|
+
constructor(host: HTMLElement, selectFields: () => Iterable<OwnedFormField>);
|
|
42
|
+
readonly host: HTMLElement;
|
|
43
|
+
private readonly selectFields;
|
|
44
|
+
/**
|
|
45
|
+
* 当前浏览器样例读取此值断言 owner;供 Form 的提交/重置协调入口使用。
|
|
46
|
+
* 未启动、停止或宿主断开后为 undefined;不会隐式执行 refresh。
|
|
47
|
+
*/
|
|
48
|
+
get form(): HTMLFormElement | undefined;
|
|
49
|
+
/** 辅助 form 只归当前宿主使用,复用的原生祖先可能由多个宿主共享。 */
|
|
50
|
+
get ownsForm(): boolean;
|
|
51
|
+
/**
|
|
52
|
+
* 宿主连接时调用:首次同步并安装局部观察器;重复调用不重复安装。
|
|
53
|
+
* 当前由样例 connectedCallback 调用;首次失败会执行 stop 清理后再抛出错误。
|
|
54
|
+
*/
|
|
55
|
+
start(): void;
|
|
56
|
+
/** 自定义控件可能在原位置升级,子树观察器收不到这类变化。 */
|
|
57
|
+
scheduleRefresh(): void;
|
|
58
|
+
/** 同步读取或提交时,先处理本轮尚未交给观察器的结构变化。 */
|
|
59
|
+
refreshPending(): void;
|
|
60
|
+
/**
|
|
61
|
+
* 内部由 refresh、跨管理器移交和 stop 调用,释放一项由本管理器写入的关联。
|
|
62
|
+
* 仅在属性仍等于本次写入值时移除;用户显式更改后的值不回滚。
|
|
63
|
+
*/
|
|
64
|
+
private release;
|
|
65
|
+
/**
|
|
66
|
+
* start 与局部观察器调用;未来字段升级/登记以及特殊移动后也应主动调用。
|
|
67
|
+
* 重读候选字段并修正 owner、ID 和归属,处理增删、框架替换及跨宿主移交。
|
|
68
|
+
* 不监听宿主之外的 ID 更改:外部新冲突需下一次主动 refresh 才会发现。
|
|
69
|
+
* 明确拒绝同树嵌套 l-form;不跨 ShadowRoot 查找祖先或字段。
|
|
70
|
+
*/
|
|
71
|
+
refresh(): void;
|
|
72
|
+
/**
|
|
73
|
+
* 当前由浏览器样例 disconnectedCallback 调用,由 Form 断开/销毁时调用。
|
|
74
|
+
* 停止观察、恢复自动属性、移除辅助 form 并注销宿主;重复调用安全。
|
|
75
|
+
* 不移除应用原生 form 或用户节点;需要重新挂载时可以再次 start。
|
|
76
|
+
*/
|
|
77
|
+
stop(): void;
|
|
78
|
+
}
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
// src/components/form/owner.ts
|
|
2
|
+
var e = 0, t = /* @__PURE__ */ new WeakMap(), n = /* @__PURE__ */ new WeakMap(), r = /* @__PURE__ */ new WeakMap();
|
|
3
|
+
function i(e, t) {
|
|
4
|
+
let n = e.ownerDocument.createElement("button");
|
|
5
|
+
n.type = "submit", n.hidden = !0, n.formNoValidate = t.hasAttribute("formnovalidate");
|
|
6
|
+
for (let e of ["name", "value"]) {
|
|
7
|
+
let r = t.getAttribute(e);
|
|
8
|
+
r !== null && n.setAttribute(e, r);
|
|
9
|
+
}
|
|
10
|
+
r.set(n, t), Element.prototype.append.call(e, n);
|
|
11
|
+
try {
|
|
12
|
+
HTMLFormElement.prototype.requestSubmit.call(e, n);
|
|
13
|
+
} finally {
|
|
14
|
+
n.remove();
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
var a = /* @__PURE__ */ new WeakMap();
|
|
18
|
+
function o(e, t, n, i) {
|
|
19
|
+
let o = a.get(e);
|
|
20
|
+
if (!o) {
|
|
21
|
+
let t = /* @__PURE__ */ new Map(), n = (n) => {
|
|
22
|
+
if (n.target !== e) return;
|
|
23
|
+
let i = n.submitter, a = i ? r.get(i) ?? i : null, o = a?.closest("l-form"), s = t.keys().next().value, c = s && (t.get(s)?.ownsForm || !a && t.size === 1) ? s : void 0, l = o && t.has(o) ? o : c, u = l && t.get(l);
|
|
24
|
+
if (!l || !u || (n.stopPropagation(), n.defaultPrevented)) return;
|
|
25
|
+
let d = Object.getOwnPropertyDescriptor(n, "preventDefault"), f = n.preventDefault, p = !1, m = () => {
|
|
26
|
+
p = !0, f.call(n);
|
|
27
|
+
};
|
|
28
|
+
f.call(n), n.preventDefault = m, setTimeout(() => {
|
|
29
|
+
n.preventDefault === m && (d ? Object.defineProperty(n, "preventDefault", d) : Reflect.deleteProperty(n, "preventDefault")), !p && t.get(l) === u && u.submit();
|
|
30
|
+
}, 0);
|
|
31
|
+
};
|
|
32
|
+
e.addEventListener("submit", n), o = {
|
|
33
|
+
hosts: t,
|
|
34
|
+
dispose: () => {
|
|
35
|
+
e.removeEventListener("submit", n), a.delete(e);
|
|
36
|
+
}
|
|
37
|
+
}, a.set(e, o);
|
|
38
|
+
}
|
|
39
|
+
let s = o, c = {
|
|
40
|
+
submit: i,
|
|
41
|
+
ownsForm: n
|
|
42
|
+
};
|
|
43
|
+
return s.hosts.set(t, c), () => {
|
|
44
|
+
s.hosts.get(t) === c && (s.hosts.delete(t), s.hosts.size || s.dispose());
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
var s = class {
|
|
48
|
+
auxiliary;
|
|
49
|
+
observer;
|
|
50
|
+
managed = /* @__PURE__ */ new Map();
|
|
51
|
+
active = !1;
|
|
52
|
+
refreshing = !1;
|
|
53
|
+
refreshScheduled = !1;
|
|
54
|
+
current;
|
|
55
|
+
constructor(e, t) {
|
|
56
|
+
this.host = e, this.selectFields = t;
|
|
57
|
+
}
|
|
58
|
+
host;
|
|
59
|
+
selectFields;
|
|
60
|
+
get form() {
|
|
61
|
+
return this.current;
|
|
62
|
+
}
|
|
63
|
+
get ownsForm() {
|
|
64
|
+
return this.auxiliary !== void 0 && this.current === this.auxiliary;
|
|
65
|
+
}
|
|
66
|
+
start() {
|
|
67
|
+
if (this.active) return;
|
|
68
|
+
let e = t.get(this.host);
|
|
69
|
+
if (e && e !== this) throw Error("Litos UI: host already has a form owner manager.");
|
|
70
|
+
t.set(this.host, this), this.active = !0;
|
|
71
|
+
try {
|
|
72
|
+
this.refresh(), this.observer = new MutationObserver(() => this.refresh()), this.observer.observe(this.host, {
|
|
73
|
+
childList: !0,
|
|
74
|
+
subtree: !0,
|
|
75
|
+
attributes: !0,
|
|
76
|
+
attributeFilter: ["form", "id"]
|
|
77
|
+
});
|
|
78
|
+
} catch (e) {
|
|
79
|
+
throw this.stop(), e;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
scheduleRefresh() {
|
|
83
|
+
this.refreshScheduled || (this.refreshScheduled = !0, queueMicrotask(() => this.refreshPending()));
|
|
84
|
+
}
|
|
85
|
+
refreshPending() {
|
|
86
|
+
if (!this.active || this.refreshing) return;
|
|
87
|
+
let e = this.observer?.takeRecords();
|
|
88
|
+
(this.refreshScheduled || e?.length) && this.refresh();
|
|
89
|
+
}
|
|
90
|
+
release(e) {
|
|
91
|
+
let t = this.managed.get(e);
|
|
92
|
+
t !== void 0 && e.getAttribute("form") === t && e.removeAttribute("form"), this.managed.delete(e), n.get(e) === this && n.delete(e);
|
|
93
|
+
}
|
|
94
|
+
refresh() {
|
|
95
|
+
if (this.active && !this.refreshing) {
|
|
96
|
+
this.refreshScheduled = !1, this.refreshing = !0;
|
|
97
|
+
try {
|
|
98
|
+
if (!this.host.isConnected) {
|
|
99
|
+
for (let e of this.managed.keys()) this.release(e);
|
|
100
|
+
this.auxiliary?.remove(), this.auxiliary = void 0, this.current = void 0;
|
|
101
|
+
return;
|
|
102
|
+
}
|
|
103
|
+
if (this.host.parentElement?.closest("l-form")) throw Error("Litos UI: nested l-form is not supported by the native owner protocol.");
|
|
104
|
+
let t = this.host.parentElement?.closest("form") ?? void 0, r;
|
|
105
|
+
if (t) this.auxiliary?.remove(), this.auxiliary = void 0, r = t;
|
|
106
|
+
else {
|
|
107
|
+
this.auxiliary || (this.auxiliary = this.host.ownerDocument.createElement("form"), this.auxiliary.hidden = !0, this.auxiliary.noValidate = !0, this.auxiliary.slot = "__l_form_owner"), r = this.auxiliary, r.parentNode !== this.host && this.host.append(r);
|
|
108
|
+
let t = this.host.getRootNode();
|
|
109
|
+
if (!r.id || t.getElementById(r.id) !== r || Array.from(t.querySelectorAll("[id]")).some((e) => e !== r && e.id === r.id)) {
|
|
110
|
+
let n;
|
|
111
|
+
do
|
|
112
|
+
n = `l-form-owner-${++e}`;
|
|
113
|
+
while (t.getElementById(n));
|
|
114
|
+
r.id = n;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
this.current = r;
|
|
118
|
+
let i = this.host.getRootNode(), a = new Set(Array.from(this.selectFields()).filter((e) => e.isConnected && e.getRootNode() === i && this.host.contains(e) && e.closest("l-form") === this.host && !e.closest("form")));
|
|
119
|
+
if (t) for (let e of this.selectFields()) e.isConnected && e.getRootNode() === i && this.host.contains(e) && e.closest("l-form") === this.host && e.closest("form") === t && a.add(e);
|
|
120
|
+
for (let e of this.managed.keys()) a.has(e) || this.release(e);
|
|
121
|
+
for (let e of a) {
|
|
122
|
+
let i = n.get(e);
|
|
123
|
+
i && i !== this && i.release(e);
|
|
124
|
+
let a = this.managed.get(e), o = e.getAttribute("form");
|
|
125
|
+
a !== void 0 && o !== a && this.managed.delete(e), (!e.hasAttribute("form") || this.managed.has(e)) && (t ? this.release(e) : e.getAttribute("form") !== r.id && (e.setAttribute("form", r.id), this.managed.set(e, r.id), n.set(e, this)));
|
|
126
|
+
}
|
|
127
|
+
} finally {
|
|
128
|
+
this.refreshing = !1;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
stop() {
|
|
133
|
+
this.active = !1, this.refreshScheduled = !1, this.observer?.disconnect(), this.observer = void 0;
|
|
134
|
+
for (let e of this.managed.keys()) this.release(e);
|
|
135
|
+
this.auxiliary?.remove(), this.auxiliary = void 0, this.current = void 0, t.get(this.host) === this && t.delete(this.host);
|
|
136
|
+
}
|
|
137
|
+
};
|
|
138
|
+
export { s as FormOwner, o as listenFormSubmit, i as requestSubmitFromButton };
|
package/lib/icon/arrow_down.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/arrow_down.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "arrow-down-icon";
|
|
5
5
|
connectedCallback() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path fill=\"currentColor\" d=\"M831.872 340.864 512 652.672 192.128 340.864a30.592 30.592 0 0 0-42.752 0 29.12 29.12 0 0 0 0 41.6L489.664 714.24a32 32 0 0 0 44.672 0l340.288-331.712a29.12 29.12 0 0 0 0-41.728 30.592 30.592 0 0 0-42.752 0z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/arrow_left.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/arrow_left.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "arrow-left-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M609.408 149.376 277.76 489.6a32 32 0 0 0 0 44.672l331.648 340.352a29.12 29.12 0 0 0 41.728 0 30.592 30.592 0 0 0 0-42.752L339.264 511.936l311.872-319.872a30.592 30.592 0 0 0 0-42.688 29.12 29.12 0 0 0-41.728 0z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/arrow_right.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/arrow_right.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "arrow-right-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-44.672L382.592 149.376a29.12 29.12 0 0 0-41.728 0z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/arrow_up.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/arrow_up.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "arrow-up-icon";
|
|
5
5
|
connectedCallback() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path fill=\"currentColor\" d=\"m488.832 344.32-339.84 356.672a32 32 0 0 0 0 44.16l.384.384a29.44 29.44 0 0 0 42.688 0l320-335.872 319.872 335.872a29.44 29.44 0 0 0 42.688 0l.384-.384a32 32 0 0 0 0-44.16L535.168 344.32a32 32 0 0 0-46.336 0\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/base.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "../base.js";
|
|
2
2
|
import { unitNumberStr as t } from "../utils/index.js";
|
|
3
3
|
import n from "./icon_style.js";
|
|
4
|
-
|
|
4
|
+
// src/components/icon/base.ts
|
|
5
5
|
var r = class extends e {
|
|
6
6
|
static baseName = "base-icon";
|
|
7
7
|
useLink;
|
|
@@ -59,5 +59,4 @@ var r = class extends e {
|
|
|
59
59
|
return document.createElementNS("http://www.w3.org/2000/svg", e);
|
|
60
60
|
}
|
|
61
61
|
};
|
|
62
|
-
//#endregion
|
|
63
62
|
export { r as default };
|
package/lib/icon/calendar.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/calendar.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "calendar-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M128 384v512h768V192H768v32a32 32 0 1 1-64 0v-32H320v32a32 32 0 0 1-64 0v-32H128v128h768v64zm192-256h384V96a32 32 0 1 1 64 0v32h160a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h160V96a32 32 0 0 1 64 0zm-32 384h64a32 32 0 0 1 0 64h-64a32 32 0 0 1 0-64m0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64m192-192h64a32 32 0 0 1 0 64h-64a32 32 0 0 1 0-64m0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64m192-192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64m0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/caret_bottom.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/caret_bottom.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "caret-bottom-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"m192 384 320 384 320-384z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/caret_top.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/caret_top.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "caret-top-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M512 320 192 704h639.936z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/close.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/close.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "close-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/close_filled.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/close_filled.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "close-filled-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path fill=\"currentColor\" d=\"M12 23a11 11 0 100-22 11 11 0 000 22zM8.82 7.4L12 10.6l3.18-3.19 1.42 1.42L13.4 12l3.19 3.18-1.42 1.42L12 13.4 8.82 16.6 7.4 15.18 10.6 12 7.4 8.82 8.82 7.4z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/copy.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/copy.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "copy-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<rect width=\"14\" height=\"14\" x=\"8\" y=\"8\" rx=\"2\" ry=\"2\" /><path d=\"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2\" />";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/d_arrow_left.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/d_arrow_left.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "d-arrow-left-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M529.408 149.376a29.12 29.12 0 0 1 41.728 0 30.592 30.592 0 0 1 0 42.688L259.264 511.936l311.872 319.936a30.592 30.592 0 0 1-.512 43.264 29.12 29.12 0 0 1-41.216-.512L197.76 534.272a32 32 0 0 1 0-44.672l331.648-340.224zm256 0a29.12 29.12 0 0 1 41.728 0 30.592 30.592 0 0 1 0 42.688L515.264 511.936l311.872 319.936a30.592 30.592 0 0 1-.512 43.264 29.12 29.12 0 0 1-41.216-.512L453.76 534.272a32 32 0 0 1 0-44.672l331.648-340.224z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/d_arrow_right.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "d-arrow-right-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M452.864 149.312a29.12 29.12 0 0 1 41.728.064L826.24 489.664a32 32 0 0 1 0 44.672L494.592 874.624a29.12 29.12 0 0 1-41.728 0 30.592 30.592 0 0 1 0-42.752L764.736 512 452.864 192a30.592 30.592 0 0 1 0-42.688m-256 0a29.12 29.12 0 0 1 41.728.064L570.24 489.664a32 32 0 0 1 0 44.672L238.592 874.624a29.12 29.12 0 0 1-41.728 0 30.592 30.592 0 0 1 0-42.752L508.736 512 196.864 192a30.592 30.592 0 0 1 0-42.688z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/delete.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/delete.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "delete-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M160 256H96a32 32 0 0 1 0-64h256V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64h-64v672a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32zm448-64v-64H416v64zM224 896h576V256H224zm192-128a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32m192 0a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/eye_outline.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/eye_outline.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "eye-outline-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M8.25 12a3.75 3.75 0 1 1 7.5 0a3.75 3.75 0 0 1-7.5 0M12 9.75a2.25 2.25 0 1 0 0 4.5a2.25 2.25 0 0 0 0-4.5\"></path><path d=\"M4.323 10.646c-.419.604-.573 1.077-.573 1.354s.154.75.573 1.354c.406.583 1.008 1.216 1.77 1.801C7.62 16.327 9.713 17.25 12 17.25s4.38-.923 5.907-2.095c.762-.585 1.364-1.218 1.77-1.801c.419-.604.573-1.077.573-1.354s-.154-.75-.573-1.354c-.406-.583-1.008-1.216-1.77-1.801C16.38 7.673 14.287 6.75 12 6.75s-4.38.923-5.907 2.095c-.762.585-1.364 1.218-1.77 1.801m.856-2.991C6.91 6.327 9.316 5.25 12 5.25s5.09 1.077 6.82 2.405c.867.665 1.583 1.407 2.089 2.136c.492.709.841 1.486.841 2.209s-.35 1.5-.841 2.209c-.506.729-1.222 1.47-2.088 2.136c-1.73 1.328-4.137 2.405-6.821 2.405s-5.09-1.077-6.82-2.405c-.867-.665-1.583-1.407-2.089-2.136C2.6 13.5 2.25 12.723 2.25 12s.35-1.5.841-2.209c.506-.729 1.222-1.47 2.088-2.136\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/font_icon.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/font_icon.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "font-icon";
|
|
5
5
|
_t;
|
|
@@ -32,5 +32,4 @@ var t = class extends e {
|
|
|
32
32
|
}));
|
|
33
33
|
}
|
|
34
34
|
};
|
|
35
|
-
//#endregion
|
|
36
35
|
export { t as default };
|
package/lib/icon/icon_style.js
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import e from "./index.less_inline.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/icon_style.ts
|
|
3
3
|
var t = /* @__PURE__ */ (() => {
|
|
4
4
|
let t = new CSSStyleSheet();
|
|
5
5
|
return t.replaceSync(e), t;
|
|
6
6
|
})();
|
|
7
|
-
//#endregion
|
|
8
7
|
export { t as default };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/icon/index.less?inline
|
|
2
2
|
var e = ":host{display:inline-flex}.l-icon{fill:currentColor;vertical-align:middle;width:1em;height:1em;color:var(--l-icon-color,inherit);font-size:var(--l-icon-size,inherit);display:inline-block}.l-stroke-icon{fill:none;stroke:currentColor;stroke-width:2px;stroke-linecap:round;stroke-linejoin:round}";
|
|
3
|
-
//#endregion
|
|
4
3
|
export { e as default };
|
package/lib/icon/info.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/info.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "info-icon";
|
|
5
5
|
connectedCallback() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path fill=\"currentColor\" d=\"M512 64a448 448 0 110 896.064A448 448 0 01512 64zm67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344zM590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.992 12.992 0 01-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 017.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/loading.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/loading.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "loading-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path d=\"M520.665 64.564a29.244 29.244 0 0 0-7.071-.894c-16.211 0-29.35 13.14-29.35 29.35 0 15.83 12.538 28.696 28.223 29.293v.073c.375 0 .751-.014 1.127-.014 216.493 0 389.629 173.942 389.629 390.433 0 216.496-173.136 388.827-389.63 388.827s-389.63-172.333-389.63-388.829c0-.27.01-.536.01-.804h-.01c0-16.209-13.141-29.35-29.35-29.35s-29.35 13.139-29.35 29.35c0 .055.007.11.007.164-.001.214-.007.425-.007.64 0 247.609 200.722 448.331 448.33 448.331 247.607 0 448.33-200.722 448.33-448.33-.002-245.242-196.917-444.456-441.258-448.24z\" fill=\"currentColor\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/minus.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/minus.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "minus-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M128 544h768a32 32 0 1 0 0-64H128a32 32 0 0 0 0 64\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/moon.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/moon.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "moon-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M12.1 22h-.9c-5.5-.5-9.5-5.4-9-10.9.4-4.8 4.2-8.6 9-9 .4 0 .8.2 1 .5.2.3.2.8-.1 1.1-2 2.7-1.4 6.4 1.3 8.4 2.1 1.6 5 1.6 7.1 0 .3-.2.7-.3 1.1-.1.3.2.5.6.5 1-.2 2.7-1.5 5.1-3.6 6.8-1.9 1.4-4.1 2.2-6.4 2.2zM9.3 4.4c-2.9 1-5 3.6-5.2 6.8-.4 4.4 2.8 8.3 7.2 8.7 2.1.2 4.2-.4 5.8-1.8 1.1-.9 1.9-2.1 2.4-3.4-2.5.9-5.3.5-7.5-1.1-2.8-2.2-3.9-5.9-2.7-9.2z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/more.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/more.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "more-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M176 416a112 112 0 1 1 0 224 112 112 0 0 1 0-224m336 0a112 112 0 1 1 0 224 112 112 0 0 1 0-224m336 0a112 112 0 1 1 0 224 112 112 0 0 1 0-224\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/picture.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/picture.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "picture-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path d=\"M0 914.907717c0 59.561323 48.482772 107.834457 107.834457 107.834456H914.907717c59.55326 0 107.826394-48.482772 107.826393-107.826393V107.834457C1022.742173 48.273134 974.259402 0 914.91578 0H107.834457C48.273134 0 0 48.482772 0 107.834457V914.907717z m914.907717 56.634456H107.84252c-31.139276 0-56.634457-25.495181-56.634457-56.626393V780.118677l193.931087-193.931086 165.72674 165.718677a25.479055 25.479055 0 0 0 36.146393 0L746.262173 452.656378l225.28 225.28v236.987465c0 31.131213-25.495181 56.626394-56.626393 56.626393zM107.84252 51.2H914.907717c31.131213 0 56.626394 25.495181 56.626393 56.634457v497.58337L764.242646 398.311811a25.479055 25.479055 0 0 0-36.154457 0L428.822173 697.577827 263.103496 531.851087a25.479055 25.479055 0 0 0-36.154457 0L51.2 707.608189V107.834457c0-31.139276 25.495181-56.634457 56.634457-56.634457z m209.186267 358.609638c71.889638 0 130.193134-58.513134 130.193134-130.193134 0-71.68-58.513134-130.193134-130.193134-130.193134-71.68 0-130.193134 58.513134-130.193133 130.193134 0 71.68 58.303496 130.193134 130.193133 130.193134z m0-209.186268c43.677228 0 78.993134 35.525543 78.993134 78.993134 0 43.459528-35.525543 78.993134-78.993134 78.993134-43.459528 0-78.993134-35.525543-78.993133-78.993134 0-43.467591 35.315906-78.993134 78.993133-78.993134z\" fill=\"currentColor\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/plus.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/plus.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "plus-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M480 480V128a32 32 0 0 1 64 0v352h352a32 32 0 1 1 0 64H544v352a32 32 0 1 1-64 0V544H128a32 32 0 0 1 0-64z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/reduction.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/reduction.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "reduction-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M1039.92888889 967.11111111L1039.92888889 56.88888889c0-40.15900445-32.65877333-72.81777778-72.81777778-72.81777778l-910.22222222 0c-40.15900445 0-72.81777778 32.65877333-72.81777778 72.81777778l0 910.22222222c0 40.15900445 32.65877333 72.81777778 72.81777778 72.81777778L967.11111111 1039.92888889c40.15900445 0 72.81777778-32.65877333 72.81777778-72.81777778zM56.88888889 56.88888889L967.11111111 56.88888889l0 910.22222222-910.22222221 0.07281778L56.88888889 56.88888889z\"></path><path d=\"M876.08888889 349.17944888a36.40888889 36.40888889 0 0 0-36.40888889-36.40888889l-120.47701333 1e-8L719.20298668 184.32a36.40888889 36.40888889 0 0 0-72.81777779 0l0 164.85944889a36.40888889 36.40888889 0 0 0 36.40888889 36.40888889L839.68 385.58833778a36.40888889 36.40888889 0 0 0 36.40888889-36.4088889z m-156.88590221 473.27914667L719.20298667 694.04444445 839.68 694.04444445a36.40888889 36.40888889 0 1 0 0-72.81777778l-156.88590222 0a36.40888889 36.40888889 0 0 0-36.40888889 36.40888888l0 164.82304a36.40888889 36.40888889 0 1 0 72.81777779 0zM366.36444445 349.17944888L366.36444445 184.32a36.40888889 36.40888889 0 1 0-72.81777778 0l0 128.45055999-120.51342222 1e-8a36.40888889 36.40888889 0 1 0 0 72.81777778L329.95555555 385.58833778a36.40888889 36.40888889 0 0 0 36.4088889-36.4088889z m0 473.27914667L366.36444445 657.63555555a36.40888889 36.40888889 0 0 0-36.4088889-36.40888888l-156.9223111-1e-8a36.40888889 36.40888889 0 1 0 0 72.81777779L293.54666667 694.04444445l0 128.4141511a36.40888889 36.40888889 0 1 0 72.81777778 0z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
package/lib/icon/refresh.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/refresh.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "refresh-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"M771.776 794.88A384 384 0 0 1 128 512h64a320 320 0 0 0 555.712 216.448H654.72a32 32 0 1 1 0-64h149.056a32 32 0 0 1 32 32v148.928a32 32 0 1 1-64 0v-50.56zM276.288 295.616h92.992a32 32 0 0 1 0 64H220.16a32 32 0 0 1-32-32V178.56a32 32 0 0 1 64 0v50.56A384 384 0 0 1 896.128 512h-64a320 320 0 0 0-555.776-216.384z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/refresh_left.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/refresh_left.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "refresh-left-icon";
|
|
5
5
|
constructor() {
|
|
@@ -9,5 +9,4 @@ var t = class extends e {
|
|
|
9
9
|
return "<path d=\"M289.088 296.704h92.992a32 32 0 0 1 0 64H232.96a32 32 0 0 1-32-32V179.712a32 32 0 0 1 64 0v50.56a384 384 0 0 1 643.84 282.88 384 384 0 0 1-383.936 384 384 384 0 0 1-384-384h64a320 320 0 1 0 640 0 320 320 0 0 0-555.712-216.448z\"></path>";
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
|
-
//#endregion
|
|
13
12
|
export { t as default };
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/refresh_right.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "refresh-right-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path d=\"M784.512 230.272v-50.56a32 32 0 1 1 64 0v149.056a32 32 0 0 1-32 32H667.52a32 32 0 1 1 0-64h92.992A320 320 0 1 0 524.8 833.152a320 320 0 0 0 320-320h64a384 384 0 0 1-384 384 384 384 0 0 1-384-384 384 384 0 0 1 643.712-282.88z\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|
package/lib/icon/search.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import e from "./base.js";
|
|
2
|
-
|
|
2
|
+
// src/components/icon/search.ts
|
|
3
3
|
var t = class extends e {
|
|
4
4
|
static baseName = "search-icon";
|
|
5
5
|
renderChildren() {
|
|
6
6
|
return "<path fill=\"currentColor\" d=\"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704\"></path>";
|
|
7
7
|
}
|
|
8
8
|
};
|
|
9
|
-
//#endregion
|
|
10
9
|
export { t as default };
|