@whitesev/pops 2.4.6 → 2.4.7

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.
Files changed (142) hide show
  1. package/dist/index.amd.js +578 -571
  2. package/dist/index.amd.js.map +1 -1
  3. package/dist/index.cjs.js +578 -571
  4. package/dist/index.cjs.js.map +1 -1
  5. package/dist/index.esm.js +578 -571
  6. package/dist/index.esm.js.map +1 -1
  7. package/dist/index.iife.js +578 -571
  8. package/dist/index.iife.js.map +1 -1
  9. package/dist/index.system.js +578 -571
  10. package/dist/index.system.js.map +1 -1
  11. package/dist/index.umd.js +578 -571
  12. package/dist/index.umd.js.map +1 -1
  13. package/dist/types/src/types/PopsDOMUtilsEventType.d.ts +252 -252
  14. package/dist/types/src/types/animation.d.ts +19 -19
  15. package/dist/types/src/types/button.d.ts +187 -187
  16. package/dist/types/src/types/components.d.ts +210 -210
  17. package/dist/types/src/types/event.d.ts +63 -63
  18. package/dist/types/src/types/global.d.ts +25 -25
  19. package/dist/types/src/types/icon.d.ts +32 -32
  20. package/dist/types/src/types/inst.d.ts +24 -24
  21. package/dist/types/src/types/main.d.ts +111 -111
  22. package/dist/types/src/types/mask.d.ts +49 -49
  23. package/dist/types/src/types/position.d.ts +60 -60
  24. package/index.ts +3 -0
  25. package/package.json +4 -2
  26. package/src/Pops.ts +206 -0
  27. package/src/PopsAnimation.ts +32 -0
  28. package/src/PopsCSS.ts +51 -0
  29. package/src/PopsCore.ts +64 -0
  30. package/src/PopsIcon.ts +95 -0
  31. package/src/PopsInst.ts +21 -0
  32. package/src/components/alert/config.ts +62 -0
  33. package/src/components/alert/index.css +0 -0
  34. package/src/components/alert/index.ts +163 -0
  35. package/src/components/alert/types/index.ts +23 -0
  36. package/src/components/confirm/config.ts +90 -0
  37. package/src/components/confirm/index.css +0 -0
  38. package/src/components/confirm/index.ts +166 -0
  39. package/src/components/confirm/types/index.ts +17 -0
  40. package/src/components/drawer/config.ts +89 -0
  41. package/src/components/drawer/index.css +37 -0
  42. package/src/components/drawer/index.ts +237 -0
  43. package/src/components/drawer/types/index.ts +61 -0
  44. package/src/components/folder/config.ts +147 -0
  45. package/src/components/folder/folderIcon.ts +28 -0
  46. package/src/components/folder/index.css +303 -0
  47. package/src/components/folder/index.ts +929 -0
  48. package/src/components/folder/types/index.ts +97 -0
  49. package/src/components/iframe/config.ts +60 -0
  50. package/src/components/iframe/index.css +76 -0
  51. package/src/components/iframe/index.ts +334 -0
  52. package/src/components/iframe/types/index.ts +139 -0
  53. package/src/components/loading/config.ts +29 -0
  54. package/src/components/loading/index.css +66 -0
  55. package/src/components/loading/index.ts +99 -0
  56. package/src/components/loading/types/index.ts +34 -0
  57. package/src/components/panel/config.ts +519 -0
  58. package/src/components/panel/handlerComponents.ts +2900 -0
  59. package/src/components/panel/index.css +1222 -0
  60. package/src/components/panel/index.ts +207 -0
  61. package/src/components/panel/types/components-button.ts +68 -0
  62. package/src/components/panel/types/components-common.ts +50 -0
  63. package/src/components/panel/types/components-deepMenu.ts +84 -0
  64. package/src/components/panel/types/components-forms.ts +44 -0
  65. package/src/components/panel/types/components-input.ts +78 -0
  66. package/src/components/panel/types/components-own.ts +30 -0
  67. package/src/components/panel/types/components-select.ts +93 -0
  68. package/src/components/panel/types/components-selectMultiple.ts +130 -0
  69. package/src/components/panel/types/components-slider.ts +77 -0
  70. package/src/components/panel/types/components-switch.ts +56 -0
  71. package/src/components/panel/types/components-textarea.ts +68 -0
  72. package/src/components/panel/types/index.ts +177 -0
  73. package/src/components/prompt/config.ts +94 -0
  74. package/src/components/prompt/index.css +34 -0
  75. package/src/components/prompt/index.ts +216 -0
  76. package/src/components/prompt/types/index.ts +55 -0
  77. package/src/components/rightClickMenu/config.ts +98 -0
  78. package/src/components/rightClickMenu/index.css +112 -0
  79. package/src/components/rightClickMenu/index.ts +602 -0
  80. package/src/components/rightClickMenu/types/index.ts +97 -0
  81. package/src/components/searchSuggestion/config.ts +56 -0
  82. package/src/components/searchSuggestion/index.ts +856 -0
  83. package/src/components/searchSuggestion/types/index.ts +239 -0
  84. package/src/components/tooltip/config.ts +34 -0
  85. package/src/components/tooltip/index.css +199 -0
  86. package/src/components/tooltip/index.ts +604 -0
  87. package/src/components/tooltip/types/index.ts +117 -0
  88. package/src/config/CommonCSSClassName.ts +17 -0
  89. package/src/config/GlobalConfig.ts +63 -0
  90. package/src/css/animation.css +987 -0
  91. package/src/css/button.css +551 -0
  92. package/src/css/common.css +48 -0
  93. package/src/css/index.css +253 -0
  94. package/src/css/ninePalaceGridPosition.css +50 -0
  95. package/src/css/scrollbar.css +22 -0
  96. package/src/handler/PopsElementHandler.ts +304 -0
  97. package/src/handler/PopsHandler.ts +589 -0
  98. package/src/svg/arrowLeft.svg +4 -0
  99. package/src/svg/arrowRight.svg +4 -0
  100. package/src/svg/chromeFilled.svg +11 -0
  101. package/src/svg/circleClose.svg +8 -0
  102. package/src/svg/close.svg +5 -0
  103. package/src/svg/cpu.svg +8 -0
  104. package/src/svg/delete.svg +5 -0
  105. package/src/svg/documentCopy.svg +5 -0
  106. package/src/svg/edit.svg +8 -0
  107. package/src/svg/eleme.svg +5 -0
  108. package/src/svg/elemePlus.svg +5 -0
  109. package/src/svg/headset.svg +5 -0
  110. package/src/svg/hide.svg +8 -0
  111. package/src/svg/keyboard.svg +8 -0
  112. package/src/svg/loading.svg +5 -0
  113. package/src/svg/max.svg +5 -0
  114. package/src/svg/min.svg +5 -0
  115. package/src/svg/mise.svg +5 -0
  116. package/src/svg/monitor.svg +5 -0
  117. package/src/svg/next.svg +5 -0
  118. package/src/svg/picture.svg +8 -0
  119. package/src/svg/prev.svg +5 -0
  120. package/src/svg/search.svg +5 -0
  121. package/src/svg/share.svg +5 -0
  122. package/src/svg/upload.svg +5 -0
  123. package/src/svg/videoPause.svg +5 -0
  124. package/src/svg/videoPlay.svg +5 -0
  125. package/src/svg/view.svg +5 -0
  126. package/src/types/PopsDOMUtilsEventType.d.ts +252 -0
  127. package/src/types/animation.d.ts +19 -0
  128. package/src/types/button.d.ts +187 -0
  129. package/src/types/components.d.ts +210 -0
  130. package/src/types/event.d.ts +63 -0
  131. package/src/types/global.d.ts +25 -0
  132. package/src/types/icon.d.ts +32 -0
  133. package/src/types/inst.d.ts +24 -0
  134. package/src/types/main.d.ts +111 -0
  135. package/src/types/mask.d.ts +49 -0
  136. package/src/types/position.d.ts +60 -0
  137. package/src/utils/PopsDOMUtils.ts +2408 -0
  138. package/src/utils/PopsDOMUtilsEventsConfig.ts +4 -0
  139. package/src/utils/PopsInstanceUtils.ts +688 -0
  140. package/src/utils/PopsMathUtils.ts +71 -0
  141. package/src/utils/PopsSafeUtils.ts +22 -0
  142. package/src/utils/PopsUtils.ts +406 -0
