@sdcorejs/angular 20.3.4 → 20.3.6
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/assets/STYLE-GUIDE.md +78 -1
- package/assets/THEME.md +45 -3
- package/assets/scss/core/_popover-panel.scss +90 -0
- package/assets/scss/core/form.scss +5 -2
- package/assets/scss/core/utilities/_grid.scss +15 -0
- package/assets/scss/core/utilities/_sizing.scss +4 -0
- package/assets/scss/themes/_component-tokens.scss +9 -4
- package/assets/scss/themes/_semantic.scss +6 -5
- package/components/anchor/index.d.ts +6 -1
- package/components/button/index.d.ts +7 -1
- package/components/calendar/index.d.ts +1092 -0
- package/components/card/index.d.ts +247 -9
- package/components/index.d.ts +3 -1
- package/components/kanban/index.d.ts +191 -74
- package/components/modal/index.d.ts +15 -1
- package/components/query-bar/index.d.ts +204 -38
- package/components/quick-action/index.d.ts +65 -1
- package/components/scheduler/index.d.ts +544 -0
- package/components/tab/index.d.ts +6 -1
- package/components/table/index.d.ts +338 -31
- package/components/timeline/index.d.ts +216 -0
- package/components/tree/index.d.ts +119 -6
- package/directives/index.d.ts +4 -2
- package/fesm2022/sdcorejs-angular-components-anchor.mjs +62 -3
- package/fesm2022/sdcorejs-angular-components-anchor.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-button.mjs +14 -6
- package/fesm2022/sdcorejs-angular-components-button.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-calendar.mjs +2481 -0
- package/fesm2022/sdcorejs-angular-components-calendar.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-components-card.mjs +486 -23
- package/fesm2022/sdcorejs-angular-components-card.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-editor-engine.mjs +1 -1
- package/fesm2022/sdcorejs-angular-components-editor-engine.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-file-explorer.mjs +4 -18
- package/fesm2022/sdcorejs-angular-components-file-explorer.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-form-generic.mjs +7 -7
- package/fesm2022/sdcorejs-angular-components-form-generic.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-import-excel.mjs +1 -1
- package/fesm2022/sdcorejs-angular-components-import-excel.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-kanban.mjs +833 -154
- package/fesm2022/sdcorejs-angular-components-kanban.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-modal.mjs +69 -14
- package/fesm2022/sdcorejs-angular-components-modal.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-query-bar.mjs +1477 -365
- package/fesm2022/sdcorejs-angular-components-query-bar.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-quick-action.mjs +68 -2
- package/fesm2022/sdcorejs-angular-components-quick-action.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-scheduler.mjs +1934 -0
- package/fesm2022/sdcorejs-angular-components-scheduler.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-components-side-drawer.mjs +2 -2
- package/fesm2022/sdcorejs-angular-components-side-drawer.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-tab-router.mjs +126 -26
- package/fesm2022/sdcorejs-angular-components-tab-router.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-tab.mjs +31 -2
- package/fesm2022/sdcorejs-angular-components-tab.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-table.mjs +5967 -3690
- package/fesm2022/sdcorejs-angular-components-table.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-timeline.mjs +473 -0
- package/fesm2022/sdcorejs-angular-components-timeline.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-components-tree.mjs +597 -36
- package/fesm2022/sdcorejs-angular-components-tree.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-upload-file.mjs +2 -4
- package/fesm2022/sdcorejs-angular-components-upload-file.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components.mjs +3 -1
- package/fesm2022/sdcorejs-angular-components.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-directives.mjs +109 -22
- package/fesm2022/sdcorejs-angular-directives.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-date.mjs +140 -42
- package/fesm2022/sdcorejs-angular-forms-date.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-datetime.mjs +70 -21
- package/fesm2022/sdcorejs-angular-forms-datetime.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-directives.mjs +4 -3
- package/fesm2022/sdcorejs-angular-forms-directives.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-entity-picker.mjs +1 -1
- package/fesm2022/sdcorejs-angular-forms-entity-picker.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-select.mjs +23 -4
- package/fesm2022/sdcorejs-angular-forms-select.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-tree-select.mjs +1 -1
- package/fesm2022/sdcorejs-angular-forms-tree-select.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-i18n.mjs +812 -52
- package/fesm2022/sdcorejs-angular-i18n.mjs.map +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-configuration.page-D_1BxDC9.mjs → sdcorejs-angular-modules-generic-generic-configuration.page-w7iVesRB.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-configuration.page-D_1BxDC9.mjs.map → sdcorejs-angular-modules-generic-generic-configuration.page-w7iVesRB.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-form-host.page-CgH8Qi25.mjs → sdcorejs-angular-modules-generic-generic-form-host.page-DwGr3EVD.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-form-host.page-CgH8Qi25.mjs.map → sdcorejs-angular-modules-generic-generic-form-host.page-DwGr3EVD.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-list.page-CyCGqW9W.mjs → sdcorejs-angular-modules-generic-generic-list.page-QqBNS185.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-list.page-CyCGqW9W.mjs.map → sdcorejs-angular-modules-generic-generic-list.page-QqBNS185.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-DTmU8Te4.mjs → sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-_WrprZ_o.mjs} +4 -4
- package/fesm2022/{sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-DTmU8Te4.mjs.map → sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-_WrprZ_o.mjs.map} +1 -1
- package/fesm2022/sdcorejs-angular-modules-generic.mjs +1 -1
- package/fesm2022/sdcorejs-angular-modules-layout.mjs +17 -8
- package/fesm2022/sdcorejs-angular-modules-layout.mjs.map +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-base-api.service-okZVmcd5.mjs → sdcorejs-angular-modules-pattern-base-api.service-B2HMyv8F.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-base-api.service-okZVmcd5.mjs.map → sdcorejs-angular-modules-pattern-base-api.service-B2HMyv8F.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-create.component-LPUj7MqG.mjs → sdcorejs-angular-modules-pattern-create.component-CNtkbnRK.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-create.component-LPUj7MqG.mjs.map → sdcorejs-angular-modules-pattern-create.component-CNtkbnRK.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-create.component-2-dyjvCH.mjs → sdcorejs-angular-modules-pattern-create.component-DlNyY3e7.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-create.component-2-dyjvCH.mjs.map → sdcorejs-angular-modules-pattern-create.component-DlNyY3e7.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-create.component-BCoG3bVV.mjs → sdcorejs-angular-modules-pattern-create.component-DxV_0Ckg.mjs} +11 -7
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-DxV_0Ckg.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-customer.service-Caua6Xto.mjs → sdcorejs-angular-modules-pattern-customer.service-DS0cFc3u.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-customer.service-Caua6Xto.mjs.map → sdcorejs-angular-modules-pattern-customer.service-DS0cFc3u.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-detail.component-_c_4slgf.mjs → sdcorejs-angular-modules-pattern-detail.component-B_1ppVNA.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-detail.component-_c_4slgf.mjs.map → sdcorejs-angular-modules-pattern-detail.component-B_1ppVNA.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-detail.component-B2Y0PbbC.mjs → sdcorejs-angular-modules-pattern-detail.component-CFvwPHFx.mjs} +58 -55
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-CFvwPHFx.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-flow.component-C_HziBQN.mjs → sdcorejs-angular-modules-pattern-flow.component-Ba4xO_tF.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-pattern-flow.component-C_HziBQN.mjs.map → sdcorejs-angular-modules-pattern-flow.component-Ba4xO_tF.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-index.component-B2dNqckm.mjs → sdcorejs-angular-modules-pattern-index.component-DvwY0K3t.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-index.component-B2dNqckm.mjs.map → sdcorejs-angular-modules-pattern-index.component-DvwY0K3t.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-lines-table-form.component-Dq8Q8Vfm.mjs → sdcorejs-angular-modules-pattern-lines-table-form.component-BSAQaAgH.mjs} +5 -5
- package/fesm2022/{sdcorejs-angular-modules-pattern-lines-table-form.component-Dq8Q8Vfm.mjs.map → sdcorejs-angular-modules-pattern-lines-table-form.component-BSAQaAgH.mjs.map} +1 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-BIv2k6NI.mjs +506 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-BIv2k6NI.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-list.component-CeX57FPi.mjs → sdcorejs-angular-modules-pattern-list.component-BYyL5Q5n.mjs} +30 -39
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-BYyL5Q5n.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CZRTnqNx.mjs +501 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CZRTnqNx.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-list.component-DS8A17mM.mjs → sdcorejs-angular-modules-pattern-list.component-DF7CvaVG.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-pattern-list.component-DS8A17mM.mjs.map → sdcorejs-angular-modules-pattern-list.component-DF7CvaVG.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-list.component-Bs9hhMr7.mjs → sdcorejs-angular-modules-pattern-list.component-nMyLso8Z.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-pattern-list.component-Bs9hhMr7.mjs.map → sdcorejs-angular-modules-pattern-list.component-nMyLso8Z.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-mock-backend.factory-Dfil91qL.mjs → sdcorejs-angular-modules-pattern-mock-backend.factory-CS7VK5Ol.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-mock-backend.factory-Dfil91qL.mjs.map → sdcorejs-angular-modules-pattern-mock-backend.factory-CS7VK5Ol.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-pattern-source-viewer-BqHwKfoc.mjs → sdcorejs-angular-modules-pattern-pattern-source-viewer-DuhyXsGn.mjs} +4 -22
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source-viewer-DuhyXsGn.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-pattern-source.generated-CIiLOizq.mjs → sdcorejs-angular-modules-pattern-pattern-source.generated-bfpj85ke.mjs} +26 -27
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source.generated-bfpj85ke.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-product.service-PaIGZ1ve.mjs → sdcorejs-angular-modules-pattern-product.service-KKWwzMEG.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-product.service-PaIGZ1ve.mjs.map → sdcorejs-angular-modules-pattern-product.service-KKWwzMEG.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-profile.component-B8j8cieu.mjs → sdcorejs-angular-modules-pattern-profile.component-XDuLwzEl.mjs} +25 -15
- package/fesm2022/sdcorejs-angular-modules-pattern-profile.component-XDuLwzEl.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-0Vh73aXL.mjs → sdcorejs-angular-modules-pattern-routes--ScZNg7A.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-0Vh73aXL.mjs.map → sdcorejs-angular-modules-pattern-routes--ScZNg7A.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-Cw9uJySU.mjs → sdcorejs-angular-modules-pattern-routes-Bka6PaRB.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-Cw9uJySU.mjs.map → sdcorejs-angular-modules-pattern-routes-Bka6PaRB.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-nrxSHE-O.mjs → sdcorejs-angular-modules-pattern-routes-CCwFQAdd.mjs} +4 -4
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-nrxSHE-O.mjs.map → sdcorejs-angular-modules-pattern-routes-CCwFQAdd.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-CFT9DyKj.mjs → sdcorejs-angular-modules-pattern-routes-CKryLRCh.mjs} +8 -8
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-CFT9DyKj.mjs.map → sdcorejs-angular-modules-pattern-routes-CKryLRCh.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-CFLETqYK.mjs → sdcorejs-angular-modules-pattern-routes-Dr72yGSt.mjs} +5 -5
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-CFLETqYK.mjs.map → sdcorejs-angular-modules-pattern-routes-Dr72yGSt.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-BoB2usST.mjs → sdcorejs-angular-modules-pattern-routes-P9WvwSEW.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-pattern-routes-BoB2usST.mjs.map → sdcorejs-angular-modules-pattern-routes-P9WvwSEW.mjs.map} +1 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-_EDJ1-63.mjs +65 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-_EDJ1-63.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-n4kpjO0y.mjs +56 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-n4kpjO0y.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-sdcorejs-angular-modules-pattern-CJ6hUHjk.mjs → sdcorejs-angular-modules-pattern-sdcorejs-angular-modules-pattern-DHhmKKVI.mjs} +12 -12
- package/fesm2022/{sdcorejs-angular-modules-pattern-sdcorejs-angular-modules-pattern-CJ6hUHjk.mjs.map → sdcorejs-angular-modules-pattern-sdcorejs-angular-modules-pattern-DHhmKKVI.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-shell.component-C_AFK_9X.mjs → sdcorejs-angular-modules-pattern-shell.component-DxNC-ixx.mjs} +4 -4
- package/fesm2022/{sdcorejs-angular-modules-pattern-shell.component-C_AFK_9X.mjs.map → sdcorejs-angular-modules-pattern-shell.component-DxNC-ixx.mjs.map} +1 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-TWYHj6in.mjs +480 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-TWYHj6in.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-update.component-B7H9pp-R.mjs → sdcorejs-angular-modules-pattern-update.component-BcBxBqWB.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-update.component-B7H9pp-R.mjs.map → sdcorejs-angular-modules-pattern-update.component-BcBxBqWB.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-pattern-update.component-Dhfba-qx.mjs → sdcorejs-angular-modules-pattern-update.component-BntTyV55.mjs} +9 -6
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-BntTyV55.mjs.map +1 -0
- package/fesm2022/{sdcorejs-angular-modules-pattern-update.component-hRTu79uE.mjs → sdcorejs-angular-modules-pattern-update.component-CJjZWZuz.mjs} +2 -2
- package/fesm2022/{sdcorejs-angular-modules-pattern-update.component-hRTu79uE.mjs.map → sdcorejs-angular-modules-pattern-update.component-CJjZWZuz.mjs.map} +1 -1
- package/fesm2022/sdcorejs-angular-modules-pattern.mjs +1 -1
- package/fesm2022/sdcorejs-angular-services-confirm.mjs +171 -158
- package/fesm2022/sdcorejs-angular-services-confirm.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-services-excel.mjs +34 -0
- package/fesm2022/sdcorejs-angular-services-excel.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-services-query-params.mjs +226 -0
- package/fesm2022/sdcorejs-angular-services-query-params.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-utilities-extensions.mjs +24 -1
- package/fesm2022/sdcorejs-angular-utilities-extensions.mjs.map +1 -1
- package/forms/date/index.d.ts +2 -0
- package/forms/directives/index.d.ts +1 -1
- package/i18n/index.d.ts +159 -9
- package/modules/layout/index.d.ts +2 -1
- package/modules/pattern/README.md +5 -4
- package/modules/pattern/docs/detail.md +18 -9
- package/modules/pattern/docs/drawer.md +185 -83
- package/modules/pattern/docs/header-actions.md +1 -1
- package/modules/pattern/docs/list.md +3 -3
- package/modules/pattern/docs/states.md +1 -1
- package/modules/pattern/features/category/components/create-side-drawer/create-side-drawer.component.ts +12 -16
- package/modules/pattern/features/category/components/update-side-drawer/update-side-drawer.component.ts +58 -29
- package/modules/pattern/features/category/pages/list/list.component.html +11 -3
- package/modules/pattern/features/category/pages/list/list.component.ts +36 -10
- package/modules/pattern/features/category/routes.ts +5 -22
- package/modules/pattern/features/customer/components/create-side-drawer/create-side-drawer.component.ts +7 -11
- package/modules/pattern/features/customer/components/detail-side-drawer/detail-side-drawer.component.ts +70 -27
- package/modules/pattern/features/customer/components/summary-cards/summary-cards.component.ts +9 -53
- package/modules/pattern/features/customer/components/update-side-drawer/update-side-drawer.component.ts +53 -19
- package/modules/pattern/features/customer/entity.resolver.ts +1 -1
- package/modules/pattern/features/customer/pages/list/list.component.html +18 -3
- package/modules/pattern/features/customer/pages/list/list.component.ts +43 -16
- package/modules/pattern/features/customer/pages/profile/profile.component.ts +17 -8
- package/modules/pattern/features/customer/routes.ts +6 -27
- package/modules/pattern/features/order/components/approval-steps/approval-steps.component.ts +37 -56
- package/modules/pattern/features/order/components/summary-cards/summary-cards.component.ts +14 -76
- package/modules/pattern/features/order/pages/create/create.component.ts +7 -3
- package/modules/pattern/features/order/pages/detail/detail.component.ts +1 -1
- package/modules/pattern/features/order/pages/update/update.component.ts +5 -2
- package/package.json +17 -5
- package/services/confirm/index.d.ts +22 -81
- package/services/excel/index.d.ts +59 -0
- package/services/query-params/index.d.ts +67 -0
- package/utilities/extensions/index.d.ts +10 -1
- package/components/history/index.d.ts +0 -23
- package/fesm2022/sdcorejs-angular-components-history.mjs +0 -54
- package/fesm2022/sdcorejs-angular-components-history.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-CB4F9cBe.mjs +0 -144
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-CB4F9cBe.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-CowdEzyv.mjs +0 -145
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-CowdEzyv.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-BCoG3bVV.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-customer.model-C3fr4yNw.mjs +0 -18
- package/fesm2022/sdcorejs-angular-modules-pattern-customer.model-C3fr4yNw.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-detail-side-drawer.component-Bu6E63bN.mjs +0 -148
- package/fesm2022/sdcorejs-angular-modules-pattern-detail-side-drawer.component-Bu6E63bN.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-B2Y0PbbC.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-BRsdOwWy.mjs +0 -87
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-BRsdOwWy.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-DalxHa8D.mjs +0 -232
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-DalxHa8D.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-view.component-kdEZ9s7K.mjs +0 -70
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-view.component-kdEZ9s7K.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-B3-th1z4.mjs +0 -164
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-B3-th1z4.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CRttQEXa.mjs +0 -118
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CRttQEXa.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CeX57FPi.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source-viewer-BqHwKfoc.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source.generated-CIiLOizq.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-profile.component-B8j8cieu.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-CZusLcS3.mjs +0 -74
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-CZusLcS3.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-Cq4BqjE9.mjs +0 -99
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-Cq4BqjE9.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-C74EEboR.mjs +0 -143
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-C74EEboR.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-Dj9lvkCP.mjs +0 -132
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-Dj9lvkCP.mjs.map +0 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-Dhfba-qx.mjs.map +0 -1
- package/modules/pattern/features/category/entity.resolver.ts +0 -27
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ChangeDetectionStrategy, Component, computed, inject, input, linkedSignal, model } from '@angular/core';
|
|
2
|
-
import { SdCard, SdCardGroup } from '@sdcorejs/angular/components/card';
|
|
2
|
+
import { SdCard, SdCardGroup, type SdCardContent } from '@sdcorejs/angular/components/card';
|
|
3
3
|
import { SD_PAGE_LIST } from '@sdcorejs/angular/modules/layout';
|
|
4
4
|
import type { OrderCounts, OrderStatus } from '../../services/order.model';
|
|
5
5
|
|
|
@@ -11,15 +11,9 @@ const CARDS: readonly { readonly key: CardKey; readonly label: string }[] = [
|
|
|
11
11
|
{ key: 'shipping', label: 'Đang giao' },
|
|
12
12
|
];
|
|
13
13
|
|
|
14
|
-
/** 1.234.567.890 → "1,2 tỷ"; 350.000.000 → "350 triệu". */
|
|
15
|
-
function money(value: number): string {
|
|
16
|
-
if (value >= 1_000_000_000) return `${(value / 1_000_000_000).toLocaleString('vi-VN', { maximumFractionDigits: 1 })} tỷ`;
|
|
17
|
-
return `${Math.round(value / 1_000_000).toLocaleString('vi-VN')} triệu`;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
14
|
/**
|
|
21
15
|
* Score card của danh sách đơn: ba thẻ đầu lọc theo trạng thái, đồng bộ với tab vì cùng một state; thẻ doanh thu
|
|
22
|
-
* chỉ để xem. Khi `sd-page-list` thu gọn (màn thấp),
|
|
16
|
+
* là thẻ `static` cuối nhóm, chỉ để xem. Khi `sd-page-list` thu gọn (màn thấp), thẻ tự về size `sm` (một dòng 32px) và nhóm xếp thành hàng.
|
|
23
17
|
*/
|
|
24
18
|
@Component({
|
|
25
19
|
selector: 'summary-cards',
|
|
@@ -28,77 +22,18 @@ function money(value: number): string {
|
|
|
28
22
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
29
23
|
template: `
|
|
30
24
|
<sd-card-group
|
|
31
|
-
class="
|
|
25
|
+
class="sd-card-grid"
|
|
32
26
|
autoId="order-summary"
|
|
33
27
|
aria-label="Tóm tắt đơn hàng"
|
|
34
|
-
[class.
|
|
28
|
+
[class.sd-card-grid--sm]="compact()"
|
|
35
29
|
[(model)]="selected"
|
|
36
30
|
(sdChange)="choose($event)">
|
|
37
31
|
@for (card of cards(); track card.key) {
|
|
38
|
-
<sd-card
|
|
39
|
-
<span class="summary__label">{{ card.label }}</span>
|
|
40
|
-
<strong class="summary__value">{{ card.value }}</strong>
|
|
41
|
-
</sd-card>
|
|
32
|
+
<sd-card [value]="card.key" [autoId]="'order-summary-' + card.key" [loading]="!counts()" [content]="card.content" />
|
|
42
33
|
}
|
|
43
|
-
<
|
|
44
|
-
<span class="summary__label">Doanh thu hoàn tất</span>
|
|
45
|
-
<strong class="summary__value">{{ revenue() }}</strong>
|
|
46
|
-
</div>
|
|
34
|
+
<sd-card behavior="static" autoId="order-summary-revenue" [loading]="!counts()" [content]="revenue()" />
|
|
47
35
|
</sd-card-group>
|
|
48
36
|
`,
|
|
49
|
-
styles: `
|
|
50
|
-
.summary {
|
|
51
|
-
display: grid;
|
|
52
|
-
grid-template-columns: repeat(4, minmax(0, 1fr));
|
|
53
|
-
gap: 12px;
|
|
54
|
-
}
|
|
55
|
-
.summary__card {
|
|
56
|
-
display: flex;
|
|
57
|
-
flex-direction: column;
|
|
58
|
-
gap: 4px;
|
|
59
|
-
padding: 12px 16px;
|
|
60
|
-
}
|
|
61
|
-
.summary__card--static {
|
|
62
|
-
border: 1px solid var(--sd-border);
|
|
63
|
-
border-radius: 8px;
|
|
64
|
-
background: var(--sd-surface);
|
|
65
|
-
}
|
|
66
|
-
.summary__label {
|
|
67
|
-
color: var(--sd-text-secondary);
|
|
68
|
-
font-size: 13px;
|
|
69
|
-
}
|
|
70
|
-
.summary__value {
|
|
71
|
-
font-size: 22px;
|
|
72
|
-
line-height: 28px;
|
|
73
|
-
font-weight: 500;
|
|
74
|
-
font-variant-numeric: tabular-nums;
|
|
75
|
-
}
|
|
76
|
-
.summary--compact {
|
|
77
|
-
display: flex;
|
|
78
|
-
align-items: center;
|
|
79
|
-
gap: 8px;
|
|
80
|
-
height: 36px;
|
|
81
|
-
}
|
|
82
|
-
.summary--compact .summary__card {
|
|
83
|
-
flex-direction: row;
|
|
84
|
-
align-items: baseline;
|
|
85
|
-
gap: 6px;
|
|
86
|
-
padding: 4px 10px;
|
|
87
|
-
}
|
|
88
|
-
.summary--compact .summary__card--static {
|
|
89
|
-
border: 0;
|
|
90
|
-
background: transparent;
|
|
91
|
-
}
|
|
92
|
-
.summary--compact .summary__value {
|
|
93
|
-
font-size: 14px;
|
|
94
|
-
line-height: 20px;
|
|
95
|
-
}
|
|
96
|
-
@media (max-width: 767px) {
|
|
97
|
-
.summary {
|
|
98
|
-
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
`,
|
|
102
37
|
})
|
|
103
38
|
export class SummaryCardsComponent {
|
|
104
39
|
readonly counts = input<OrderCounts | null>(null);
|
|
@@ -106,7 +41,10 @@ export class SummaryCardsComponent {
|
|
|
106
41
|
readonly status = model<OrderStatus | null>(null);
|
|
107
42
|
protected readonly cards = computed(() => {
|
|
108
43
|
const counts = this.counts();
|
|
109
|
-
return CARDS.map(card =>
|
|
44
|
+
return CARDS.map(card => {
|
|
45
|
+
const content: SdCardContent = { layout: 'stat', data: { label: card.label, value: counts ? counts[card.key] : null } };
|
|
46
|
+
return { key: card.key, content };
|
|
47
|
+
});
|
|
110
48
|
});
|
|
111
49
|
protected readonly compact = inject(SD_PAGE_LIST).compact;
|
|
112
50
|
/** Trạng thái chọn từ tab mà không có thẻ (Hoàn tất, Đã huỷ): không thẻ nào sáng. */
|
|
@@ -114,10 +52,10 @@ export class SummaryCardsComponent {
|
|
|
114
52
|
const status = this.status();
|
|
115
53
|
return status === null ? 'all' : status === 'pending' || status === 'shipping' ? status : null;
|
|
116
54
|
});
|
|
117
|
-
protected readonly revenue = computed(() => {
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
});
|
|
55
|
+
protected readonly revenue = computed<SdCardContent>(() => ({
|
|
56
|
+
layout: 'stat',
|
|
57
|
+
data: { label: 'Doanh thu hoàn tất', value: this.counts()?.revenue ?? null, format: 'compact' },
|
|
58
|
+
}));
|
|
121
59
|
|
|
122
60
|
protected choose(key: unknown): void {
|
|
123
61
|
// Bấm lại thẻ đang chọn (model về null) hoặc thẻ Tổng đơn đều là bỏ lọc.
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { afterNextRender, ChangeDetectionStrategy, Component, DestroyRef, ElementRef, inject, Injector, signal } from '@angular/core';
|
|
2
2
|
import { FormGroup } from '@angular/forms';
|
|
3
3
|
import { ActivatedRoute, Router } from '@angular/router';
|
|
4
|
-
import {
|
|
4
|
+
import { toSignal } from '@angular/core/rxjs-interop';
|
|
5
|
+
import { firstValueFrom, map } from 'rxjs';
|
|
5
6
|
import { SdButton } from '@sdcorejs/angular/components/button';
|
|
6
7
|
import { SdSection } from '@sdcorejs/angular/components/section';
|
|
7
8
|
import { SdTextarea } from '@sdcorejs/angular/forms/textarea';
|
|
@@ -42,7 +43,7 @@ import { ORDER_CHANNELS, ORDER_PAYMENTS, ORDER_WAREHOUSES, type OrderSaveReq } f
|
|
|
42
43
|
</div>
|
|
43
44
|
<div class="d-flex flex-column gap-16 py-16">
|
|
44
45
|
<general-information-form [form]="form" [seed]="seed" />
|
|
45
|
-
@if (linesTable) {
|
|
46
|
+
@if (linesTable()) {
|
|
46
47
|
<lines-table-form [form]="form" [seed]="seed.lines" [errors]="apiErrors.errors()" />
|
|
47
48
|
} @else {
|
|
48
49
|
<lines-form [form]="form" [seed]="seed.lines" [errors]="apiErrors.errors()" />
|
|
@@ -62,7 +63,10 @@ export class CreateComponent {
|
|
|
62
63
|
readonly #router = inject(Router);
|
|
63
64
|
readonly #route = inject(ActivatedRoute);
|
|
64
65
|
/** `?lines=sd-table`: dòng hàng dựng bằng `sd-table` (`lines-table-form`) để so với `<table>`. Màn thật chọn một. */
|
|
65
|
-
|
|
66
|
+
// why: subscribe, không đọc snapshot — trong sd-tab-router-outlet cùng path khác query giữ nguyên component.
|
|
67
|
+
protected readonly linesTable = toSignal(this.#route.queryParamMap.pipe(map(params => params.get('lines') === 'sd-table')), {
|
|
68
|
+
requireSync: true,
|
|
69
|
+
});
|
|
66
70
|
readonly #host: HTMLElement = inject(ElementRef).nativeElement;
|
|
67
71
|
readonly #injector = inject(Injector);
|
|
68
72
|
protected readonly seed: OrderSaveReq = {
|
|
@@ -151,7 +151,7 @@ import { canUpdateOrder, orderApprovalBadge, orderStatusBadge, type OrderAction,
|
|
|
151
151
|
<sd-section-item label="Ghi chú">{{ order.note | sdEmpty }}</sd-section-item>
|
|
152
152
|
</sd-section>
|
|
153
153
|
</div>
|
|
154
|
-
<approval-steps sdAside [steps]="order.approvalHistory" />
|
|
154
|
+
<approval-steps sdAside [steps]="order.approvalHistory" [createdAt]="order.createdAt" [creator]="order.creator" />
|
|
155
155
|
</sd-page-detail>
|
|
156
156
|
}
|
|
157
157
|
`,
|
|
@@ -50,7 +50,7 @@ import type { OrderDto } from '../../services/order.model';
|
|
|
50
50
|
</div>
|
|
51
51
|
<div class="d-flex flex-column gap-16 py-16">
|
|
52
52
|
<general-information-form [form]="form" [seed]="entity()" />
|
|
53
|
-
@if (linesTable) {
|
|
53
|
+
@if (linesTable()) {
|
|
54
54
|
<lines-table-form [form]="form" [seed]="entity().lines" [errors]="apiErrors.errors()" />
|
|
55
55
|
} @else {
|
|
56
56
|
<lines-form [form]="form" [seed]="entity().lines" [errors]="apiErrors.errors()" />
|
|
@@ -70,7 +70,10 @@ export class UpdateComponent {
|
|
|
70
70
|
readonly #router = inject(Router);
|
|
71
71
|
readonly #route = inject(ActivatedRoute);
|
|
72
72
|
/** `?lines=sd-table`: dòng hàng dựng bằng `sd-table` (`lines-table-form`) để so với `<table>`. Màn thật chọn một. */
|
|
73
|
-
|
|
73
|
+
// why: subscribe, không đọc snapshot — trong sd-tab-router-outlet cùng path khác query giữ nguyên component.
|
|
74
|
+
protected readonly linesTable = toSignal(this.#route.queryParamMap.pipe(map(params => params.get('lines') === 'sd-table')), {
|
|
75
|
+
requireSync: true,
|
|
76
|
+
});
|
|
74
77
|
readonly #host: HTMLElement = inject(ElementRef).nativeElement;
|
|
75
78
|
readonly #injector = inject(Injector);
|
|
76
79
|
/** Đơn do resolver tải; draft khởi tạo từ đây. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sdcorejs/angular",
|
|
3
|
-
"version": "20.3.
|
|
3
|
+
"version": "20.3.6",
|
|
4
4
|
"description": "Angular component library: data table, query bar/builder, 20+ signal-based form controls, layout, auth and workflow services. Standalone, OnPush, signals-first. Published in parallel lines for Angular 19, 20, 21 and 22.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
@@ -119,6 +119,10 @@
|
|
|
119
119
|
"types": "./components/button/index.d.ts",
|
|
120
120
|
"default": "./fesm2022/sdcorejs-angular-components-button.mjs"
|
|
121
121
|
},
|
|
122
|
+
"./components/calendar": {
|
|
123
|
+
"types": "./components/calendar/index.d.ts",
|
|
124
|
+
"default": "./fesm2022/sdcorejs-angular-components-calendar.mjs"
|
|
125
|
+
},
|
|
122
126
|
"./components/card": {
|
|
123
127
|
"types": "./components/card/index.d.ts",
|
|
124
128
|
"default": "./fesm2022/sdcorejs-angular-components-card.mjs"
|
|
@@ -155,10 +159,6 @@
|
|
|
155
159
|
"types": "./components/highlight/index.d.ts",
|
|
156
160
|
"default": "./fesm2022/sdcorejs-angular-components-highlight.mjs"
|
|
157
161
|
},
|
|
158
|
-
"./components/history": {
|
|
159
|
-
"types": "./components/history/index.d.ts",
|
|
160
|
-
"default": "./fesm2022/sdcorejs-angular-components-history.mjs"
|
|
161
|
-
},
|
|
162
162
|
"./components/image-editor": {
|
|
163
163
|
"types": "./components/image-editor/index.d.ts",
|
|
164
164
|
"default": "./fesm2022/sdcorejs-angular-components-image-editor.mjs"
|
|
@@ -215,6 +215,10 @@
|
|
|
215
215
|
"types": "./components/quick-action/index.d.ts",
|
|
216
216
|
"default": "./fesm2022/sdcorejs-angular-components-quick-action.mjs"
|
|
217
217
|
},
|
|
218
|
+
"./components/scheduler": {
|
|
219
|
+
"types": "./components/scheduler/index.d.ts",
|
|
220
|
+
"default": "./fesm2022/sdcorejs-angular-components-scheduler.mjs"
|
|
221
|
+
},
|
|
218
222
|
"./components/section": {
|
|
219
223
|
"types": "./components/section/index.d.ts",
|
|
220
224
|
"default": "./fesm2022/sdcorejs-angular-components-section.mjs"
|
|
@@ -243,6 +247,10 @@
|
|
|
243
247
|
"types": "./components/table/index.d.ts",
|
|
244
248
|
"default": "./fesm2022/sdcorejs-angular-components-table.mjs"
|
|
245
249
|
},
|
|
250
|
+
"./components/timeline": {
|
|
251
|
+
"types": "./components/timeline/index.d.ts",
|
|
252
|
+
"default": "./fesm2022/sdcorejs-angular-components-timeline.mjs"
|
|
253
|
+
},
|
|
246
254
|
"./components/tree": {
|
|
247
255
|
"types": "./components/tree/index.d.ts",
|
|
248
256
|
"default": "./fesm2022/sdcorejs-angular-components-tree.mjs"
|
|
@@ -447,6 +455,10 @@
|
|
|
447
455
|
"types": "./services/persistence/index.d.ts",
|
|
448
456
|
"default": "./fesm2022/sdcorejs-angular-services-persistence.mjs"
|
|
449
457
|
},
|
|
458
|
+
"./services/query-params": {
|
|
459
|
+
"types": "./services/query-params/index.d.ts",
|
|
460
|
+
"default": "./fesm2022/sdcorejs-angular-services-query-params.mjs"
|
|
461
|
+
},
|
|
450
462
|
"./services/storage": {
|
|
451
463
|
"types": "./services/storage/index.d.ts",
|
|
452
464
|
"default": "./fesm2022/sdcorejs-angular-services-storage.mjs"
|
|
@@ -1,81 +1,28 @@
|
|
|
1
|
-
import { MatDialogRef } from '@angular/material/dialog';
|
|
2
1
|
import { Color } from '@sdcorejs/utils/models';
|
|
3
2
|
import { SdIconShape } from '@sdcorejs/angular/modules/icon';
|
|
4
3
|
import * as i0 from '@angular/core';
|
|
5
4
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
required?: boolean;
|
|
21
|
-
defaultValue?: string;
|
|
22
|
-
};
|
|
23
|
-
date?: {
|
|
24
|
-
required?: boolean;
|
|
25
|
-
placeholder?: string;
|
|
26
|
-
defaultValue?: string | Date;
|
|
27
|
-
min?: string | Date;
|
|
28
|
-
max?: string | Date;
|
|
29
|
-
};
|
|
30
|
-
datetime?: {
|
|
31
|
-
required?: boolean;
|
|
32
|
-
placeholder?: string;
|
|
33
|
-
defaultValue?: string | Date;
|
|
34
|
-
min?: string | Date;
|
|
35
|
-
max?: string | Date;
|
|
36
|
-
showSeconds?: boolean;
|
|
37
|
-
};
|
|
38
|
-
radio?: {
|
|
39
|
-
required?: boolean;
|
|
40
|
-
defaultValue?: string | number;
|
|
41
|
-
items: any[];
|
|
42
|
-
valueField: string;
|
|
43
|
-
displayField: string;
|
|
44
|
-
display?: 'row' | 'column';
|
|
45
|
-
};
|
|
46
|
-
select?: {
|
|
47
|
-
required?: boolean;
|
|
48
|
-
defaultValue?: string | number | (string | number)[];
|
|
49
|
-
items: any[];
|
|
50
|
-
valueField: string;
|
|
51
|
-
displayField: string;
|
|
52
|
-
placeholder?: string;
|
|
53
|
-
multiple?: boolean;
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
declare class DialogConfirmComponent {
|
|
57
|
-
value: any;
|
|
58
|
-
required: boolean;
|
|
59
|
-
id: string;
|
|
60
|
-
readonly dialogRef: MatDialogRef<any, any>;
|
|
61
|
-
readonly data: DialogData;
|
|
62
|
-
readonly iconTone: Color;
|
|
63
|
-
readonly iconShape: SdIconShape;
|
|
64
|
-
readonly resolvedIcon: string;
|
|
65
|
-
readonly hasFields: boolean;
|
|
66
|
-
constructor();
|
|
67
|
-
onCancel: () => void;
|
|
68
|
-
onAccept: () => void;
|
|
69
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<DialogConfirmComponent, never>;
|
|
70
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<DialogConfirmComponent, "sd-dialog-confirm", never, {}, {}, never, never, true, never>;
|
|
5
|
+
/** Options shared by every `SdConfirmService` method. */
|
|
6
|
+
interface SdConfirmDisplayOption {
|
|
7
|
+
/** Force the presentation. Omitted: a bottom sheet on mobile, a dialog on desktop. */
|
|
8
|
+
view?: 'dialog' | 'bottom-sheet';
|
|
9
|
+
/**
|
|
10
|
+
* Allow closing by a backdrop click or the Esc key. Omitted = `false`. When passed, it decides and
|
|
11
|
+
* `disableBackdropClose` is ignored. Closing this way rejects the promise with `'CANCEL'`.
|
|
12
|
+
*/
|
|
13
|
+
enableBackdropClose?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Block closing by a backdrop click and the Esc key. Default `true`.
|
|
16
|
+
* @deprecated Use `enableBackdropClose` (the opposite meaning). Only applies when `enableBackdropClose` is omitted.
|
|
17
|
+
*/
|
|
18
|
+
disableBackdropClose?: boolean;
|
|
71
19
|
}
|
|
72
|
-
|
|
73
20
|
declare class SdConfirmService {
|
|
74
21
|
#private;
|
|
75
22
|
private dialog;
|
|
76
23
|
/** Inserted by Angular inject() migration for backwards compatibility */
|
|
77
24
|
constructor(...args: unknown[]);
|
|
78
|
-
confirm: (message: string, option?: {
|
|
25
|
+
confirm: (message: string, option?: SdConfirmDisplayOption & {
|
|
79
26
|
title?: string;
|
|
80
27
|
icon?: string;
|
|
81
28
|
/** Hình nền ô icon; bỏ trống thì dùng `defaultShape` của `provideSdIcon`. */
|
|
@@ -84,10 +31,10 @@ declare class SdConfirmService {
|
|
|
84
31
|
noTitle?: string;
|
|
85
32
|
yesButtonColor?: Color;
|
|
86
33
|
noButtonColor?: Color;
|
|
34
|
+
/** Dialog width. Not applied to the bottom sheet, which is always full-width. */
|
|
87
35
|
width?: string;
|
|
88
|
-
disableBackdropClose?: boolean;
|
|
89
36
|
}) => Promise<unknown>;
|
|
90
|
-
withInput: (message?: string, option?: {
|
|
37
|
+
withInput: (message?: string, option?: SdConfirmDisplayOption & {
|
|
91
38
|
title?: string;
|
|
92
39
|
icon?: string;
|
|
93
40
|
/** Hình nền ô icon; bỏ trống thì dùng `defaultShape` của `provideSdIcon`. */
|
|
@@ -101,9 +48,8 @@ declare class SdConfirmService {
|
|
|
101
48
|
yesButtonColor?: Color;
|
|
102
49
|
noButtonColor?: Color;
|
|
103
50
|
defaultValue?: string;
|
|
104
|
-
disableBackdropClose?: boolean;
|
|
105
51
|
}) => Promise<string>;
|
|
106
|
-
withRadio: (message?: string, option?: {
|
|
52
|
+
withRadio: (message?: string, option?: SdConfirmDisplayOption & {
|
|
107
53
|
title?: string;
|
|
108
54
|
icon?: string;
|
|
109
55
|
/** Hình nền ô icon; bỏ trống thì dùng `defaultShape` của `provideSdIcon`. */
|
|
@@ -118,9 +64,8 @@ declare class SdConfirmService {
|
|
|
118
64
|
valueField: string;
|
|
119
65
|
displayField: string;
|
|
120
66
|
display?: "row" | "column";
|
|
121
|
-
disableBackdropClose?: boolean;
|
|
122
67
|
}) => Promise<string>;
|
|
123
|
-
withSelect: (message?: string, option?: {
|
|
68
|
+
withSelect: (message?: string, option?: SdConfirmDisplayOption & {
|
|
124
69
|
title?: string;
|
|
125
70
|
icon?: string;
|
|
126
71
|
/** Hình nền ô icon; bỏ trống thì dùng `defaultShape` của `provideSdIcon`. */
|
|
@@ -136,9 +81,8 @@ declare class SdConfirmService {
|
|
|
136
81
|
displayField: string;
|
|
137
82
|
placeholder?: string;
|
|
138
83
|
multiple?: boolean;
|
|
139
|
-
disableBackdropClose?: boolean;
|
|
140
84
|
}) => Promise<string | number | (string | number)[]>;
|
|
141
|
-
withDate: (message?: string, option?: {
|
|
85
|
+
withDate: (message?: string, option?: SdConfirmDisplayOption & {
|
|
142
86
|
title?: string;
|
|
143
87
|
icon?: string;
|
|
144
88
|
/** Hình nền ô icon; bỏ trống thì dùng `defaultShape` của `provideSdIcon`. */
|
|
@@ -152,9 +96,8 @@ declare class SdConfirmService {
|
|
|
152
96
|
placeholder?: string;
|
|
153
97
|
min?: string | Date;
|
|
154
98
|
max?: string | Date;
|
|
155
|
-
disableBackdropClose?: boolean;
|
|
156
99
|
}) => Promise<string | Date>;
|
|
157
|
-
withDatetime: (message?: string, option?: {
|
|
100
|
+
withDatetime: (message?: string, option?: SdConfirmDisplayOption & {
|
|
158
101
|
title?: string;
|
|
159
102
|
icon?: string;
|
|
160
103
|
/** Hình nền ô icon; bỏ trống thì dùng `defaultShape` của `provideSdIcon`. */
|
|
@@ -169,11 +112,9 @@ declare class SdConfirmService {
|
|
|
169
112
|
min?: string | Date;
|
|
170
113
|
max?: string | Date;
|
|
171
114
|
showSeconds?: boolean;
|
|
172
|
-
disableBackdropClose?: boolean;
|
|
173
115
|
}) => Promise<string | Date>;
|
|
174
116
|
static ɵfac: i0.ɵɵFactoryDeclaration<SdConfirmService, never>;
|
|
175
117
|
static ɵprov: i0.ɵɵInjectableDeclaration<SdConfirmService>;
|
|
176
118
|
}
|
|
177
119
|
|
|
178
|
-
export {
|
|
179
|
-
export type { DialogData };
|
|
120
|
+
export { SdConfirmService };
|
|
@@ -10,6 +10,35 @@ interface SdExcelColumn {
|
|
|
10
10
|
title: string;
|
|
11
11
|
description?: string;
|
|
12
12
|
width?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Excel number-format code for numeric or `Date` data cells written by
|
|
15
|
+
* {@link SdExcelService.export}, for example `'dd/mm/yyyy'`,
|
|
16
|
+
* `'dd/mm/yyyy hh:mm:ss'`, `'hh:mm:ss'` or `'0.00'`.
|
|
17
|
+
*
|
|
18
|
+
* Defaults to no override: omitted, `undefined` and `''` preserve the existing
|
|
19
|
+
* writer behavior. Any nonempty string is passed to ExcelJS without semantic
|
|
20
|
+
* validation; use Excel format codes, not DateUtilities formatting tokens.
|
|
21
|
+
* Formatting changes display only, never the value or timezone. Strings are
|
|
22
|
+
* kept as text (with the usual formula neutralization), even if they look like
|
|
23
|
+
* dates. Headers, descriptions, additional sheets, `generateTemplate()` and
|
|
24
|
+
* `exportCSV()` ignore this property.
|
|
25
|
+
*
|
|
26
|
+
* For a time without a date, supply seconds since midnight divided by 86400.
|
|
27
|
+
* Calendar serials use the Excel 1900 date system, including its leap-year
|
|
28
|
+
* compatibility rule. The caller owns calendar conversion and valid ranges;
|
|
29
|
+
* this service does not parse date strings or convert configured timezones.
|
|
30
|
+
*
|
|
31
|
+
* @example
|
|
32
|
+
* ```ts
|
|
33
|
+
* import { SdExcelColumn } from '@sdcorejs/angular/services/excel';
|
|
34
|
+
* const column: SdExcelColumn = {
|
|
35
|
+
* field: 'day', title: 'Day', numFmt: 'dd/mm/yyyy',
|
|
36
|
+
* };
|
|
37
|
+
* // With excel.export({ columns: [column], items: [{ day: 46323 }] }),
|
|
38
|
+
* // Excel displays 28/10/2026 as a date. The string '28/10/2026' stays text.
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
numFmt?: string;
|
|
13
42
|
}
|
|
14
43
|
interface SdExcelTemplateColumn extends SdExcelColumn {
|
|
15
44
|
required?: boolean;
|
|
@@ -37,6 +66,36 @@ declare class SdExcelService {
|
|
|
37
66
|
constructor();
|
|
38
67
|
generateTemplate: (template: SdExcelTemplate) => Promise<void>;
|
|
39
68
|
exportCSV: (option: SdExcelExportOption) => Promise<void>;
|
|
69
|
+
/**
|
|
70
|
+
* Serializes tabular values to an XLSX workbook and starts a browser download.
|
|
71
|
+
* The main `data` sheet contains field keys, titles, optional descriptions,
|
|
72
|
+
* then data. This browser API lazily loads ExcelJS; it does not mutate rows or
|
|
73
|
+
* column options and does not convert application timezones.
|
|
74
|
+
*
|
|
75
|
+
* @param option Columns, rows, optional filename and additional sheets. Each
|
|
76
|
+
* column requires a nonempty field and title. Empty columns/rows are allowed.
|
|
77
|
+
* A nonempty `column.numFmt` applies only to number/Date data cells in the main
|
|
78
|
+
* sheet; omitted or empty formats preserve existing behavior. Strings stay
|
|
79
|
+
* text and are neutralized for spreadsheet formula injection. Nullish data
|
|
80
|
+
* values remain blank. ExcelJS handles Date serialization in the 1900 system;
|
|
81
|
+
* the caller owns valid serials, date ranges and timezone conversion.
|
|
82
|
+
* @returns A promise resolving after serialization and the download trigger,
|
|
83
|
+
* not after the user saves the file. There is no cancellation or timeout API.
|
|
84
|
+
* @throws Rejects if a column lacks its field/title, or if loading ExcelJS,
|
|
85
|
+
* serialization or the browser download helper fails.
|
|
86
|
+
* @example
|
|
87
|
+
* ```ts
|
|
88
|
+
* import { inject } from '@angular/core';
|
|
89
|
+
* import { SdExcelService } from '@sdcorejs/angular/services/excel';
|
|
90
|
+
* // Inside an Angular injection context:
|
|
91
|
+
* const excel = inject(SdExcelService);
|
|
92
|
+
* await excel.export({
|
|
93
|
+
* columns: [{ field: 'day', title: 'Day', numFmt: 'dd/mm/yyyy' }],
|
|
94
|
+
* items: [{ day: 46323 }],
|
|
95
|
+
* fileName: 'dates.xlsx',
|
|
96
|
+
* }); // Excel displays a date cell as 28/10/2026.
|
|
97
|
+
* ```
|
|
98
|
+
*/
|
|
40
99
|
export: (option: SdExcelExportOption) => Promise<void>;
|
|
41
100
|
upload: () => Promise<{
|
|
42
101
|
items: Record<string, any>[];
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { ActivatedRoute } from '@angular/router';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Đọc/ghi một query param làm nơi giữ state của component (`syncQueryParams` của `sd-table`, `sd-tab-group`,
|
|
7
|
+
* `sd-anchor`). Nội bộ: tên và hình dạng có thể đổi mà không báo trước.
|
|
8
|
+
*/
|
|
9
|
+
interface ɵSdQueryParamSync {
|
|
10
|
+
/** `false` khi app không có Router: mọi hàm khác là no-op. */
|
|
11
|
+
readonly available: boolean;
|
|
12
|
+
/** Giá trị hiện tại của `name` trên route của component, `null` khi không có. */
|
|
13
|
+
value(name: string): string | null;
|
|
14
|
+
/** Phát giá trị hiện tại rồi mỗi lần `name` đổi (không phát trùng). Không có Router thì không phát. */
|
|
15
|
+
changes(name: string): Observable<string | null>;
|
|
16
|
+
/** Ghi `value` (`null` xoá param). Ghi trong cùng lượt được gộp vào một navigation `replaceUrl`. */
|
|
17
|
+
write(name: string, value: string | null): void;
|
|
18
|
+
}
|
|
19
|
+
/** Hàng đợi ghi dùng chung cho cả app: một navigation cho mọi param ghi trong cùng lượt. */
|
|
20
|
+
declare class ɵSdQueryParamWriter {
|
|
21
|
+
#private;
|
|
22
|
+
queue(owner: object, route: ActivatedRoute | null, name: string, value: string | null): void;
|
|
23
|
+
cancel(owner: object): void;
|
|
24
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ɵSdQueryParamWriter, never>;
|
|
25
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ɵSdQueryParamWriter>;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Tạo binding đọc/ghi query param cho component hiện tại. Gọi trong injection context. Ghi đang chờ bị huỷ khi
|
|
29
|
+
* component huỷ; ghi của route không còn hiển thị bị bỏ.
|
|
30
|
+
*/
|
|
31
|
+
declare const ɵsdQueryParamSync: () => ɵSdQueryParamSync;
|
|
32
|
+
interface ɵSdQueryParamStateOptions {
|
|
33
|
+
/** Selector dùng trong cảnh báo, vd `'sd-table'`. */
|
|
34
|
+
selector: string;
|
|
35
|
+
/** Tiền tố tên param: tên là `<prefix>-<autoId>`. */
|
|
36
|
+
prefix: string;
|
|
37
|
+
/** Input `syncQueryParams`. */
|
|
38
|
+
enabled: () => boolean;
|
|
39
|
+
/** Giá trị `autoId` consumer truyền (không phải autoId đã thêm tiền tố). */
|
|
40
|
+
autoId: () => string | null | undefined;
|
|
41
|
+
/** `false` khi component chưa đủ dữ liệu để đọc/ghi (vd tab chưa render): không áp dụng, không ghi. */
|
|
42
|
+
ready?: () => boolean;
|
|
43
|
+
/** State hiện tại đã serialize; `null` là mặc định (param bị xoá). Phải đọc signal để theo dõi được. */
|
|
44
|
+
state: () => string | null;
|
|
45
|
+
/**
|
|
46
|
+
* URL mang giá trị khác state: áp dụng nó. Giá trị không hợp lệ thì bỏ qua — state giữ nguyên và URL được ghi lại.
|
|
47
|
+
* Trả `false` khi giá trị hợp lệ nhưng đích chưa render (tab/mục đến sau): param được giữ và thử lại khi dữ liệu mà
|
|
48
|
+
* `ready`/`state` đọc thay đổi, cho tới khi áp được hoặc người dùng tự đổi state.
|
|
49
|
+
*/
|
|
50
|
+
apply: (value: string) => boolean | void;
|
|
51
|
+
}
|
|
52
|
+
interface ɵSdQueryParamState {
|
|
53
|
+
/** Giá trị param hiện trên URL; `null` khi tắt, thiếu `autoId` hoặc không có param. Dùng để áp state trước lần đọc đầu. */
|
|
54
|
+
value(): string | null;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Nối state của component với query param `<prefix>-<autoId>` khi `syncQueryParams` bật. Gọi trong injection context.
|
|
58
|
+
*
|
|
59
|
+
* - URL có param khác state (lúc mở hay đổi từ ngoài) → `apply`.
|
|
60
|
+
* - State đổi → ghi (mặc định thì xoá param). Lần URL đổi do chính binding này ghi không bị áp dụng lại.
|
|
61
|
+
* - Param biến mất (vd bấm menu không có query) → giữ state và ghi lại.
|
|
62
|
+
* - Bật mà thiếu `autoId` → không làm gì, cảnh báo một lần (chỉ khi app có route).
|
|
63
|
+
*/
|
|
64
|
+
declare const ɵsdQueryParamState: (options: ɵSdQueryParamStateOptions) => ɵSdQueryParamState;
|
|
65
|
+
|
|
66
|
+
export { ɵSdQueryParamWriter, ɵsdQueryParamState, ɵsdQueryParamSync };
|
|
67
|
+
export type { ɵSdQueryParamState, ɵSdQueryParamStateOptions, ɵSdQueryParamSync };
|
|
@@ -180,5 +180,14 @@ declare function sdNormalizeSearchText(value: string | null | undefined): string
|
|
|
180
180
|
*/
|
|
181
181
|
declare function sdFindHighlightRanges(text: string | null | undefined, term: string | null | undefined): SdHighlightRange[];
|
|
182
182
|
|
|
183
|
-
|
|
183
|
+
/**
|
|
184
|
+
* Human-readable file size in base 1024: `846 KB`, `2,4 MB` (vi) / `2.4 MB` (en).
|
|
185
|
+
* One fraction digit below 10 units, none above — the precision users expect from file managers.
|
|
186
|
+
* Empty string for a missing, negative or non-finite value.
|
|
187
|
+
*
|
|
188
|
+
* @internal Shared by `sd-file-explorer` and `sd-card`; not a public API.
|
|
189
|
+
*/
|
|
190
|
+
declare function ɵsdFormatBytes(bytes: number | null | undefined, locale: string): string;
|
|
191
|
+
|
|
192
|
+
export { ObjectUtilities, SD_NON_BROWSER_ORIGIN, SdUtilities, sdFindHighlightRanges, sdIsAllowedOrigin, sdIsExternalHttpUrl, sdIsPathPrefix, sdIsSafeResourceUrl, sdMatchesSecureRoute, sdNormalizeSearchText, sdOpenExternal, sdParseUrl, sdResolveBaseOrigin, sdSanitizeEditorHtml, ɵsdFormatBytes };
|
|
184
193
|
export type { SdHighlightRange };
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { Color } from '@sdcorejs/utils/models';
|
|
2
|
-
import * as i0 from '@angular/core';
|
|
3
|
-
|
|
4
|
-
interface SdHistoryItemType {
|
|
5
|
-
title: string;
|
|
6
|
-
status?: {
|
|
7
|
-
title?: string;
|
|
8
|
-
color?: Color;
|
|
9
|
-
icon?: string;
|
|
10
|
-
};
|
|
11
|
-
date?: string;
|
|
12
|
-
actor?: string;
|
|
13
|
-
source?: string;
|
|
14
|
-
description?: string;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
declare class SdHistoryItem {
|
|
18
|
-
items: SdHistoryItemType[];
|
|
19
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<SdHistoryItem, never>;
|
|
20
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SdHistoryItem, "sd-history", never, { "items": { "alias": "items"; "required": false; }; }, {}, never, never, true, never>;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export { SdHistoryItem };
|