@wavemaker-ai/app-ng-runtime 12.0.2-rc.647771 → 12.1.0-rc.647821
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-task/bundles/index.umd.js +2489 -2963
- package/build-task/fesm2022/index.mjs +2307 -2786
- package/build-task/fesm2022/index.mjs.map +1 -1
- package/build-task/types/index.d.ts +401 -844
- package/components/advanced/carousel/bundles/index.umd.js +387 -344
- package/components/advanced/carousel/fesm2022/index.mjs +363 -325
- package/components/advanced/carousel/fesm2022/index.mjs.map +1 -1
- package/components/advanced/carousel/types/index.d.ts +85 -86
- package/components/advanced/custom/bundles/index.umd.js +298 -249
- package/components/advanced/custom/fesm2022/index.mjs +280 -236
- package/components/advanced/custom/fesm2022/index.mjs.map +1 -1
- package/components/advanced/custom/types/index.d.ts +49 -49
- package/components/advanced/login/bundles/index.umd.js +177 -127
- package/components/advanced/login/fesm2022/index.mjs +162 -117
- package/components/advanced/login/fesm2022/index.mjs.map +1 -1
- package/components/advanced/login/types/index.d.ts +33 -34
- package/components/advanced/marquee/bundles/index.umd.js +93 -63
- package/components/advanced/marquee/fesm2022/index.mjs +73 -48
- package/components/advanced/marquee/fesm2022/index.mjs.map +1 -1
- package/components/advanced/marquee/types/index.d.ts +11 -12
- package/components/base/bundles/index.umd.js +5515 -6359
- package/components/base/fesm2022/index.mjs +5169 -6027
- package/components/base/fesm2022/index.mjs.map +1 -1
- package/components/base/types/index.d.ts +1198 -1154
- package/components/basic/anchor/bundles/index.umd.js +273 -195
- package/components/basic/anchor/fesm2022/index.mjs +251 -178
- package/components/basic/anchor/fesm2022/index.mjs.map +1 -1
- package/components/basic/anchor/types/index.d.ts +40 -41
- package/components/basic/audio/bundles/index.umd.js +124 -75
- package/components/basic/audio/fesm2022/index.mjs +104 -60
- package/components/basic/audio/fesm2022/index.mjs.map +1 -1
- package/components/basic/audio/types/index.d.ts +22 -23
- package/components/basic/html/bundles/index.umd.js +144 -113
- package/components/basic/html/fesm2022/index.mjs +125 -99
- package/components/basic/html/fesm2022/index.mjs.map +1 -1
- package/components/basic/html/types/index.d.ts +20 -17
- package/components/basic/icon/bundles/index.umd.js +144 -72
- package/components/basic/icon/fesm2022/index.mjs +124 -57
- package/components/basic/icon/fesm2022/index.mjs.map +1 -1
- package/components/basic/icon/types/index.d.ts +18 -19
- package/components/basic/iframe/bundles/index.umd.js +143 -93
- package/components/basic/iframe/fesm2022/index.mjs +124 -79
- package/components/basic/iframe/fesm2022/index.mjs.map +1 -1
- package/components/basic/iframe/types/index.d.ts +28 -29
- package/components/basic/label/bundles/index.umd.js +136 -120
- package/components/basic/label/fesm2022/index.mjs +118 -107
- package/components/basic/label/fesm2022/index.mjs.map +1 -1
- package/components/basic/label/types/index.d.ts +14 -15
- package/components/basic/picture/bundles/index.umd.js +171 -130
- package/components/basic/picture/fesm2022/index.mjs +152 -116
- package/components/basic/picture/fesm2022/index.mjs.map +1 -1
- package/components/basic/picture/types/index.d.ts +21 -22
- package/components/basic/progress/progress-bar/bundles/index.umd.js +211 -160
- package/components/basic/progress/progress-bar/fesm2022/index.mjs +193 -147
- package/components/basic/progress/progress-bar/fesm2022/index.mjs.map +1 -1
- package/components/basic/progress/progress-bar/types/index.d.ts +45 -41
- package/components/basic/progress/progress-circle/bundles/index.umd.js +294 -165
- package/components/basic/progress/progress-circle/fesm2022/index.mjs +274 -150
- package/components/basic/progress/progress-circle/fesm2022/index.mjs.map +1 -1
- package/components/basic/progress/progress-circle/types/index.d.ts +41 -42
- package/components/basic/progress/progress-utils/bundles/index.umd.js +27 -29
- package/components/basic/progress/progress-utils/fesm2022/index.mjs +18 -25
- package/components/basic/progress/progress-utils/fesm2022/index.mjs.map +1 -1
- package/components/basic/progress/progress-utils/types/index.d.ts +3 -5
- package/components/basic/rich-text-editor/bundles/index.umd.js +294 -228
- package/components/basic/rich-text-editor/fesm2022/index.mjs +275 -214
- package/components/basic/rich-text-editor/fesm2022/index.mjs.map +1 -1
- package/components/basic/rich-text-editor/types/index.d.ts +55 -56
- package/components/basic/search/bundles/index.umd.js +1129 -1090
- package/components/basic/search/fesm2022/index.mjs +1117 -1083
- package/components/basic/search/fesm2022/index.mjs.map +1 -1
- package/components/basic/search/types/index.d.ts +132 -130
- package/components/basic/spinner/bundles/index.umd.js +216 -120
- package/components/basic/spinner/fesm2022/index.mjs +201 -110
- package/components/basic/spinner/fesm2022/index.mjs.map +1 -1
- package/components/basic/spinner/types/index.d.ts +30 -31
- package/components/basic/tree/bundles/index.umd.js +756 -756
- package/components/basic/tree/fesm2022/index.mjs +740 -745
- package/components/basic/tree/fesm2022/index.mjs.map +1 -1
- package/components/basic/tree/types/index.d.ts +106 -97
- package/components/basic/video/bundles/index.umd.js +164 -108
- package/components/basic/video/fesm2022/index.mjs +145 -94
- package/components/basic/video/fesm2022/index.mjs.map +1 -1
- package/components/basic/video/types/index.d.ts +29 -30
- package/components/chart/bundles/index.umd.js +1768 -1737
- package/components/chart/fesm2022/index.mjs +1713 -1728
- package/components/chart/fesm2022/index.mjs.map +1 -1
- package/components/chart/types/index.d.ts +102 -104
- package/components/containers/accordion/bundles/index.umd.js +522 -494
- package/components/containers/accordion/fesm2022/index.mjs +502 -479
- package/components/containers/accordion/fesm2022/index.mjs.map +1 -1
- package/components/containers/accordion/types/index.d.ts +116 -116
- package/components/containers/layout-grid/bundles/index.umd.js +260 -164
- package/components/containers/layout-grid/fesm2022/index.mjs +231 -140
- package/components/containers/layout-grid/fesm2022/index.mjs.map +1 -1
- package/components/containers/layout-grid/types/index.d.ts +30 -27
- package/components/containers/linear-layout/bundles/index.umd.js +220 -178
- package/components/containers/linear-layout/fesm2022/index.mjs +193 -156
- package/components/containers/linear-layout/fesm2022/index.mjs.map +1 -1
- package/components/containers/linear-layout/types/index.d.ts +26 -26
- package/components/containers/panel/bundles/index.umd.js +343 -215
- package/components/containers/panel/fesm2022/index.mjs +330 -207
- package/components/containers/panel/fesm2022/index.mjs.map +1 -1
- package/components/containers/panel/types/index.d.ts +48 -49
- package/components/containers/tabs/bundles/index.umd.js +832 -779
- package/components/containers/tabs/fesm2022/index.mjs +811 -763
- package/components/containers/tabs/fesm2022/index.mjs.map +1 -1
- package/components/containers/tabs/types/index.d.ts +134 -126
- package/components/containers/tile/bundles/index.umd.js +93 -60
- package/components/containers/tile/fesm2022/index.mjs +75 -47
- package/components/containers/tile/fesm2022/index.mjs.map +1 -1
- package/components/containers/tile/types/index.d.ts +11 -12
- package/components/containers/wizard/bundles/index.umd.js +1096 -1078
- package/components/containers/wizard/fesm2022/index.mjs +1069 -1056
- package/components/containers/wizard/fesm2022/index.mjs.map +1 -1
- package/components/containers/wizard/types/index.d.ts +258 -252
- package/components/data/card/bundles/index.umd.js +439 -229
- package/components/data/card/fesm2022/index.mjs +408 -203
- package/components/data/card/fesm2022/index.mjs.map +1 -1
- package/components/data/card/types/index.d.ts +50 -48
- package/components/data/form/bundles/index.umd.js +3392 -3339
- package/components/data/form/fesm2022/index.mjs +3350 -3304
- package/components/data/form/fesm2022/index.mjs.map +1 -1
- package/components/data/form/types/index.d.ts +561 -482
- package/components/data/list/bundles/index.umd.js +1523 -1601
- package/components/data/list/fesm2022/index.mjs +1507 -1590
- package/components/data/list/fesm2022/index.mjs.map +1 -1
- package/components/data/list/types/index.d.ts +300 -283
- package/components/data/live-table/bundles/index.umd.js +299 -280
- package/components/data/live-table/fesm2022/index.mjs +284 -270
- package/components/data/live-table/fesm2022/index.mjs.map +1 -1
- package/components/data/live-table/types/index.d.ts +42 -39
- package/components/data/pagination/bundles/index.umd.js +848 -881
- package/components/data/pagination/fesm2022/index.mjs +835 -879
- package/components/data/pagination/fesm2022/index.mjs.map +1 -1
- package/components/data/pagination/types/index.d.ts +110 -106
- package/components/data/table/bundles/index.umd.js +4977 -5042
- package/components/data/table/fesm2022/index.mjs +4937 -5007
- package/components/data/table/fesm2022/index.mjs.map +1 -1
- package/components/data/table/types/index.d.ts +770 -736
- package/components/dialogs/alert-dialog/bundles/index.umd.js +259 -118
- package/components/dialogs/alert-dialog/fesm2022/index.mjs +243 -109
- package/components/dialogs/alert-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/alert-dialog/types/index.d.ts +31 -26
- package/components/dialogs/confirm-dialog/bundles/index.umd.js +250 -121
- package/components/dialogs/confirm-dialog/fesm2022/index.mjs +236 -114
- package/components/dialogs/confirm-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/confirm-dialog/types/index.d.ts +34 -29
- package/components/dialogs/default/bundles/index.umd.js +509 -373
- package/components/dialogs/default/fesm2022/index.mjs +485 -354
- package/components/dialogs/default/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/default/types/index.d.ts +129 -86
- package/components/dialogs/design-dialog/bundles/index.umd.js +320 -142
- package/components/dialogs/design-dialog/fesm2022/index.mjs +305 -132
- package/components/dialogs/design-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/design-dialog/types/index.d.ts +31 -20
- package/components/dialogs/iframe-dialog/bundles/index.umd.js +258 -111
- package/components/dialogs/iframe-dialog/fesm2022/index.mjs +245 -105
- package/components/dialogs/iframe-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/iframe-dialog/types/index.d.ts +27 -22
- package/components/dialogs/login-dialog/bundles/index.umd.js +139 -106
- package/components/dialogs/login-dialog/fesm2022/index.mjs +125 -97
- package/components/dialogs/login-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/login-dialog/types/index.d.ts +27 -26
- package/components/dialogs/partial-dialog/bundles/index.umd.js +302 -149
- package/components/dialogs/partial-dialog/fesm2022/index.mjs +289 -143
- package/components/dialogs/partial-dialog/fesm2022/index.mjs.map +1 -1
- package/components/dialogs/partial-dialog/types/index.d.ts +37 -32
- package/components/input/base-form/bundles/index.umd.js +143 -139
- package/components/input/base-form/fesm2022/index.mjs +129 -130
- package/components/input/base-form/fesm2022/index.mjs.map +1 -1
- package/components/input/base-form/types/index.d.ts +28 -29
- package/components/input/base-form-custom/bundles/index.umd.js +107 -121
- package/components/input/base-form-custom/fesm2022/index.mjs +88 -107
- package/components/input/base-form-custom/fesm2022/index.mjs.map +1 -1
- package/components/input/base-form-custom/types/index.d.ts +23 -26
- package/components/input/button/bundles/index.umd.js +177 -89
- package/components/input/button/fesm2022/index.mjs +158 -75
- package/components/input/button/fesm2022/index.mjs.map +1 -1
- package/components/input/button/types/index.d.ts +24 -25
- package/components/input/button-group/bundles/index.umd.js +110 -72
- package/components/input/button-group/fesm2022/index.mjs +90 -57
- package/components/input/button-group/fesm2022/index.mjs.map +1 -1
- package/components/input/button-group/types/index.d.ts +13 -14
- package/components/input/calendar/bundles/index.umd.js +615 -647
- package/components/input/calendar/fesm2022/index.mjs +596 -649
- package/components/input/calendar/fesm2022/index.mjs.map +1 -1
- package/components/input/calendar/types/index.d.ts +130 -131
- package/components/input/caption-position/bundles/index.umd.js +175 -188
- package/components/input/caption-position/fesm2022/index.mjs +159 -177
- package/components/input/caption-position/fesm2022/index.mjs.map +1 -1
- package/components/input/caption-position/types/index.d.ts +31 -34
- package/components/input/checkbox/bundles/index.umd.js +339 -200
- package/components/input/checkbox/fesm2022/index.mjs +319 -185
- package/components/input/checkbox/fesm2022/index.mjs.map +1 -1
- package/components/input/checkbox/types/index.d.ts +46 -41
- package/components/input/checkboxset/bundles/index.umd.js +256 -170
- package/components/input/checkboxset/fesm2022/index.mjs +242 -161
- package/components/input/checkboxset/fesm2022/index.mjs.map +1 -1
- package/components/input/checkboxset/types/index.d.ts +26 -27
- package/components/input/chips/bundles/index.umd.js +721 -733
- package/components/input/chips/fesm2022/index.mjs +706 -723
- package/components/input/chips/fesm2022/index.mjs.map +1 -1
- package/components/input/chips/types/index.d.ts +101 -90
- package/components/input/color-picker/bundles/index.umd.js +312 -137
- package/components/input/color-picker/fesm2022/index.mjs +296 -126
- package/components/input/color-picker/fesm2022/index.mjs.map +1 -1
- package/components/input/color-picker/types/index.d.ts +35 -36
- package/components/input/composite/bundles/index.umd.js +127 -112
- package/components/input/composite/fesm2022/index.mjs +106 -96
- package/components/input/composite/fesm2022/index.mjs.map +1 -1
- package/components/input/composite/types/index.d.ts +26 -27
- package/components/input/currency/bundles/index.umd.js +237 -104
- package/components/input/currency/fesm2022/index.mjs +219 -91
- package/components/input/currency/fesm2022/index.mjs.map +1 -1
- package/components/input/currency/types/index.d.ts +30 -31
- package/components/input/dataset-aware-form/bundles/index.umd.js +298 -346
- package/components/input/dataset-aware-form/fesm2022/index.mjs +286 -339
- package/components/input/dataset-aware-form/fesm2022/index.mjs.map +1 -1
- package/components/input/dataset-aware-form/types/index.d.ts +80 -80
- package/components/input/epoch/base-date-time/bundles/index.umd.js +809 -1081
- package/components/input/epoch/base-date-time/fesm2022/index.mjs +796 -1073
- package/components/input/epoch/base-date-time/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/base-date-time/types/index.d.ts +244 -247
- package/components/input/epoch/date/bundles/index.umd.js +619 -513
- package/components/input/epoch/date/fesm2022/index.mjs +604 -503
- package/components/input/epoch/date/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/date/types/index.d.ts +63 -64
- package/components/input/epoch/date-time/bundles/index.umd.js +682 -511
- package/components/input/epoch/date-time/fesm2022/index.mjs +672 -506
- package/components/input/epoch/date-time/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/date-time/types/index.d.ts +111 -112
- package/components/input/epoch/date-time-picker/bundles/index.umd.js +417 -321
- package/components/input/epoch/date-time-picker/fesm2022/index.mjs +405 -314
- package/components/input/epoch/date-time-picker/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/date-time-picker/types/index.d.ts +135 -80
- package/components/input/epoch/picker/bundles/index.umd.js +201 -148
- package/components/input/epoch/picker/fesm2022/index.mjs +183 -135
- package/components/input/epoch/picker/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/picker/types/index.d.ts +46 -38
- package/components/input/epoch/time/bundles/index.umd.js +534 -392
- package/components/input/epoch/time/fesm2022/index.mjs +523 -386
- package/components/input/epoch/time/fesm2022/index.mjs.map +1 -1
- package/components/input/epoch/time/types/index.d.ts +107 -108
- package/components/input/file-upload/bundles/index.umd.js +500 -477
- package/components/input/file-upload/fesm2022/index.mjs +484 -466
- package/components/input/file-upload/fesm2022/index.mjs.map +1 -1
- package/components/input/file-upload/types/index.d.ts +110 -109
- package/components/input/number/bundles/index.umd.js +241 -101
- package/components/input/number/fesm2022/index.mjs +224 -89
- package/components/input/number/fesm2022/index.mjs.map +1 -1
- package/components/input/number/types/index.d.ts +28 -29
- package/components/input/radioset/bundles/index.umd.js +240 -156
- package/components/input/radioset/fesm2022/index.mjs +226 -147
- package/components/input/radioset/fesm2022/index.mjs.map +1 -1
- package/components/input/radioset/types/index.d.ts +25 -26
- package/components/input/rating/bundles/index.umd.js +353 -266
- package/components/input/rating/fesm2022/index.mjs +337 -255
- package/components/input/rating/fesm2022/index.mjs.map +1 -1
- package/components/input/rating/types/index.d.ts +52 -53
- package/components/input/select/bundles/index.umd.js +295 -217
- package/components/input/select/fesm2022/index.mjs +280 -207
- package/components/input/select/fesm2022/index.mjs.map +1 -1
- package/components/input/select/types/index.d.ts +38 -39
- package/components/input/slider/bundles/index.umd.js +316 -197
- package/components/input/slider/fesm2022/index.mjs +297 -183
- package/components/input/slider/fesm2022/index.mjs.map +1 -1
- package/components/input/slider/types/index.d.ts +43 -44
- package/components/input/switch/bundles/index.umd.js +257 -219
- package/components/input/switch/fesm2022/index.mjs +243 -210
- package/components/input/switch/fesm2022/index.mjs.map +1 -1
- package/components/input/switch/types/index.d.ts +34 -35
- package/components/input/text/bundles/index.umd.js +1585 -1120
- package/components/input/text/fesm2022/index.mjs +1542 -1082
- package/components/input/text/fesm2022/index.mjs.map +1 -1
- package/components/input/text/types/index.d.ts +313 -310
- package/components/input/textarea/bundles/index.umd.js +224 -100
- package/components/input/textarea/fesm2022/index.mjs +207 -88
- package/components/input/textarea/fesm2022/index.mjs.map +1 -1
- package/components/input/textarea/types/index.d.ts +32 -33
- package/components/navigation/breadcrumb/bundles/index.umd.js +205 -131
- package/components/navigation/breadcrumb/fesm2022/index.mjs +188 -118
- package/components/navigation/breadcrumb/fesm2022/index.mjs.map +1 -1
- package/components/navigation/breadcrumb/types/index.d.ts +29 -28
- package/components/navigation/menu/bundles/index.umd.js +1461 -950
- package/components/navigation/menu/fesm2022/index.mjs +1416 -910
- package/components/navigation/menu/fesm2022/index.mjs.map +1 -1
- package/components/navigation/menu/types/index.d.ts +220 -193
- package/components/navigation/navbar/bundles/index.umd.js +172 -79
- package/components/navigation/navbar/fesm2022/index.mjs +155 -67
- package/components/navigation/navbar/fesm2022/index.mjs.map +1 -1
- package/components/navigation/navbar/types/index.d.ts +19 -20
- package/components/navigation/popover/bundles/index.umd.js +543 -519
- package/components/navigation/popover/fesm2022/index.mjs +524 -505
- package/components/navigation/popover/fesm2022/index.mjs.map +1 -1
- package/components/navigation/popover/types/index.d.ts +86 -86
- package/components/page/default/bundles/index.umd.js +634 -451
- package/components/page/default/fesm2022/index.mjs +600 -422
- package/components/page/default/fesm2022/index.mjs.map +1 -1
- package/components/page/default/types/index.d.ts +123 -119
- package/components/page/footer/bundles/index.umd.js +91 -63
- package/components/page/footer/fesm2022/index.mjs +71 -48
- package/components/page/footer/fesm2022/index.mjs.map +1 -1
- package/components/page/footer/types/index.d.ts +11 -12
- package/components/page/header/bundles/index.umd.js +96 -59
- package/components/page/header/fesm2022/index.mjs +76 -44
- package/components/page/header/fesm2022/index.mjs.map +1 -1
- package/components/page/header/types/index.d.ts +12 -13
- package/components/page/left-panel/bundles/index.umd.js +405 -407
- package/components/page/left-panel/fesm2022/index.mjs +386 -393
- package/components/page/left-panel/fesm2022/index.mjs.map +1 -1
- package/components/page/left-panel/types/index.d.ts +47 -40
- package/components/page/right-panel/bundles/index.umd.js +115 -78
- package/components/page/right-panel/fesm2022/index.mjs +96 -64
- package/components/page/right-panel/fesm2022/index.mjs.map +1 -1
- package/components/page/right-panel/types/index.d.ts +14 -13
- package/components/page/top-nav/bundles/index.umd.js +91 -60
- package/components/page/top-nav/fesm2022/index.mjs +73 -47
- package/components/page/top-nav/fesm2022/index.mjs.map +1 -1
- package/components/page/top-nav/types/index.d.ts +11 -12
- package/components/prefab/bundles/index.umd.js +253 -173
- package/components/prefab/fesm2022/index.mjs +233 -158
- package/components/prefab/fesm2022/index.mjs.map +1 -1
- package/components/prefab/types/index.d.ts +35 -33
- package/core/bundles/index.umd.js +4466 -5642
- package/core/fesm2022/index.mjs +3997 -5202
- package/core/fesm2022/index.mjs.map +1 -1
- package/core/types/index.d.ts +1785 -1808
- package/http/bundles/index.umd.js +339 -413
- package/http/fesm2022/index.mjs +323 -402
- package/http/fesm2022/index.mjs.map +1 -1
- package/http/types/index.d.ts +107 -112
- package/locales/moment/am-et.js +73 -0
- package/locales/moment/bm.js +2 -0
- package/locales/moment/ca.js +1 -1
- package/locales/moment/de-at.js +29 -1
- package/locales/moment/de-ch.js +29 -1
- package/locales/moment/de.js +29 -1
- package/locales/moment/hu.js +3 -3
- package/locales/moment/id.js +12 -1
- package/locales/moment/ka.js +1 -1
- package/locales/moment/mk.js +0 -1
- package/locales/moment/nl-be.js +1 -1
- package/locales/moment/pl.js +1 -1
- package/locales/moment/ps.js +188 -0
- package/locales/moment/pt-br.js +14 -6
- package/locales/moment/sv.js +1 -1
- package/locales/moment/sw.js +56 -14
- package/locales/moment/uk.js +5 -4
- package/locales/moment/uz-latn.js +1 -1
- package/locales/moment/uz.js +1 -1
- package/npm-shrinkwrap.json +2 -2
- package/oAuth/bundles/index.umd.js +326 -483
- package/oAuth/fesm2022/index.mjs +267 -429
- package/oAuth/fesm2022/index.mjs.map +1 -1
- package/oAuth/types/index.d.ts +22 -26
- package/package-lock.json +2 -2
- package/package.json +1 -1
- package/runtime/base/bundles/index.umd.js +6380 -6093
- package/runtime/base/fesm2022/index.mjs +6368 -6107
- package/runtime/base/fesm2022/index.mjs.map +1 -1
- package/runtime/base/types/index.d.ts +1336 -1359
- package/runtime/dynamic/bundles/index.umd.js +1215 -851
- package/runtime/dynamic/fesm2022/index.mjs +1253 -898
- package/runtime/dynamic/fesm2022/index.mjs.map +1 -1
- package/runtime/dynamic/types/index.d.ts +140 -128
- package/scripts/datatable/datatable.js +20 -30
- package/security/bundles/index.umd.js +297 -438
- package/security/fesm2022/index.mjs +282 -443
- package/security/fesm2022/index.mjs.map +1 -1
- package/security/types/index.d.ts +127 -130
- package/swipey/bundles/index.umd.js +57 -48
- package/swipey/fesm2022/index.mjs +55 -50
- package/swipey/fesm2022/index.mjs.map +1 -1
- package/swipey/types/index.d.ts +19 -21
- package/transpiler/bundles/index.umd.js +1174 -811
- package/transpiler/fesm2022/index.mjs +1109 -757
- package/transpiler/fesm2022/index.mjs.map +1 -1
- package/transpiler/types/index.d.ts +32 -36
- package/variables/bundles/index.umd.js +2226 -3245
- package/variables/fesm2022/index.mjs +2117 -3237
- package/variables/fesm2022/index.mjs.map +1 -1
- package/variables/types/index.d.ts +410 -393
- package/build-task/.npmignore +0 -2
- package/components/advanced/carousel/.npmignore +0 -2
- package/components/advanced/custom/.npmignore +0 -2
- package/components/advanced/login/.npmignore +0 -2
- package/components/advanced/marquee/.npmignore +0 -2
- package/components/base/.npmignore +0 -2
- package/components/basic/anchor/.npmignore +0 -2
- package/components/basic/audio/.npmignore +0 -2
- package/components/basic/html/.npmignore +0 -2
- package/components/basic/icon/.npmignore +0 -2
- package/components/basic/iframe/.npmignore +0 -2
- package/components/basic/label/.npmignore +0 -2
- package/components/basic/picture/.npmignore +0 -2
- package/components/basic/progress/progress-bar/.npmignore +0 -2
- package/components/basic/progress/progress-circle/.npmignore +0 -2
- package/components/basic/progress/progress-utils/.npmignore +0 -2
- package/components/basic/rich-text-editor/.npmignore +0 -2
- package/components/basic/search/.npmignore +0 -2
- package/components/basic/spinner/.npmignore +0 -2
- package/components/basic/tree/.npmignore +0 -2
- package/components/basic/video/.npmignore +0 -2
- package/components/chart/.npmignore +0 -2
- package/components/containers/accordion/.npmignore +0 -2
- package/components/containers/layout-grid/.npmignore +0 -2
- package/components/containers/linear-layout/.npmignore +0 -2
- package/components/containers/panel/.npmignore +0 -2
- package/components/containers/tabs/.npmignore +0 -2
- package/components/containers/tile/.npmignore +0 -2
- package/components/containers/wizard/.npmignore +0 -2
- package/components/data/card/.npmignore +0 -2
- package/components/data/form/.npmignore +0 -2
- package/components/data/list/.npmignore +0 -2
- package/components/data/live-table/.npmignore +0 -2
- package/components/data/pagination/.npmignore +0 -2
- package/components/data/table/.npmignore +0 -2
- package/components/dialogs/alert-dialog/.npmignore +0 -2
- package/components/dialogs/confirm-dialog/.npmignore +0 -2
- package/components/dialogs/default/.npmignore +0 -2
- package/components/dialogs/design-dialog/.npmignore +0 -2
- package/components/dialogs/iframe-dialog/.npmignore +0 -2
- package/components/dialogs/login-dialog/.npmignore +0 -2
- package/components/dialogs/partial-dialog/.npmignore +0 -2
- package/components/input/base-form/.npmignore +0 -2
- package/components/input/base-form-custom/.npmignore +0 -2
- package/components/input/button/.npmignore +0 -2
- package/components/input/button-group/.npmignore +0 -2
- package/components/input/calendar/.npmignore +0 -2
- package/components/input/caption-position/.npmignore +0 -2
- package/components/input/checkbox/.npmignore +0 -2
- package/components/input/checkboxset/.npmignore +0 -2
- package/components/input/chips/.npmignore +0 -2
- package/components/input/color-picker/.npmignore +0 -2
- package/components/input/composite/.npmignore +0 -2
- package/components/input/currency/.npmignore +0 -2
- package/components/input/dataset-aware-form/.npmignore +0 -2
- package/components/input/epoch/base-date-time/.npmignore +0 -2
- package/components/input/epoch/date/.npmignore +0 -2
- package/components/input/epoch/date-time/.npmignore +0 -2
- package/components/input/epoch/date-time-picker/.npmignore +0 -2
- package/components/input/epoch/picker/.npmignore +0 -2
- package/components/input/epoch/time/.npmignore +0 -2
- package/components/input/file-upload/.npmignore +0 -2
- package/components/input/number/.npmignore +0 -2
- package/components/input/radioset/.npmignore +0 -2
- package/components/input/rating/.npmignore +0 -2
- package/components/input/select/.npmignore +0 -2
- package/components/input/slider/.npmignore +0 -2
- package/components/input/switch/.npmignore +0 -2
- package/components/input/text/.npmignore +0 -2
- package/components/input/textarea/.npmignore +0 -2
- package/components/navigation/breadcrumb/.npmignore +0 -2
- package/components/navigation/menu/.npmignore +0 -2
- package/components/navigation/navbar/.npmignore +0 -2
- package/components/navigation/popover/.npmignore +0 -2
- package/components/page/default/.npmignore +0 -2
- package/components/page/footer/.npmignore +0 -2
- package/components/page/header/.npmignore +0 -2
- package/components/page/left-panel/.npmignore +0 -2
- package/components/page/right-panel/.npmignore +0 -2
- package/components/page/top-nav/.npmignore +0 -2
- package/components/prefab/.npmignore +0 -2
- package/core/.npmignore +0 -2
- package/http/.npmignore +0 -2
- package/oAuth/.npmignore +0 -2
- package/runtime/base/.npmignore +0 -2
- package/runtime/dynamic/.npmignore +0 -2
- package/security/.npmignore +0 -2
- package/swipey/.npmignore +0 -2
- package/transpiler/.npmignore +0 -2
- package/variables/.npmignore +0 -2
|
@@ -1,1087 +1,1121 @@
|
|
|
1
|
-
import * as i2 from
|
|
2
|
-
import { CommonModule } from
|
|
3
|
-
import * as i3 from
|
|
4
|
-
import { FormsModule,
|
|
5
|
-
import * as i0 from
|
|
6
|
-
import {
|
|
7
|
-
import { Observable,
|
|
8
|
-
import { filter
|
|
9
|
-
import * as i4 from
|
|
10
|
-
import {
|
|
11
|
-
import * as i1 from
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import { DatasetAwareFormComponent } from
|
|
15
|
-
import {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
1
|
+
import * as i2 from "@angular/common";
|
|
2
|
+
import { CommonModule } from "@angular/common";
|
|
3
|
+
import * as i3 from "@angular/forms";
|
|
4
|
+
import { FormsModule, NG_VALIDATORS, NG_VALUE_ACCESSOR } from "@angular/forms";
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
import { Attribute, ChangeDetectionStrategy, Component, Directive, ElementRef, Inject, Optional, ViewChild, ViewChildren, inject } from "@angular/core";
|
|
7
|
+
import { Observable, from, of } from "rxjs";
|
|
8
|
+
import { filter, mergeMap } from "rxjs/operators";
|
|
9
|
+
import * as i4 from "ngx-bootstrap/typeahead";
|
|
10
|
+
import { TypeaheadDirective, TypeaheadModule } from "ngx-bootstrap/typeahead";
|
|
11
|
+
import * as i1 from "@wm/core";
|
|
12
|
+
import { AppConstants, DataSource, FormWidgetType, addClass, adjustContainerPosition, findValueOf, getClonedObject, isDefined, isMobile, toBoolean } from "@wm/core";
|
|
13
|
+
import { ALLFIELDS, ItemTemplateDirective, PROP_ANY, PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, PartialContainerDirective, PartialParamHandlerDirective, TextContentDirective, WmAppIconComponent, convertDataToObject, extractDataAsArray, getContainerTargetClass, getUniqObjsByDataField, interpolateBindExpressions, provideAs, provideAsWidgetRef, register, registerFormWidget, styler, transformFormData } from "@wm/components/base";
|
|
14
|
+
import { DatasetAwareFormComponent } from "@wm/components/input/dataset-aware-form";
|
|
15
|
+
import { assign, debounce, endsWith, filter as filter$1, find, get, includes, indexOf, isArray, isEmpty, isEqual, isNumber, isObject, isUndefined, map, set, slice, split, startsWith, toLower, toString, trim, values } from "lodash-es";
|
|
16
|
+
var ScrollableDirective = class ScrollableDirective {
|
|
17
|
+
constructor(inj) {
|
|
18
|
+
this.searchRef = inject(SearchComponent);
|
|
19
|
+
this.elementRef = inj.get(ElementRef);
|
|
20
|
+
}
|
|
21
|
+
ngAfterContentInit() {
|
|
22
|
+
this.boundNotifyParent = this.notifyParent.bind(this);
|
|
23
|
+
this.elementRef.nativeElement.addEventListener("scroll", this.boundNotifyParent);
|
|
24
|
+
this.searchRef.dropdownEl = $(this.elementRef.nativeElement);
|
|
25
|
+
this.searchRef.onDropdownOpen();
|
|
26
|
+
}
|
|
27
|
+
ngAfterViewInit() {
|
|
28
|
+
if (!this.searchRef.isMobileAutoComplete()) {
|
|
29
|
+
const typeAheadInput = this.searchRef.$element.find("input").first();
|
|
30
|
+
this.searchRef.dropdownEl.width(typeAheadInput.outerWidth());
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
notifyParent(evt) {
|
|
34
|
+
this.searchRef.onScroll(this.elementRef.nativeElement, evt);
|
|
35
|
+
}
|
|
36
|
+
ngOnDestroy() {
|
|
37
|
+
if (this.elementRef?.nativeElement && this.boundNotifyParent) {
|
|
38
|
+
this.elementRef.nativeElement.removeEventListener("scroll", this.boundNotifyParent);
|
|
39
|
+
this.boundNotifyParent = null;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
static {
|
|
43
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
44
|
+
minVersion: "12.0.0",
|
|
45
|
+
version: "22.2.1",
|
|
46
|
+
ngImport: i0,
|
|
47
|
+
type: ScrollableDirective,
|
|
48
|
+
deps: [{ token: i0.Injector }],
|
|
49
|
+
target: i0.ɵɵFactoryTarget.Directive
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
static {
|
|
53
|
+
this.ɵdir = i0.ɵɵngDeclareDirective({
|
|
54
|
+
minVersion: "14.0.0",
|
|
55
|
+
version: "22.2.1",
|
|
56
|
+
type: ScrollableDirective,
|
|
57
|
+
isStandalone: true,
|
|
58
|
+
selector: "[scrollableHandler]",
|
|
59
|
+
ngImport: i0
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
};
|
|
63
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
64
|
+
minVersion: "12.0.0",
|
|
65
|
+
version: "22.2.1",
|
|
66
|
+
ngImport: i0,
|
|
67
|
+
type: ScrollableDirective,
|
|
68
|
+
decorators: [{
|
|
69
|
+
type: Directive,
|
|
70
|
+
args: [{
|
|
71
|
+
standalone: true,
|
|
72
|
+
selector: "[scrollableHandler]"
|
|
73
|
+
}]
|
|
74
|
+
}],
|
|
75
|
+
ctorParameters: () => [{ type: i0.Injector }]
|
|
76
|
+
});
|
|
77
|
+
const searchProps = /* @__PURE__ */ new Map([
|
|
78
|
+
["casesensitive", {
|
|
79
|
+
value: false,
|
|
80
|
+
...PROP_BOOLEAN
|
|
81
|
+
}],
|
|
82
|
+
["class", PROP_STRING],
|
|
83
|
+
["datacompletemsg", {
|
|
84
|
+
value: "No more data to load",
|
|
85
|
+
...PROP_STRING
|
|
86
|
+
}],
|
|
87
|
+
["datafield", {
|
|
88
|
+
value: "All Fields",
|
|
89
|
+
...PROP_STRING
|
|
90
|
+
}],
|
|
91
|
+
["dataoptions", PROP_ANY],
|
|
92
|
+
["dataset", PROP_ANY],
|
|
93
|
+
["datasource", PROP_ANY],
|
|
94
|
+
["datavalue", PROP_STRING],
|
|
95
|
+
["datavaluesource", PROP_ANY],
|
|
96
|
+
["dateformat", PROP_STRING],
|
|
97
|
+
["disabled", PROP_BOOLEAN],
|
|
98
|
+
["displayimagesrc", PROP_STRING],
|
|
99
|
+
["displaylabel", PROP_STRING],
|
|
100
|
+
["displayexpression", PROP_STRING],
|
|
101
|
+
["dropup", PROP_BOOLEAN],
|
|
102
|
+
["groupby", PROP_STRING],
|
|
103
|
+
["hint", PROP_STRING],
|
|
104
|
+
["arialabel", PROP_STRING],
|
|
105
|
+
["imagewidth", {
|
|
106
|
+
value: "16px",
|
|
107
|
+
...PROP_STRING
|
|
108
|
+
}],
|
|
109
|
+
["limit", PROP_NUMBER],
|
|
110
|
+
["loadingdatamsg", {
|
|
111
|
+
value: "Loading items...",
|
|
112
|
+
...PROP_STRING
|
|
113
|
+
}],
|
|
114
|
+
["match", PROP_STRING],
|
|
115
|
+
["matchmode", PROP_STRING],
|
|
116
|
+
["minchars", PROP_NUMBER],
|
|
117
|
+
["name", PROP_STRING],
|
|
118
|
+
["navsearchbar", {
|
|
119
|
+
value: false,
|
|
120
|
+
...PROP_BOOLEAN
|
|
121
|
+
}],
|
|
122
|
+
["orderby", PROP_STRING],
|
|
123
|
+
["placeholder", {
|
|
124
|
+
value: "Search",
|
|
125
|
+
...PROP_STRING
|
|
126
|
+
}],
|
|
127
|
+
["position", PROP_STRING],
|
|
128
|
+
["query", PROP_STRING],
|
|
129
|
+
["readonly", PROP_BOOLEAN],
|
|
130
|
+
["required", PROP_BOOLEAN],
|
|
131
|
+
["searchkey", PROP_STRING],
|
|
132
|
+
["searchon", {
|
|
133
|
+
value: "typing",
|
|
134
|
+
...PROP_STRING
|
|
135
|
+
}],
|
|
136
|
+
["shortcutkey", PROP_STRING],
|
|
137
|
+
["show", {
|
|
138
|
+
value: true,
|
|
139
|
+
...PROP_BOOLEAN
|
|
140
|
+
}],
|
|
141
|
+
["showclear", {
|
|
142
|
+
value: false,
|
|
143
|
+
...PROP_BOOLEAN
|
|
144
|
+
}],
|
|
145
|
+
["showsearchicon", PROP_BOOLEAN],
|
|
146
|
+
["tabindex", {
|
|
147
|
+
value: 0,
|
|
148
|
+
...PROP_NUMBER
|
|
149
|
+
}],
|
|
150
|
+
["type", {
|
|
151
|
+
value: "search",
|
|
152
|
+
...PROP_STRING
|
|
153
|
+
}],
|
|
154
|
+
["debouncetime", {
|
|
155
|
+
value: 250,
|
|
156
|
+
...PROP_NUMBER
|
|
157
|
+
}],
|
|
158
|
+
["width", PROP_STRING],
|
|
159
|
+
["clearsearchiconclass", {
|
|
160
|
+
value: "wi wi-close",
|
|
161
|
+
...PROP_STRING
|
|
162
|
+
}],
|
|
163
|
+
["backsearchiconclass", {
|
|
164
|
+
value: "wi wi-arrow-left",
|
|
165
|
+
...PROP_STRING
|
|
166
|
+
}],
|
|
167
|
+
["searchiconclass", {
|
|
168
|
+
value: "wm-sl-l sl-search",
|
|
169
|
+
...PROP_STRING
|
|
170
|
+
}],
|
|
171
|
+
["clearsearchiconurl", PROP_STRING],
|
|
172
|
+
["backsearchiconurl", PROP_STRING],
|
|
173
|
+
["searchiconurl", PROP_STRING]
|
|
107
174
|
]);
|
|
108
175
|
const registerProps = () => {
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
176
|
+
register("wm-search", searchProps);
|
|
177
|
+
registerFormWidget(FormWidgetType.AUTOCOMPLETE, new Map(searchProps));
|
|
178
|
+
registerFormWidget(FormWidgetType.TYPEAHEAD, new Map(searchProps));
|
|
112
179
|
};
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
], viewQueries: [{ propertyName: "typeahead", first: true, predicate: TypeaheadDirective, descendants: true }, { propertyName: "ulElement", first: true, predicate: ["ulElement"], descendants: true }, { propertyName: "liElements", predicate: ["liElements"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<ng-template #customItemTemplate let-model=\"item\" let-index=\"index\" let-query=\"query\" let-match=\"match\">\n <!-- Default item template -->\n @if (!content) {\n <a>\n @if (model.imgSrc) {\n <img [src]=\"model.imgSrc\" alt=\"Search\" [style.width]=\"imagewidth\">\n }\n <span [title]=\"model.label\" [innerHtml]=\"highlight(match, query) || model.label\"></span>\n </a>\n }\n <!-- Custom partial template -->\n @if (content) {\n <a [ngClass]=\"{customTemplate: content}\" partialContainer [wmItemTemplate]=\"content\" [userComponentParams]=\"match.item\">\n <div partial-container-target></div>\n </a>\n }\n</ng-template>\n\n<ng-template #customListTemplate let-matches=\"matches\" let-itemTemplate=\"itemTemplate\" let-query=\"query\">\n <ul #ulElement class=\"app-search dropdown-menu\" scrollableHandler>\n @for (match of matches; track match; let i = $index) {\n <li #liElements [ngClass]=\"{active: typeaheadContainer && typeaheadContainer.isActive(match), 'list-group-header': match && match.isHeader()}\"\n (mouseenter)=\"typeaheadContainer.selectActive(match);\"\n (click)=\"match && !match.isHeader() && typeaheadContainer.selectMatch(match, $event); $typeaheadEvent = $event; notifySubscriber();\">\n <!-- itemTemplate comes from the <input> -->\n @if (match.isHeader()) {\n <h4 class=\"group-title\">{{match.value}}</h4>\n }\n @if (!match.isHeader()) {\n <ng-container [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{item: match.item, index: i, match: match, query: query}\">\n </ng-container>\n }\n </li>\n }\n <div class=\"status\" [hidden]=\"_loadingItems || !(datacompletemsg && dataProvider?.isLastPage)\">\n <span [textContent]=\"datacompletemsg\"></span>\n </div>\n <div class=\"status\" [hidden]=\"!_loadingItems\">\n <i class=\"fa fa-circle-o-notch fa-spin\"></i>\n <span [textContent]=\"loadingdatamsg\"></span>\n </div>\n </ul>\n</ng-template>\n\n<!--This template is for search inside mobile navbar.-->\n@if (navsearchbar) {\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n container=\"body\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event)\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event);\"\n (focusout)=\"onFocusOut()\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [dropup]=\"dropup\"\n [tabindex]=\"tabindex\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\"/>\n <i class=\"btn-close wi wi-cancel\" [hidden]=\"!showClosebtn\" (click)=\"clearSearch($event);\"></i>\n} @else {\n <button type=\"button\" class=\"btn btn-icon form-control-feedback back-btn\" aria-hidden=\"true\" (click)=\"closeSearch()\">\n <wm-app-icon [iconclass]=\"backsearchiconclass\" [iconurl]=\"backsearchiconurl\" alt=\"Back\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Back button</span>\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n [container]=\"containerTarget || '.wm-app'\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event); onFocusOut()\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event)\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [tabindex]=\"tabindex\"\n [dropup]=\"dropup\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\">\n <input class=\"model-holder\" ng-model=\"proxyModel\" ng-required=\"required\" tabindex=\"-1\" aria-hidden=\"true\">\n @if (_loadingItems) {\n <span aria-hidden=\"true\" class=\"fa fa-circle-o-notch fa-spin form-control-feedback\"></span>\n }\n <button type=\"button\" class=\"btn btn-icon form-control-feedback clear-btn\" [ngClass]=\"{'show-btn': isQueryEntered()}\" (click)=\"clearSearch($event, true)\">\n <wm-app-icon [iconclass]=\"clearsearchiconclass\" [iconurl]=\"clearsearchiconurl\" alt=\"Clear\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Clear button</span>\n @if (showsearchicon) {\n <span [ngClass]=\"{'disabled': disabled}\" class=\"input-group-addon\">\n <form>\n <button title=\"Search\" [disabled]=\"disabled\" class=\"app-search-button btn btn-icon\" type=\"submit\"\n (click)=\"onSearchSelect($event)\">\n <wm-app-icon [iconclass]=\"searchiconclass\" [iconurl]=\"searchiconurl\" alt=\"Search\"></wm-app-icon>\n </button>\n </form>\n </span>\n }\n }\n <!--This template is for both web and fullscreen mode in mobile.-->\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.NgForm, selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: ScrollableDirective, selector: "[scrollableHandler]" }, { kind: "ngmodule", type: TypeaheadModule }, { kind: "directive", type: i4.TypeaheadDirective, selector: "[typeahead]", inputs: ["typeahead", "typeaheadMinLength", "adaptivePosition", "isAnimated", "typeaheadWaitMs", "typeaheadOptionsLimit", "typeaheadOptionField", "typeaheadGroupField", "typeaheadOrderBy", "typeaheadAsync", "typeaheadLatinize", "typeaheadSingleWords", "typeaheadWordDelimiters", "typeaheadMultipleSearch", "typeaheadMultipleSearchDelimiters", "typeaheadPhraseDelimiters", "typeaheadItemTemplate", "optionsListTemplate", "typeaheadScrollable", "typeaheadOptionsInScrollableView", "typeaheadHideResultsOnBlur", "typeaheadSelectFirstItem", "typeaheadIsFirstItemActive", "container", "dropup"], outputs: ["typeaheadLoading", "typeaheadNoResults", "typeaheadOnSelect", "typeaheadOnPreview", "typeaheadOnBlur"], exportAs: ["bs-typeahead"] }, { kind: "directive", type: TextContentDirective, selector: "[textContent]", inputs: ["textContent"] }, { kind: "directive", type: ItemTemplateDirective, selector: "[wmItemTemplate]", inputs: ["userComponentParams", "wmItemTemplate"], exportAs: ["itemTemplateRef"] }, { kind: "directive", type: PartialParamHandlerDirective, selector: "[partialContainer]" }, { kind: "directive", type: PartialContainerDirective, selector: "[partialContainer]" }, { kind: "component", type: WmAppIconComponent, selector: "wm-app-icon", inputs: ["icon", "iconclass", "iconurl", "defaultIconClass", "defaultClasses", "iconStyle", "alt"] }] }); }
|
|
1052
|
-
}
|
|
1053
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.21", ngImport: i0, type: SearchComponent, decorators: [{
|
|
1054
|
-
type: Component,
|
|
1055
|
-
args: [{ standalone: true, imports: [CommonModule, FormsModule, ScrollableDirective, TypeaheadModule, TextContentDirective, ItemTemplateDirective, PartialParamHandlerDirective, PartialContainerDirective, WmAppIconComponent], selector: '[wmSearch]', providers: [
|
|
1056
|
-
provideAs(SearchComponent, NG_VALUE_ACCESSOR, true),
|
|
1057
|
-
provideAs(SearchComponent, NG_VALIDATORS, true),
|
|
1058
|
-
provideAsWidgetRef(SearchComponent)
|
|
1059
|
-
], template: "<ng-template #customItemTemplate let-model=\"item\" let-index=\"index\" let-query=\"query\" let-match=\"match\">\n <!-- Default item template -->\n @if (!content) {\n <a>\n @if (model.imgSrc) {\n <img [src]=\"model.imgSrc\" alt=\"Search\" [style.width]=\"imagewidth\">\n }\n <span [title]=\"model.label\" [innerHtml]=\"highlight(match, query) || model.label\"></span>\n </a>\n }\n <!-- Custom partial template -->\n @if (content) {\n <a [ngClass]=\"{customTemplate: content}\" partialContainer [wmItemTemplate]=\"content\" [userComponentParams]=\"match.item\">\n <div partial-container-target></div>\n </a>\n }\n</ng-template>\n\n<ng-template #customListTemplate let-matches=\"matches\" let-itemTemplate=\"itemTemplate\" let-query=\"query\">\n <ul #ulElement class=\"app-search dropdown-menu\" scrollableHandler>\n @for (match of matches; track match; let i = $index) {\n <li #liElements [ngClass]=\"{active: typeaheadContainer && typeaheadContainer.isActive(match), 'list-group-header': match && match.isHeader()}\"\n (mouseenter)=\"typeaheadContainer.selectActive(match);\"\n (click)=\"match && !match.isHeader() && typeaheadContainer.selectMatch(match, $event); $typeaheadEvent = $event; notifySubscriber();\">\n <!-- itemTemplate comes from the <input> -->\n @if (match.isHeader()) {\n <h4 class=\"group-title\">{{match.value}}</h4>\n }\n @if (!match.isHeader()) {\n <ng-container [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{item: match.item, index: i, match: match, query: query}\">\n </ng-container>\n }\n </li>\n }\n <div class=\"status\" [hidden]=\"_loadingItems || !(datacompletemsg && dataProvider?.isLastPage)\">\n <span [textContent]=\"datacompletemsg\"></span>\n </div>\n <div class=\"status\" [hidden]=\"!_loadingItems\">\n <i class=\"fa fa-circle-o-notch fa-spin\"></i>\n <span [textContent]=\"loadingdatamsg\"></span>\n </div>\n </ul>\n</ng-template>\n\n<!--This template is for search inside mobile navbar.-->\n@if (navsearchbar) {\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n container=\"body\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event)\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event);\"\n (focusout)=\"onFocusOut()\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [dropup]=\"dropup\"\n [tabindex]=\"tabindex\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\"/>\n <i class=\"btn-close wi wi-cancel\" [hidden]=\"!showClosebtn\" (click)=\"clearSearch($event);\"></i>\n} @else {\n <button type=\"button\" class=\"btn btn-icon form-control-feedback back-btn\" aria-hidden=\"true\" (click)=\"closeSearch()\">\n <wm-app-icon [iconclass]=\"backsearchiconclass\" [iconurl]=\"backsearchiconurl\" alt=\"Back\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Back button</span>\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n [container]=\"containerTarget || '.wm-app'\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event); onFocusOut()\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event)\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [tabindex]=\"tabindex\"\n [dropup]=\"dropup\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\">\n <input class=\"model-holder\" ng-model=\"proxyModel\" ng-required=\"required\" tabindex=\"-1\" aria-hidden=\"true\">\n @if (_loadingItems) {\n <span aria-hidden=\"true\" class=\"fa fa-circle-o-notch fa-spin form-control-feedback\"></span>\n }\n <button type=\"button\" class=\"btn btn-icon form-control-feedback clear-btn\" [ngClass]=\"{'show-btn': isQueryEntered()}\" (click)=\"clearSearch($event, true)\">\n <wm-app-icon [iconclass]=\"clearsearchiconclass\" [iconurl]=\"clearsearchiconurl\" alt=\"Clear\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Clear button</span>\n @if (showsearchicon) {\n <span [ngClass]=\"{'disabled': disabled}\" class=\"input-group-addon\">\n <form>\n <button title=\"Search\" [disabled]=\"disabled\" class=\"app-search-button btn btn-icon\" type=\"submit\"\n (click)=\"onSearchSelect($event)\">\n <wm-app-icon [iconclass]=\"searchiconclass\" [iconurl]=\"searchiconurl\" alt=\"Search\"></wm-app-icon>\n </button>\n </form>\n </span>\n }\n }\n <!--This template is for both web and fullscreen mode in mobile.-->\n" }]
|
|
1060
|
-
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1.App }, { type: undefined, decorators: [{
|
|
1061
|
-
type: Attribute,
|
|
1062
|
-
args: ['datavalue.bind']
|
|
1063
|
-
}] }, { type: undefined, decorators: [{
|
|
1064
|
-
type: Attribute,
|
|
1065
|
-
args: ['dataset.bind']
|
|
1066
|
-
}] }, { type: undefined, decorators: [{
|
|
1067
|
-
type: Inject,
|
|
1068
|
-
args: ['EXPLICIT_CONTEXT']
|
|
1069
|
-
}, {
|
|
1070
|
-
type: Optional
|
|
1071
|
-
}] }], propDecorators: { typeahead: [{
|
|
1072
|
-
type: ViewChild,
|
|
1073
|
-
args: [TypeaheadDirective]
|
|
1074
|
-
}], ulElement: [{
|
|
1075
|
-
type: ViewChild,
|
|
1076
|
-
args: ['ulElement']
|
|
1077
|
-
}], liElements: [{
|
|
1078
|
-
type: ViewChildren,
|
|
1079
|
-
args: ['liElements']
|
|
1080
|
-
}] } });
|
|
1081
|
-
|
|
1082
|
-
/**
|
|
1083
|
-
* Generated bundle index. Do not edit.
|
|
1084
|
-
*/
|
|
1085
|
-
|
|
180
|
+
var LocalDataProvider = class {
|
|
181
|
+
applyFilter(entry, queryText, filtername) {
|
|
182
|
+
entry = isNumber(entry) ? entry.toString() : entry;
|
|
183
|
+
if (includes(filtername, "start")) return startsWith(entry, queryText);
|
|
184
|
+
else if (includes(filtername, "end")) return endsWith(entry, queryText);
|
|
185
|
+
else if (includes(filtername, "exact")) return isEqual(entry, queryText);
|
|
186
|
+
return includes(entry, queryText);
|
|
187
|
+
}
|
|
188
|
+
filter(config) {
|
|
189
|
+
const entries = config.dataset;
|
|
190
|
+
let casesensitive = config.casesensitive;
|
|
191
|
+
const matchMode = config.matchMode;
|
|
192
|
+
if (matchMode && !includes(matchMode, "ignorecase")) casesensitive = true;
|
|
193
|
+
let queryText = config.query, filteredData;
|
|
194
|
+
return new Promise((resolve, reject) => {
|
|
195
|
+
if (config.searchKey) {
|
|
196
|
+
const keys = split(config.searchKey, ",");
|
|
197
|
+
filteredData = filter$1(config.dataset, (item) => {
|
|
198
|
+
return keys.some((key) => {
|
|
199
|
+
let a = get(item, key), b = queryText;
|
|
200
|
+
if (!casesensitive) {
|
|
201
|
+
a = toLower(toString(a));
|
|
202
|
+
b = toLower(toString(b));
|
|
203
|
+
}
|
|
204
|
+
return this.applyFilter(a, b, matchMode);
|
|
205
|
+
});
|
|
206
|
+
});
|
|
207
|
+
} else if (isArray(entries) && isObject(entries[0])) filteredData = filter$1(entries, (entry) => {
|
|
208
|
+
let a = values(entry).join(" ");
|
|
209
|
+
if (!casesensitive) {
|
|
210
|
+
a = toLower(a);
|
|
211
|
+
queryText = toLower(queryText);
|
|
212
|
+
}
|
|
213
|
+
return this.applyFilter(a, queryText);
|
|
214
|
+
});
|
|
215
|
+
else filteredData = filter$1(entries, (entry) => {
|
|
216
|
+
if (!casesensitive) {
|
|
217
|
+
entry = toLower(entry);
|
|
218
|
+
queryText = toLower(queryText);
|
|
219
|
+
}
|
|
220
|
+
return this.applyFilter(entry, queryText, matchMode);
|
|
221
|
+
});
|
|
222
|
+
resolve({
|
|
223
|
+
data: filteredData,
|
|
224
|
+
hasMoreData: false,
|
|
225
|
+
isLastPage: true
|
|
226
|
+
});
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
};
|
|
230
|
+
var RemoteDataProvider = class {
|
|
231
|
+
filter(config) {
|
|
232
|
+
return this.filterData(config).then((response) => this.onFilterSuccess(config, response), () => this.onFilterFailure());
|
|
233
|
+
}
|
|
234
|
+
filterData(config) {
|
|
235
|
+
if (config.dataoptions) {
|
|
236
|
+
const dataoptions = config.dataoptions;
|
|
237
|
+
const requestParams = config.datasource.execute(DataSource.Operation.GET_REQUEST_PARAMS, config);
|
|
238
|
+
if (dataoptions.relatedField) return new Promise((resolve, reject) => {
|
|
239
|
+
interpolateBindExpressions(config.viewParent, dataoptions.filterExpr, (filterexpressions) => {
|
|
240
|
+
requestParams.filterExpr = dataoptions.filterExpr = filterexpressions;
|
|
241
|
+
dataoptions.filterExpr = filterexpressions;
|
|
242
|
+
config.datasource.execute(DataSource.Operation.GET_RELATED_TABLE_DATA, assign({ relatedField: dataoptions.relatedField }, requestParams)).then(resolve, reject);
|
|
243
|
+
});
|
|
244
|
+
});
|
|
245
|
+
if (dataoptions.distinctField) return config.datasource.execute(DataSource.Operation.GET_DISTINCT_DATA_BY_FIELDS, {
|
|
246
|
+
pagesize: config.limit || config.pagesize,
|
|
247
|
+
page: config.page,
|
|
248
|
+
fields: dataoptions.distinctField,
|
|
249
|
+
entityName: dataoptions.tableName,
|
|
250
|
+
filterFields: assign(dataoptions.filterFields, requestParams.filterFields),
|
|
251
|
+
filterExpr: getClonedObject(dataoptions.filterExpr || {})
|
|
252
|
+
});
|
|
253
|
+
}
|
|
254
|
+
return config.datasource.execute(DataSource.Operation.SEARCH_RECORDS, config);
|
|
255
|
+
}
|
|
256
|
+
isLast(page, dataSize, maxResults, currentResults) {
|
|
257
|
+
if (dataSize === AppConstants.INT_MAX_VALUE) return currentResults !== 0 && currentResults < maxResults;
|
|
258
|
+
return page === (dataSize > maxResults ? Math.ceil(dataSize / maxResults) : dataSize < 0 ? 0 : 1);
|
|
259
|
+
}
|
|
260
|
+
getTransformedData(variable, data) {
|
|
261
|
+
const operationResult = variable.operation + "Result";
|
|
262
|
+
const tempResponse = data[operationResult];
|
|
263
|
+
if (tempResponse) {
|
|
264
|
+
const tempObj = {};
|
|
265
|
+
set(tempObj, operationResult, tempResponse);
|
|
266
|
+
data = [tempObj];
|
|
267
|
+
} else data = [data];
|
|
268
|
+
return data;
|
|
269
|
+
}
|
|
270
|
+
onFilterFailure() {
|
|
271
|
+
return [];
|
|
272
|
+
}
|
|
273
|
+
isLastPageForDistinctApi(data, page, totalElements, _isLastPage) {
|
|
274
|
+
return page > 1 && !_isLastPage && isEmpty(data) && totalElements === AppConstants.INT_MAX_VALUE;
|
|
275
|
+
}
|
|
276
|
+
onFilterSuccess(config, response) {
|
|
277
|
+
let data = response.data;
|
|
278
|
+
let formattedData;
|
|
279
|
+
let _isLastPage;
|
|
280
|
+
let page;
|
|
281
|
+
let isPaginatedData;
|
|
282
|
+
const expressionArray = split(config.binddataset, ".");
|
|
283
|
+
const dataExpression = slice(expressionArray, indexOf(expressionArray, "dataSet") + 1).join(".");
|
|
284
|
+
const $I = "[$i]";
|
|
285
|
+
return new Promise((resolve, reject) => {
|
|
286
|
+
const pageOptions = response.pagination;
|
|
287
|
+
if (config.datasource.execute(DataSource.Operation.IS_PAGEABLE)) {
|
|
288
|
+
page = pageOptions.number + 1;
|
|
289
|
+
_isLastPage = this.isLast(page, config.limit > 0 && config.limit || pageOptions.totalElements, pageOptions.size, pageOptions.numberOfElements);
|
|
290
|
+
isPaginatedData = true;
|
|
291
|
+
if (this.isLastPageForDistinctApi(data, page, pageOptions.totalElements, _isLastPage)) {
|
|
292
|
+
_isLastPage = true;
|
|
293
|
+
resolve({
|
|
294
|
+
data: [],
|
|
295
|
+
isLastPage: _isLastPage,
|
|
296
|
+
hasMoreData: page > 1,
|
|
297
|
+
isPaginatedData,
|
|
298
|
+
page
|
|
299
|
+
});
|
|
300
|
+
return;
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
if (dataExpression) {
|
|
304
|
+
if (isArray(data)) {
|
|
305
|
+
const index = dataExpression.lastIndexOf($I);
|
|
306
|
+
if (index > -1) {
|
|
307
|
+
const restExpr = dataExpression.substr(index + 5);
|
|
308
|
+
formattedData = data.map((datum) => findValueOf(datum, restExpr));
|
|
309
|
+
}
|
|
310
|
+
} else if (isObject(data)) formattedData = get(data, dataExpression);
|
|
311
|
+
data = formattedData || data;
|
|
312
|
+
}
|
|
313
|
+
if (!isArray(data)) data = this.getTransformedData(config.datasource, data);
|
|
314
|
+
if (!data.length) resolve({
|
|
315
|
+
data: [],
|
|
316
|
+
isLastPage: _isLastPage,
|
|
317
|
+
hasMoreData: page > 1,
|
|
318
|
+
isPaginatedData,
|
|
319
|
+
page
|
|
320
|
+
});
|
|
321
|
+
else resolve({
|
|
322
|
+
data,
|
|
323
|
+
isLastPage: _isLastPage,
|
|
324
|
+
hasMoreData: page > 1,
|
|
325
|
+
isPaginatedData,
|
|
326
|
+
page
|
|
327
|
+
});
|
|
328
|
+
});
|
|
329
|
+
}
|
|
330
|
+
};
|
|
331
|
+
var DataProvider = class DataProvider {
|
|
332
|
+
static {
|
|
333
|
+
this.remoteDataProvider = new RemoteDataProvider();
|
|
334
|
+
}
|
|
335
|
+
static {
|
|
336
|
+
this.localDataProvider = new LocalDataProvider();
|
|
337
|
+
}
|
|
338
|
+
filter(config) {
|
|
339
|
+
let promise;
|
|
340
|
+
const hasNoVariableDataset = config.datasource?.execute(DataSource.Operation.IS_UPDATE_REQUIRED, config.hasData);
|
|
341
|
+
if (!config.isLocalFilter && (config.dataoptions || config.datasource?.execute(DataSource.Operation.IS_API_AWARE) && config.searchKey && hasNoVariableDataset)) promise = DataProvider.remoteDataProvider.filter(config);
|
|
342
|
+
else promise = DataProvider.localDataProvider.filter(config);
|
|
343
|
+
return promise.then((response) => {
|
|
344
|
+
this.updateDataset = config.datasource && !config.datasource.execute(DataSource.Operation.SUPPORTS_CRUD) && hasNoVariableDataset;
|
|
345
|
+
this.hasMoreData = response.hasMoreData;
|
|
346
|
+
this.isLastPage = response.isLastPage;
|
|
347
|
+
this.page = response.page;
|
|
348
|
+
this.isPaginatedData = response.isPaginatedData;
|
|
349
|
+
return response;
|
|
350
|
+
});
|
|
351
|
+
}
|
|
352
|
+
};
|
|
353
|
+
const WIDGET_CONFIG = {
|
|
354
|
+
widgetType: "wm-search",
|
|
355
|
+
hostClass: "input-group"
|
|
356
|
+
};
|
|
357
|
+
var SearchComponent = class SearchComponent extends DatasetAwareFormComponent {
|
|
358
|
+
static {
|
|
359
|
+
this.initializeProps = registerProps();
|
|
360
|
+
}
|
|
361
|
+
get typeaheadOptionsLimit() {
|
|
362
|
+
return isDefined(this.limit) ? this.limit : this._dynamicTypeaheadOptionsLimit;
|
|
363
|
+
}
|
|
364
|
+
get datasource() {
|
|
365
|
+
return this._datasource;
|
|
366
|
+
}
|
|
367
|
+
set datasource(nv) {
|
|
368
|
+
this._datasource = nv;
|
|
369
|
+
const data = this.datavalue || this.toBeProcessedDatavalue;
|
|
370
|
+
this.updateByDatavalue(data);
|
|
371
|
+
}
|
|
372
|
+
constructor(inj, app, binddatavalue, binddataset, explicitContext) {
|
|
373
|
+
super(inj, WIDGET_CONFIG, explicitContext);
|
|
374
|
+
this.binddatavalue = binddatavalue;
|
|
375
|
+
this.binddataset = binddataset;
|
|
376
|
+
this.query = "";
|
|
377
|
+
this.page = 1;
|
|
378
|
+
this.allowempty = false;
|
|
379
|
+
this.app = app;
|
|
380
|
+
addClass(this.nativeElement, "app-search", true);
|
|
381
|
+
this.typeaheadDataSource = Observable.create((observer) => {
|
|
382
|
+
if (this.listenQuery) {
|
|
383
|
+
this._defaultQueryInvoked = false;
|
|
384
|
+
this._loadingItems = true;
|
|
385
|
+
observer.next(this.query);
|
|
386
|
+
}
|
|
387
|
+
if (this.lastSelectedIndex) this.typeahead._container = void 0;
|
|
388
|
+
}).pipe(filter(() => {
|
|
389
|
+
this._loadingItems = false;
|
|
390
|
+
return this.minchars === 0 || this.query && this.query.length >= this.minchars;
|
|
391
|
+
}), mergeMap((token) => this.getDataSourceAsObservable(token)));
|
|
392
|
+
this.dataProvider = new DataProvider();
|
|
393
|
+
const datavalueSubscription = this.datavalue$.subscribe((val) => {
|
|
394
|
+
const query = isArray(val) ? val[0] : val;
|
|
395
|
+
if (query === null || query === "") {
|
|
396
|
+
this._modelByValue = "";
|
|
397
|
+
this.query = this.queryModel = "";
|
|
398
|
+
this._lastResult = void 0;
|
|
399
|
+
return;
|
|
400
|
+
}
|
|
401
|
+
if (!this._unsubscribeDv) {
|
|
402
|
+
this._defaultQueryInvoked = false;
|
|
403
|
+
if (!isObject(val) && this.prevDatavalue !== val) {
|
|
404
|
+
this._modelByKey = void 0;
|
|
405
|
+
this.query = this.queryModel = "";
|
|
406
|
+
}
|
|
407
|
+
this.updateByDatavalue(val);
|
|
408
|
+
}
|
|
409
|
+
this.showClosebtn = this.query !== "";
|
|
410
|
+
});
|
|
411
|
+
this.registerDestroyListener(() => datavalueSubscription.unsubscribe());
|
|
412
|
+
const datasetSubscription = this.dataset$.subscribe(() => {
|
|
413
|
+
this.startIndex = this.datasetItems.length;
|
|
414
|
+
this._lastResult = void 0;
|
|
415
|
+
const defaultValue = this.datavalue || this.toBeProcessedDatavalue;
|
|
416
|
+
if (isDefined(defaultValue)) this.updateByDataset(defaultValue);
|
|
417
|
+
});
|
|
418
|
+
this.registerDestroyListener(() => datasetSubscription.unsubscribe());
|
|
419
|
+
}
|
|
420
|
+
clearSearch($event, loadOnClear) {
|
|
421
|
+
this.query = "";
|
|
422
|
+
this.onInputChange($event);
|
|
423
|
+
if (this.dataProvider) this.dataProvider.isLastPage = false;
|
|
424
|
+
this.listenQuery = false;
|
|
425
|
+
if (loadOnClear) {
|
|
426
|
+
this.listenQuery = true;
|
|
427
|
+
this._unsubscribeDv = false;
|
|
428
|
+
this.loadMoreData();
|
|
429
|
+
}
|
|
430
|
+
this.invokeEventCallback("clearsearch");
|
|
431
|
+
this._loadingItems = false;
|
|
432
|
+
if ($event) this.$element.find(".app-search-input").focus();
|
|
433
|
+
}
|
|
434
|
+
clearText() {
|
|
435
|
+
this.query = "";
|
|
436
|
+
this.showClosebtn = false;
|
|
437
|
+
}
|
|
438
|
+
closeSearch() {
|
|
439
|
+
this._loadingItems = false;
|
|
440
|
+
this.page = 1;
|
|
441
|
+
this.insertAtIndex(this.elIndex);
|
|
442
|
+
this.elIndex = void 0;
|
|
443
|
+
this.parentEl = void 0;
|
|
444
|
+
this.$element.removeClass("full-screen");
|
|
445
|
+
if (this._domUpdated) this._domUpdated = false;
|
|
446
|
+
this.listenQuery = false;
|
|
447
|
+
this._unsubscribeDv = true;
|
|
448
|
+
this.typeahead.hide();
|
|
449
|
+
}
|
|
450
|
+
renderMobileAutoComplete() {
|
|
451
|
+
if (!isDefined(this.elIndex)) {
|
|
452
|
+
this.parentEl = this.$element.parent();
|
|
453
|
+
this.elIndex = this.parentEl.children().index(this.$element);
|
|
454
|
+
}
|
|
455
|
+
if (!this.$element.hasClass("full-screen")) {
|
|
456
|
+
this._domUpdated = true;
|
|
457
|
+
this.$element.addClass("full-screen");
|
|
458
|
+
if (this.position === "inline") this.$element.addClass(this.position);
|
|
459
|
+
}
|
|
460
|
+
if (this.$element.hasClass("full-screen")) this.$element.find(".app-search-input").focus();
|
|
461
|
+
}
|
|
462
|
+
getDataSourceAsObservable(query) {
|
|
463
|
+
if (this._lastQuery === query && !get(this.dataoptions, "filterFields") && isDefined(this._lastResult)) {
|
|
464
|
+
this._loadingItems = false;
|
|
465
|
+
return of(this._lastResult);
|
|
466
|
+
}
|
|
467
|
+
if (this.type === "autocomplete" && this.searchkey && this.query && this.datavalue) {
|
|
468
|
+
let bindDisplayLabelArray = [];
|
|
469
|
+
const searchKeyArray = split(this.searchkey, ",");
|
|
470
|
+
let displaylabel;
|
|
471
|
+
if (this.binddisplaylabel) {
|
|
472
|
+
bindDisplayLabelArray = split(this.binddisplaylabel, "+");
|
|
473
|
+
if (bindDisplayLabelArray.length === 1) {
|
|
474
|
+
if (!includes(bindDisplayLabelArray[0], "|")) displaylabel = /\[(.*?)\]/.exec(bindDisplayLabelArray[0])[1];
|
|
475
|
+
else displaylabel = true;
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
if (bindDisplayLabelArray.length > 1 || displaylabel && !includes(searchKeyArray, displaylabel) || this.displayexpression && !includes(searchKeyArray, this.displayexpression)) {
|
|
479
|
+
this._loadingItems = false;
|
|
480
|
+
return of([]);
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
this._lastQuery = this.query;
|
|
484
|
+
return from(this.getDataSource(query));
|
|
485
|
+
}
|
|
486
|
+
handleEvent(node, eventName, eventCallback, locals) {
|
|
487
|
+
if (!includes([
|
|
488
|
+
"blur",
|
|
489
|
+
"focus",
|
|
490
|
+
"select",
|
|
491
|
+
"submit",
|
|
492
|
+
"change"
|
|
493
|
+
], eventName)) super.handleEvent(node, eventName, eventCallback, locals);
|
|
494
|
+
}
|
|
495
|
+
highlight(match, query) {
|
|
496
|
+
if (this.typeaheadContainer) {
|
|
497
|
+
match.value = match.item.label.toString();
|
|
498
|
+
return this.typeaheadContainer.highlight(match, query);
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
insertAtIndex(i) {
|
|
502
|
+
if (i === 0) this.parentEl.prepend(this.$element);
|
|
503
|
+
else if (this.parentEl.children().eq(i).length) this.$element.insertBefore(this.parentEl.children().eq(i));
|
|
504
|
+
else this.$element.insertAfter(this.parentEl.children().eq(i - 1));
|
|
505
|
+
}
|
|
506
|
+
isMobileAutoComplete() {
|
|
507
|
+
return this.type === "autocomplete" && isMobile();
|
|
508
|
+
}
|
|
509
|
+
isQueryEntered() {
|
|
510
|
+
return this.showclear && this.showClosebtn;
|
|
511
|
+
}
|
|
512
|
+
loadMoreData(incrementPage) {
|
|
513
|
+
if (!this.dataProvider || this.dataProvider.isLastPage) return;
|
|
514
|
+
this.page = incrementPage ? this.page + 1 : this.page;
|
|
515
|
+
this.isScrolled = true;
|
|
516
|
+
this._loadingItems = true;
|
|
517
|
+
if (incrementPage) this._lastQuery = void 0;
|
|
518
|
+
this.typeahead.onInput({ target: { value: trim(this.query) || "0" } });
|
|
519
|
+
}
|
|
520
|
+
onFocusOut() {
|
|
521
|
+
this._unsubscribeDv = false;
|
|
522
|
+
this._loadingItems = false;
|
|
523
|
+
this.page = 1;
|
|
524
|
+
if (!this._domUpdated && this._isOpen) this.listenQuery = false;
|
|
525
|
+
this._isOpen = false;
|
|
526
|
+
if (this._domUpdated && this.typeahead && this.typeahead._container) this.typeahead._container.isFocused = true;
|
|
527
|
+
}
|
|
528
|
+
onInputChange($event) {
|
|
529
|
+
this.result = [];
|
|
530
|
+
this.page = 1;
|
|
531
|
+
this.listenQuery = this.isUpdateOnKeyPress();
|
|
532
|
+
this._modelByValue = void 0;
|
|
533
|
+
if (this.query === "") {
|
|
534
|
+
this.queryModel = "";
|
|
535
|
+
this._modelByValue = "";
|
|
536
|
+
this.updatePrevDatavalue(this._lastQuery);
|
|
537
|
+
this.invokeOnChange(this._modelByValue, {}, true);
|
|
538
|
+
this.invokeEventCallback("clear", { $event });
|
|
539
|
+
if ($event && $event.which !== 9) this.invokeEventCallback("submit", { $event });
|
|
540
|
+
} else this.invokeEventCallback("change", {
|
|
541
|
+
$event,
|
|
542
|
+
newVal: this._modelByValue || this.query,
|
|
543
|
+
oldVal: this.prevDatavalue
|
|
544
|
+
});
|
|
545
|
+
this.showClosebtn = this.query !== "";
|
|
546
|
+
}
|
|
547
|
+
handleEnterEvent($event) {
|
|
548
|
+
if (!get(this.typeahead, "matches.length")) this.onSearchSelect($event);
|
|
549
|
+
}
|
|
550
|
+
onSearchSelect($event) {
|
|
551
|
+
let item;
|
|
552
|
+
const isQueryMatch = this.typeaheadContainer?.active?.value === this.query;
|
|
553
|
+
if (this.typeaheadContainer?.active && isQueryMatch) item = this.typeaheadContainer.active.item;
|
|
554
|
+
$event = this.eventData($event, item || {});
|
|
555
|
+
if (!this.isUpdateOnKeyPress()) {
|
|
556
|
+
this.listenQuery = true;
|
|
557
|
+
this.typeahead.onInput({ target: { value: this.query } });
|
|
558
|
+
return;
|
|
559
|
+
}
|
|
560
|
+
if (this.typeaheadContainer && this.liElements.length && isQueryMatch) this.typeaheadContainer.selectActiveMatch();
|
|
561
|
+
else {
|
|
562
|
+
this.queryModel = this.query;
|
|
563
|
+
this.invokeEventCallback("submit", { $event });
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
invokeOnBeforeServiceCall(inputData) {
|
|
567
|
+
this.invokeEventCallback("beforeservicecall", { inputData });
|
|
568
|
+
}
|
|
569
|
+
onDropdownOpen() {
|
|
570
|
+
if (this.clearData) this.typeahead.hide();
|
|
571
|
+
debounce(() => {
|
|
572
|
+
this._isOpen = true;
|
|
573
|
+
this.typeaheadContainer = this.typeahead._container || this.typeahead._typeahead.instance;
|
|
574
|
+
this.typeaheadContainer.liElements = this.liElements;
|
|
575
|
+
this.typeaheadContainer.ulElement = this.ulElement;
|
|
576
|
+
adjustContainerPosition($("typeahead-container"), this.nativeElement, this.typeahead._typeahead, $("typeahead-container .dropdown-menu"));
|
|
577
|
+
})();
|
|
578
|
+
if (this.isMobileAutoComplete()) {
|
|
579
|
+
if (!this.$element.hasClass("full-screen")) this.renderMobileAutoComplete();
|
|
580
|
+
const dropdownEl = this.dropdownEl.closest("typeahead-container");
|
|
581
|
+
dropdownEl.insertAfter(this.$element.find("input").first());
|
|
582
|
+
const screenHeight = this.$element.closest(".app-content").height();
|
|
583
|
+
dropdownEl.css({
|
|
584
|
+
position: "relative",
|
|
585
|
+
top: 0,
|
|
586
|
+
height: screenHeight + "px"
|
|
587
|
+
});
|
|
588
|
+
this.showClosebtn = this.query && this.query !== "";
|
|
589
|
+
if (this.dataProvider && !isUndefined(this.dataProvider.isLastPage) && !this.dataProvider.isLastPage) this.triggerSearch();
|
|
590
|
+
}
|
|
591
|
+
}
|
|
592
|
+
selectNext() {
|
|
593
|
+
const matches = this.typeaheadContainer.matches;
|
|
594
|
+
if (!matches) return;
|
|
595
|
+
const index = matches.indexOf(this.typeaheadContainer.active);
|
|
596
|
+
if (!this._loadingItems && this.dataProvider && !this.dataProvider.isLastPage && index + 1 > matches.length - 1) {
|
|
597
|
+
this.lastSelectedIndex = index;
|
|
598
|
+
this.loadMoreData(true);
|
|
599
|
+
}
|
|
600
|
+
}
|
|
601
|
+
setLastActiveMatchAsSelected() {
|
|
602
|
+
if (this.lastSelectedIndex) {
|
|
603
|
+
this.typeaheadContainer._active = this.typeaheadContainer.matches[this.lastSelectedIndex];
|
|
604
|
+
this.typeaheadContainer.nextActiveMatch();
|
|
605
|
+
this.lastSelectedIndex = void 0;
|
|
606
|
+
}
|
|
607
|
+
}
|
|
608
|
+
triggerSearch() {
|
|
609
|
+
if (!this.dataProvider || this.dataProvider.isLastPage || !this.$element.hasClass("full-screen")) return;
|
|
610
|
+
const typeAheadDropDown = this.dropdownEl;
|
|
611
|
+
const $lastItem = typeAheadDropDown.find("li").last();
|
|
612
|
+
if ($lastItem.length && typeAheadDropDown.length && typeAheadDropDown.height() + typeAheadDropDown.position().top > $lastItem.height() + $lastItem.position().top) this.loadMoreData(true);
|
|
613
|
+
}
|
|
614
|
+
isUpdateOnKeyPress() {
|
|
615
|
+
return this.searchon === "typing";
|
|
616
|
+
}
|
|
617
|
+
debounceDefaultQuery(data) {
|
|
618
|
+
this._defaultQueryInvoked = true;
|
|
619
|
+
this.getDataSource(data, true).then((response) => {
|
|
620
|
+
if (response.length) {
|
|
621
|
+
this.queryModel = response;
|
|
622
|
+
this._lastQuery = this.query = this.queryModel[0].label || "";
|
|
623
|
+
this._modelByValue = this.queryModel[0].value;
|
|
624
|
+
this._modelByKey = this.queryModel[0].key;
|
|
625
|
+
this.showClosebtn = this.query !== "";
|
|
626
|
+
} else {
|
|
627
|
+
this._modelByValue = void 0;
|
|
628
|
+
this.queryModel = void 0;
|
|
629
|
+
this.query = "";
|
|
630
|
+
}
|
|
631
|
+
if (this.clearData) {
|
|
632
|
+
if (get(this.typeahead, "_typeahead.isShown")) this.typeahead.hide();
|
|
633
|
+
}
|
|
634
|
+
});
|
|
635
|
+
}
|
|
636
|
+
updateByDatavalue(data) {
|
|
637
|
+
this.updateByDataset(data);
|
|
638
|
+
this.updateByDataSource(data);
|
|
639
|
+
}
|
|
640
|
+
updateByDataSource(data) {
|
|
641
|
+
if (isDefined(data) && !isObject(data) && this.datasource && !isDefined(this._modelByKey) && this.datafield !== ALLFIELDS) {
|
|
642
|
+
if (isDefined(this.queryModel) && !isEmpty(this.queryModel)) {
|
|
643
|
+
this.updateDatavalueFromQueryModel();
|
|
644
|
+
return;
|
|
645
|
+
}
|
|
646
|
+
if (!this._defaultQueryInvoked && this.datasource.execute(DataSource.Operation.SUPPORTS_CRUD)) this.debounceDefaultQuery(data);
|
|
647
|
+
}
|
|
648
|
+
}
|
|
649
|
+
updateDatavalueFromQueryModel() {
|
|
650
|
+
if (isDefined(this.queryModel)) {
|
|
651
|
+
this._modelByValue = isArray(this.queryModel) ? this.queryModel[0].value : this.queryModel;
|
|
652
|
+
this._modelByKey = isArray(this.queryModel) ? this.queryModel[0].key : this.queryModel;
|
|
653
|
+
this.toBeProcessedDatavalue = void 0;
|
|
654
|
+
}
|
|
655
|
+
}
|
|
656
|
+
updateByDataset(data) {
|
|
657
|
+
if (this._defaultQueryInvoked && this.searchkey) return;
|
|
658
|
+
const selectedItem = find(this.datasetItems, (item) => {
|
|
659
|
+
return isObject(item.value) ? isEqual(item.value, data) : toString(item.value).toLowerCase() === toString(data).toLowerCase();
|
|
660
|
+
});
|
|
661
|
+
if (selectedItem) this.queryModel = [selectedItem];
|
|
662
|
+
else if (this.datafield === ALLFIELDS && isObject(data)) this.queryModel = this.getTransformedData(extractDataAsArray(data));
|
|
663
|
+
else if (this.prevDatavalue !== data) {
|
|
664
|
+
this.queryModel = void 0;
|
|
665
|
+
this.query = "";
|
|
666
|
+
return;
|
|
667
|
+
}
|
|
668
|
+
this.updateDatavalueFromQueryModel();
|
|
669
|
+
this._lastQuery = this.query = isDefined(this.queryModel) && this.queryModel.length ? get(this.queryModel[0], "label") : "";
|
|
670
|
+
this.showClosebtn = this.query !== "";
|
|
671
|
+
}
|
|
672
|
+
handleFocus($event) {
|
|
673
|
+
if (this.type === "search" && this.query === this._lastQuery && this._lastResult) this.typeahead.keyUpEventEmitter.emit(this.query);
|
|
674
|
+
}
|
|
675
|
+
notifySubscriber() {
|
|
676
|
+
const parentEl = $(this.nativeElement).closest(".app-composite-widget.caption-floating");
|
|
677
|
+
if (parentEl.length > 0) this.app.notify("captionPositionAnimate", {
|
|
678
|
+
displayVal: true,
|
|
679
|
+
nativeEl: parentEl
|
|
680
|
+
});
|
|
681
|
+
}
|
|
682
|
+
getDataSource(query, searchOnDataField, nextItemIndex) {
|
|
683
|
+
if (searchOnDataField && this.datafield === ALLFIELDS) {
|
|
684
|
+
this._loadingItems = false;
|
|
685
|
+
return Promise.resolve([]);
|
|
686
|
+
}
|
|
687
|
+
const dataConfig = {
|
|
688
|
+
dataset: this.dataset ? convertDataToObject(this.dataset) : void 0,
|
|
689
|
+
binddataset: this.binddataset,
|
|
690
|
+
datasource: this.datasource,
|
|
691
|
+
datafield: this.datafield,
|
|
692
|
+
hasData: this.dataset?.length,
|
|
693
|
+
query,
|
|
694
|
+
isLocalFilter: !this.searchkey,
|
|
695
|
+
searchKey: searchOnDataField ? this.datafield : this.searchkey,
|
|
696
|
+
matchMode: searchOnDataField ? "startignorecase" : this.matchmode,
|
|
697
|
+
casesensitive: this.casesensitive,
|
|
698
|
+
isformfield: this.isformfield,
|
|
699
|
+
orderby: this.orderby,
|
|
700
|
+
limit: this.limit,
|
|
701
|
+
pagesize: this.pagesize,
|
|
702
|
+
page: this.page,
|
|
703
|
+
onBeforeservicecall: this.invokeOnBeforeServiceCall.bind(this)
|
|
704
|
+
};
|
|
705
|
+
if (this.dataoptions) {
|
|
706
|
+
dataConfig.dataoptions = this.dataoptions;
|
|
707
|
+
dataConfig.viewParent = this.viewParent;
|
|
708
|
+
}
|
|
709
|
+
this._loadingItems = true;
|
|
710
|
+
return this.dataProvider.filter(dataConfig).then((response) => {
|
|
711
|
+
response = response.data || response;
|
|
712
|
+
if (this.dataProvider && (!isDefined(this.dataset) || !this.dataset.length) && this.dataProvider.updateDataset) this.dataset = response;
|
|
713
|
+
if (this.dataProvider?.hasMoreData) this.formattedDataset = this.formattedDataset.concat(response);
|
|
714
|
+
else this.formattedDataset = response;
|
|
715
|
+
if (this.formattedDataset.length > 20 && !isDefined(this.limit)) this._dynamicTypeaheadOptionsLimit = this.formattedDataset.length;
|
|
716
|
+
else this._dynamicTypeaheadOptionsLimit = void 0;
|
|
717
|
+
if (this.dataProvider && this._isOpen && this.isMobileAutoComplete() && !isUndefined(this.dataProvider.isLastPage) && !this.dataProvider.isLastPage) this.triggerSearch();
|
|
718
|
+
const transformedData = this.getTransformedData(this.formattedDataset, nextItemIndex);
|
|
719
|
+
this.result = map(transformedData, "value");
|
|
720
|
+
return transformedData;
|
|
721
|
+
}, (error) => {
|
|
722
|
+
this._loadingItems = false;
|
|
723
|
+
return [];
|
|
724
|
+
}).then((result) => {
|
|
725
|
+
if (this.isScrolled) {
|
|
726
|
+
debounce(() => {
|
|
727
|
+
this.setLastActiveMatchAsSelected();
|
|
728
|
+
}, 30)();
|
|
729
|
+
this.isScrolled = false;
|
|
730
|
+
}
|
|
731
|
+
if (!result.length) {
|
|
732
|
+
this._modelByValue = void 0;
|
|
733
|
+
this.queryModel = query;
|
|
734
|
+
}
|
|
735
|
+
if (this._unsubscribeDv) result = [];
|
|
736
|
+
this._loadingItems = false;
|
|
737
|
+
this._lastResult = result;
|
|
738
|
+
return result;
|
|
739
|
+
});
|
|
740
|
+
}
|
|
741
|
+
getContext(context) {
|
|
742
|
+
if (context && get(context, "widget")) return this.getContext(context.viewParent);
|
|
743
|
+
return context;
|
|
744
|
+
}
|
|
745
|
+
getTransformedData(data, itemIndex, iscustom) {
|
|
746
|
+
if (isDefined(itemIndex)) itemIndex++;
|
|
747
|
+
const transformedData = transformFormData(this.getContext(this.viewParent), data, this.datafield, {
|
|
748
|
+
displayField: this.displaylabel || this.displayfield,
|
|
749
|
+
displayExpr: iscustom ? "" : this.displayexpression,
|
|
750
|
+
bindDisplayExpr: iscustom ? "" : this.binddisplaylabel,
|
|
751
|
+
bindDisplayImgSrc: this.binddisplayimagesrc,
|
|
752
|
+
displayImgSrc: this.displayimagesrc
|
|
753
|
+
}, itemIndex, this);
|
|
754
|
+
return getUniqObjsByDataField(transformedData, this.datafield, this.displayfield || this.displaylabel, toBoolean(this.allowempty));
|
|
755
|
+
}
|
|
756
|
+
onScroll($scrollEl, evt) {
|
|
757
|
+
const totalHeight = $scrollEl.scrollHeight, clientHeight = $scrollEl.clientHeight;
|
|
758
|
+
if (!this._loadingItems && this.dataProvider && !this.dataProvider.isLastPage && $scrollEl.scrollTop + clientHeight >= totalHeight) this.loadMoreData(true);
|
|
759
|
+
}
|
|
760
|
+
ngOnInit() {
|
|
761
|
+
super.ngOnInit();
|
|
762
|
+
if (!isDefined(this.minchars)) {
|
|
763
|
+
if (this.type === "autocomplete") this.minchars = 0;
|
|
764
|
+
else this.minchars = 1;
|
|
765
|
+
}
|
|
766
|
+
this.listenQuery = this.isUpdateOnKeyPress();
|
|
767
|
+
this.showsearchicon = isDefined(this.showsearchicon) ? this.showsearchicon : this.type === "search";
|
|
768
|
+
}
|
|
769
|
+
ngAfterViewInit() {
|
|
770
|
+
super.ngAfterViewInit();
|
|
771
|
+
styler(this.nativeElement, this);
|
|
772
|
+
this.containerTarget = getContainerTargetClass(this.nativeElement);
|
|
773
|
+
}
|
|
774
|
+
ngAfterViewChecked() {
|
|
775
|
+
const searchInputEl = $(".app-search-input");
|
|
776
|
+
if (searchInputEl) searchInputEl.removeAttr("aria-expanded");
|
|
777
|
+
}
|
|
778
|
+
eventData($event, item) {
|
|
779
|
+
if ($event) $event["data"] = {
|
|
780
|
+
item: item.dataObject,
|
|
781
|
+
model: item.value,
|
|
782
|
+
label: item.label,
|
|
783
|
+
query: this.query
|
|
784
|
+
};
|
|
785
|
+
return $event;
|
|
786
|
+
}
|
|
787
|
+
typeaheadOnSelect(match, $event) {
|
|
788
|
+
const item = match.item;
|
|
789
|
+
this.queryModel = item;
|
|
790
|
+
item.selected = true;
|
|
791
|
+
this.query = item.label;
|
|
792
|
+
this.showClosebtn = this.query !== "";
|
|
793
|
+
$event = $event || this.$typeaheadEvent;
|
|
794
|
+
this._modelByKey = item.key;
|
|
795
|
+
this._modelByValue = item.value;
|
|
796
|
+
$event = this.eventData($event, item);
|
|
797
|
+
this.invokeOnTouched();
|
|
798
|
+
this.invokeOnChange(this.datavalue, $event || {});
|
|
799
|
+
if (this.datavalue !== this.prevDatavalue) this.updateBoundVariable(this.datavalue);
|
|
800
|
+
if (this.$element.hasClass("full-screen")) this.closeSearch();
|
|
801
|
+
this.invokeEventCallback("select", {
|
|
802
|
+
$event,
|
|
803
|
+
selectedValue: this.datavalue
|
|
804
|
+
});
|
|
805
|
+
this.invokeEventCallback("submit", { $event });
|
|
806
|
+
this.updatePrevDatavalue(this.datavalue);
|
|
807
|
+
}
|
|
808
|
+
onPropertyChange(key, nv, ov) {
|
|
809
|
+
if (key === "tabindex") return;
|
|
810
|
+
if (this.type === "autocomplete" && key === "displaylabel" && this.displaylabel && (!this.displayexpression || this.displayexpression && !this.datasource)) {
|
|
811
|
+
this.displayexpression = this.displaylabel;
|
|
812
|
+
this.displaylabel = void 0;
|
|
813
|
+
}
|
|
814
|
+
if (key === "displaylabel" && this.dataoptions && this.binddisplaylabel === null) this.query = get(this._modelByValue, nv) || this._modelByValue;
|
|
815
|
+
if (key === "disabled") {
|
|
816
|
+
if (nv === false) this.clearData = false;
|
|
817
|
+
else {
|
|
818
|
+
this.clearData = true;
|
|
819
|
+
if (get(this.typeahead, "_typeahead.isShown")) this.typeahead.hide();
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
if (key === "minchars" && this.typeahead && isDefined(nv)) this.typeahead._typeaheadMinLengthValue = nv;
|
|
823
|
+
super.onPropertyChange(key, nv, ov);
|
|
824
|
+
}
|
|
825
|
+
ngOnDestroy() {
|
|
826
|
+
this.liElements = null;
|
|
827
|
+
if (this.dataProvider) this.dataProvider = null;
|
|
828
|
+
if (this.typeahead) this.typeahead = null;
|
|
829
|
+
this.queryModel = null;
|
|
830
|
+
this.query = "";
|
|
831
|
+
super.ngOnDestroy();
|
|
832
|
+
}
|
|
833
|
+
static {
|
|
834
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
835
|
+
minVersion: "12.0.0",
|
|
836
|
+
version: "22.2.1",
|
|
837
|
+
ngImport: i0,
|
|
838
|
+
type: SearchComponent,
|
|
839
|
+
deps: [
|
|
840
|
+
{ token: i0.Injector },
|
|
841
|
+
{ token: i1.App },
|
|
842
|
+
{
|
|
843
|
+
token: "datavalue.bind",
|
|
844
|
+
attribute: true
|
|
845
|
+
},
|
|
846
|
+
{
|
|
847
|
+
token: "dataset.bind",
|
|
848
|
+
attribute: true
|
|
849
|
+
},
|
|
850
|
+
{
|
|
851
|
+
token: "EXPLICIT_CONTEXT",
|
|
852
|
+
optional: true
|
|
853
|
+
}
|
|
854
|
+
],
|
|
855
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
856
|
+
});
|
|
857
|
+
}
|
|
858
|
+
static {
|
|
859
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
860
|
+
minVersion: "17.0.0",
|
|
861
|
+
version: "22.2.1",
|
|
862
|
+
type: SearchComponent,
|
|
863
|
+
isStandalone: true,
|
|
864
|
+
selector: "[wmSearch]",
|
|
865
|
+
providers: [
|
|
866
|
+
provideAs(SearchComponent, NG_VALUE_ACCESSOR, true),
|
|
867
|
+
provideAs(SearchComponent, NG_VALIDATORS, true),
|
|
868
|
+
provideAsWidgetRef(SearchComponent)
|
|
869
|
+
],
|
|
870
|
+
viewQueries: [
|
|
871
|
+
{
|
|
872
|
+
propertyName: "typeahead",
|
|
873
|
+
first: true,
|
|
874
|
+
predicate: TypeaheadDirective,
|
|
875
|
+
descendants: true
|
|
876
|
+
},
|
|
877
|
+
{
|
|
878
|
+
propertyName: "ulElement",
|
|
879
|
+
first: true,
|
|
880
|
+
predicate: ["ulElement"],
|
|
881
|
+
descendants: true
|
|
882
|
+
},
|
|
883
|
+
{
|
|
884
|
+
propertyName: "liElements",
|
|
885
|
+
predicate: ["liElements"],
|
|
886
|
+
descendants: true
|
|
887
|
+
}
|
|
888
|
+
],
|
|
889
|
+
usesInheritance: true,
|
|
890
|
+
ngImport: i0,
|
|
891
|
+
template: "<ng-template #customItemTemplate let-model=\"item\" let-index=\"index\" let-query=\"query\" let-match=\"match\">\n <!-- Default item template -->\n @if (!content) {\n <a>\n @if (model.imgSrc) {\n <img [src]=\"model.imgSrc\" alt=\"Search\" [style.width]=\"imagewidth\">\n }\n <span [title]=\"model.label\" [innerHtml]=\"highlight(match, query) || model.label\"></span>\n </a>\n }\n <!-- Custom partial template -->\n @if (content) {\n <a [ngClass]=\"{customTemplate: content}\" partialContainer [wmItemTemplate]=\"content\" [userComponentParams]=\"match.item\">\n <div partial-container-target></div>\n </a>\n }\n</ng-template>\n\n<ng-template #customListTemplate let-matches=\"matches\" let-itemTemplate=\"itemTemplate\" let-query=\"query\">\n <ul #ulElement class=\"app-search dropdown-menu\" scrollableHandler>\n @for (match of matches; track match; let i = $index) {\n <li #liElements [ngClass]=\"{active: typeaheadContainer && typeaheadContainer.isActive(match), 'list-group-header': match && match.isHeader()}\"\n (mouseenter)=\"typeaheadContainer.selectActive(match);\"\n (click)=\"match && !match.isHeader() && typeaheadContainer.selectMatch(match, $event); $typeaheadEvent = $event; notifySubscriber();\">\n <!-- itemTemplate comes from the <input> -->\n @if (match.isHeader()) {\n <h4 class=\"group-title\">{{match.value}}</h4>\n }\n @if (!match.isHeader()) {\n <ng-container [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{item: match.item, index: i, match: match, query: query}\">\n </ng-container>\n }\n </li>\n }\n <div class=\"status\" [hidden]=\"_loadingItems || !(datacompletemsg && dataProvider?.isLastPage)\">\n <span [textContent]=\"datacompletemsg\"></span>\n </div>\n <div class=\"status\" [hidden]=\"!_loadingItems\">\n <i class=\"fa fa-circle-o-notch fa-spin\"></i>\n <span [textContent]=\"loadingdatamsg\"></span>\n </div>\n </ul>\n</ng-template>\n\n<!--This template is for search inside mobile navbar.-->\n@if (navsearchbar) {\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n container=\"body\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event)\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event);\"\n (focusout)=\"onFocusOut()\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [dropup]=\"dropup\"\n [tabindex]=\"tabindex\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\"/>\n <i class=\"btn-close wi wi-cancel\" [hidden]=\"!showClosebtn\" (click)=\"clearSearch($event);\"></i>\n} @else {\n <button type=\"button\" class=\"btn btn-icon form-control-feedback back-btn\" aria-hidden=\"true\" aria-label=\"Back\" (click)=\"closeSearch()\">\n <wm-app-icon [iconclass]=\"backsearchiconclass\" [iconurl]=\"backsearchiconurl\" alt=\"Back\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Back button</span>\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n [container]=\"containerTarget || '.wm-app'\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event); onFocusOut()\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event)\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [tabindex]=\"tabindex\"\n [dropup]=\"dropup\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\">\n <input aria-label=\"Search value\" class=\"model-holder\" ng-model=\"proxyModel\" ng-required=\"required\" tabindex=\"-1\" aria-hidden=\"true\">\n @if (_loadingItems) {\n <span aria-hidden=\"true\" class=\"fa fa-circle-o-notch fa-spin form-control-feedback\"></span>\n }\n <button type=\"button\" class=\"btn btn-icon form-control-feedback clear-btn\" aria-label=\"Clear\" [ngClass]=\"{'show-btn': isQueryEntered()}\" (click)=\"clearSearch($event, true)\">\n <wm-app-icon [iconclass]=\"clearsearchiconclass\" [iconurl]=\"clearsearchiconurl\" alt=\"Clear\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Clear button</span>\n @if (showsearchicon) {\n <span [ngClass]=\"{'disabled': disabled}\" class=\"input-group-addon\">\n <form>\n <button title=\"Search\" [disabled]=\"disabled\" class=\"app-search-button btn btn-icon\" type=\"submit\"\n (click)=\"onSearchSelect($event)\">\n <wm-app-icon [iconclass]=\"searchiconclass\" [iconurl]=\"searchiconurl\" alt=\"Search\"></wm-app-icon>\n </button>\n </form>\n </span>\n }\n }\n <!--This template is for both web and fullscreen mode in mobile.-->\n",
|
|
892
|
+
dependencies: [
|
|
893
|
+
{
|
|
894
|
+
kind: "ngmodule",
|
|
895
|
+
type: CommonModule
|
|
896
|
+
},
|
|
897
|
+
{
|
|
898
|
+
kind: "directive",
|
|
899
|
+
type: i2.NgClass,
|
|
900
|
+
selector: "[ngClass]",
|
|
901
|
+
inputs: ["class", "ngClass"]
|
|
902
|
+
},
|
|
903
|
+
{
|
|
904
|
+
kind: "directive",
|
|
905
|
+
type: i2.NgTemplateOutlet,
|
|
906
|
+
selector: "[ngTemplateOutlet]",
|
|
907
|
+
inputs: [
|
|
908
|
+
"ngTemplateOutletContext",
|
|
909
|
+
"ngTemplateOutlet",
|
|
910
|
+
"ngTemplateOutletInjector"
|
|
911
|
+
]
|
|
912
|
+
},
|
|
913
|
+
{
|
|
914
|
+
kind: "ngmodule",
|
|
915
|
+
type: FormsModule
|
|
916
|
+
},
|
|
917
|
+
{
|
|
918
|
+
kind: "directive",
|
|
919
|
+
type: i3.ɵNgNoValidate,
|
|
920
|
+
selector: "form:not([ngNoForm]):not([ngNativeValidate])"
|
|
921
|
+
},
|
|
922
|
+
{
|
|
923
|
+
kind: "directive",
|
|
924
|
+
type: i3.DefaultValueAccessor,
|
|
925
|
+
selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]"
|
|
926
|
+
},
|
|
927
|
+
{
|
|
928
|
+
kind: "directive",
|
|
929
|
+
type: i3.NgControlStatus,
|
|
930
|
+
selector: "[formControlName],[ngModel],[formControl]"
|
|
931
|
+
},
|
|
932
|
+
{
|
|
933
|
+
kind: "directive",
|
|
934
|
+
type: i3.NgControlStatusGroup,
|
|
935
|
+
selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]"
|
|
936
|
+
},
|
|
937
|
+
{
|
|
938
|
+
kind: "directive",
|
|
939
|
+
type: i3.NgModel,
|
|
940
|
+
selector: "[ngModel]:not([formControlName]):not([formControl])",
|
|
941
|
+
inputs: [
|
|
942
|
+
"name",
|
|
943
|
+
"disabled",
|
|
944
|
+
"ngModel",
|
|
945
|
+
"ngModelOptions"
|
|
946
|
+
],
|
|
947
|
+
outputs: ["ngModelChange"],
|
|
948
|
+
exportAs: ["ngModel"]
|
|
949
|
+
},
|
|
950
|
+
{
|
|
951
|
+
kind: "directive",
|
|
952
|
+
type: i3.NgForm,
|
|
953
|
+
selector: "form:not([ngNoForm]):not([formGroup]):not([formArray]),ng-form,[ngForm]",
|
|
954
|
+
inputs: ["ngFormOptions"],
|
|
955
|
+
outputs: ["ngSubmit"],
|
|
956
|
+
exportAs: ["ngForm"]
|
|
957
|
+
},
|
|
958
|
+
{
|
|
959
|
+
kind: "directive",
|
|
960
|
+
type: ScrollableDirective,
|
|
961
|
+
selector: "[scrollableHandler]"
|
|
962
|
+
},
|
|
963
|
+
{
|
|
964
|
+
kind: "ngmodule",
|
|
965
|
+
type: TypeaheadModule
|
|
966
|
+
},
|
|
967
|
+
{
|
|
968
|
+
kind: "directive",
|
|
969
|
+
type: i4.TypeaheadDirective,
|
|
970
|
+
selector: "[typeahead]",
|
|
971
|
+
inputs: [
|
|
972
|
+
"typeahead",
|
|
973
|
+
"typeaheadMinLength",
|
|
974
|
+
"adaptivePosition",
|
|
975
|
+
"isAnimated",
|
|
976
|
+
"typeaheadWaitMs",
|
|
977
|
+
"typeaheadOptionsLimit",
|
|
978
|
+
"typeaheadOptionField",
|
|
979
|
+
"typeaheadGroupField",
|
|
980
|
+
"typeaheadOrderBy",
|
|
981
|
+
"typeaheadAsync",
|
|
982
|
+
"typeaheadLatinize",
|
|
983
|
+
"typeaheadSingleWords",
|
|
984
|
+
"typeaheadWordDelimiters",
|
|
985
|
+
"typeaheadMultipleSearch",
|
|
986
|
+
"typeaheadMultipleSearchDelimiters",
|
|
987
|
+
"typeaheadPhraseDelimiters",
|
|
988
|
+
"typeaheadItemTemplate",
|
|
989
|
+
"optionsListTemplate",
|
|
990
|
+
"typeaheadScrollable",
|
|
991
|
+
"typeaheadOptionsInScrollableView",
|
|
992
|
+
"typeaheadHideResultsOnBlur",
|
|
993
|
+
"typeaheadSelectFirstItem",
|
|
994
|
+
"typeaheadIsFirstItemActive",
|
|
995
|
+
"container",
|
|
996
|
+
"dropup"
|
|
997
|
+
],
|
|
998
|
+
outputs: [
|
|
999
|
+
"typeaheadLoading",
|
|
1000
|
+
"typeaheadNoResults",
|
|
1001
|
+
"typeaheadOnSelect",
|
|
1002
|
+
"typeaheadOnPreview",
|
|
1003
|
+
"typeaheadOnBlur"
|
|
1004
|
+
],
|
|
1005
|
+
exportAs: ["bs-typeahead"]
|
|
1006
|
+
},
|
|
1007
|
+
{
|
|
1008
|
+
kind: "directive",
|
|
1009
|
+
type: TextContentDirective,
|
|
1010
|
+
selector: "[textContent]",
|
|
1011
|
+
inputs: ["textContent"]
|
|
1012
|
+
},
|
|
1013
|
+
{
|
|
1014
|
+
kind: "directive",
|
|
1015
|
+
type: ItemTemplateDirective,
|
|
1016
|
+
selector: "[wmItemTemplate]",
|
|
1017
|
+
inputs: ["userComponentParams", "wmItemTemplate"],
|
|
1018
|
+
exportAs: ["itemTemplateRef"]
|
|
1019
|
+
},
|
|
1020
|
+
{
|
|
1021
|
+
kind: "directive",
|
|
1022
|
+
type: PartialParamHandlerDirective,
|
|
1023
|
+
selector: "[partialContainer]"
|
|
1024
|
+
},
|
|
1025
|
+
{
|
|
1026
|
+
kind: "directive",
|
|
1027
|
+
type: PartialContainerDirective,
|
|
1028
|
+
selector: "[partialContainer]"
|
|
1029
|
+
},
|
|
1030
|
+
{
|
|
1031
|
+
kind: "component",
|
|
1032
|
+
type: WmAppIconComponent,
|
|
1033
|
+
selector: "wm-app-icon",
|
|
1034
|
+
inputs: [
|
|
1035
|
+
"icon",
|
|
1036
|
+
"iconclass",
|
|
1037
|
+
"iconurl",
|
|
1038
|
+
"defaultIconClass",
|
|
1039
|
+
"defaultClasses",
|
|
1040
|
+
"iconStyle",
|
|
1041
|
+
"alt"
|
|
1042
|
+
]
|
|
1043
|
+
}
|
|
1044
|
+
],
|
|
1045
|
+
changeDetection: i0.ChangeDetectionStrategy.Eager
|
|
1046
|
+
});
|
|
1047
|
+
}
|
|
1048
|
+
};
|
|
1049
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
1050
|
+
minVersion: "12.0.0",
|
|
1051
|
+
version: "22.2.1",
|
|
1052
|
+
ngImport: i0,
|
|
1053
|
+
type: SearchComponent,
|
|
1054
|
+
decorators: [{
|
|
1055
|
+
type: Component,
|
|
1056
|
+
args: [{
|
|
1057
|
+
changeDetection: ChangeDetectionStrategy.Eager,
|
|
1058
|
+
standalone: true,
|
|
1059
|
+
imports: [
|
|
1060
|
+
CommonModule,
|
|
1061
|
+
FormsModule,
|
|
1062
|
+
ScrollableDirective,
|
|
1063
|
+
TypeaheadModule,
|
|
1064
|
+
TextContentDirective,
|
|
1065
|
+
ItemTemplateDirective,
|
|
1066
|
+
PartialParamHandlerDirective,
|
|
1067
|
+
PartialContainerDirective,
|
|
1068
|
+
WmAppIconComponent
|
|
1069
|
+
],
|
|
1070
|
+
selector: "[wmSearch]",
|
|
1071
|
+
providers: [
|
|
1072
|
+
provideAs(SearchComponent, NG_VALUE_ACCESSOR, true),
|
|
1073
|
+
provideAs(SearchComponent, NG_VALIDATORS, true),
|
|
1074
|
+
provideAsWidgetRef(SearchComponent)
|
|
1075
|
+
],
|
|
1076
|
+
template: "<ng-template #customItemTemplate let-model=\"item\" let-index=\"index\" let-query=\"query\" let-match=\"match\">\n <!-- Default item template -->\n @if (!content) {\n <a>\n @if (model.imgSrc) {\n <img [src]=\"model.imgSrc\" alt=\"Search\" [style.width]=\"imagewidth\">\n }\n <span [title]=\"model.label\" [innerHtml]=\"highlight(match, query) || model.label\"></span>\n </a>\n }\n <!-- Custom partial template -->\n @if (content) {\n <a [ngClass]=\"{customTemplate: content}\" partialContainer [wmItemTemplate]=\"content\" [userComponentParams]=\"match.item\">\n <div partial-container-target></div>\n </a>\n }\n</ng-template>\n\n<ng-template #customListTemplate let-matches=\"matches\" let-itemTemplate=\"itemTemplate\" let-query=\"query\">\n <ul #ulElement class=\"app-search dropdown-menu\" scrollableHandler>\n @for (match of matches; track match; let i = $index) {\n <li #liElements [ngClass]=\"{active: typeaheadContainer && typeaheadContainer.isActive(match), 'list-group-header': match && match.isHeader()}\"\n (mouseenter)=\"typeaheadContainer.selectActive(match);\"\n (click)=\"match && !match.isHeader() && typeaheadContainer.selectMatch(match, $event); $typeaheadEvent = $event; notifySubscriber();\">\n <!-- itemTemplate comes from the <input> -->\n @if (match.isHeader()) {\n <h4 class=\"group-title\">{{match.value}}</h4>\n }\n @if (!match.isHeader()) {\n <ng-container [ngTemplateOutlet]=\"itemTemplate\"\n [ngTemplateOutletContext]=\"{item: match.item, index: i, match: match, query: query}\">\n </ng-container>\n }\n </li>\n }\n <div class=\"status\" [hidden]=\"_loadingItems || !(datacompletemsg && dataProvider?.isLastPage)\">\n <span [textContent]=\"datacompletemsg\"></span>\n </div>\n <div class=\"status\" [hidden]=\"!_loadingItems\">\n <i class=\"fa fa-circle-o-notch fa-spin\"></i>\n <span [textContent]=\"loadingdatamsg\"></span>\n </div>\n </ul>\n</ng-template>\n\n<!--This template is for search inside mobile navbar.-->\n@if (navsearchbar) {\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n container=\"body\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event)\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event);\"\n (focusout)=\"onFocusOut()\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [dropup]=\"dropup\"\n [tabindex]=\"tabindex\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\"/>\n <i class=\"btn-close wi wi-cancel\" [hidden]=\"!showClosebtn\" (click)=\"clearSearch($event);\"></i>\n} @else {\n <button type=\"button\" class=\"btn btn-icon form-control-feedback back-btn\" aria-hidden=\"true\" aria-label=\"Back\" (click)=\"closeSearch()\">\n <wm-app-icon [iconclass]=\"backsearchiconclass\" [iconurl]=\"backsearchiconurl\" alt=\"Back\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Back button</span>\n <input [title]=\"query || ''\" type=\"text\" class=\"app-textbox form-control list-of-objs app-search-input\" [placeholder]=\"placeholder || ''\"\n focus-target\n [container]=\"containerTarget || '.wm-app'\"\n [disabled]=\"disabled\"\n [attr.accesskey]=\"shortcutkey\"\n autocomplete=\"off\"\n [(ngModel)]=\"query\"\n [ngModelOptions]=\"{standalone: true}\"\n [readonly]=\"readonly\"\n [typeahead]=\"typeaheadDataSource\"\n [typeaheadWaitMs]=\"debouncetime\"\n [typeaheadItemTemplate]=\"customItemTemplate\"\n [optionsListTemplate]=\"customListTemplate\"\n (input)=\"onInputChange($event)\"\n (keydown)=\"listenQuery = true\"\n (keydown.enter)=\"$typeaheadEvent = $event;handleEnterEvent($event)\"\n (keydown.arrowdown)=\"selectNext($event)\"\n (blur)=\"invokeOnTouched($event); onFocusOut()\"\n (click)=\"handleFocus($event);\"\n (focus)=\"_unsubscribeDv = false; listenQuery = true; handleFocus($event); invokeOnFocus($event)\"\n [typeaheadMinLength]=\"minchars\"\n [typeaheadOptionsLimit]=\"typeaheadOptionsLimit\"\n (typeaheadLoading)=\"_loadingItems\"\n (typeaheadOnSelect)=\"typeaheadOnSelect($event)\"\n typeaheadOptionField=\"label\"\n [typeaheadGroupField]=\"groupby ? 'groupby' : null\"\n [typeaheadAsync]=\"true\"\n [typeaheadScrollable]=\"true\"\n [adaptivePosition]=\"true\"\n [typeaheadOptionsInScrollableView]=\"optionslimitinscrollableview\"\n [tabindex]=\"tabindex\"\n [dropup]=\"dropup\"\n [attr.name]=\"name\"\n [attr.aria-label]=\"arialabel || 'Search field'\">\n <input aria-label=\"Search value\" class=\"model-holder\" ng-model=\"proxyModel\" ng-required=\"required\" tabindex=\"-1\" aria-hidden=\"true\">\n @if (_loadingItems) {\n <span aria-hidden=\"true\" class=\"fa fa-circle-o-notch fa-spin form-control-feedback\"></span>\n }\n <button type=\"button\" class=\"btn btn-icon form-control-feedback clear-btn\" aria-label=\"Clear\" [ngClass]=\"{'show-btn': isQueryEntered()}\" (click)=\"clearSearch($event, true)\">\n <wm-app-icon [iconclass]=\"clearsearchiconclass\" [iconurl]=\"clearsearchiconurl\" alt=\"Clear\"></wm-app-icon>\n </button>\n <span class=\"sr-only\">Clear button</span>\n @if (showsearchicon) {\n <span [ngClass]=\"{'disabled': disabled}\" class=\"input-group-addon\">\n <form>\n <button title=\"Search\" [disabled]=\"disabled\" class=\"app-search-button btn btn-icon\" type=\"submit\"\n (click)=\"onSearchSelect($event)\">\n <wm-app-icon [iconclass]=\"searchiconclass\" [iconurl]=\"searchiconurl\" alt=\"Search\"></wm-app-icon>\n </button>\n </form>\n </span>\n }\n }\n <!--This template is for both web and fullscreen mode in mobile.-->\n"
|
|
1077
|
+
}]
|
|
1078
|
+
}],
|
|
1079
|
+
ctorParameters: () => [
|
|
1080
|
+
{ type: i0.Injector },
|
|
1081
|
+
{ type: i1.App },
|
|
1082
|
+
{
|
|
1083
|
+
type: void 0,
|
|
1084
|
+
decorators: [{
|
|
1085
|
+
type: Attribute,
|
|
1086
|
+
args: ["datavalue.bind"]
|
|
1087
|
+
}]
|
|
1088
|
+
},
|
|
1089
|
+
{
|
|
1090
|
+
type: void 0,
|
|
1091
|
+
decorators: [{
|
|
1092
|
+
type: Attribute,
|
|
1093
|
+
args: ["dataset.bind"]
|
|
1094
|
+
}]
|
|
1095
|
+
},
|
|
1096
|
+
{
|
|
1097
|
+
type: void 0,
|
|
1098
|
+
decorators: [{
|
|
1099
|
+
type: Inject,
|
|
1100
|
+
args: ["EXPLICIT_CONTEXT"]
|
|
1101
|
+
}, { type: Optional }]
|
|
1102
|
+
}
|
|
1103
|
+
],
|
|
1104
|
+
propDecorators: {
|
|
1105
|
+
typeahead: [{
|
|
1106
|
+
type: ViewChild,
|
|
1107
|
+
args: [TypeaheadDirective]
|
|
1108
|
+
}],
|
|
1109
|
+
ulElement: [{
|
|
1110
|
+
type: ViewChild,
|
|
1111
|
+
args: ["ulElement"]
|
|
1112
|
+
}],
|
|
1113
|
+
liElements: [{
|
|
1114
|
+
type: ViewChildren,
|
|
1115
|
+
args: ["liElements"]
|
|
1116
|
+
}]
|
|
1117
|
+
}
|
|
1118
|
+
});
|
|
1086
1119
|
export { ScrollableDirective, SearchComponent };
|
|
1087
|
-
|
|
1120
|
+
|
|
1121
|
+
//# sourceMappingURL=index.mjs.map
|