@pisell/materials 1.0.1 → 1.0.3
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/build/lowcode/assets-daily.json +93 -0
- package/build/lowcode/assets-dev.json +93 -0
- package/build/lowcode/assets-prod.json +93 -0
- package/build/lowcode/designer.html +303 -0
- package/build/lowcode/index.html +305 -0
- package/build/lowcode/index.js +1 -0
- package/build/lowcode/meta.js +9 -0
- package/build/lowcode/preview.css +1 -0
- package/build/lowcode/preview.html +35 -0
- package/build/lowcode/preview.js +304 -0
- package/build/lowcode/render/default/view.js +22 -0
- package/build/lowcode/view.js +22 -0
- package/es/components/auto-complete/index.d.ts +3 -0
- package/es/components/auto-complete/index.js +4 -0
- package/es/components/button/index.d.ts +3 -0
- package/es/components/button/index.js +15 -0
- package/es/components/calendar/index.d.ts +3 -0
- package/es/components/calendar/index.js +4 -0
- package/es/components/cascader/index.d.ts +3 -0
- package/es/components/cascader/index.js +4 -0
- package/es/components/checkbox/index.d.ts +3 -0
- package/es/components/checkbox/index.js +5 -0
- package/es/components/config-provider/index.d.ts +4 -0
- package/es/components/config-provider/index.js +30 -0
- package/es/components/date-picker/index.d.ts +3 -0
- package/es/components/date-picker/index.js +7 -0
- package/es/components/drawer/index.d.ts +2 -0
- package/es/components/drawer/index.js +13 -0
- package/es/components/dropdown/index.d.ts +3 -0
- package/es/components/dropdown/index.js +13 -0
- package/es/components/form/index.d.ts +8 -0
- package/es/components/form/index.js +132 -0
- package/es/components/icon/index.d.ts +12 -0
- package/es/components/icon/index.js +40 -0
- package/es/components/input/index.d.ts +3 -0
- package/es/components/input/index.js +12 -0
- package/es/components/modal/index.d.ts +2 -0
- package/es/components/modal/index.js +18 -0
- package/es/components/radio/index.d.ts +3 -0
- package/es/components/radio/index.js +5 -0
- package/es/components/select/index.d.ts +3 -0
- package/es/components/select/index.js +4 -0
- package/es/components/skeleton/index.d.ts +3 -0
- package/es/components/skeleton/index.js +5 -0
- package/es/components/slider/index.d.ts +3 -0
- package/es/components/slider/index.js +16 -0
- package/es/components/table/index.d.ts +3 -0
- package/es/components/table/index.js +12 -0
- package/es/components/tabs/index.d.ts +11 -0
- package/es/components/tabs/index.js +93 -0
- package/es/components/time-picker/index.d.ts +3 -0
- package/es/components/time-picker/index.js +4 -0
- package/es/components/tree-select/index.d.ts +2 -0
- package/es/components/tree-select/index.js +6 -0
- package/es/components/upload/index.d.ts +3 -0
- package/es/components/upload/index.js +4 -0
- package/es/index.d.ts +63 -0
- package/es/index.js +85 -0
- package/es/utils/hoc.d.ts +17 -0
- package/es/utils/hoc.js +80 -0
- package/es/utils/warning.d.ts +1 -0
- package/es/utils/warning.js +6 -0
- package/lib/components/auto-complete/index.d.ts +3 -0
- package/lib/components/auto-complete/index.js +28 -0
- package/lib/components/button/index.d.ts +3 -0
- package/lib/components/button/index.js +45 -0
- package/lib/components/calendar/index.d.ts +3 -0
- package/lib/components/calendar/index.js +32 -0
- package/lib/components/cascader/index.d.ts +3 -0
- package/lib/components/cascader/index.js +28 -0
- package/lib/components/checkbox/index.d.ts +3 -0
- package/lib/components/checkbox/index.js +29 -0
- package/lib/components/config-provider/index.d.ts +4 -0
- package/lib/components/config-provider/index.js +54 -0
- package/lib/components/date-picker/index.d.ts +3 -0
- package/lib/components/date-picker/index.js +41 -0
- package/lib/components/drawer/index.d.ts +2 -0
- package/lib/components/drawer/index.js +45 -0
- package/lib/components/dropdown/index.d.ts +3 -0
- package/lib/components/dropdown/index.js +45 -0
- package/lib/components/form/index.d.ts +8 -0
- package/lib/components/form/index.js +114 -0
- package/lib/components/icon/index.d.ts +12 -0
- package/lib/components/icon/index.js +52 -0
- package/lib/components/input/index.d.ts +3 -0
- package/lib/components/input/index.js +38 -0
- package/lib/components/modal/index.d.ts +2 -0
- package/lib/components/modal/index.js +50 -0
- package/lib/components/radio/index.d.ts +3 -0
- package/lib/components/radio/index.js +29 -0
- package/lib/components/select/index.d.ts +3 -0
- package/lib/components/select/index.js +28 -0
- package/lib/components/skeleton/index.d.ts +3 -0
- package/lib/components/skeleton/index.js +29 -0
- package/lib/components/slider/index.d.ts +3 -0
- package/lib/components/slider/index.js +47 -0
- package/lib/components/table/index.d.ts +3 -0
- package/lib/components/table/index.js +41 -0
- package/lib/components/tabs/index.d.ts +11 -0
- package/lib/components/tabs/index.js +92 -0
- package/lib/components/time-picker/index.d.ts +3 -0
- package/lib/components/time-picker/index.js +31 -0
- package/lib/components/tree-select/index.d.ts +2 -0
- package/lib/components/tree-select/index.js +40 -0
- package/lib/components/upload/index.d.ts +3 -0
- package/lib/components/upload/index.js +28 -0
- package/lib/index.d.ts +63 -0
- package/lib/index.js +225 -0
- package/lib/utils/hoc.d.ts +17 -0
- package/lib/utils/hoc.js +101 -0
- package/lib/utils/warning.d.ts +1 -0
- package/lib/utils/warning.js +31 -0
- package/lowcode/_setters/antd-icon-setter/index.tsx +285 -0
- package/lowcode/_setters/antd-icon-setter/style.less +69 -0
- package/lowcode/_setters/index.tsx +1 -0
- package/lowcode/_utils/hoc.tsx +93 -0
- package/lowcode/_utils/transform-meta.ts +343 -0
- package/lowcode/_utils/utils.ts +6 -0
- package/lowcode/affix/__screenshots__/affix-1.jpg +0 -0
- package/lowcode/affix/meta.ts +68 -0
- package/lowcode/affix/snippets.ts +20 -0
- package/lowcode/alert/__screenshots__/alert-1.png +0 -0
- package/lowcode/alert/__screenshots__/alert-2.png +0 -0
- package/lowcode/alert/__screenshots__/alert-3.png +0 -0
- package/lowcode/alert/__screenshots__/alert-4.png +0 -0
- package/lowcode/alert/meta.ts +102 -0
- package/lowcode/alert/snippets.ts +54 -0
- package/lowcode/anchor/__screenshots__/anchor-1.png +0 -0
- package/lowcode/anchor/snippets.ts +30 -0
- package/lowcode/anchor.link/meta.ts +29 -0
- package/lowcode/anchor.link/snippets.ts +1 -0
- package/lowcode/auto-complete/__screenshots__/auto-complete-1.png +0 -0
- package/lowcode/auto-complete/meta.ts +453 -0
- package/lowcode/auto-complete/snippets.ts +26 -0
- package/lowcode/avatar/__screenshots__/avatar-1.jpg +0 -0
- package/lowcode/avatar/meta.ts +82 -0
- package/lowcode/avatar/snippets.ts +12 -0
- package/lowcode/badge/__screenshots__/badge-1.png +0 -0
- package/lowcode/badge/meta.ts +94 -0
- package/lowcode/badge/snippets.ts +12 -0
- package/lowcode/breadcrumb/__screenshots__/breadcrumb-1.jpg +0 -0
- package/lowcode/breadcrumb/meta.ts +136 -0
- package/lowcode/breadcrumb/snippets.ts +44 -0
- package/lowcode/button/__screenshots__/button-1.png +0 -0
- package/lowcode/button/__screenshots__/button-2.png +0 -0
- package/lowcode/button/__screenshots__/button-3.png +0 -0
- package/lowcode/button/__screenshots__/button-4.png +0 -0
- package/lowcode/button/__screenshots__/button-5.png +0 -0
- package/lowcode/button/__screenshots__/button-6.png +0 -0
- package/lowcode/button/meta.ts +510 -0
- package/lowcode/button/snippets.ts +68 -0
- package/lowcode/calendar/__screenshots__/calendar-1.jpg +0 -0
- package/lowcode/calendar/meta.ts +133 -0
- package/lowcode/calendar/snippets.ts +10 -0
- package/lowcode/card/__screenshots__/card-1.png +0 -0
- package/lowcode/card/meta.ts +97 -0
- package/lowcode/card/snippets.ts +12 -0
- package/lowcode/carousel/__screenshots__/carousel-1.jpg +0 -0
- package/lowcode/carousel/meta.ts +148 -0
- package/lowcode/carousel/snippets.ts +23 -0
- package/lowcode/cascader/__screenshots__/cascader-1.png +0 -0
- package/lowcode/cascader/meta.ts +175 -0
- package/lowcode/cascader/snippets.ts +46 -0
- package/lowcode/checkbox/__screenshots__/checkbox-1.png +0 -0
- package/lowcode/checkbox/meta.ts +85 -0
- package/lowcode/checkbox/snippets.ts +35 -0
- package/lowcode/checkbox.group/__screenshots__/checkbox-group-1.png +0 -0
- package/lowcode/checkbox.group/meta.ts +150 -0
- package/lowcode/collapse/__screenshots__/collapse-1.png +0 -0
- package/lowcode/collapse/meta.ts +221 -0
- package/lowcode/collapse/snippets.ts +28 -0
- package/lowcode/collapse.pane/meta.ts +84 -0
- package/lowcode/config-provider/__screenshots__/config-provider-1.jpg +0 -0
- package/lowcode/config-provider/meta.ts +140 -0
- package/lowcode/config-provider/snippets.ts +10 -0
- package/lowcode/date-picker/__screenshots__/date-picker-1.png +0 -0
- package/lowcode/date-picker/__screenshots__/date-picker-2.png +0 -0
- package/lowcode/date-picker/__screenshots__/date-picker-3.png +0 -0
- package/lowcode/date-picker/__screenshots__/date-picker-4.png +0 -0
- package/lowcode/date-picker/__screenshots__/date-picker-5.png +0 -0
- package/lowcode/date-picker/meta.ts +281 -0
- package/lowcode/date-picker/snippets.ts +50 -0
- package/lowcode/date-picker.range-picker/__screenshots__/date-picker-range-picker-1.png +0 -0
- package/lowcode/date-picker.range-picker/__screenshots__/date-picker-range-picker-2.png +0 -0
- package/lowcode/date-picker.range-picker/__screenshots__/date-picker-range-picker-3.png +0 -0
- package/lowcode/date-picker.range-picker/__screenshots__/date-picker-range-picker-4.png +0 -0
- package/lowcode/date-picker.range-picker/meta.ts +356 -0
- package/lowcode/date-picker.range-picker/snippets.ts +44 -0
- package/lowcode/descriptions/__screenshots__/descriptions-1.jpg +0 -0
- package/lowcode/descriptions/meta.ts +230 -0
- package/lowcode/descriptions/snippets.ts +18 -0
- package/lowcode/descriptions.item/meta.ts +37 -0
- package/lowcode/directory-tree/meta.ts +2747 -0
- package/lowcode/divider/__screenshots__/divider-1.png +0 -0
- package/lowcode/divider/__screenshots__/divider-2.png +0 -0
- package/lowcode/divider/meta.ts +70 -0
- package/lowcode/divider/snippets.ts +27 -0
- package/lowcode/drawer/__screenshots__/drawer-1.png +0 -0
- package/lowcode/drawer/__screenshots__/drawer-2.png +0 -0
- package/lowcode/drawer/meta.ts +420 -0
- package/lowcode/drawer/snippets.ts +40 -0
- package/lowcode/dropdown/__screenshots__/dropdown-1.png +0 -0
- package/lowcode/dropdown/meta.ts +143 -0
- package/lowcode/dropdown/snippets.ts +73 -0
- package/lowcode/empty/__screenshots__/empty-1.png +0 -0
- package/lowcode/empty/meta.ts +40 -0
- package/lowcode/empty/snippets.ts +10 -0
- package/lowcode/form/__screenshots__/form-1.png +0 -0
- package/lowcode/form/meta.ts +380 -0
- package/lowcode/form/snippets.ts +511 -0
- package/lowcode/form.item/__screenshots__/form-item-1.jpg +0 -0
- package/lowcode/form.item/meta.ts +348 -0
- package/lowcode/form.item/snippets.ts +12 -0
- package/lowcode/form.list/meta.ts +42 -0
- package/lowcode/form.list/snippets.ts +11 -0
- package/lowcode/grid.col/meta.ts +116 -0
- package/lowcode/grid.col/snippets.ts +1 -0
- package/lowcode/grid.row/__screenshots__/1-1-1-1.png +0 -0
- package/lowcode/grid.row/__screenshots__/1-1-1.png +0 -0
- package/lowcode/grid.row/__screenshots__/1-1.png +0 -0
- package/lowcode/grid.row/__screenshots__/1-3.png +0 -0
- package/lowcode/grid.row/meta.ts +118 -0
- package/lowcode/grid.row/snippets.ts +108 -0
- package/lowcode/icon/__screenshots__/icon-1.jpg +0 -0
- package/lowcode/icon/meta.ts +74 -0
- package/lowcode/icon/snippets.ts +13 -0
- package/lowcode/image/__screenshots__/image-1.png +0 -0
- package/lowcode/image/meta.ts +53 -0
- package/lowcode/image/snippets.ts +14 -0
- package/lowcode/input/__screenshots__/input-1.png +0 -0
- package/lowcode/input/meta.ts +190 -0
- package/lowcode/input/snippets.ts +12 -0
- package/lowcode/input-number/__screenshots__/input-number-1.png +0 -0
- package/lowcode/input-number/meta.ts +213 -0
- package/lowcode/input-number/snippets.ts +12 -0
- package/lowcode/input.group/__screenshots__/input-group-1.jpg +0 -0
- package/lowcode/input.group/meta.ts +53 -0
- package/lowcode/input.group/snippets.ts +24 -0
- package/lowcode/input.password/__screenshots__/input-password-1.png +0 -0
- package/lowcode/input.password/meta.ts +192 -0
- package/lowcode/input.password/snippets.ts +12 -0
- package/lowcode/input.search/__screenshots__/input-search-1.png +0 -0
- package/lowcode/input.search/meta.ts +206 -0
- package/lowcode/input.search/snippets.ts +12 -0
- package/lowcode/input.text-area/__screenshots__/input-text-area-1.png +0 -0
- package/lowcode/input.text-area/meta.ts +210 -0
- package/lowcode/input.text-area/snippets.ts +16 -0
- package/lowcode/list/__screenshots__/list-1.png +0 -0
- package/lowcode/list/meta.ts +499 -0
- package/lowcode/list/snippets.ts +201 -0
- package/lowcode/list.item/meta.ts +58 -0
- package/lowcode/list.item.meta/meta.ts +49 -0
- package/lowcode/login/meta.ts +56 -0
- package/lowcode/mentions/__screenshots__/mentions-1.png +0 -0
- package/lowcode/mentions/meta.ts +159 -0
- package/lowcode/mentions/snippets.ts +10 -0
- package/lowcode/menu/__screenshots__/menu-1.jpg +0 -0
- package/lowcode/menu/meta.ts +248 -0
- package/lowcode/menu/snippets.ts +22 -0
- package/lowcode/menu/utils.ts +97 -0
- package/lowcode/menu.item/meta.ts +63 -0
- package/lowcode/menu.item/snippets.ts +1 -0
- package/lowcode/menu.item-group/__screenshots__/menu-item-group-1.png +0 -0
- package/lowcode/menu.item-group/meta.ts +110 -0
- package/lowcode/menu.item-group/snippets.ts +1 -0
- package/lowcode/menu.sub-menu/meta.ts +131 -0
- package/lowcode/menu.sub-menu/snippets.ts +1 -0
- package/lowcode/modal/__screenshots__/modal-1.png +0 -0
- package/lowcode/modal/__screenshots__/modal-2.png +0 -0
- package/lowcode/modal/meta.ts +270 -0
- package/lowcode/modal/snippets.ts +33 -0
- package/lowcode/page-header/__screenshots__/page-header-1.jpg +0 -0
- package/lowcode/page-header/meta.ts +157 -0
- package/lowcode/page-header/snippets.ts +13 -0
- package/lowcode/pagination/__screenshots__/pagination-1.jpg +0 -0
- package/lowcode/pagination/meta.ts +231 -0
- package/lowcode/pagination/snippets.ts +14 -0
- package/lowcode/popconfirm/__screenshots__/popconfirm-1.jpg +0 -0
- package/lowcode/popconfirm/meta.ts +121 -0
- package/lowcode/popconfirm/snippets.ts +21 -0
- package/lowcode/popover/__screenshots__/popover-1.jpg +0 -0
- package/lowcode/popover/meta.ts +332 -0
- package/lowcode/popover/snippets.ts +10 -0
- package/lowcode/progress/__screenshots__/progress-1.png +0 -0
- package/lowcode/progress/__screenshots__/progress-2.png +0 -0
- package/lowcode/progress/meta.ts +142 -0
- package/lowcode/progress/snippets.ts +24 -0
- package/lowcode/radio/__screenshots__/radio-1.png +0 -0
- package/lowcode/radio/meta.ts +69 -0
- package/lowcode/radio/snippets.ts +35 -0
- package/lowcode/radio.group/__screenshots__/radio-group-1.png +0 -0
- package/lowcode/radio.group/meta.ts +213 -0
- package/lowcode/rate/__screenshots__/rate-1.png +0 -0
- package/lowcode/rate/meta.ts +132 -0
- package/lowcode/rate/snippets.ts +12 -0
- package/lowcode/result/__screenshots__/result-1.png +0 -0
- package/lowcode/result/meta.ts +53 -0
- package/lowcode/result/snippets.ts +14 -0
- package/lowcode/select/__screenshots__/select-1.png +0 -0
- package/lowcode/select/meta.ts +427 -0
- package/lowcode/select/snippets.ts +28 -0
- package/lowcode/skeleton/__screenshots__/skeleton-1.png +0 -0
- package/lowcode/skeleton/meta.ts +63 -0
- package/lowcode/skeleton/snippets.ts +13 -0
- package/lowcode/slider/__screenshots__/slider-1.png +0 -0
- package/lowcode/slider/meta.ts +218 -0
- package/lowcode/slider/snippets.ts +12 -0
- package/lowcode/slot/meta.ts +61 -0
- package/lowcode/slot/view.tsx +58 -0
- package/lowcode/space/__screenshots__/space-1.png +0 -0
- package/lowcode/space/meta.ts +65 -0
- package/lowcode/space/snippets.ts +24 -0
- package/lowcode/spin/__screenshots__/spin-1.png +0 -0
- package/lowcode/spin/meta.ts +60 -0
- package/lowcode/spin/snippets.ts +13 -0
- package/lowcode/statistic/__screenshots__/statistic-1.png +0 -0
- package/lowcode/statistic/meta.ts +67 -0
- package/lowcode/statistic/snippets.ts +13 -0
- package/lowcode/steps/__screenshots__/steps-1.png +0 -0
- package/lowcode/steps/meta.ts +281 -0
- package/lowcode/steps/snippets.ts +36 -0
- package/lowcode/steps.step/meta.ts +54 -0
- package/lowcode/steps.step/snippets.ts +1 -0
- package/lowcode/switch/__screenshots__/switch-1.png +0 -0
- package/lowcode/switch/meta.ts +122 -0
- package/lowcode/switch/snippets.ts +12 -0
- package/lowcode/table/__screenshots__/table-1.png +0 -0
- package/lowcode/table/meta.ts +847 -0
- package/lowcode/table/snippets.ts +43 -0
- package/lowcode/tabs/__screenshots__/tabs-1.jpg +0 -0
- package/lowcode/tabs/__screenshots__/tabs-2.jpg +0 -0
- package/lowcode/tabs/__screenshots__/tabs-3.jpg +0 -0
- package/lowcode/tabs/meta.ts +415 -0
- package/lowcode/tabs/snippets.ts +86 -0
- package/lowcode/tabs.tab-pane/meta.ts +78 -0
- package/lowcode/tag/__screenshots__/tag-1.png +0 -0
- package/lowcode/tag/meta.ts +69 -0
- package/lowcode/tag/snippets.ts +13 -0
- package/lowcode/time-picker/__screenshots__/time-picker-1.png +0 -0
- package/lowcode/time-picker/meta.ts +224 -0
- package/lowcode/time-picker/snippets.ts +10 -0
- package/lowcode/timeline/__screenshots__/timeline-1.jpg +0 -0
- package/lowcode/timeline/meta.ts +189 -0
- package/lowcode/timeline/snippets.ts +21 -0
- package/lowcode/timeline.item/__screenshots__/timeline-1.jpg +0 -0
- package/lowcode/timeline.item/meta.ts +53 -0
- package/lowcode/timeline.item/snippets.ts +10 -0
- package/lowcode/tooltip/__screenshots__/tooltip-1.jpg +0 -0
- package/lowcode/tooltip/meta.ts +306 -0
- package/lowcode/tooltip/snippets.ts +12 -0
- package/lowcode/transfer/__screenshots__/transfer-1.png +0 -0
- package/lowcode/transfer/meta.ts +304 -0
- package/lowcode/transfer/snippets.ts +42 -0
- package/lowcode/tree/__screenshots__/tree-1.jpg +0 -0
- package/lowcode/tree/meta.ts +377 -0
- package/lowcode/tree/snippets.ts +30 -0
- package/lowcode/tree-select/__screenshots__/tree-select-1.png +0 -0
- package/lowcode/tree-select/meta.ts +314 -0
- package/lowcode/tree-select/snippets.ts +34 -0
- package/lowcode/typography.link/__screenshots__/typography-link-1.png +0 -0
- package/lowcode/typography.link/meta.ts +44 -0
- package/lowcode/typography.link/snippets.ts +14 -0
- package/lowcode/typography.paragraph/__screenshots__/typography-paragraph-1.png +0 -0
- package/lowcode/typography.paragraph/meta.ts +129 -0
- package/lowcode/typography.paragraph/snippets.ts +14 -0
- package/lowcode/typography.text/__screenshots__/typography-text-1.png +0 -0
- package/lowcode/typography.text/__screenshots__/typography-text-2.png +0 -0
- package/lowcode/typography.text/__screenshots__/typography-text-3.png +0 -0
- package/lowcode/typography.text/meta.ts +200 -0
- package/lowcode/typography.text/snippets.ts +34 -0
- package/lowcode/typography.title/__screenshots__/typography-title-1.png +0 -0
- package/lowcode/typography.title/__screenshots__/typography-title-2.png +0 -0
- package/lowcode/typography.title/__screenshots__/typography-title-3.png +0 -0
- package/lowcode/typography.title/__screenshots__/typography-title-4.png +0 -0
- package/lowcode/typography.title/meta.ts +130 -0
- package/lowcode/typography.title/snippets.ts +46 -0
- package/lowcode/upload/__screenshots__/upload-1.png +0 -0
- package/lowcode/upload/meta.ts +439 -0
- package/lowcode/upload/snippets.ts +16 -0
- package/package.json +37 -3
- package/.fatherrc.ts +0 -7
- package/CHANGELOG.md +0 -7
- package/tsconfig.json +0 -14
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
{
|
|
2
|
+
"packages": [
|
|
3
|
+
{
|
|
4
|
+
"package": "dayjs",
|
|
5
|
+
"version": "1.11.7",
|
|
6
|
+
"urls": "https://g.alicdn.com/code/lib/dayjs/1.11.7/dayjs.min.js",
|
|
7
|
+
"library": "dayjs"
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"package": "iconfont-icons",
|
|
11
|
+
"urls": "//at.alicdn.com/t/font_2369445_ukrtsovd92r.js"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"package": "@ant-design/icons",
|
|
15
|
+
"version": "4.7.0",
|
|
16
|
+
"urls": [
|
|
17
|
+
"//g.alicdn.com/code/npm/@ali/ant-design-icons-cdn/4.5.0/index.umd.min.js"
|
|
18
|
+
],
|
|
19
|
+
"library": "icons"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"package": "antd",
|
|
23
|
+
"version": "5.6.2",
|
|
24
|
+
"urls": [
|
|
25
|
+
"https://g.alicdn.com/code/lib/antd/5.6.2/antd.min.js"
|
|
26
|
+
],
|
|
27
|
+
"library": "antd"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"package": "@pisell/materials",
|
|
31
|
+
"version": "1.0.2",
|
|
32
|
+
"library": "BaseMaterials",
|
|
33
|
+
"urls": [
|
|
34
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.js",
|
|
35
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.css"
|
|
36
|
+
],
|
|
37
|
+
"editUrls": [
|
|
38
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/view.js",
|
|
39
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/view.css"
|
|
40
|
+
],
|
|
41
|
+
"advancedUrls": {
|
|
42
|
+
"default": [
|
|
43
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.js",
|
|
44
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.css"
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
"advancedEditUrls": {}
|
|
48
|
+
}
|
|
49
|
+
],
|
|
50
|
+
"components": [
|
|
51
|
+
{
|
|
52
|
+
"exportName": "PisellMaterialsMeta",
|
|
53
|
+
"npm": {
|
|
54
|
+
"package": "@pisell/materials",
|
|
55
|
+
"version": "1.0.2"
|
|
56
|
+
},
|
|
57
|
+
"url": "https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/meta.js",
|
|
58
|
+
"urls": {
|
|
59
|
+
"default": "https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/meta.js"
|
|
60
|
+
},
|
|
61
|
+
"advancedUrls": {
|
|
62
|
+
"default": [
|
|
63
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/meta.js"
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"sort": {
|
|
69
|
+
"groupList": [
|
|
70
|
+
"精选组件",
|
|
71
|
+
"原子组件"
|
|
72
|
+
],
|
|
73
|
+
"categoryList": [
|
|
74
|
+
"基础元素",
|
|
75
|
+
"布局容器类",
|
|
76
|
+
"表格类",
|
|
77
|
+
"表单详情类",
|
|
78
|
+
"帮助类",
|
|
79
|
+
"对话框类",
|
|
80
|
+
"业务类",
|
|
81
|
+
"通用",
|
|
82
|
+
"引导",
|
|
83
|
+
"信息输入",
|
|
84
|
+
"信息展示",
|
|
85
|
+
"信息反馈"
|
|
86
|
+
]
|
|
87
|
+
},
|
|
88
|
+
"groupList": [
|
|
89
|
+
"精选组件",
|
|
90
|
+
"原子组件"
|
|
91
|
+
],
|
|
92
|
+
"ignoreComponents": {}
|
|
93
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
{
|
|
2
|
+
"packages": [
|
|
3
|
+
{
|
|
4
|
+
"package": "dayjs",
|
|
5
|
+
"version": "1.11.7",
|
|
6
|
+
"urls": "https://g.alicdn.com/code/lib/dayjs/1.11.7/dayjs.min.js",
|
|
7
|
+
"library": "dayjs"
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"package": "iconfont-icons",
|
|
11
|
+
"urls": "//at.alicdn.com/t/font_2369445_ukrtsovd92r.js"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"package": "@ant-design/icons",
|
|
15
|
+
"version": "4.7.0",
|
|
16
|
+
"urls": [
|
|
17
|
+
"//g.alicdn.com/code/npm/@ali/ant-design-icons-cdn/4.5.0/index.umd.min.js"
|
|
18
|
+
],
|
|
19
|
+
"library": "icons"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"package": "antd",
|
|
23
|
+
"version": "5.6.2",
|
|
24
|
+
"urls": [
|
|
25
|
+
"https://g.alicdn.com/code/lib/antd/5.6.2/antd.min.js"
|
|
26
|
+
],
|
|
27
|
+
"library": "antd"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"package": "@pisell/materials",
|
|
31
|
+
"version": "1.0.2",
|
|
32
|
+
"library": "BaseMaterials",
|
|
33
|
+
"urls": [
|
|
34
|
+
"./render/default/view.js",
|
|
35
|
+
"./render/default/view.css"
|
|
36
|
+
],
|
|
37
|
+
"editUrls": [
|
|
38
|
+
"./view.js",
|
|
39
|
+
"./view.css"
|
|
40
|
+
],
|
|
41
|
+
"advancedUrls": {
|
|
42
|
+
"default": [
|
|
43
|
+
"./render/default/view.js",
|
|
44
|
+
"./render/default/view.css"
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
"advancedEditUrls": {}
|
|
48
|
+
}
|
|
49
|
+
],
|
|
50
|
+
"components": [
|
|
51
|
+
{
|
|
52
|
+
"exportName": "PisellMaterialsMeta",
|
|
53
|
+
"npm": {
|
|
54
|
+
"package": "@pisell/materials",
|
|
55
|
+
"version": "1.0.2"
|
|
56
|
+
},
|
|
57
|
+
"url": "./meta.js",
|
|
58
|
+
"urls": {
|
|
59
|
+
"default": "./meta.js"
|
|
60
|
+
},
|
|
61
|
+
"advancedUrls": {
|
|
62
|
+
"default": [
|
|
63
|
+
"./meta.js"
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"sort": {
|
|
69
|
+
"groupList": [
|
|
70
|
+
"精选组件",
|
|
71
|
+
"原子组件"
|
|
72
|
+
],
|
|
73
|
+
"categoryList": [
|
|
74
|
+
"基础元素",
|
|
75
|
+
"布局容器类",
|
|
76
|
+
"表格类",
|
|
77
|
+
"表单详情类",
|
|
78
|
+
"帮助类",
|
|
79
|
+
"对话框类",
|
|
80
|
+
"业务类",
|
|
81
|
+
"通用",
|
|
82
|
+
"引导",
|
|
83
|
+
"信息输入",
|
|
84
|
+
"信息展示",
|
|
85
|
+
"信息反馈"
|
|
86
|
+
]
|
|
87
|
+
},
|
|
88
|
+
"groupList": [
|
|
89
|
+
"精选组件",
|
|
90
|
+
"原子组件"
|
|
91
|
+
],
|
|
92
|
+
"ignoreComponents": {}
|
|
93
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
{
|
|
2
|
+
"packages": [
|
|
3
|
+
{
|
|
4
|
+
"package": "dayjs",
|
|
5
|
+
"version": "1.11.7",
|
|
6
|
+
"urls": "https://g.alicdn.com/code/lib/dayjs/1.11.7/dayjs.min.js",
|
|
7
|
+
"library": "dayjs"
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"package": "iconfont-icons",
|
|
11
|
+
"urls": "//at.alicdn.com/t/font_2369445_ukrtsovd92r.js"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"package": "@ant-design/icons",
|
|
15
|
+
"version": "4.7.0",
|
|
16
|
+
"urls": [
|
|
17
|
+
"//g.alicdn.com/code/npm/@ali/ant-design-icons-cdn/4.5.0/index.umd.min.js"
|
|
18
|
+
],
|
|
19
|
+
"library": "icons"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"package": "antd",
|
|
23
|
+
"version": "5.6.2",
|
|
24
|
+
"urls": [
|
|
25
|
+
"https://g.alicdn.com/code/lib/antd/5.6.2/antd.min.js"
|
|
26
|
+
],
|
|
27
|
+
"library": "antd"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"package": "@pisell/materials",
|
|
31
|
+
"version": "1.0.2",
|
|
32
|
+
"library": "BaseMaterials",
|
|
33
|
+
"urls": [
|
|
34
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.js",
|
|
35
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.css"
|
|
36
|
+
],
|
|
37
|
+
"editUrls": [
|
|
38
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/view.js",
|
|
39
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/view.css"
|
|
40
|
+
],
|
|
41
|
+
"advancedUrls": {
|
|
42
|
+
"default": [
|
|
43
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.js",
|
|
44
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/render/default/view.css"
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
"advancedEditUrls": {}
|
|
48
|
+
}
|
|
49
|
+
],
|
|
50
|
+
"components": [
|
|
51
|
+
{
|
|
52
|
+
"exportName": "PisellMaterialsMeta",
|
|
53
|
+
"npm": {
|
|
54
|
+
"package": "@pisell/materials",
|
|
55
|
+
"version": "1.0.2"
|
|
56
|
+
},
|
|
57
|
+
"url": "https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/meta.js",
|
|
58
|
+
"urls": {
|
|
59
|
+
"default": "https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/meta.js"
|
|
60
|
+
},
|
|
61
|
+
"advancedUrls": {
|
|
62
|
+
"default": [
|
|
63
|
+
"https://unpkg.com/@pisell/materials@1.0.2/build/lowcode/meta.js"
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"sort": {
|
|
69
|
+
"groupList": [
|
|
70
|
+
"精选组件",
|
|
71
|
+
"原子组件"
|
|
72
|
+
],
|
|
73
|
+
"categoryList": [
|
|
74
|
+
"基础元素",
|
|
75
|
+
"布局容器类",
|
|
76
|
+
"表格类",
|
|
77
|
+
"表单详情类",
|
|
78
|
+
"帮助类",
|
|
79
|
+
"对话框类",
|
|
80
|
+
"业务类",
|
|
81
|
+
"通用",
|
|
82
|
+
"引导",
|
|
83
|
+
"信息输入",
|
|
84
|
+
"信息展示",
|
|
85
|
+
"信息反馈"
|
|
86
|
+
]
|
|
87
|
+
},
|
|
88
|
+
"groupList": [
|
|
89
|
+
"精选组件",
|
|
90
|
+
"原子组件"
|
|
91
|
+
],
|
|
92
|
+
"ignoreComponents": {}
|
|
93
|
+
}
|
|
@@ -0,0 +1,303 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
|
|
7
|
+
<title>DEMO 预览</title>
|
|
8
|
+
<style>
|
|
9
|
+
body {
|
|
10
|
+
font-family: PingFangSC-Regular, Roboto, Helvetica Neue, Helvetica, Tahoma, Arial,
|
|
11
|
+
PingFang SC-Light, Microsoft YaHei;
|
|
12
|
+
font-size: 12px;
|
|
13
|
+
|
|
14
|
+
* {
|
|
15
|
+
box-sizing: border-box;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
body,
|
|
20
|
+
#lce-container {
|
|
21
|
+
position: fixed;
|
|
22
|
+
left: 0;
|
|
23
|
+
right: 0;
|
|
24
|
+
bottom: 0;
|
|
25
|
+
top: 0;
|
|
26
|
+
box-sizing: border-box;
|
|
27
|
+
padding: 0;
|
|
28
|
+
margin: 0;
|
|
29
|
+
overflow: hidden;
|
|
30
|
+
text-rendering: optimizeLegibility;
|
|
31
|
+
-webkit-user-select: none;
|
|
32
|
+
-webkit-user-drag: none;
|
|
33
|
+
-webkit-text-size-adjust: none;
|
|
34
|
+
-webkit-touch-callout: none;
|
|
35
|
+
-webkit-font-smoothing: antialiased;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
html {
|
|
39
|
+
min-width: 1024px;
|
|
40
|
+
}
|
|
41
|
+
</style>
|
|
42
|
+
</head>
|
|
43
|
+
|
|
44
|
+
<body>
|
|
45
|
+
<link rel="stylesheet" href="https://uipaas-assets.com/prod/npm/@alilc/lowcode-engine/1.1.7-beta.11/dist/css/engine-core.css" />
|
|
46
|
+
<link rel="stylesheet" href="https://uipaas-assets.com/prod/npm/@alilc/lowcode-engine-ext/1.0.6-beta.25/dist/css/engine-ext.css" />
|
|
47
|
+
<link rel="stylesheet" href="https://alifd.alicdn.com/npm/@alilc/lowcode-preset-plugin@0.1.2/dist/lowcode-preset-plugin.css" />
|
|
48
|
+
<link href="https://alifd.alicdn.com/npm/@alifd/theme-lowcode-light@0.2.1/variables.css" rel="stylesheet" />
|
|
49
|
+
<link href="https://alifd.alicdn.com/npm/@alifd/theme-lowcode-light@0.2.1/dist/next.var.min.css" rel="stylesheet" />
|
|
50
|
+
<div id="lce-container"></div>
|
|
51
|
+
<script src="https://g.alicdn.com/code/lib/rax/1.1.0/rax.umd.min.js"></script>
|
|
52
|
+
<script src="https://g.alicdn.com/code/lib/react/16.9.0/umd/react.development.js"></script>
|
|
53
|
+
<script src="https://g.alicdn.com/code/lib/react-dom/16.9.0/umd/react-dom.development.js"></script>
|
|
54
|
+
<script src="https://g.alicdn.com/code/lib/prop-types/15.7.2/prop-types.js"></script>
|
|
55
|
+
<script>
|
|
56
|
+
React.PropTypes = PropTypes;
|
|
57
|
+
</script>
|
|
58
|
+
<script src="https://g.alicdn.com/platform/c/??react15-polyfill/0.0.1/dist/index.js,lodash/4.6.1/lodash.min.js,immutable/3.7.6/dist/immutable.min.js,natty-storage/2.0.2/dist/natty-storage.min.js,natty-fetch/2.6.0/dist/natty-fetch.pc.min.js,tinymce/4.2.5/tinymce-full.js"></script>
|
|
59
|
+
<script src="https://g.alicdn.com/mylib/moment/2.24.0/min/moment.min.js"></script>
|
|
60
|
+
<script src="https://g.alicdn.com/code/lib/dayjs/1.11.7/dayjs.min.js"></script>
|
|
61
|
+
<script src="https://g.alicdn.com/code/lib/alifd__next/1.23.20/next-with-locales.min.js"></script>
|
|
62
|
+
<script crossorigin="anonymous" src="https://uipaas-assets.com/prod/npm/@alilc/lowcode-engine/1.1.7-beta.11/dist/js/engine-core.js"></script>
|
|
63
|
+
<script crossorigin="anonymous" src="https://uipaas-assets.com/prod/npm/@alilc/lowcode-engine-ext/1.0.6-beta.25/dist/js/engine-ext.js"></script>
|
|
64
|
+
<script>
|
|
65
|
+
if (!window.AliLowCodeEngine.common) {
|
|
66
|
+
window.AliLowCodeEngine.common = {
|
|
67
|
+
designerCabin: window.AliLowCodeEngine.designerCabin,
|
|
68
|
+
editorCabin: window.AliLowCodeEngine.editorCabin,
|
|
69
|
+
skeletonCabin: window.AliLowCodeEngine.skeletonCabin,
|
|
70
|
+
utils: window.AliLowCodeEngine.utils,
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
</script>
|
|
74
|
+
<script src="https://alifd.alicdn.com/npm/@alilc/lowcode-preset-plugin@0.1.2/dist/lowcode-preset-plugin.js"></script>
|
|
75
|
+
<script type="text/javascript" charset="utf-8" src="./index.js"></script>
|
|
76
|
+
<script>
|
|
77
|
+
(function (factory) {
|
|
78
|
+
if (typeof define === 'function' && define.amd) {
|
|
79
|
+
define([], factory);
|
|
80
|
+
} else if (typeof module === 'object' && module.exports) {
|
|
81
|
+
module.exports = factory();
|
|
82
|
+
} else {
|
|
83
|
+
window.idleCallbackShim = factory();
|
|
84
|
+
}
|
|
85
|
+
})(function () {
|
|
86
|
+
'use strict';
|
|
87
|
+
var scheduleStart, throttleDelay, lazytimer, lazyraf;
|
|
88
|
+
var root =
|
|
89
|
+
typeof window != 'undefined' ? window : typeof global != undefined ? global : this || {};
|
|
90
|
+
var requestAnimationFrame =
|
|
91
|
+
(root.cancelRequestAnimationFrame && root.requestAnimationFrame) || setTimeout;
|
|
92
|
+
var cancelRequestAnimationFrame = root.cancelRequestAnimationFrame || clearTimeout;
|
|
93
|
+
var tasks = [];
|
|
94
|
+
var runAttempts = 0;
|
|
95
|
+
var isRunning = false;
|
|
96
|
+
var remainingTime = 7;
|
|
97
|
+
var minThrottle = 35;
|
|
98
|
+
var throttle = 125;
|
|
99
|
+
var index = 0;
|
|
100
|
+
var taskStart = 0;
|
|
101
|
+
var tasklength = 0;
|
|
102
|
+
var IdleDeadline = {
|
|
103
|
+
get didTimeout() {
|
|
104
|
+
return false;
|
|
105
|
+
},
|
|
106
|
+
timeRemaining: function () {
|
|
107
|
+
var timeRemaining = remainingTime - (Date.now() - taskStart);
|
|
108
|
+
return Math.max(0, timeRemaining);
|
|
109
|
+
},
|
|
110
|
+
};
|
|
111
|
+
var setInactive = debounce(function () {
|
|
112
|
+
remainingTime = 22;
|
|
113
|
+
throttle = 66;
|
|
114
|
+
minThrottle = 0;
|
|
115
|
+
});
|
|
116
|
+
|
|
117
|
+
function debounce(fn) {
|
|
118
|
+
var id, timestamp;
|
|
119
|
+
var wait = 99;
|
|
120
|
+
var check = function () {
|
|
121
|
+
var last = Date.now() - timestamp;
|
|
122
|
+
|
|
123
|
+
if (last < wait) {
|
|
124
|
+
id = setTimeout(check, wait - last);
|
|
125
|
+
} else {
|
|
126
|
+
id = null;
|
|
127
|
+
fn();
|
|
128
|
+
}
|
|
129
|
+
};
|
|
130
|
+
return function () {
|
|
131
|
+
timestamp = Date.now();
|
|
132
|
+
if (!id) {
|
|
133
|
+
id = setTimeout(check, wait);
|
|
134
|
+
}
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
function abortRunning() {
|
|
139
|
+
if (isRunning) {
|
|
140
|
+
if (lazyraf) {
|
|
141
|
+
cancelRequestAnimationFrame(lazyraf);
|
|
142
|
+
}
|
|
143
|
+
if (lazytimer) {
|
|
144
|
+
clearTimeout(lazytimer);
|
|
145
|
+
}
|
|
146
|
+
isRunning = false;
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
function onInputorMutation() {
|
|
151
|
+
if (throttle != 125) {
|
|
152
|
+
remainingTime = 7;
|
|
153
|
+
throttle = 125;
|
|
154
|
+
minThrottle = 35;
|
|
155
|
+
|
|
156
|
+
if (isRunning) {
|
|
157
|
+
abortRunning();
|
|
158
|
+
scheduleLazy();
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
setInactive();
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
function scheduleAfterRaf() {
|
|
165
|
+
lazyraf = null;
|
|
166
|
+
lazytimer = setTimeout(runTasks, 0);
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
function scheduleRaf() {
|
|
170
|
+
lazytimer = null;
|
|
171
|
+
requestAnimationFrame(scheduleAfterRaf);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
function scheduleLazy() {
|
|
175
|
+
if (isRunning) {
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
throttleDelay = throttle - (Date.now() - taskStart);
|
|
179
|
+
|
|
180
|
+
scheduleStart = Date.now();
|
|
181
|
+
|
|
182
|
+
isRunning = true;
|
|
183
|
+
|
|
184
|
+
if (minThrottle && throttleDelay < minThrottle) {
|
|
185
|
+
throttleDelay = minThrottle;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
if (throttleDelay > 9) {
|
|
189
|
+
lazytimer = setTimeout(scheduleRaf, throttleDelay);
|
|
190
|
+
} else {
|
|
191
|
+
throttleDelay = 0;
|
|
192
|
+
scheduleRaf();
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
function runTasks() {
|
|
197
|
+
var task, i, len;
|
|
198
|
+
var timeThreshold = remainingTime > 9 ? 9 : 1;
|
|
199
|
+
taskStart = Date.now();
|
|
200
|
+
isRunning = false;
|
|
201
|
+
|
|
202
|
+
lazytimer = null;
|
|
203
|
+
|
|
204
|
+
if (runAttempts > 2 || taskStart - throttleDelay - 50 < scheduleStart) {
|
|
205
|
+
for (
|
|
206
|
+
i = 0, len = tasks.length;
|
|
207
|
+
i < len && IdleDeadline.timeRemaining() > timeThreshold;
|
|
208
|
+
i++
|
|
209
|
+
) {
|
|
210
|
+
task = tasks.shift();
|
|
211
|
+
tasklength++;
|
|
212
|
+
if (task) {
|
|
213
|
+
task(IdleDeadline);
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
if (tasks.length) {
|
|
219
|
+
scheduleLazy();
|
|
220
|
+
} else {
|
|
221
|
+
runAttempts = 0;
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
function requestIdleCallbackShim(task) {
|
|
226
|
+
index++;
|
|
227
|
+
tasks.push(task);
|
|
228
|
+
scheduleLazy();
|
|
229
|
+
return index;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
function cancelIdleCallbackShim(id) {
|
|
233
|
+
var index = id - 1 - tasklength;
|
|
234
|
+
if (tasks[index]) {
|
|
235
|
+
tasks[index] = null;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
if (!root.requestIdleCallback || !root.cancelIdleCallback) {
|
|
240
|
+
root.requestIdleCallback = requestIdleCallbackShim;
|
|
241
|
+
root.cancelIdleCallback = cancelIdleCallbackShim;
|
|
242
|
+
|
|
243
|
+
if (root.document && document.addEventListener) {
|
|
244
|
+
root.addEventListener('scroll', onInputorMutation, true);
|
|
245
|
+
root.addEventListener('resize', onInputorMutation);
|
|
246
|
+
|
|
247
|
+
document.addEventListener('focus', onInputorMutation, true);
|
|
248
|
+
document.addEventListener('mouseover', onInputorMutation, true);
|
|
249
|
+
['click', 'keypress', 'touchstart', 'mousedown'].forEach(function (name) {
|
|
250
|
+
document.addEventListener(name, onInputorMutation, { capture: true, passive: true });
|
|
251
|
+
});
|
|
252
|
+
|
|
253
|
+
if (root.MutationObserver) {
|
|
254
|
+
new MutationObserver(onInputorMutation).observe(document.documentElement, {
|
|
255
|
+
childList: true,
|
|
256
|
+
subtree: true,
|
|
257
|
+
attributes: true,
|
|
258
|
+
});
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
} else {
|
|
262
|
+
try {
|
|
263
|
+
root.requestIdleCallback(function () {}, { timeout: 0 });
|
|
264
|
+
} catch (e) {
|
|
265
|
+
(function (rIC) {
|
|
266
|
+
var timeRemainingProto, timeRemaining;
|
|
267
|
+
root.requestIdleCallback = function (fn, timeout) {
|
|
268
|
+
if (timeout && typeof timeout.timeout == 'number') {
|
|
269
|
+
return rIC(fn, timeout.timeout);
|
|
270
|
+
}
|
|
271
|
+
return rIC(fn);
|
|
272
|
+
};
|
|
273
|
+
if (
|
|
274
|
+
root.IdleCallbackDeadline &&
|
|
275
|
+
(timeRemainingProto = IdleCallbackDeadline.prototype)
|
|
276
|
+
) {
|
|
277
|
+
timeRemaining = Object.getOwnPropertyDescriptor(
|
|
278
|
+
timeRemainingProto,
|
|
279
|
+
'timeRemaining',
|
|
280
|
+
);
|
|
281
|
+
if (!timeRemaining || !timeRemaining.configurable || !timeRemaining.get) {
|
|
282
|
+
return;
|
|
283
|
+
}
|
|
284
|
+
Object.defineProperty(timeRemainingProto, 'timeRemaining', {
|
|
285
|
+
value: function () {
|
|
286
|
+
return timeRemaining.get.call(this);
|
|
287
|
+
},
|
|
288
|
+
enumerable: true,
|
|
289
|
+
configurable: true,
|
|
290
|
+
});
|
|
291
|
+
}
|
|
292
|
+
})(root.requestIdleCallback);
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
return {
|
|
297
|
+
request: requestIdleCallbackShim,
|
|
298
|
+
cancel: cancelIdleCallbackShim,
|
|
299
|
+
};
|
|
300
|
+
});
|
|
301
|
+
</script>
|
|
302
|
+
</body>
|
|
303
|
+
</html>
|