@@ -1,24 +1,24 @@
1
- /**
2
- * config实例配置
3
- */
4
- export interface PopsInstConfig {
5
- /** 固定id */
6
- guid: string;
7
- /** 动画元素 */
8
- animElement: HTMLDivElement;
9
- /** 主元素 */
10
- popsElement: HTMLDivElement;
11
- /** 遮罩层元素 */
12
- maskElement?: HTMLDivElement;
13
- }
14
- /**
15
- * config实例通用配置
16
- */
17
- export interface PopsInstCommonConfig extends PopsInstConfig {
18
- /** shadow容器 */
19
- $shadowContainer: HTMLDivElement;
20
- /** shadow容器的shandowRoot */
21
- $shadowRoot: ShadowRoot | HTMLElement;
22
- /** 移除实例前的回调函数 */
23
- beforeRemoveCallBack?: (instCommonConfig: PopsInstCommonConfig) => void;
24
- }
1
+ /**
2
+ * config实例配置
3
+ */
4
+ export interface PopsInstConfig {
5
+ /** 固定id */
6
+ guid: string;
7
+ /** 动画元素 */
8
+ animElement: HTMLDivElement;
9
+ /** 主元素 */
10
+ popsElement: HTMLDivElement;
11
+ /** 遮罩层元素 */
12
+ maskElement?: HTMLDivElement;
13
+ }
14
+ /**
15
+ * config实例通用配置
16
+ */
17
+ export interface PopsInstCommonConfig extends PopsInstConfig {
18
+ /** shadow容器 */
19
+ $shadowContainer: HTMLDivElement;
20
+ /** shadow容器的shandowRoot */
21
+ $shadowRoot: ShadowRoot | HTMLElement;
22
+ /** 移除实例前的回调函数 */
23
+ beforeRemoveCallBack?: (instCommonConfig: PopsInstCommonConfig) => void;
24
+ }
@@ -1,111 +1,111 @@
1
- import type { PopsAlertDetails } from "../components/alert/types";
2
- import type { PopsConfirmDetails } from "../components/confirm/types";
3
- import type { PopsDrawerDetails } from "../components/drawer/types";
4
- import type { PopsFolderDetails } from "../components/folder/types";
5
- import type { PopsIframeDetails } from "../components/iframe/types";
6
- import type { PopsLoadingDetails } from "../components/loading/types";
7
- import type { PopsPanelButtonDetails } from "../components/panel/types/components-button";
8
- import type { PopsPanelDeepMenuDetails } from "../components/panel/types/components-deepMenu";
9
- import type { PopsPanelDetails } from "../components/panel/types";
10
- import type { PopsPanelInputDetails } from "../components/panel/types/components-input";
11
- import type { PopsPanelOwnDetails } from "../components/panel/types/components-own";
12
- import type { PopsPanelSelectDetails } from "../components/panel/types/components-select";
13
- import type { PopsPanelSliderDetails } from "../components/panel/types/components-slider";
14
- import type { PopsPanelSwitchDetails } from "../components/panel/types/components-switch";
15
- import type { PopsPanelTextAreaDetails } from "../components/panel/types/components-textarea";
16
- import type { PopsPromptDetails } from "../components/prompt/types/index";
17
- import type { PopsRightClickMenuDetails } from "../components/rightClickMenu/types";
18
- import type { PopsToolTipDetails } from "../components/tooltip/types/index";
19
- import type { PopsSearchSuggestionDetails } from "../components/searchSuggestion/types";
20
-
21
- export interface PopsUtilsOwnObject<V> {
22
- [key: string]: V | PopsUtilsOwnObject<V>;
23
- }
24
-
25
- /** pops所有的类型配置 11个*/
26
- export interface PopsDetails {
27
- alert: PopsAlertDetails;
28
- confirm: PopsConfirmDetails;
29
- prompt: PopsPromptDetails;
30
- loading: PopsLoadingDetails;
31
- iframe: PopsIframeDetails;
32
- tooltip: PopsToolTipDetails;
33
- drawer: PopsDrawerDetails;
34
- folder: PopsFolderDetails;
35
- panel: PopsPanelDetails;
36
- rightClickMenu: PopsRightClickMenuDetails;
37
- searchSuggestion: PopsSearchSuggestionDetails;
38
- }
39
-
40
- /** pops的类型 */
41
- export type PopsType = keyof PopsDetails;
42
-
43
- /** pops中支持only的配置 */
44
- export type PopsSupportOnlyDetails = Omit<PopsDetails, "searchSuggestion">;
45
-
46
- /** 存储实例的类型 */
47
- export type PopsInstStoreType = keyof Omit<PopsDetails, "searchSuggestion">;
48
-
49
- /** pops弹窗支持动画元素的配置 8个 */
50
- export type PopsSupportAnimDetails = Omit<PopsDetails, "tooltip" | "rightClickMenu" | "searchSuggestion">;
51
-
52
- /** pops弹窗支持动画元素的类型 */
53
- export type PopsSupportAnimDetailsType = keyof PopsSupportAnimDetails;
54
-
55
- /** pops弹窗支持标题栏的配置 */
56
- export type PopsSupportHeaderTitleDetails = Pick<
57
- PopsDetails,
58
- "alert" | "confirm" | "prompt" | "iframe" | "drawer" | "folder" | "panel"
59
- >;
60
-
61
- /** pops弹窗支持标题栏的类型 */
62
- export type PopsSupportHeaderTitleDetailsType = keyof PopsSupportHeaderTitleDetails;
63
-
64
- /** pops支持底部按钮的配置 */
65
- export type PopsSupportBottomBtnDetails = Pick<PopsDetails, "alert" | "confirm" | "prompt" | "drawer">;
66
-
67
- /** pops支持底部按钮的类型 */
68
- export type PopsSupportBottomBtnDetailsType = keyof PopsSupportHeaderTitleDetails;
69
-
70
- /** pops支持中间内容的配置 */
71
- export type PopsSupportContentDetails = Pick<PopsDetails, "alert" | "confirm" | "prompt" | "drawer" | "loading">;
72
-
73
- /** pops支持中间内容的类型 */
74
- export type PopsSupportContentDetailsType = keyof PopsSupportContentDetails;
75
-
76
- /** panel的各种类型的配置项 */
77
- export type PopsPanelFormsTotalDetails =
78
- | PopsPanelSwitchDetails
79
- | PopsPanelSliderDetails
80
- | PopsPanelInputDetails
81
- | PopsPanelTextAreaDetails
82
- | PopsPanelSelectDetails<any>
83
- | PopsPanelButtonDetails
84
- | PopsPanelDeepMenuDetails
85
- | PopsPanelOwnDetails;
86
-
87
- /**
88
- * pops.xxx的调用返回值
89
- */
90
- export interface PopsCallResult {
91
- /** 唯一标识id */
92
- guid: string;
93
- /** 影子元素 */
94
- $shadowContainer: HTMLDivElement;
95
- /** 影子元素的根节点 */
96
- $shadowRoot: ShadowRoot | HTMLElement;
97
- /** 元素 */
98
- element: HTMLDivElement;
99
- /** 动画层元素 */
100
- animElement: HTMLDivElement;
101
- /** pops元素 */
102
- popsElement: HTMLDivElement;
103
- /** 遮罩层元素 */
104
- maskElement?: HTMLDivElement;
105
- /** 关闭弹窗 */
106
- close(): void;
107
- /** 隐藏弹窗 */
108
- hide(): void;
109
- /** 显示弹窗 */
110
- show(): void;
111
- }
1
+ import type { PopsAlertDetails } from "../components/alert/types";
2
+ import type { PopsConfirmDetails } from "../components/confirm/types";
3
+ import type { PopsDrawerDetails } from "../components/drawer/types";
4
+ import type { PopsFolderDetails } from "../components/folder/types";
5
+ import type { PopsIframeDetails } from "../components/iframe/types";
6
+ import type { PopsLoadingDetails } from "../components/loading/types";
7
+ import type { PopsPanelButtonDetails } from "../components/panel/types/components-button";
8
+ import type { PopsPanelDeepMenuDetails } from "../components/panel/types/components-deepMenu";
9
+ import type { PopsPanelDetails } from "../components/panel/types";
10
+ import type { PopsPanelInputDetails } from "../components/panel/types/components-input";
11
+ import type { PopsPanelOwnDetails } from "../components/panel/types/components-own";
12
+ import type { PopsPanelSelectDetails } from "../components/panel/types/components-select";
13
+ import type { PopsPanelSliderDetails } from "../components/panel/types/components-slider";
14
+ import type { PopsPanelSwitchDetails } from "../components/panel/types/components-switch";
15
+ import type { PopsPanelTextAreaDetails } from "../components/panel/types/components-textarea";
16
+ import type { PopsPromptDetails } from "../components/prompt/types/index";
17
+ import type { PopsRightClickMenuDetails } from "../components/rightClickMenu/types";
18
+ import type { PopsToolTipDetails } from "../components/tooltip/types/index";
19
+ import type { PopsSearchSuggestionDetails } from "../components/searchSuggestion/types";
20
+
21
+ export interface PopsUtilsOwnObject<V> {
22
+ [key: string]: V | PopsUtilsOwnObject<V>;
23
+ }
24
+
25
+ /** pops所有的类型配置 11个*/
26
+ export interface PopsDetails {
27
+ alert: PopsAlertDetails;
28
+ confirm: PopsConfirmDetails;
29
+ prompt: PopsPromptDetails;
30
+ loading: PopsLoadingDetails;
31
+ iframe: PopsIframeDetails;
32
+ tooltip: PopsToolTipDetails;
33
+ drawer: PopsDrawerDetails;
34
+ folder: PopsFolderDetails;
35
+ panel: PopsPanelDetails;
36
+ rightClickMenu: PopsRightClickMenuDetails;
37
+ searchSuggestion: PopsSearchSuggestionDetails;
38
+ }
39
+
40
+ /** pops的类型 */
41
+ export type PopsType = keyof PopsDetails;
42
+
43
+ /** pops中支持only的配置 */
44
+ export type PopsSupportOnlyDetails = Omit<PopsDetails, "searchSuggestion">;
45
+
46
+ /** 存储实例的类型 */
47
+ export type PopsInstStoreType = keyof Omit<PopsDetails, "searchSuggestion">;
48
+
49
+ /** pops弹窗支持动画元素的配置 8个 */
50
+ export type PopsSupportAnimDetails = Omit<PopsDetails, "tooltip" | "rightClickMenu" | "searchSuggestion">;
51
+
52
+ /** pops弹窗支持动画元素的类型 */
53
+ export type PopsSupportAnimDetailsType = keyof PopsSupportAnimDetails;
54
+
55
+ /** pops弹窗支持标题栏的配置 */
56
+ export type PopsSupportHeaderTitleDetails = Pick<
57
+ PopsDetails,
58
+ "alert" | "confirm" | "prompt" | "iframe" | "drawer" | "folder" | "panel"
59
+ >;
60
+
61
+ /** pops弹窗支持标题栏的类型 */
62
+ export type PopsSupportHeaderTitleDetailsType = keyof PopsSupportHeaderTitleDetails;
63
+
64
+ /** pops支持底部按钮的配置 */
65
+ export type PopsSupportBottomBtnDetails = Pick<PopsDetails, "alert" | "confirm" | "prompt" | "drawer">;
66
+
67
+ /** pops支持底部按钮的类型 */
68
+ export type PopsSupportBottomBtnDetailsType = keyof PopsSupportHeaderTitleDetails;
69
+
70
+ /** pops支持中间内容的配置 */
71
+ export type PopsSupportContentDetails = Pick<PopsDetails, "alert" | "confirm" | "prompt" | "drawer" | "loading">;
72
+
73
+ /** pops支持中间内容的类型 */
74
+ export type PopsSupportContentDetailsType = keyof PopsSupportContentDetails;
75
+
76
+ /** panel的各种类型的配置项 */
77
+ export type PopsPanelFormsTotalDetails =
78
+ | PopsPanelSwitchDetails
79
+ | PopsPanelSliderDetails
80
+ | PopsPanelInputDetails
81
+ | PopsPanelTextAreaDetails
82
+ | PopsPanelSelectDetails<any>
83
+ | PopsPanelButtonDetails
84
+ | PopsPanelDeepMenuDetails
85
+ | PopsPanelOwnDetails;
86
+
87
+ /**
88
+ * pops.xxx的调用返回值
89
+ */
90
+ export interface PopsCallResult {
91
+ /** 唯一标识id */
92
+ guid: string;
93
+ /** 影子元素 */
94
+ $shadowContainer: HTMLDivElement;
95
+ /** 影子元素的根节点 */
96
+ $shadowRoot: ShadowRoot | HTMLElement;
97
+ /** 元素 */
98
+ element: HTMLDivElement;
99
+ /** 动画层元素 */
100
+ animElement: HTMLDivElement;
101
+ /** pops元素 */
102
+ popsElement: HTMLDivElement;
103
+ /** 遮罩层元素 */
104
+ maskElement?: HTMLDivElement;
105
+ /** 关闭弹窗 */
106
+ close(): void;
107
+ /** 隐藏弹窗 */
108
+ hide(): void;
109
+ /** 显示弹窗 */
110
+ show(): void;
111
+ }
@@ -1,49 +1,49 @@
1
- import type { PopsAlertDetails } from "../components/alert/types";
2
- import type { PopsDrawerDetails } from "../components/drawer/types";
3
- import type { PopsFolderDetails } from "../components/folder/types";
4
- import type { PopsIframeDetails } from "../components/iframe/types";
5
- import type { PopsLoadingDetails } from "../components/loading/types";
6
- import type { PopsPanelDetails } from "../components/panel/types";
7
- import type { PopsPromptDetails } from "../components/prompt/types/index";
8
-
9
- /**
10
- * 遮罩层配置
11
- */
12
- export interface PopsMaskDetails {
13
- /**
14
- * 是否启用遮罩层,默认false
15
- * @default false
16
- */
17
- enable?: boolean;
18
- clickEvent?: {
19
- /**
20
- * 点击遮罩层是否触发关闭事件
21
- * @default false
22
- */
23
- toClose?: boolean;
24
- /**
25
- * 点击遮罩层是否触发隐藏事件
26
- * @default false
27
- */
28
- toHide?: boolean;
29
- };
30
- /**
31
- * 遮罩层自定义的点击事件
32
- * @param originalRun 当toClose为true,它是关闭弹窗,当toHide为true,它是隐藏弹窗
33
- * @param config 配置信息
34
- */
35
- clickCallBack?:
36
- | ((
37
- originalRun: () => void | Promise<void>,
38
- config:
39
- | PopsAlertDetails
40
- | PopsDrawerDetails
41
- | PopsIframeDetails
42
- | PopsPromptDetails
43
- | PopsFolderDetails
44
- | PopsLoadingDetails
45
- | PopsPanelDetails
46
- ) => void)
47
- | undefined
48
- | null;
49
- }
1
+ import type { PopsAlertDetails } from "../components/alert/types";
2
+ import type { PopsDrawerDetails } from "../components/drawer/types";
3
+ import type { PopsFolderDetails } from "../components/folder/types";
4
+ import type { PopsIframeDetails } from "../components/iframe/types";
5
+ import type { PopsLoadingDetails } from "../components/loading/types";
6
+ import type { PopsPanelDetails } from "../components/panel/types";
7
+ import type { PopsPromptDetails } from "../components/prompt/types/index";
8
+
9
+ /**
10
+ * 遮罩层配置
11
+ */
12
+ export interface PopsMaskDetails {
13
+ /**
14
+ * 是否启用遮罩层,默认false
15
+ * @default false
16
+ */
17
+ enable?: boolean;
18
+ clickEvent?: {
19
+ /**
20
+ * 点击遮罩层是否触发关闭事件
21
+ * @default false
22
+ */
23
+ toClose?: boolean;
24
+ /**
25
+ * 点击遮罩层是否触发隐藏事件
26
+ * @default false
27
+ */
28
+ toHide?: boolean;
29
+ };
30
+ /**
31
+ * 遮罩层自定义的点击事件
32
+ * @param originalRun 当toClose为true,它是关闭弹窗,当toHide为true,它是隐藏弹窗
33
+ * @param config 配置信息
34
+ */
35
+ clickCallBack?:
36
+ | ((
37
+ originalRun: () => void | Promise<void>,
38
+ config:
39
+ | PopsAlertDetails
40
+ | PopsDrawerDetails
41
+ | PopsIframeDetails
42
+ | PopsPromptDetails
43
+ | PopsFolderDetails
44
+ | PopsLoadingDetails
45
+ | PopsPanelDetails
46
+ ) => void)
47
+ | undefined
48
+ | null;
49
+ }
@@ -1,60 +1,60 @@
1
- /**
2
- * 弹窗位置
3
- */
4
- export type PopsPosition =
5
- | "top_left"
6
- | "top"
7
- | "top_right"
8
- | "center_left"
9
- | "center"
10
- | "center_right"
11
- | "bottom_left"
12
- | "bottom"
13
- | "bottom_right";
14
-
15
- /**
16
- * 按钮位置
17
- */
18
- export type PopsJustifyContent =
19
- | "center"
20
- | "end"
21
- | "flex-end"
22
- | "flex-start"
23
- | "left"
24
- | "normal"
25
- | "right"
26
- | "space-around"
27
- | "space-between"
28
- | "space-evenly"
29
- | "start"
30
- | "stretch"
31
- | "inherit"
32
- | "initial"
33
- | "revert"
34
- | "revert-layer"
35
- | "unset";
36
-
37
- /**
38
- * text-align
39
- */
40
- export type PopsTextAlign =
41
- | "center"
42
- | "end"
43
- | "justify"
44
- | "left"
45
- | "right"
46
- | "start"
47
- | "-webkit-auto"
48
- | "-moz-center-or-inherit"
49
- | "-webkit-center"
50
- | "-moz-center"
51
- | "-webkit-left"
52
- | "-moz-left"
53
- | "-webkit-match-parent"
54
- | "-webkit-right"
55
- | "-moz-right"
56
- | "inherit"
57
- | "initial"
58
- | "revert"
59
- | "revert-layer"
60
- | "unset";
1
+ /**
2
+ * 弹窗位置
3
+ */
4
+ export type PopsPosition =
5
+ | "top_left"
6
+ | "top"
7
+ | "top_right"
8
+ | "center_left"
9
+ | "center"
10
+ | "center_right"
11
+ | "bottom_left"
12
+ | "bottom"
13
+ | "bottom_right";
14
+
15
+ /**
16
+ * 按钮位置
17
+ */
18
+ export type PopsJustifyContent =
19
+ | "center"
20
+ | "end"
21
+ | "flex-end"
22
+ | "flex-start"
23
+ | "left"
24
+ | "normal"
25
+ | "right"
26
+ | "space-around"
27
+ | "space-between"
28
+ | "space-evenly"
29
+ | "start"
30
+ | "stretch"
31
+ | "inherit"
32
+ | "initial"
33
+ | "revert"
34
+ | "revert-layer"
35
+ | "unset";
36
+
37
+ /**
38
+ * text-align
39
+ */
40
+ export type PopsTextAlign =
41
+ | "center"
42
+ | "end"
43
+ | "justify"
44
+ | "left"
45
+ | "right"
46
+ | "start"
47
+ | "-webkit-auto"
48
+ | "-moz-center-or-inherit"
49
+ | "-webkit-center"
50
+ | "-moz-center"
51
+ | "-webkit-left"
52
+ | "-moz-left"
53
+ | "-webkit-match-parent"
54
+ | "-webkit-right"
55
+ | "-moz-right"
56
+ | "inherit"
57
+ | "initial"
58
+ | "revert"
59
+ | "revert-layer"
60
+ | "unset";
package/index.ts ADDED
@@ -0,0 +1,3 @@
1
+ import { pops } from "./src/Pops";
2
+
3
+ export default pops;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@whitesev/pops",
3
- "version": "2.4.6",
3
+ "version": "2.4.7",
4
4
  "description": "弹窗库",
5
5
  "type": "module",
6
6
  "homepage": "https://github.com/WhiteSevs/TamperMonkeyScript/tree/master/lib/pops#readme",
@@ -21,7 +21,9 @@
21
21
  }
22
22
  },
23
23
  "files": [
24
- "dist"
24
+ "dist",
25
+ "src",
26
+ "./index.ts"
25
27
  ],
26
28
  "publishConfig": {
27
29
  "registry": "https://registry.npmjs.org/"