cedro 0.1.12 → 0.1.13
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/assets/_virtual/_commonjsHelpers.js +1 -0
- package/lib/assets/_virtual/index.js +1 -0
- package/lib/assets/_virtual/modulepreload-polyfill.js +1 -0
- package/lib/assets/_virtual/named-references.js +1 -0
- package/lib/assets/_virtual/numeric-unicode-map.js +1 -0
- package/lib/assets/_virtual/surrogate-pairs.js +1 -0
- package/lib/assets/core/application.builder.js +1 -0
- package/lib/assets/core/application.core.js +1 -0
- package/lib/assets/core/jsxsupport.js +1 -0
- package/lib/assets/core/screeen.core.js +1 -0
- package/lib/assets/core/seo.js +1 -0
- package/lib/assets/core/themes.core.js +1 -0
- package/lib/assets/core/uid.js +1 -0
- package/lib/assets/index.js +5 -0
- package/lib/assets/material-icons-outlined.woff +0 -0
- package/lib/assets/material-icons-outlined.woff2 +0 -0
- package/lib/assets/material-icons-round.woff +0 -0
- package/lib/assets/material-icons-round.woff2 +0 -0
- package/lib/assets/material-icons-sharp.woff +0 -0
- package/lib/assets/material-icons-sharp.woff2 +0 -0
- package/lib/assets/material-icons-two-tone.woff +0 -0
- package/lib/assets/material-icons-two-tone.woff2 +0 -0
- package/lib/assets/material-icons.woff +0 -0
- package/lib/assets/material-icons.woff2 +0 -0
- package/lib/assets/node_modules/@fontsource/roboto/100.css +1 -0
- package/lib/assets/node_modules/@fontsource/roboto/300.css +1 -0
- package/lib/assets/node_modules/@fontsource/roboto/400.css +1 -0
- package/lib/assets/node_modules/@fontsource/roboto/500.css +1 -0
- package/lib/assets/node_modules/@fontsource/roboto/700.css +1 -0
- package/lib/assets/node_modules/@fontsource/roboto/900.css +1 -0
- package/lib/assets/node_modules/html-entities/lib/index.js +1 -0
- package/lib/assets/node_modules/html-entities/lib/named-references.js +2 -0
- package/lib/assets/node_modules/html-entities/lib/numeric-unicode-map.js +1 -0
- package/lib/assets/node_modules/html-entities/lib/surrogate-pairs.js +1 -0
- package/lib/assets/node_modules/material-icons/iconfont/material-icons.css +1 -0
- package/lib/assets/node_modules/navigo/lib/es/Q.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/constants.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/index.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/lifecycles.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/callHandler.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForAfterHook.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForAlreadyHook.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForBeforeHook.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForDeprecationMethods.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForForceOp.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForLeaveHook.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/checkForNotFoundHandler.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/errorOut.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/flushCurrent.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/matchPathToRegisteredRoutes.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/processMatches.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/setLocationPath.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/updateBrowserURL.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/updateState.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/middlewares/waitingList.js +1 -0
- package/lib/assets/node_modules/navigo/lib/es/utils.js +1 -0
- package/lib/assets/roboto-cyrillic-100-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-100-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-300-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-300-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-400-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-400-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-500-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-500-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-700-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-700-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-900-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-900-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-ext-100-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-ext-100-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-ext-300-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-ext-300-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-ext-400-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-ext-400-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-ext-500-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-ext-500-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-ext-700-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-ext-700-normal.woff2 +0 -0
- package/lib/assets/roboto-cyrillic-ext-900-normal.woff +0 -0
- package/lib/assets/roboto-cyrillic-ext-900-normal.woff2 +0 -0
- package/lib/assets/roboto-greek-100-normal.woff +0 -0
- package/lib/assets/roboto-greek-100-normal.woff2 +0 -0
- package/lib/assets/roboto-greek-300-normal.woff +0 -0
- package/lib/assets/roboto-greek-300-normal.woff2 +0 -0
- package/lib/assets/roboto-greek-400-normal.woff +0 -0
- package/lib/assets/roboto-greek-400-normal.woff2 +0 -0
- package/lib/assets/roboto-greek-500-normal.woff +0 -0
- package/lib/assets/roboto-greek-500-normal.woff2 +0 -0
- package/lib/assets/roboto-greek-700-normal.woff +0 -0
- package/lib/assets/roboto-greek-700-normal.woff2 +0 -0
- package/lib/assets/roboto-greek-900-normal.woff +0 -0
- package/lib/assets/roboto-greek-900-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-100-normal.woff +0 -0
- package/lib/assets/roboto-latin-100-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-300-normal.woff +0 -0
- package/lib/assets/roboto-latin-300-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-400-normal.woff +0 -0
- package/lib/assets/roboto-latin-400-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-500-normal.woff +0 -0
- package/lib/assets/roboto-latin-500-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-700-normal.woff +0 -0
- package/lib/assets/roboto-latin-700-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-900-normal.woff +0 -0
- package/lib/assets/roboto-latin-900-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-ext-100-normal.woff +0 -0
- package/lib/assets/roboto-latin-ext-100-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-ext-300-normal.woff +0 -0
- package/lib/assets/roboto-latin-ext-300-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-ext-400-normal.woff +0 -0
- package/lib/assets/roboto-latin-ext-400-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-ext-500-normal.woff +0 -0
- package/lib/assets/roboto-latin-ext-500-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-ext-700-normal.woff +0 -0
- package/lib/assets/roboto-latin-ext-700-normal.woff2 +0 -0
- package/lib/assets/roboto-latin-ext-900-normal.woff +0 -0
- package/lib/assets/roboto-latin-ext-900-normal.woff2 +0 -0
- package/lib/assets/roboto-vietnamese-100-normal.woff +0 -0
- package/lib/assets/roboto-vietnamese-100-normal.woff2 +0 -0
- package/lib/assets/roboto-vietnamese-300-normal.woff +0 -0
- package/lib/assets/roboto-vietnamese-300-normal.woff2 +0 -0
- package/lib/assets/roboto-vietnamese-400-normal.woff +0 -0
- package/lib/assets/roboto-vietnamese-400-normal.woff2 +0 -0
- package/lib/assets/roboto-vietnamese-500-normal.woff +0 -0
- package/lib/assets/roboto-vietnamese-500-normal.woff2 +0 -0
- package/lib/assets/roboto-vietnamese-700-normal.woff +0 -0
- package/lib/assets/roboto-vietnamese-700-normal.woff2 +0 -0
- package/lib/assets/roboto-vietnamese-900-normal.woff +0 -0
- package/lib/assets/roboto-vietnamese-900-normal.woff2 +0 -0
- package/lib/assets/types/select.item.type.js +1 -0
- package/lib/assets/ui/Icon.ui.js +1 -0
- package/lib/assets/ui/IconButton.ui.js +1 -0
- package/lib/assets/ui/Textbox.ui.js +1 -0
- package/lib/assets/ui/accordion.ui.js +1 -0
- package/lib/assets/ui/button.ui.js +1 -0
- package/lib/assets/ui/buttonColor.ui.js +1 -0
- package/lib/assets/ui/buttonmenu.ui.js +1 -0
- package/lib/assets/ui/buttonstack.ui.js +1 -0
- package/lib/assets/ui/checkbox.ui.js +1 -0
- package/lib/assets/ui/container.ui.js +1 -0
- package/lib/assets/ui/datagrid.ui.js +1 -0
- package/lib/assets/ui/dialog.js +1 -0
- package/lib/assets/ui/draggable.ui.js +1 -0
- package/lib/assets/ui/hpanel.ui.js +1 -0
- package/lib/assets/ui/iconButtonMenu.ui.js +1 -0
- package/lib/assets/ui/image.ui.js +1 -0
- package/lib/assets/ui/label.ui.js +1 -0
- package/lib/assets/ui/loading.ui.js +1 -0
- package/lib/assets/ui/menu.ui.js +1 -0
- package/lib/assets/ui/progressbar.ui.js +1 -0
- package/lib/assets/ui/radiobutton.ui.js +1 -0
- package/lib/assets/ui/scroll.ui.js +1 -0
- package/lib/assets/ui/select.ui.js +1 -0
- package/lib/assets/ui/styles/accordion.css +1 -0
- package/lib/assets/ui/styles/button.css +1 -0
- package/lib/assets/ui/styles/buttoncolor.css +1 -0
- package/lib/assets/ui/styles/container.css +1 -0
- package/lib/assets/ui/styles/datagrid.css +1 -0
- package/lib/assets/ui/styles/dialog.css +1 -0
- package/lib/assets/ui/styles/draggable.css +1 -0
- package/lib/assets/ui/styles/hpanel.css +1 -0
- package/lib/assets/ui/styles/icon.css +1 -0
- package/lib/assets/ui/styles/image.css +1 -0
- package/lib/assets/ui/styles/label.css +1 -0
- package/lib/assets/ui/styles/loading.css +1 -0
- package/lib/assets/ui/styles/main.css +1 -0
- package/lib/assets/ui/styles/menu.css +1 -0
- package/lib/assets/ui/styles/progressbar.css +1 -0
- package/lib/assets/ui/styles/scroll.css +1 -0
- package/lib/assets/ui/styles/select.css +1 -0
- package/lib/assets/ui/styles/stackbutton.css +1 -0
- package/lib/assets/ui/styles/tabs.css +1 -0
- package/lib/assets/ui/styles/textarea.css +1 -0
- package/lib/assets/ui/styles/textbox.css +1 -0
- package/lib/assets/ui/styles/toolbar.css +1 -0
- package/lib/assets/ui/styles/valuebar.css +1 -0
- package/lib/assets/ui/styles/vpanel.css +1 -0
- package/lib/assets/ui/styles/vstackbutton.css +1 -0
- package/lib/assets/ui/switch.ui.js +1 -0
- package/lib/assets/ui/tabs.ui.js +1 -0
- package/lib/assets/ui/textarea.ui.js +1 -0
- package/lib/assets/ui/toggle.ui.js +1 -0
- package/lib/assets/ui/toolbar.ui.js +1 -0
- package/lib/assets/ui/valuebar.ui.js +1 -0
- package/lib/assets/ui/vpanel.ui.js +1 -0
- package/lib/assets/ui/widget.builder.js +1 -0
- package/lib/assets/ui/widget.collection.js +1 -0
- package/lib/assets/ui/widget.ui.js +1 -0
- package/lib/cedro-logo.png +0 -0
- package/lib/cedro-logo.svg +97 -0
- package/lib/fangio.jpg +0 -0
- package/lib/material-icons-list.json/357/200/272Zone.Identifier +3 -0
- package/package.json +10 -4
- package/rollup.config.js +31 -0
- package/tsconfig.json +3 -0
- package/tsconfig.publish.json +3 -0
- package/vite.publish.config.ts +41 -0
- package/lib/core/application.builder.d.ts +0 -2
- package/lib/core/application.builder.jsx +0 -103
- package/lib/core/application.builder.jsx.map +0 -1
- package/lib/core/application.core.d.ts +0 -96
- package/lib/core/application.core.jsx +0 -290
- package/lib/core/application.core.jsx.map +0 -1
- package/lib/core/index.d.ts +0 -3
- package/lib/core/index.js +0 -4
- package/lib/core/index.js.map +0 -1
- package/lib/core/jsxsupport.d.ts +0 -13
- package/lib/core/jsxsupport.js +0 -82
- package/lib/core/jsxsupport.js.map +0 -1
- package/lib/core/screeen.core.d.ts +0 -41
- package/lib/core/screeen.core.js +0 -76
- package/lib/core/screeen.core.js.map +0 -1
- package/lib/core/seo.d.ts +0 -33
- package/lib/core/seo.js +0 -66
- package/lib/core/seo.js.map +0 -1
- package/lib/core/themes.core.d.ts +0 -22
- package/lib/core/themes.core.js +0 -317
- package/lib/core/themes.core.js.map +0 -1
- package/lib/core/uid.d.ts +0 -1
- package/lib/core/uid.js +0 -4
- package/lib/core/uid.js.map +0 -1
- package/lib/index.d.ts +0 -5
- package/lib/index.js +0 -8
- package/lib/index.js.map +0 -1
- package/lib/interfaces/application.interface.d.ts +0 -39
- package/lib/interfaces/application.interface.js +0 -6
- package/lib/interfaces/application.interface.js.map +0 -1
- package/lib/interfaces/screen.interface.d.ts +0 -12
- package/lib/interfaces/screen.interface.js +0 -2
- package/lib/interfaces/screen.interface.js.map +0 -1
- package/lib/interfaces/themes.interface.d.ts +0 -15
- package/lib/interfaces/themes.interface.js +0 -2
- package/lib/interfaces/themes.interface.js.map +0 -1
- package/lib/interfaces/widget.interface.d.ts +0 -85
- package/lib/interfaces/widget.interface.js +0 -2
- package/lib/interfaces/widget.interface.js.map +0 -1
- package/lib/types/orientation.type.d.ts +0 -1
- package/lib/types/orientation.type.js +0 -2
- package/lib/types/orientation.type.js.map +0 -1
- package/lib/types/select.item.type.d.ts +0 -6
- package/lib/types/select.item.type.js +0 -26
- package/lib/types/select.item.type.js.map +0 -1
- package/lib/types/vector2d.type.d.ts +0 -4
- package/lib/types/vector2d.type.js +0 -2
- package/lib/types/vector2d.type.js.map +0 -1
- package/lib/ui/Icon.ui.d.ts +0 -31
- package/lib/ui/Icon.ui.jsx +0 -121
- package/lib/ui/Icon.ui.jsx.map +0 -1
- package/lib/ui/IconButton.ui.d.ts +0 -32
- package/lib/ui/IconButton.ui.jsx +0 -184
- package/lib/ui/IconButton.ui.jsx.map +0 -1
- package/lib/ui/Textbox.ui.d.ts +0 -32
- package/lib/ui/Textbox.ui.jsx +0 -152
- package/lib/ui/Textbox.ui.jsx.map +0 -1
- package/lib/ui/accordion.ui.d.ts +0 -27
- package/lib/ui/accordion.ui.jsx +0 -108
- package/lib/ui/accordion.ui.jsx.map +0 -1
- package/lib/ui/button.ui.d.ts +0 -44
- package/lib/ui/button.ui.jsx +0 -180
- package/lib/ui/button.ui.jsx.map +0 -1
- package/lib/ui/buttonColor.ui.d.ts +0 -14
- package/lib/ui/buttonColor.ui.jsx +0 -58
- package/lib/ui/buttonColor.ui.jsx.map +0 -1
- package/lib/ui/buttonmenu.ui.d.ts +0 -23
- package/lib/ui/buttonmenu.ui.jsx +0 -104
- package/lib/ui/buttonmenu.ui.jsx.map +0 -1
- package/lib/ui/buttonstack.ui.d.ts +0 -26
- package/lib/ui/buttonstack.ui.jsx +0 -138
- package/lib/ui/buttonstack.ui.jsx.map +0 -1
- package/lib/ui/checkbox.ui.d.ts +0 -12
- package/lib/ui/checkbox.ui.jsx +0 -29
- package/lib/ui/checkbox.ui.jsx.map +0 -1
- package/lib/ui/colors.ui.d.ts +0 -1
- package/lib/ui/colors.ui.js +0 -2
- package/lib/ui/colors.ui.js.map +0 -1
- package/lib/ui/container.ui.d.ts +0 -33
- package/lib/ui/container.ui.jsx +0 -96
- package/lib/ui/container.ui.jsx.map +0 -1
- package/lib/ui/datagrid.ui.d.ts +0 -119
- package/lib/ui/datagrid.ui.jsx +0 -445
- package/lib/ui/datagrid.ui.jsx.map +0 -1
- package/lib/ui/dialog.d.ts +0 -102
- package/lib/ui/dialog.jsx +0 -480
- package/lib/ui/dialog.jsx.map +0 -1
- package/lib/ui/draggable.ui.d.ts +0 -27
- package/lib/ui/draggable.ui.js +0 -183
- package/lib/ui/draggable.ui.js.map +0 -1
- package/lib/ui/hpanel.ui.d.ts +0 -26
- package/lib/ui/hpanel.ui.jsx +0 -183
- package/lib/ui/hpanel.ui.jsx.map +0 -1
- package/lib/ui/iconButtonMenu.ui.d.ts +0 -27
- package/lib/ui/iconButtonMenu.ui.jsx +0 -135
- package/lib/ui/iconButtonMenu.ui.jsx.map +0 -1
- package/lib/ui/image.ui.d.ts +0 -25
- package/lib/ui/image.ui.jsx +0 -88
- package/lib/ui/image.ui.jsx.map +0 -1
- package/lib/ui/index.d.ts +0 -30
- package/lib/ui/index.js +0 -30
- package/lib/ui/index.js.map +0 -1
- package/lib/ui/label.ui.d.ts +0 -37
- package/lib/ui/label.ui.jsx +0 -155
- package/lib/ui/label.ui.jsx.map +0 -1
- package/lib/ui/loading.ui.d.ts +0 -5
- package/lib/ui/loading.ui.js +0 -10
- package/lib/ui/loading.ui.js.map +0 -1
- package/lib/ui/menu.ui.d.ts +0 -19
- package/lib/ui/menu.ui.js +0 -186
- package/lib/ui/menu.ui.js.map +0 -1
- package/lib/ui/progressbar.ui.d.ts +0 -23
- package/lib/ui/progressbar.ui.jsx +0 -109
- package/lib/ui/progressbar.ui.jsx.map +0 -1
- package/lib/ui/radiobutton.ui.d.ts +0 -12
- package/lib/ui/radiobutton.ui.jsx +0 -29
- package/lib/ui/radiobutton.ui.jsx.map +0 -1
- package/lib/ui/scroll.ui.d.ts +0 -13
- package/lib/ui/scroll.ui.js +0 -163
- package/lib/ui/scroll.ui.js.map +0 -1
- package/lib/ui/select.ui.d.ts +0 -29
- package/lib/ui/select.ui.jsx +0 -129
- package/lib/ui/select.ui.jsx.map +0 -1
- package/lib/ui/switch.ui.d.ts +0 -12
- package/lib/ui/switch.ui.jsx +0 -29
- package/lib/ui/switch.ui.jsx.map +0 -1
- package/lib/ui/tabs.ui.d.ts +0 -40
- package/lib/ui/tabs.ui.jsx +0 -242
- package/lib/ui/tabs.ui.jsx.map +0 -1
- package/lib/ui/textarea.ui.d.ts +0 -13
- package/lib/ui/textarea.ui.jsx +0 -34
- package/lib/ui/textarea.ui.jsx.map +0 -1
- package/lib/ui/toggle.ui.d.ts +0 -11
- package/lib/ui/toggle.ui.jsx +0 -48
- package/lib/ui/toggle.ui.jsx.map +0 -1
- package/lib/ui/toolbar.ui.d.ts +0 -44
- package/lib/ui/toolbar.ui.jsx +0 -261
- package/lib/ui/toolbar.ui.jsx.map +0 -1
- package/lib/ui/valuebar.ui.d.ts +0 -23
- package/lib/ui/valuebar.ui.jsx +0 -144
- package/lib/ui/valuebar.ui.jsx.map +0 -1
- package/lib/ui/vpanel.ui.d.ts +0 -24
- package/lib/ui/vpanel.ui.jsx +0 -170
- package/lib/ui/vpanel.ui.jsx.map +0 -1
- package/lib/ui/widget.builder.d.ts +0 -25
- package/lib/ui/widget.builder.js +0 -216
- package/lib/ui/widget.builder.js.map +0 -1
- package/lib/ui/widget.collection.d.ts +0 -20
- package/lib/ui/widget.collection.js +0 -49
- package/lib/ui/widget.collection.js.map +0 -1
- package/lib/ui/widget.ui.d.ts +0 -337
- package/lib/ui/widget.ui.js +0 -964
- package/lib/ui/widget.ui.js.map +0 -1
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { Widget, WidgetTypes } from "./widget.ui";
|
|
2
|
-
import { OrientationTypes } from "src/types/orientation.type";
|
|
3
|
-
export type WidgetEventProps = {
|
|
4
|
-
onClick?: (args: any) => {} | void;
|
|
5
|
-
onResize?: (args: any) => {} | void;
|
|
6
|
-
onMouseDown?: (args: any) => {} | void;
|
|
7
|
-
onMouseUp?: (args: any) => {} | void;
|
|
8
|
-
onMouseMove?: (args: any) => {} | void;
|
|
9
|
-
onMouseOut?: (args: any) => {} | void;
|
|
10
|
-
onMouseLeave?: (args: any) => {} | void;
|
|
11
|
-
onWheel?: (args: any) => {} | void;
|
|
12
|
-
onDrag?: (args: any) => {} | void;
|
|
13
|
-
onRender?: (args: any) => {} | void;
|
|
14
|
-
};
|
|
15
|
-
export type WidgetProps = {
|
|
16
|
-
id?: string | null;
|
|
17
|
-
type?: WidgetTypes | null;
|
|
18
|
-
padding?: number | null;
|
|
19
|
-
classNames?: string | null;
|
|
20
|
-
fixedSize?: number | null;
|
|
21
|
-
orientation?: OrientationTypes | null;
|
|
22
|
-
hidden?: boolean | null;
|
|
23
|
-
} & WidgetEventProps;
|
|
24
|
-
export declare function createWidget(content: any, parent?: Widget | null, freedom?: boolean): Widget | null;
|
|
25
|
-
export declare function normalizeWidget(widget: any, props: WidgetProps): any;
|
package/lib/ui/widget.builder.js
DELETED
|
@@ -1,216 +0,0 @@
|
|
|
1
|
-
import { UID } from "../core/uid";
|
|
2
|
-
import { Widget, WidgetAlignTypes, WidgetTypes } from "./widget.ui";
|
|
3
|
-
import { addNewWidget } from "./widget.collection";
|
|
4
|
-
import { createTextbox } from "./Textbox.ui";
|
|
5
|
-
import { createButton } from "./button.ui";
|
|
6
|
-
import { createLabel } from "./label.ui";
|
|
7
|
-
import { createContainer } from "./container.ui";
|
|
8
|
-
import { createIconButton } from "./IconButton.ui";
|
|
9
|
-
import { createImage } from "./image.ui";
|
|
10
|
-
import { createCheckbox } from "./checkbox.ui";
|
|
11
|
-
import { createRadioButton } from "./radiobutton.ui";
|
|
12
|
-
import { createToolbar } from "./toolbar.ui";
|
|
13
|
-
import { createProgressBar } from "./progressbar.ui";
|
|
14
|
-
import { createValueBar } from "./valuebar.ui";
|
|
15
|
-
import { VPanel, createVPanel } from "./vpanel.ui";
|
|
16
|
-
import { HPanel, createHPanel } from "./hpanel.ui";
|
|
17
|
-
import { Tabs, createTab } from "./tabs.ui";
|
|
18
|
-
import { createSwitch } from "./switch.ui";
|
|
19
|
-
import { Accordion, createAccordion } from "./accordion.ui";
|
|
20
|
-
import { createButtonStack } from "./buttonstack.ui";
|
|
21
|
-
import { createButtonColor } from "./buttonColor.ui";
|
|
22
|
-
import { createButtonMenu } from "./buttonmenu.ui";
|
|
23
|
-
import { createIconButtonMenu } from "./iconButtonMenu.ui";
|
|
24
|
-
import { createIcon } from "./Icon.ui";
|
|
25
|
-
import { createTextarea } from "./textarea.ui";
|
|
26
|
-
import { createSelect } from "./select.ui";
|
|
27
|
-
import { createDialog, Dialog } from "./dialog";
|
|
28
|
-
import { createDataGrid, DataGrid } from "./datagrid.ui";
|
|
29
|
-
export function createWidget(content, parent = null, freedom = false) {
|
|
30
|
-
if (!content.tagName) {
|
|
31
|
-
return null;
|
|
32
|
-
}
|
|
33
|
-
let widget = null;
|
|
34
|
-
let widgetProps = {
|
|
35
|
-
id: content.id ? content.id : UID(),
|
|
36
|
-
type: content.getAttribute("w-type") === null
|
|
37
|
-
? WidgetTypes.FILL
|
|
38
|
-
: parseInt(content.getAttribute("w-type")),
|
|
39
|
-
orientation: content.getAttribute("w-orientation") === null
|
|
40
|
-
? "horizontal"
|
|
41
|
-
: content.getAttribute("w-orientation"),
|
|
42
|
-
hidden: content.getAttribute("w-hidden") !== null ? true : false,
|
|
43
|
-
padding: content.getAttribute("w-padding") === null
|
|
44
|
-
? 0
|
|
45
|
-
: parseInt(content.getAttribute("w-padding")),
|
|
46
|
-
fixedSize: content.getAttribute("w-fixed-size") === null
|
|
47
|
-
? null
|
|
48
|
-
: parseInt(content.getAttribute("w-fixed-size")),
|
|
49
|
-
classNames: content.getAttribute("w-classes") === null ? null : content.getAttribute("w-classes"),
|
|
50
|
-
};
|
|
51
|
-
if (!widgetProps.id) {
|
|
52
|
-
widgetProps.id = UID();
|
|
53
|
-
}
|
|
54
|
-
if (content.getAttribute("w-textbox")) {
|
|
55
|
-
widget = createTextbox(widgetProps.id, content, parent);
|
|
56
|
-
}
|
|
57
|
-
else if (content.getAttribute("w-textarea")) {
|
|
58
|
-
widget = createTextarea(widgetProps.id, content, parent);
|
|
59
|
-
}
|
|
60
|
-
else if (content.getAttribute("w-button")) {
|
|
61
|
-
widget = createButton(widgetProps.id, content, parent);
|
|
62
|
-
}
|
|
63
|
-
else if (content.getAttribute("w-icon-button")) {
|
|
64
|
-
widget = createIconButton(widgetProps.id, content, parent);
|
|
65
|
-
}
|
|
66
|
-
else if (content.getAttribute("w-button-stack")) {
|
|
67
|
-
widget = createButtonStack(widgetProps.id, content, parent);
|
|
68
|
-
}
|
|
69
|
-
else if (content.getAttribute("w-button-color")) {
|
|
70
|
-
widget = createButtonColor(widgetProps.id, content, parent);
|
|
71
|
-
}
|
|
72
|
-
else if (content.getAttribute("w-button-menu")) {
|
|
73
|
-
widget = createButtonMenu(widgetProps.id, content, parent);
|
|
74
|
-
}
|
|
75
|
-
else if (content.getAttribute("w-icon-button-menu")) {
|
|
76
|
-
widget = createIconButtonMenu(widgetProps.id, content, parent);
|
|
77
|
-
}
|
|
78
|
-
else if (content.getAttribute("w-label")) {
|
|
79
|
-
widget = createLabel(widgetProps.id, content, parent);
|
|
80
|
-
}
|
|
81
|
-
else if (content.getAttribute("w-image")) {
|
|
82
|
-
widget = createImage(widgetProps.id, content, parent);
|
|
83
|
-
}
|
|
84
|
-
else if (content.getAttribute("w-icon")) {
|
|
85
|
-
widget = createIcon(widgetProps.id, content, parent);
|
|
86
|
-
}
|
|
87
|
-
else if (content.getAttribute("w-checkbox")) {
|
|
88
|
-
widget = createCheckbox(widgetProps.id, content, parent);
|
|
89
|
-
}
|
|
90
|
-
else if (content.getAttribute("w-radiobutton")) {
|
|
91
|
-
widget = createRadioButton(widgetProps.id, content, parent);
|
|
92
|
-
}
|
|
93
|
-
else if (content.getAttribute("w-switch")) {
|
|
94
|
-
widget = createSwitch(widgetProps.id, content, parent);
|
|
95
|
-
}
|
|
96
|
-
else if (content.getAttribute("w-toolbar")) {
|
|
97
|
-
widget = createToolbar(widgetProps.id, content, parent);
|
|
98
|
-
}
|
|
99
|
-
else if (content.getAttribute("w-progressbar")) {
|
|
100
|
-
widget = createProgressBar(widgetProps.id, content, parent);
|
|
101
|
-
}
|
|
102
|
-
else if (content.getAttribute("w-valuebar")) {
|
|
103
|
-
widget = createValueBar(widgetProps.id, content, parent);
|
|
104
|
-
}
|
|
105
|
-
else if (content.getAttribute("w-tab")) {
|
|
106
|
-
widget = createTab(widgetProps.id, content, parent);
|
|
107
|
-
}
|
|
108
|
-
else if (content.getAttribute("w-accordion")) {
|
|
109
|
-
widget = createAccordion(widgetProps.id, content, parent);
|
|
110
|
-
}
|
|
111
|
-
else if (content.getAttribute("w-vpanel")) {
|
|
112
|
-
widget = createVPanel(widgetProps.id, content, parent);
|
|
113
|
-
}
|
|
114
|
-
else if (content.getAttribute("w-hpanel")) {
|
|
115
|
-
widget = createHPanel(widgetProps.id, content, parent);
|
|
116
|
-
}
|
|
117
|
-
else if (content.getAttribute("w-container")) {
|
|
118
|
-
widget = createContainer(content, parent);
|
|
119
|
-
}
|
|
120
|
-
else if (content.getAttribute("w-select")) {
|
|
121
|
-
widget = createSelect(widgetProps.id, content, parent);
|
|
122
|
-
}
|
|
123
|
-
else if (content.getAttribute("w-dialog")) {
|
|
124
|
-
widget = createDialog(widgetProps.id, content, null);
|
|
125
|
-
}
|
|
126
|
-
else if (content.getAttribute("w-data-grid")) {
|
|
127
|
-
widget = createDataGrid(widgetProps.id, content, parent);
|
|
128
|
-
}
|
|
129
|
-
else {
|
|
130
|
-
widget = new Widget(widgetProps.id, content.tagName, parent);
|
|
131
|
-
if (widgetProps.type === WidgetTypes.FREE) {
|
|
132
|
-
freedom = true;
|
|
133
|
-
}
|
|
134
|
-
content.getAttributeNames().forEach((key) => {
|
|
135
|
-
if (widget)
|
|
136
|
-
widget.getBody().setAttribute(key, content.getAttribute(key));
|
|
137
|
-
});
|
|
138
|
-
content.childNodes.forEach((child) => {
|
|
139
|
-
if (child.hasChildNodes() == true) {
|
|
140
|
-
createWidget(child, widget, freedom);
|
|
141
|
-
}
|
|
142
|
-
else {
|
|
143
|
-
if (widget)
|
|
144
|
-
widget.getBody().appendChild(child);
|
|
145
|
-
}
|
|
146
|
-
});
|
|
147
|
-
}
|
|
148
|
-
if (widget) {
|
|
149
|
-
if (!freedom && widgetProps.type) {
|
|
150
|
-
widget.setType(widgetProps.type);
|
|
151
|
-
}
|
|
152
|
-
else {
|
|
153
|
-
widget.setType(WidgetTypes.FREE);
|
|
154
|
-
}
|
|
155
|
-
if (widget instanceof Dialog) {
|
|
156
|
-
widget.setType(WidgetTypes.CUSTOM);
|
|
157
|
-
}
|
|
158
|
-
if (widgetProps.orientation &&
|
|
159
|
-
!(widget instanceof VPanel) &&
|
|
160
|
-
!(widget instanceof HPanel) &&
|
|
161
|
-
!(widget instanceof Dialog) &&
|
|
162
|
-
!(widget instanceof DataGrid) &&
|
|
163
|
-
!(widget instanceof Tabs)) {
|
|
164
|
-
if (widgetProps.orientation === "vertical") {
|
|
165
|
-
widget.setAlign(WidgetAlignTypes.VERTICAL);
|
|
166
|
-
}
|
|
167
|
-
else {
|
|
168
|
-
widget.setAlign(WidgetAlignTypes.HORIZONTAL);
|
|
169
|
-
}
|
|
170
|
-
}
|
|
171
|
-
if (widget instanceof Accordion) {
|
|
172
|
-
widget.setAlign(WidgetAlignTypes.VERTICAL);
|
|
173
|
-
}
|
|
174
|
-
if (widget instanceof DataGrid) {
|
|
175
|
-
widget.setAlign(WidgetAlignTypes.VERTICAL);
|
|
176
|
-
}
|
|
177
|
-
if (widgetProps.padding)
|
|
178
|
-
widget.setPadding(widgetProps.padding);
|
|
179
|
-
if (widgetProps.fixedSize)
|
|
180
|
-
widget.setFixedSize(widgetProps.fixedSize);
|
|
181
|
-
if (widgetProps.classNames) {
|
|
182
|
-
const clases = widgetProps.classNames.split(" ");
|
|
183
|
-
for (const clase of clases) {
|
|
184
|
-
widget.addClass(clase);
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
if (widgetProps.hidden) {
|
|
188
|
-
widget.setVisible(false);
|
|
189
|
-
}
|
|
190
|
-
addNewWidget(widgetProps.id, widget);
|
|
191
|
-
return widget;
|
|
192
|
-
}
|
|
193
|
-
return null;
|
|
194
|
-
}
|
|
195
|
-
export function normalizeWidget(widget, props) {
|
|
196
|
-
if (props.fixedSize !== undefined) {
|
|
197
|
-
widget.setAttribute("w-fixed-size", props.fixedSize);
|
|
198
|
-
}
|
|
199
|
-
if (props.padding !== undefined) {
|
|
200
|
-
widget.setAttribute("w-padding", props.padding);
|
|
201
|
-
}
|
|
202
|
-
if (props.type !== undefined) {
|
|
203
|
-
widget.setAttribute("w-type", props.type);
|
|
204
|
-
}
|
|
205
|
-
if (props.hidden !== undefined) {
|
|
206
|
-
widget.setAttribute("w-hidden", props.hidden);
|
|
207
|
-
}
|
|
208
|
-
if (props.classNames !== undefined) {
|
|
209
|
-
widget.setAttribute("w-classes", props.classNames);
|
|
210
|
-
}
|
|
211
|
-
if (props.orientation !== undefined) {
|
|
212
|
-
widget.setAttribute("w-orientation", props.orientation);
|
|
213
|
-
}
|
|
214
|
-
return widget;
|
|
215
|
-
}
|
|
216
|
-
//# sourceMappingURL=widget.builder.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"widget.builder.js","sourceRoot":"","sources":["../../src/ui/widget.builder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,aAAa,CAAC;AAClC,OAAO,EAAE,MAAM,EAAE,gBAAgB,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACpE,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AACzC,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;A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IAClB,CAAC;IAED,OAAO,IAAI,CAAC;AAChB,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,MAAW,EAAE,KAAkB;IAC3D,IAAI,KAAK,CAAC,SAAS,KAAK,SAAS,EAAE,CAAC;QAChC,MAAM,CAAC,YAAY,CAAC,cAAc,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;IACzD,CAAC;IAED,IAAI,KAAK,CAAC,OAAO,KAAK,SAAS,EAAE,CAAC;QAC9B,MAAM,CAAC,YAAY,CAAC,WAAW,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;IACpD,CAAC;IAED,IAAI,KAAK,CAAC,IAAI,KAAK,SAAS,EAAE,CAAC;QAC3B,MAAM,CAAC,YAAY,CAAC,QAAQ,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;IAC9C,CAAC;IAED,IAAI,KAAK,CAAC,MAAM,KAAK,SAAS,EAAE,CAAC;QAC7B,MAAM,CAAC,YAAY,CAAC,UAAU,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAClD,CAAC;IAED,IAAI,KAAK,CAAC,UAAU,KAAK,SAAS,EAAE,CAAC;QACjC,MAAM,CAAC,YAAY,CAAC,WAAW,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IACvD,CAAC;IAED,IAAI,KAAK,CAAC,WAAW,KAAK,SAAS,EAAE,CAAC;QAClC,MAAM,CAAC,YAAY,CAAC,eAAe,EAAE,KAAK,CAAC,WAAW,CAAC,CAAC;IAC5D,CAAC;IAED,OAAO,MAAM,CAAC;AAClB,CAAC"}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import WApplication from "src/core/application.core";
|
|
2
|
-
import { IWidget, WUICallback } from "../interfaces/widget.interface";
|
|
3
|
-
declare global {
|
|
4
|
-
interface Window {
|
|
5
|
-
app: WApplication | undefined;
|
|
6
|
-
w: Map<string, IWidget>;
|
|
7
|
-
widgetConnections: Map<string, WUICallback>;
|
|
8
|
-
}
|
|
9
|
-
var w: Map<string, IWidget>;
|
|
10
|
-
var app: WApplication | undefined;
|
|
11
|
-
var widgetConnections: Map<string, WUICallback>;
|
|
12
|
-
var widgetCustomConnections: Map<string, WUICallback>;
|
|
13
|
-
}
|
|
14
|
-
export declare const initWidgetCollection: () => void;
|
|
15
|
-
export declare const initWidgetConnections: () => void;
|
|
16
|
-
export declare const addNewWidget: (id: string, widget: IWidget) => void;
|
|
17
|
-
export declare const connectWidget: (id: string, callback: WUICallback) => void;
|
|
18
|
-
export declare const connectCustomWidget: (id: string, callback: WUICallback) => void;
|
|
19
|
-
export declare const run: (eventId: string) => void;
|
|
20
|
-
export declare const runCustom: (eventId: string) => void;
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
export const initWidgetCollection = () => {
|
|
2
|
-
if (!window.w) {
|
|
3
|
-
window.w = new Map();
|
|
4
|
-
w = window.w;
|
|
5
|
-
}
|
|
6
|
-
initWidgetConnections();
|
|
7
|
-
};
|
|
8
|
-
export const initWidgetConnections = () => {
|
|
9
|
-
if (!window.widgetConnections) {
|
|
10
|
-
window.widgetConnections = new Map();
|
|
11
|
-
}
|
|
12
|
-
if (!window.widgetCustomConnections) {
|
|
13
|
-
window.widgetCustomConnections = new Map();
|
|
14
|
-
}
|
|
15
|
-
};
|
|
16
|
-
export const addNewWidget = (id, widget) => {
|
|
17
|
-
initWidgetCollection();
|
|
18
|
-
if (!w.get(id))
|
|
19
|
-
w.set(id, widget);
|
|
20
|
-
setTimeout(() => {
|
|
21
|
-
run("widget-added-" + id);
|
|
22
|
-
runCustom("widget-custom-added-" + id);
|
|
23
|
-
});
|
|
24
|
-
};
|
|
25
|
-
export const connectWidget = (id, callback) => {
|
|
26
|
-
initWidgetConnections();
|
|
27
|
-
widgetConnections.set(id, callback);
|
|
28
|
-
};
|
|
29
|
-
export const connectCustomWidget = (id, callback) => {
|
|
30
|
-
initWidgetConnections();
|
|
31
|
-
widgetCustomConnections.set(id, callback);
|
|
32
|
-
};
|
|
33
|
-
export const run = (eventId) => {
|
|
34
|
-
for (const [key, value] of widgetConnections.entries()) {
|
|
35
|
-
if (key == eventId) {
|
|
36
|
-
value.then(new Event(eventId), null);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
widgetConnections.delete(eventId);
|
|
40
|
-
};
|
|
41
|
-
export const runCustom = (eventId) => {
|
|
42
|
-
for (const [key, value] of widgetCustomConnections.entries()) {
|
|
43
|
-
if (key == eventId) {
|
|
44
|
-
value.then(new Event(eventId), null);
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
widgetCustomConnections.delete(eventId);
|
|
48
|
-
};
|
|
49
|
-
//# sourceMappingURL=widget.collection.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"widget.collection.js","sourceRoot":"","sources":["../../src/ui/widget.collection.ts"],"names":[],"mappings":"AAgBA,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,EAAE;IACrC,IAAI,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC;QACZ,MAAM,CAAC,CAAC,GAAG,IAAI,GAAG,EAAmB,CAAC;QACtC,CAAC,GAAG,MAAM,CAAC,CAAC,CAAC;IACjB,CAAC;IAED,qBAAqB,EAAE,CAAC;AAC5B,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,qBAAqB,GAAG,GAAG,EAAE;IACtC,IAAI,CAAC,MAAM,CAAC,iBAAiB,EAAE,CAAC;QAC5B,MAAM,CAAC,iBAAiB,GAAG,IAAI,GAAG,EAAuB,CAAC;IAC9D,CAAC;IAED,IAAI,CAAC,MAAM,CAAC,uBAAuB,EAAE,CAAC;QAClC,MAAM,CAAC,uBAAuB,GAAG,IAAI,GAAG,EAAuB,CAAC;IACpE,CAAC;AACL,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAAU,EAAE,MAAe,EAAE,EAAE;IACxD,oBAAoB,EAAE,CAAC;IACvB,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC;Q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AAI,CAAC,CAAC;QACzC,CAAC;IACL,CAAC;IACD,uBAAuB,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;AAC5C,CAAC,CAAC"}
|
package/lib/ui/widget.ui.d.ts
DELETED
|
@@ -1,337 +0,0 @@
|
|
|
1
|
-
import { IWidget, WUIEvent, WUICallback } from "../interfaces/widget.interface";
|
|
2
|
-
import { Vector2D } from "../types/vector2d.type";
|
|
3
|
-
import { WidgetEventProps, WidgetProps } from "./widget.builder";
|
|
4
|
-
export declare enum WidgetTypes {
|
|
5
|
-
FILL = 1,
|
|
6
|
-
CUSTOM = 2,
|
|
7
|
-
FREE = 3
|
|
8
|
-
}
|
|
9
|
-
export declare enum WidgetAlignTypes {
|
|
10
|
-
HORIZONTAL = 1,
|
|
11
|
-
VERTICAL = 2
|
|
12
|
-
}
|
|
13
|
-
export declare class Widget implements IWidget {
|
|
14
|
-
readonly id: string;
|
|
15
|
-
subscribers: Map<string, WUICallback>;
|
|
16
|
-
padding: number;
|
|
17
|
-
left: number;
|
|
18
|
-
top: number;
|
|
19
|
-
width: number;
|
|
20
|
-
height: number;
|
|
21
|
-
initialWidth: number;
|
|
22
|
-
initialHeight: number;
|
|
23
|
-
overflow: boolean;
|
|
24
|
-
fixedSize: number | null;
|
|
25
|
-
type: WidgetTypes;
|
|
26
|
-
align: WidgetAlignTypes;
|
|
27
|
-
visible: boolean;
|
|
28
|
-
enabled: boolean;
|
|
29
|
-
parent: IWidget | null;
|
|
30
|
-
childs: IWidget[];
|
|
31
|
-
bodyTagName: string;
|
|
32
|
-
body: HTMLElement;
|
|
33
|
-
constructor(id?: string | null, bodyTagName?: string, parent?: IWidget | null);
|
|
34
|
-
run(eventId: WUIEvent): void;
|
|
35
|
-
subscribe(cb: WUICallback): void;
|
|
36
|
-
unsubscribe(event: WUIEvent): void;
|
|
37
|
-
/**
|
|
38
|
-
* Sets the padding value for the object.
|
|
39
|
-
*
|
|
40
|
-
* @param {number} p - The padding value to set.
|
|
41
|
-
* @return {void} This function does not return a value.
|
|
42
|
-
*/
|
|
43
|
-
setPadding(p: number): void;
|
|
44
|
-
/**
|
|
45
|
-
* Sets the value of x and updates the left position of the element.
|
|
46
|
-
*
|
|
47
|
-
* @param {number} x - The new value of x.
|
|
48
|
-
* @return {void} This function does not return anything.
|
|
49
|
-
*/
|
|
50
|
-
setX(x: number): void;
|
|
51
|
-
/**
|
|
52
|
-
* Sets the value of the 'y' property and updates the 'top' and 'body.style.top' properties accordingly.
|
|
53
|
-
*
|
|
54
|
-
* @param {number} y - The new value for the 'y' property.
|
|
55
|
-
* @return {void} This function does not return a value.
|
|
56
|
-
*/
|
|
57
|
-
setY(y: number): void;
|
|
58
|
-
/**
|
|
59
|
-
* Sets the width of the element and updates the corresponding inline style.
|
|
60
|
-
*
|
|
61
|
-
* @param {number} w - The new width value.
|
|
62
|
-
* @return {void} This function does not return a value.
|
|
63
|
-
*/
|
|
64
|
-
setW(w: number): void;
|
|
65
|
-
/**
|
|
66
|
-
* Sets the initial value of the width property.
|
|
67
|
-
*
|
|
68
|
-
* @param {number} w - The initial width value.
|
|
69
|
-
* @return {void} This function does not return a value.
|
|
70
|
-
*/
|
|
71
|
-
setInitialW(w: number): void;
|
|
72
|
-
/**
|
|
73
|
-
* Sets the value of the height property and updates the height of the element.
|
|
74
|
-
*
|
|
75
|
-
* @param {number} h - The new height value.
|
|
76
|
-
* @return {void} This function does not return any value.
|
|
77
|
-
*/
|
|
78
|
-
setH(h: number): void;
|
|
79
|
-
/**
|
|
80
|
-
* Sets the initial height of the object.
|
|
81
|
-
*
|
|
82
|
-
* @param {number} h - The initial height value to set.
|
|
83
|
-
* @return {void} This function does not return a value.
|
|
84
|
-
*/
|
|
85
|
-
setInitialH(h: number): void;
|
|
86
|
-
/**
|
|
87
|
-
* Sets the width and height of the element.
|
|
88
|
-
*
|
|
89
|
-
* @param {number} w - The width to set.
|
|
90
|
-
* @param {number} h - The height to set.
|
|
91
|
-
* @return {void} This function does not return anything.
|
|
92
|
-
*/
|
|
93
|
-
setWH(w: number, h: number): void;
|
|
94
|
-
setFixedSize(s: number | null): void;
|
|
95
|
-
/**
|
|
96
|
-
* Sets the type of the widget.
|
|
97
|
-
*
|
|
98
|
-
* @param {WidgetTypes} type - The type of widget to set.
|
|
99
|
-
* @return {void} This function does not return anything.
|
|
100
|
-
*/
|
|
101
|
-
setType(type: WidgetTypes): void;
|
|
102
|
-
/**
|
|
103
|
-
* Sets the alignment of the widget.
|
|
104
|
-
*
|
|
105
|
-
* @param {WidgetAlignTypes} align - The alignment to set.
|
|
106
|
-
* @return {void}
|
|
107
|
-
*/
|
|
108
|
-
setAlign(align: WidgetAlignTypes): void;
|
|
109
|
-
/**
|
|
110
|
-
* Sets the visibility of the element.
|
|
111
|
-
*
|
|
112
|
-
* @param {boolean} visible - The visibility state of the element.
|
|
113
|
-
* @return {void}
|
|
114
|
-
*/
|
|
115
|
-
setVisible(visible: boolean): void;
|
|
116
|
-
/**
|
|
117
|
-
* Sets the enabled status of the object.
|
|
118
|
-
*
|
|
119
|
-
* @param {boolean} enabled - The new enabled status.
|
|
120
|
-
* @return {void} This function does not return a value.
|
|
121
|
-
*/
|
|
122
|
-
setEnabled(enabled: boolean): void;
|
|
123
|
-
/**
|
|
124
|
-
* Sets the parent of the widget.
|
|
125
|
-
*
|
|
126
|
-
* @param {IWidget | null} parent - The parent widget or null if there is no parent.
|
|
127
|
-
* @return {void} This function does not return anything.
|
|
128
|
-
*/
|
|
129
|
-
setParent(parent: IWidget | null): void;
|
|
130
|
-
/**
|
|
131
|
-
* Sets the body of the element.
|
|
132
|
-
*
|
|
133
|
-
* @param {HTMLElement} body - The new body element.
|
|
134
|
-
* @return {void} This function does not return anything.
|
|
135
|
-
*/
|
|
136
|
-
setBody(body: HTMLElement): void;
|
|
137
|
-
/**
|
|
138
|
-
* Sets the array of child widgets for this widget.
|
|
139
|
-
*
|
|
140
|
-
* @param {IWidget[]} childs - The array of child widgets to set.
|
|
141
|
-
* @return {void}
|
|
142
|
-
*/
|
|
143
|
-
setChilds(childs: IWidget[]): void;
|
|
144
|
-
/**
|
|
145
|
-
* Sets the overflow value.
|
|
146
|
-
*
|
|
147
|
-
* @param {boolean} overflow - The new value for the overflow.
|
|
148
|
-
* @return {void} This function does not return a value.
|
|
149
|
-
*/
|
|
150
|
-
setOverflow(overflow: boolean): void;
|
|
151
|
-
/**
|
|
152
|
-
* Adds a CSS class to the list of CSS classes.
|
|
153
|
-
*
|
|
154
|
-
* @param {string} cssClass - The CSS class to add.
|
|
155
|
-
* @return {void}
|
|
156
|
-
*/
|
|
157
|
-
addClass(cssClass: string): void;
|
|
158
|
-
/**
|
|
159
|
-
* Deletes a CSS class from the list of CSS classes.
|
|
160
|
-
*
|
|
161
|
-
* @param {string} cssClass - The CSS class to be deleted.
|
|
162
|
-
* @return {void} This function does not return a value.
|
|
163
|
-
*/
|
|
164
|
-
deleteClass(cssClass: string): void;
|
|
165
|
-
deleteAllClasses(): void;
|
|
166
|
-
/**
|
|
167
|
-
* Retrieves the padding value.
|
|
168
|
-
*
|
|
169
|
-
* @return {number} The padding value.
|
|
170
|
-
*/
|
|
171
|
-
getPadding(): number;
|
|
172
|
-
/**
|
|
173
|
-
* Retrieves the value of the 'left' property.
|
|
174
|
-
*
|
|
175
|
-
* @return {number} The value of the 'left' property.
|
|
176
|
-
*/
|
|
177
|
-
getX(recursive?: boolean): number;
|
|
178
|
-
/**
|
|
179
|
-
* Retrieves the value of Y.
|
|
180
|
-
*
|
|
181
|
-
* @return {number} The value of Y.
|
|
182
|
-
*/
|
|
183
|
-
getY(recursive?: boolean): number;
|
|
184
|
-
/**
|
|
185
|
-
* Get the width of the object.
|
|
186
|
-
*
|
|
187
|
-
* @return {number} The width of the object.
|
|
188
|
-
*/
|
|
189
|
-
getW(): number;
|
|
190
|
-
/**
|
|
191
|
-
* Returns the value of the height property.
|
|
192
|
-
*
|
|
193
|
-
* @return {number} The value of the height property.
|
|
194
|
-
*/
|
|
195
|
-
getH(): number;
|
|
196
|
-
/**
|
|
197
|
-
* Returns the position of the element relative to the viewport.
|
|
198
|
-
*
|
|
199
|
-
* @param {boolean} scroll - Indicates whether to account for scrolling in the position calculation. Defaults to false.
|
|
200
|
-
* @return {Vector2D} An object with x and y properties representing the position of the element.
|
|
201
|
-
*/
|
|
202
|
-
getPosition(scroll?: boolean): Vector2D;
|
|
203
|
-
getFixedSize(): number | null;
|
|
204
|
-
/**
|
|
205
|
-
* Returns the type of the widget.
|
|
206
|
-
*
|
|
207
|
-
* @return {WidgetTypes} The type of the widget.
|
|
208
|
-
*/
|
|
209
|
-
getType(): WidgetTypes;
|
|
210
|
-
/**
|
|
211
|
-
* Retrieves the alignment of the widget.
|
|
212
|
-
*
|
|
213
|
-
* @return {WidgetAlignTypes} The alignment of the widget.
|
|
214
|
-
*/
|
|
215
|
-
getAlign(): WidgetAlignTypes;
|
|
216
|
-
/**
|
|
217
|
-
* Retrieves the value of the enabled flag.
|
|
218
|
-
*
|
|
219
|
-
* @return {boolean} The value of the enabled flag.
|
|
220
|
-
*/
|
|
221
|
-
getEnabled(): boolean;
|
|
222
|
-
/**
|
|
223
|
-
* Returns the visibility status of the element.
|
|
224
|
-
*
|
|
225
|
-
* @return {boolean} The visibility status of the element.
|
|
226
|
-
*/
|
|
227
|
-
getVisible(): boolean;
|
|
228
|
-
/**
|
|
229
|
-
* Retrieves the parent widget of this widget.
|
|
230
|
-
*
|
|
231
|
-
* @return {IWidget | null} The parent widget or null if there is no parent.
|
|
232
|
-
*/
|
|
233
|
-
getParent(): IWidget | null;
|
|
234
|
-
/**
|
|
235
|
-
* Returns the body element of the object.
|
|
236
|
-
*
|
|
237
|
-
* @return {HTMLElement} The body element.
|
|
238
|
-
*/
|
|
239
|
-
getBody(): HTMLElement;
|
|
240
|
-
/**
|
|
241
|
-
* Retrieves the array of child widgets.
|
|
242
|
-
*
|
|
243
|
-
* @return {IWidget[]} The array of child widgets.
|
|
244
|
-
*/
|
|
245
|
-
getChilds(): IWidget[];
|
|
246
|
-
/**
|
|
247
|
-
* Returns the value of the 'overflow' property.
|
|
248
|
-
*
|
|
249
|
-
* @return {boolean} The value of the 'overflow' property.
|
|
250
|
-
*/
|
|
251
|
-
getOverflow(): boolean;
|
|
252
|
-
/**
|
|
253
|
-
* Adds a child widget to the current widget.
|
|
254
|
-
*
|
|
255
|
-
* @param {IWidget} child - The widget to be added.
|
|
256
|
-
* @return {void} - This function does not return anything.
|
|
257
|
-
*/
|
|
258
|
-
addChild(child?: IWidget | null): void;
|
|
259
|
-
populate(): void;
|
|
260
|
-
/**
|
|
261
|
-
* Disables the selection feature.
|
|
262
|
-
*
|
|
263
|
-
* @param {void} -
|
|
264
|
-
* @return {void} -
|
|
265
|
-
*/
|
|
266
|
-
disableSelection(): void;
|
|
267
|
-
/**
|
|
268
|
-
* Enables selection.
|
|
269
|
-
*
|
|
270
|
-
*/
|
|
271
|
-
enableSelection(): void;
|
|
272
|
-
/**
|
|
273
|
-
* Hides the element by setting its visibility to false.
|
|
274
|
-
*
|
|
275
|
-
* @param {void} -
|
|
276
|
-
* @return {void} -
|
|
277
|
-
*/
|
|
278
|
-
hide(): void;
|
|
279
|
-
/**
|
|
280
|
-
* Initializes the function.
|
|
281
|
-
*
|
|
282
|
-
* @param {type} paramName - description of parameter
|
|
283
|
-
* @return {type} description of return value
|
|
284
|
-
*/
|
|
285
|
-
init(): void;
|
|
286
|
-
/**
|
|
287
|
-
* Initializes the position.
|
|
288
|
-
*
|
|
289
|
-
* @param {void} - No parameters required.
|
|
290
|
-
* @return {void} - No return value.
|
|
291
|
-
*/
|
|
292
|
-
initPosition(): void;
|
|
293
|
-
/**
|
|
294
|
-
* Renders the component.
|
|
295
|
-
*
|
|
296
|
-
* @return {void}
|
|
297
|
-
*/
|
|
298
|
-
render(): void;
|
|
299
|
-
/**
|
|
300
|
-
* Resizes the element and its child elements.
|
|
301
|
-
*/
|
|
302
|
-
resize(): void;
|
|
303
|
-
/**
|
|
304
|
-
* Displays the element on the screen.
|
|
305
|
-
*
|
|
306
|
-
* @return {void} - Does not return a value.
|
|
307
|
-
*/
|
|
308
|
-
display(): void;
|
|
309
|
-
/**
|
|
310
|
-
* Toggles the visibility of something.
|
|
311
|
-
*
|
|
312
|
-
* @return {void} Nothing is returned.
|
|
313
|
-
*/
|
|
314
|
-
toggle(): void;
|
|
315
|
-
renderHTML(content: any): HTMLElement;
|
|
316
|
-
private getMaxZIndex;
|
|
317
|
-
setZIndex(zIndex: number): void;
|
|
318
|
-
raisteTop(): void;
|
|
319
|
-
raiseBottom(): void;
|
|
320
|
-
/**
|
|
321
|
-
* Attaches a widget to the current widget and delete all pre-existents widgets
|
|
322
|
-
*
|
|
323
|
-
* @param {IWidget} guest - The widget to attach.
|
|
324
|
-
* @return {void} This function does not return anything.
|
|
325
|
-
*/
|
|
326
|
-
attachWidget(guest: IWidget): void;
|
|
327
|
-
/**
|
|
328
|
-
* Removes all child nodes from the current element.
|
|
329
|
-
*
|
|
330
|
-
* @return {void} No return value.
|
|
331
|
-
*/
|
|
332
|
-
removeAllChilds(): void;
|
|
333
|
-
free(): void;
|
|
334
|
-
dispose(): void;
|
|
335
|
-
}
|
|
336
|
-
export declare function getOnlyEventProps(props: WidgetProps): WidgetEventProps;
|
|
337
|
-
export declare function connectWidgetCallback(id: string | null | undefined, props: WidgetEventProps): void;
|