@sdcorejs/angular 20.3.2 → 20.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/THEME.md +58 -6
- package/assets/scss/core/form.scss +291 -3
- package/assets/scss/themes/_component-tokens.scss +35 -6
- package/components/badge/index.d.ts +19 -1
- package/components/section/index.d.ts +13 -1
- package/components/splitter/index.d.ts +1 -1
- package/components/tab-router/index.d.ts +47 -5
- package/components/table/index.d.ts +127 -13
- package/components/upload-file/index.d.ts +181 -21
- package/fesm2022/sdcorejs-angular-components-badge.mjs +2 -2
- package/fesm2022/sdcorejs-angular-components-badge.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-form-generic.mjs +3 -3
- package/fesm2022/sdcorejs-angular-components-form-generic.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-section.mjs +15 -3
- package/fesm2022/sdcorejs-angular-components-section.mjs.map +1 -1
- 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-splitter.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-tab-router.mjs +393 -78
- package/fesm2022/sdcorejs-angular-components-tab-router.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-table.mjs +444 -16
- package/fesm2022/sdcorejs-angular-components-table.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-components-upload-file.mjs +887 -174
- package/fesm2022/sdcorejs-angular-components-upload-file.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-autocomplete.mjs +7 -2
- package/fesm2022/sdcorejs-angular-forms-autocomplete.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-chip-calendar.mjs +5 -2
- package/fesm2022/sdcorejs-angular-forms-chip-calendar.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-chip.mjs +422 -122
- package/fesm2022/sdcorejs-angular-forms-chip.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-date-range.mjs +4 -0
- package/fesm2022/sdcorejs-angular-forms-date-range.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-date.mjs +4 -0
- package/fesm2022/sdcorejs-angular-forms-date.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-datetime.mjs +4 -0
- package/fesm2022/sdcorejs-angular-forms-datetime.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-input-number.mjs +17 -2
- package/fesm2022/sdcorejs-angular-forms-input-number.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-input.mjs +4 -0
- package/fesm2022/sdcorejs-angular-forms-input.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-select.mjs +26 -20
- package/fesm2022/sdcorejs-angular-forms-select.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-forms-textarea.mjs +14 -1
- package/fesm2022/sdcorejs-angular-forms-textarea.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-i18n.mjs +210 -0
- package/fesm2022/sdcorejs-angular-i18n.mjs.map +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-configuration.page-DnbDCdcz.mjs → sdcorejs-angular-modules-generic-generic-configuration.page-D_1BxDC9.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-configuration.page-DnbDCdcz.mjs.map → sdcorejs-angular-modules-generic-generic-configuration.page-D_1BxDC9.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-form-host.page-EBHM4kx2.mjs → sdcorejs-angular-modules-generic-generic-form-host.page-CgH8Qi25.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-form-host.page-EBHM4kx2.mjs.map → sdcorejs-angular-modules-generic-generic-form-host.page-CgH8Qi25.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-list.page-BtHe8YIW.mjs → sdcorejs-angular-modules-generic-generic-list.page-CyCGqW9W.mjs} +3 -3
- package/fesm2022/{sdcorejs-angular-modules-generic-generic-list.page-BtHe8YIW.mjs.map → sdcorejs-angular-modules-generic-generic-list.page-CyCGqW9W.mjs.map} +1 -1
- package/fesm2022/{sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-eFshU7ew.mjs → sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-DTmU8Te4.mjs} +4 -4
- package/fesm2022/{sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-eFshU7ew.mjs.map → sdcorejs-angular-modules-generic-sdcorejs-angular-modules-generic-DTmU8Te4.mjs.map} +1 -1
- package/fesm2022/sdcorejs-angular-modules-generic.mjs +1 -1
- package/fesm2022/sdcorejs-angular-modules-layout.mjs +266 -11
- package/fesm2022/sdcorejs-angular-modules-layout.mjs.map +1 -1
- package/fesm2022/sdcorejs-angular-modules-pattern-api-error-BBWwQ6h2.mjs +23 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-api-error-BBWwQ6h2.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-approval-inbox-BMwD6_FC.mjs +16 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-approval-inbox-BMwD6_FC.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-base-api.service-BubUwgBK.mjs +51 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-base-api.service-BubUwgBK.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-C9WQdsEi.mjs +131 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-C9WQdsEi.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-s7ZXoakT.mjs +130 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create-side-drawer.component-s7ZXoakT.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-BxfQux1Q.mjs +99 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-BxfQux1Q.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-D4GrcahQ.mjs +460 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-D4GrcahQ.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-DlYVJqHo.mjs +118 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-create.component-DlYVJqHo.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-customer.model-C3fr4yNw.mjs +18 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-customer.model-C3fr4yNw.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-customer.service-Bfx6_CmA.mjs +66 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-customer.service-Bfx6_CmA.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail-side-drawer.component-3PUIy1Vi.mjs +148 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail-side-drawer.component-3PUIy1Vi.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-CbYMo3D1.mjs +172 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-CbYMo3D1.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-awjgX7ph.mjs +90 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-awjgX7ph.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-c__NdSt3.mjs +467 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-detail.component-c__NdSt3.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-flow.component-Bjvq6wJz.mjs +514 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-flow.component-Bjvq6wJz.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-form-api-errors-FwmYVkag.mjs +61 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-form-api-errors-FwmYVkag.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-BRsdOwWy.mjs +87 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-BRsdOwWy.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-DalxHa8D.mjs +232 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-DalxHa8D.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-pqT7lnS6.mjs +170 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-form.component-pqT7lnS6.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-view.component-kdEZ9s7K.mjs +70 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-general-information-view.component-kdEZ9s7K.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-index.component-DZXPZuM4.mjs +100 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-index.component-DZXPZuM4.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-lines-form.component-BjMOON6K.mjs +522 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-lines-form.component-BjMOON6K.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-Bf9QWXBp.mjs +115 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-Bf9QWXBp.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CuDjsIzi.mjs +118 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-CuDjsIzi.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-DkVrMSPZ.mjs +164 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-DkVrMSPZ.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-DkxheDVz.mjs +629 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-DkxheDVz.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-E8rkFCkK.mjs +71 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-list.component-E8rkFCkK.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-mock-backend.factory-DgmM-wTI.mjs +1069 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-mock-backend.factory-DgmM-wTI.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source-viewer-BpLQaYP5.mjs +186 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source-viewer-BpLQaYP5.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source.generated-BrejHvB2.mjs +97 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-pattern-source.generated-BrejHvB2.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-product.model-BoHLJ8vf.mjs +12 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-product.model-BoHLJ8vf.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-product.service-C3coYwmZ.mjs +48 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-product.service-C3coYwmZ.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-profile.component-YsWsrKWJ.mjs +297 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-profile.component-YsWsrKWJ.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-9ujH01cX.mjs +74 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-9ujH01cX.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-BfpsCkim.mjs +45 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-BfpsCkim.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-C7b5dRrJ.mjs +165 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-C7b5dRrJ.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-CGeqkySv.mjs +66 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-CGeqkySv.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-DoBxGoRE.mjs +74 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-DoBxGoRE.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-dBuQqYkO.mjs +43 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-dBuQqYkO.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-quSIwMOx.mjs +50 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-quSIwMOx.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-rR-MpQFh.mjs +99 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-routes-rR-MpQFh.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-sdcorejs-angular-modules-pattern-LQNpFSmN.mjs +406 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-sdcorejs-angular-modules-pattern-LQNpFSmN.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-shell.component-CcmrUIvP.mjs +317 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-shell.component-CcmrUIvP.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-Cq72tG9h.mjs +143 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-Cq72tG9h.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-xFbutFLY.mjs +132 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update-side-drawer.component-xFbutFLY.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-CsfGgGJb.mjs +128 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-CsfGgGJb.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-DYPI_CRD.mjs +100 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-DYPI_CRD.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-lHmdUXWT.mjs +357 -0
- package/fesm2022/sdcorejs-angular-modules-pattern-update.component-lHmdUXWT.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-modules-pattern.mjs +2 -0
- package/fesm2022/sdcorejs-angular-modules-pattern.mjs.map +1 -0
- package/fesm2022/sdcorejs-angular-services-unsaved-changes.mjs +104 -4
- package/fesm2022/sdcorejs-angular-services-unsaved-changes.mjs.map +1 -1
- package/forms/chip/index.d.ts +136 -26
- package/i18n/index.d.ts +42 -0
- package/modules/layout/index.d.ts +89 -6
- package/modules/pattern/README.md +76 -0
- package/modules/pattern/docs/detail.md +237 -0
- package/modules/pattern/docs/drawer.md +484 -0
- package/modules/pattern/docs/flow.md +631 -0
- package/modules/pattern/docs/form.md +518 -0
- package/modules/pattern/docs/header-actions.md +342 -0
- package/modules/pattern/docs/list.md +247 -0
- package/modules/pattern/docs/relation.md +180 -0
- package/modules/pattern/docs/select.md +206 -0
- package/modules/pattern/docs/split.md +350 -0
- package/modules/pattern/docs/states.md +168 -0
- package/modules/pattern/features/approval/entity.resolver.ts +21 -0
- package/modules/pattern/features/approval/pages/detail/detail.component.ts +139 -0
- package/modules/pattern/features/approval/pages/list/approval-inbox.ts +7 -0
- package/modules/pattern/features/approval/pages/list/list.component.html +20 -0
- package/modules/pattern/features/approval/pages/list/list.component.ts +149 -0
- package/modules/pattern/features/approval/routes.ts +30 -0
- package/modules/pattern/features/approval/services/approval.model.ts +38 -0
- package/modules/pattern/features/approval/services/approval.service.ts +23 -0
- package/modules/pattern/features/category/components/create-side-drawer/create-side-drawer.component.ts +123 -0
- package/modules/pattern/features/category/components/general-information-form/general-information-form.component.ts +61 -0
- package/modules/pattern/features/category/components/update-side-drawer/update-side-drawer.component.ts +134 -0
- package/modules/pattern/features/category/entity.resolver.ts +27 -0
- package/modules/pattern/features/category/pages/list/list.component.html +20 -0
- package/modules/pattern/features/category/pages/list/list.component.ts +105 -0
- package/modules/pattern/features/category/routes.ts +42 -0
- package/modules/pattern/features/category/services/category.model.ts +39 -0
- package/modules/pattern/features/category/services/category.service.ts +36 -0
- package/modules/pattern/features/customer/components/create-side-drawer/create-side-drawer.component.ts +131 -0
- package/modules/pattern/features/customer/components/customer-select/customer-select.component.ts +72 -0
- package/modules/pattern/features/customer/components/customer-type-select/customer-type-select.component.ts +30 -0
- package/modules/pattern/features/customer/components/debts-view/debts-view.component.ts +28 -0
- package/modules/pattern/features/customer/components/detail-side-drawer/detail-side-drawer.component.ts +106 -0
- package/modules/pattern/features/customer/components/documents-view/documents-view.component.ts +50 -0
- package/modules/pattern/features/customer/components/general-information-form/general-information-form.component.ts +140 -0
- package/modules/pattern/features/customer/components/general-information-view/general-information-view.component.ts +39 -0
- package/modules/pattern/features/customer/components/orders-view/orders-view.component.ts +35 -0
- package/modules/pattern/features/customer/components/summary-cards/summary-cards.component.ts +101 -0
- package/modules/pattern/features/customer/components/update-side-drawer/update-side-drawer.component.ts +127 -0
- package/modules/pattern/features/customer/entity.resolver.ts +21 -0
- package/modules/pattern/features/customer/pages/list/list.component.html +22 -0
- package/modules/pattern/features/customer/pages/list/list.component.ts +113 -0
- package/modules/pattern/features/customer/pages/profile/profile.component.ts +120 -0
- package/modules/pattern/features/customer/pipes/customer-detail.pipe.ts +18 -0
- package/modules/pattern/features/customer/routes.ts +59 -0
- package/modules/pattern/features/customer/services/customer.model.ts +87 -0
- package/modules/pattern/features/customer/services/customer.service.ts +79 -0
- package/modules/pattern/features/import/components/mapping-form/mapping-form.component.ts +41 -0
- package/modules/pattern/features/import/components/preview-view/preview-view.component.ts +44 -0
- package/modules/pattern/features/import/pages/flow/flow.component.ts +269 -0
- package/modules/pattern/features/import/routes.ts +19 -0
- package/modules/pattern/features/import/services/import.model.ts +82 -0
- package/modules/pattern/features/import/services/import.service.ts +18 -0
- package/modules/pattern/features/order/components/approval-steps/approval-steps.component.ts +74 -0
- package/modules/pattern/features/order/components/bulk-result/bulk-result.component.ts +46 -0
- package/modules/pattern/features/order/components/general-information-form/general-information-form.component.ts +96 -0
- package/modules/pattern/features/order/components/lines-form/lines-form.component.ts +205 -0
- package/modules/pattern/features/order/components/lines-view/lines-view.component.ts +42 -0
- package/modules/pattern/features/order/components/summary-cards/summary-cards.component.ts +128 -0
- package/modules/pattern/features/order/entity.resolver.ts +37 -0
- package/modules/pattern/features/order/pages/create/create.component.ts +99 -0
- package/modules/pattern/features/order/pages/detail/detail.component.ts +222 -0
- package/modules/pattern/features/order/pages/list/list.component.html +38 -0
- package/modules/pattern/features/order/pages/list/list.component.ts +291 -0
- package/modules/pattern/features/order/pages/update/update.component.ts +119 -0
- package/modules/pattern/features/order/routes.ts +54 -0
- package/modules/pattern/features/order/services/order.model.ts +109 -0
- package/modules/pattern/features/order/services/order.service.ts +63 -0
- package/modules/pattern/features/partner/pages/create/create.component.ts +324 -0
- package/modules/pattern/features/partner/routes.ts +20 -0
- package/modules/pattern/features/partner/services/partner.model.ts +30 -0
- package/modules/pattern/features/partner/services/partner.service.ts +17 -0
- package/modules/pattern/features/product/components/general-information-form/general-information-form.component.ts +88 -0
- package/modules/pattern/features/product/components/product-select/product-select.component.ts +65 -0
- package/modules/pattern/features/product/components/product-status-select/product-status-select.component.ts +30 -0
- package/modules/pattern/features/product/entity.resolver.ts +21 -0
- package/modules/pattern/features/product/pages/create/create.component.ts +85 -0
- package/modules/pattern/features/product/pages/detail/detail.component.ts +53 -0
- package/modules/pattern/features/product/pages/list/list.component.html +30 -0
- package/modules/pattern/features/product/pages/list/list.component.ts +71 -0
- package/modules/pattern/features/product/pages/update/update.component.ts +86 -0
- package/modules/pattern/features/product/pipes/product-detail.pipe.ts +18 -0
- package/modules/pattern/features/product/routes.ts +48 -0
- package/modules/pattern/features/product/services/product.model.ts +38 -0
- package/modules/pattern/features/product/services/product.service.ts +48 -0
- package/modules/pattern/features/settings/pages/update/update.component.ts +227 -0
- package/modules/pattern/features/settings/routes.ts +24 -0
- package/modules/pattern/features/settings/services/settings.model.ts +18 -0
- package/modules/pattern/features/settings/services/settings.service.ts +15 -0
- package/modules/pattern/features/settings/settings.resolver.ts +8 -0
- package/modules/pattern/index.d.ts +50 -0
- package/package.json +5 -1
- package/services/unsaved-changes/index.d.ts +11 -0
|
@@ -626,6 +626,9 @@ class SdChipCalendar {
|
|
|
626
626
|
}
|
|
627
627
|
/** Every user action ends here: a new array of days, written once (the connector writes the model). */
|
|
628
628
|
#commit(next) {
|
|
629
|
+
// why: người dùng sửa thì control của form phải dirty trước khi nhận giá trị, như value accessor của Angular;
|
|
630
|
+
// chọn ngày trên lịch và xoá chip không đi qua value accessor.
|
|
631
|
+
this.#formControl.markAsDirty();
|
|
629
632
|
this.#formControl.setValue(next);
|
|
630
633
|
this.#ref.markForCheck();
|
|
631
634
|
}
|
|
@@ -713,7 +716,7 @@ class SdChipCalendar {
|
|
|
713
716
|
/** Classes of a month-view cell; see `calendarDateClass`. */
|
|
714
717
|
dateClass = (cellDate) => this.calendarDateClass()(cellDate);
|
|
715
718
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: SdChipCalendar, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
716
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.25", type: SdChipCalendar, isStandalone: true, selector: "sd-chip-calendar", inputs: { autoIdInput: { classPropertyName: "autoIdInput", publicName: "autoId", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, labelPlacement: { classPropertyName: "labelPlacement", publicName: "labelPlacement", isSignal: true, isRequired: false, transformFunction: null }, floatLabel: { classPropertyName: "floatLabel", publicName: "floatLabel", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, form: { classPropertyName: "form", publicName: "form", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, removable: { classPropertyName: "removable", publicName: "removable", isSignal: true, isRequired: false, transformFunction: null }, hideInlineError: { classPropertyName: "hideInlineError", publicName: "hideInlineError", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, minCount: { classPropertyName: "minCount", publicName: "minCount", isSignal: true, isRequired: false, transformFunction: null }, maxCount: { classPropertyName: "maxCount", publicName: "maxCount", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, dateFilter: { classPropertyName: "dateFilter", publicName: "dateFilter", isSignal: true, isRequired: false, transformFunction: null }, startAt: { classPropertyName: "startAt", publicName: "startAt", isSignal: true, isRequired: false, transformFunction: null }, clearable: { classPropertyName: "clearable", publicName: "clearable", isSignal: true, isRequired: false, transformFunction: null }, maxVisible: { classPropertyName: "maxVisible", publicName: "maxVisible", isSignal: true, isRequired: false, transformFunction: null }, displayFormat: { classPropertyName: "displayFormat", publicName: "displayFormat", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, viewed: { classPropertyName: "viewed", publicName: "viewed", isSignal: true, isRequired: false, transformFunction: null }, transform: { classPropertyName: "transform", publicName: "transform", isSignal: true, isRequired: false, transformFunction: null }, hyperlink: { classPropertyName: "hyperlink", publicName: "hyperlink", isSignal: true, isRequired: false, transformFunction: null }, model: { classPropertyName: "model", publicName: "model", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { model: "modelChange", sdChange: "sdChange" }, host: { properties: { "class.sd-has-label": "!!label()", "class.sd-viewed": "isViewed()", "class.sd-label-top": "labelPlacement() === 'top'" } }, queries: [{ propertyName: "sdViewDef", first: true, predicate: SdViewDefDirective, descendants: true, isSignal: true }, { propertyName: "sdLabelDef", first: true, predicate: SdLabelDefDirective, descendants: true, isSignal: true }, { propertyName: "sdLabelTemplate", first: true, predicate: ["sdLabel"], descendants: true, isSignal: true }, { propertyName: "sdValueTemplate", first: true, predicate: ["sdValue"], descendants: true, isSignal: true }], viewQueries: [{ propertyName: "calendar", first: true, predicate: MatCalendar, descendants: true, isSignal: true }, { propertyName: "field", first: true, predicate: MatFormField, descendants: true, isSignal: true }, { propertyName: "input", first: true, predicate: ["input"], descendants: true, isSignal: true }], ngImport: i0, template: "@let _label = label();\r\n@let _appearance = appearance();\r\n@let _required = required();\r\n@let _isViewed = isViewed();\r\n@let _hideInlineError = hideInlineError();\r\n@let _sdViewDef = sdViewDef();\r\n@let _labelTemplate = (sdLabelTemplate() ?? sdLabelDef()?.templateRef) || undefined;\r\n@let _valueTemplate = (sdValueTemplate() ?? _sdViewDef?.templateRef) || undefined;\r\n@let _errorMessage = errorMessage();\r\n@let _size = size();\r\n@let _labelTop = labelPlacement() === 'top';\r\n@let _icons = iconSizes();\r\n<!-- why: m\u1ED9t c\u1ED5ng gate duy nh\u1EA5t cho <mat-error>, aria-invalid v\u00E0 aria-describedby. -->\r\n@let _errorVisible = isErrorShown();\r\n@let _showInlineError = !_hideInlineError && _errorVisible;\r\n@let _viewTemplate = _sdViewDef?.templateRef;\r\n\r\n@if (_isViewed) {\r\n <sd-view\r\n [label]=\"_label\"\r\n [labelTemplate]=\"_labelTemplate\"\r\n [value]=\"formControl.value\"\r\n [display]=\"viewText()\"\r\n [hyperlink]=\"hyperlink()\"\r\n [valueTemplate]=\"_valueTemplate\">\r\n </sd-view>\r\n} @else {\r\n @if ((!_appearance || _labelTop) && _labelTemplate) {\r\n <ng-container *ngTemplateOutlet=\"_labelTemplate\"></ng-container>\r\n }\r\n @if ((!_appearance || _labelTop) && _label && !_labelTemplate) {\r\n <sd-label [label]=\"_label\" [required]=\"_required\" [for]=\"_labelTop ? inputId : null\"></sd-label>\r\n }\r\n\r\n <!-- why: div ch\u1EC9 l\u00E0 h\u1ED9p layout \u2014 aria-hidden=\"true\" c\u0169 \u1EA9n C\u1EA2 c\u00E2y con (chip, \u00F4 nh\u1EADp, <mat-error>)\r\n kh\u1ECFi accessibility tree. \u1EDE \u0111\u00E2y (click) KH\u00D4NG ph\u1EA3i ti\u1EC7n \u00EDch chu\u1ED9t th\u1EEBa nh\u01B0 c\u00E1c control kh\u00E1c:\r\n khi sdViewDef \u0111ang hi\u1EC3n th\u1ECB th\u00EC kh\u00F4ng c\u00F3 ph\u1EA7n t\u1EED focus \u0111\u01B0\u1EE3c n\u00E0o b\u00EAn trong, n\u00EAn click l\u00E0 l\u1ED1i\r\n v\u00E0o DUY NH\u1EA4T. V\u00EC v\u1EADy handler \u0111\u01B0\u1EE3c chuy\u1EC3n h\u1EB3n xu\u1ED1ng ph\u1EA7n t\u1EED view v\u00E0 ph\u1EA7n t\u1EED \u0111\u00F3 nh\u1EADn\r\n role=\"button\" + tabindex=\"0\" + keydown Enter/Space; div ngo\u00E0i kh\u00F4ng c\u00F2n handler n\u00E0o. -->\r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"!!_viewTemplate\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\">\r\n @if (_viewTemplate && !isFocused) {\r\n <!-- why: KH\u00D4NG \u0111\u1EB7t aria-label \u2014 n\u1ED9i dung sdViewDef ch\u00EDnh l\u00E0 nh\u00E3n nh\u00ECn th\u1EA5y \u0111\u01B0\u1EE3c, aria-label\r\n s\u1EBD ghi \u0111\u00E8 v\u00E0 l\u00E0m AT \u0111\u1ECDc kh\u00E1c ch\u1EEF tr\u00EAn m\u00E0n h\u00ECnh. -->\r\n <div\r\n class=\"sd-chip-calendar__view-trigger\"\r\n role=\"button\"\r\n tabindex=\"0\"\r\n (click)=\"onClick()\"\r\n (keydown.enter)=\"onViewKeydown($event)\"\r\n (keydown.space)=\"onViewKeydown($event)\">\r\n <ng-container *ngTemplateOutlet=\"_viewTemplate; context: { value: formControl.value }\"></ng-container>\r\n </div>\r\n } @else {\r\n <mat-form-field\r\n class=\"sd-chip-calendar-field\"\r\n [class.sd-md]=\"_size === 'md'\"\r\n [class.sd-sm]=\"_size === 'sm'\"\r\n [class.sd-lg]=\"_size === 'lg'\"\r\n [class.sd-chip-calendar-field--open]=\"isOpen()\"\r\n [class.hide-inline-error]=\"_hideInlineError\"\r\n [class.sd-label-top]=\"_labelTop\"\r\n [appearance]=\"_appearance\"\r\n [floatLabel]=\"floatLabel()\"\r\n (click)=\"onFieldClick()\">\r\n @if (_appearance && _label && !_labelTop) {\r\n <mat-label>{{ _label }}</mat-label>\r\n }\r\n <mat-chip-grid [formControl]=\"formControl\" #chipList [class.sd-md]=\"_size === 'md'\" [class.sd-sm]=\"_size === 'sm'\">\r\n <!-- why: chip l\u00E0 ng\u00E0y \u0111\u00E3 chu\u1EA9n ho\u00E1 (yyyy/MM/dd), hi\u1EC7n theo ng\u00E0y (B2) v\u00E0 g\u1ED9p \u201C+N\u201D khi popup \u0111\u00F3ng (B3). `removable` \u00E1p\r\n c\u1EA3 cho Backspace / Delete tr\u00EAn chip (A1); chip c\u00F3 t\u00EAn \u0111\u1EA7y \u0111\u1EE7, n\u00FAt \u2715 c\u00F3 t\u00EAn ri\u00EAng (A6). -->\r\n @for (item of visibleDays(); track item) {\r\n @let _itemRemovable = isRemovable(item);\r\n <mat-chip-row\r\n class=\"sd-chip-calendar__chip\"\r\n [class.sd-chip-calendar__chip--locked]=\"!_itemRemovable\"\r\n [removable]=\"_itemRemovable\"\r\n [aria-label]=\"chipLabel(item)\"\r\n (removed)=\"onRemove(item)\"\r\n [disabled]=\"inputControl.disabled\"\r\n (click)=\"onClickChip($event, item)\"\r\n [value]=\"item\">\r\n <span class=\"sd-chip-calendar__chip-text\">{{ formatDay(item) }}</span>\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 \u2715 \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o \u00F4 trailing c\u1EE7a mat-chip-row ([matChipRemove]). -->\r\n @if (!inputControl.disabled && _itemRemovable) {\r\n <sd-icon matChipRemove name=\"close\" [size]=\"_icons.chip\" [ariaLabel]=\"removeLabel(item)\"></sd-icon>\r\n }\r\n @if (!inputControl.disabled && !_itemRemovable) {\r\n <sd-icon\r\n class=\"sd-chip-calendar__lock\"\r\n name=\"lock\"\r\n [size]=\"_icons.chip\"\r\n [matTooltip]=\"'core.form.chip-calendar.locked' | sdTranslate\"></sd-icon>\r\n }\r\n </mat-chip-row>\r\n }\r\n @if (hiddenCount() > 0) {\r\n <button\r\n type=\"button\"\r\n class=\"sd-chip-calendar__more\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.more' | sdTranslate: { count: hiddenCount() }\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-more' : null\"\r\n (click)=\"onMoreClick($event)\">\r\n +{{ hiddenCount() }}\r\n </button>\r\n }\r\n\r\n <input\r\n class=\"sd-chip-input\"\r\n [formControl]=\"inputControl\"\r\n [id]=\"inputId\"\r\n [placeholder]=\"effectivePlaceholder()\"\r\n [matChipInputFor]=\"chipList\"\r\n autocomplete=\"off\"\r\n [errorStateMatcher]=\"matcher\"\r\n [required]=\"_required\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n (keydown)=\"onInputKeydown($event)\"\r\n matInput\r\n [attr.data-autoId]=\"autoId()\"\r\n [attr.data-disabled]=\"dataDisabled()\"\r\n [attr.data-empty]=\"dataEmpty()\"\r\n [attr.data-value]=\"dataValue()\"\r\n [attr.data-count]=\"dataCount()\"\r\n [attr.data-required]=\"dataRequired()\"\r\n [attr.data-error-message]=\"dataErrorMessage()\"\r\n [attr.aria-invalid]=\"_errorVisible ? 'true' : null\"\r\n [attr.aria-describedby]=\"_errorMessage ? errorId : null\"\r\n readonly\r\n #input />\r\n </mat-chip-grid>\r\n\r\n @if (_hideInlineError && _errorVisible) {\r\n <sd-icon matSuffix class=\"sd-error-icon\" [matTooltip]=\"_errorMessage\" matTooltipPosition=\"above\" name=\"error\"></sd-icon>\r\n }\r\n @if (_hideInlineError && _errorVisible) {\r\n <span class=\"sd-visually-hidden\" [id]=\"errorId\" matSuffix>{{ _errorMessage }}</span>\r\n }\r\n <!-- Suffix (thi\u1EBFt k\u1EBF 2): n\u00FAt b\u1ECF h\u1EBFt (hover-gated nh\u01B0 sd-date, lu\u00F4n hi\u1EC7n khi popup m\u1EDF) r\u1ED3i n\u00FAt l\u1ECBch. \u1EA8n khi disabled. -->\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 matSuffix \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o v\u00F9ng suffix. -->\r\n @if (!formControl.disabled && clearable() && !_required && hasRemovable()) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-clear-btn sd-chip-calendar__suffix\"\r\n [class.sd-hover]=\"!isOpen()\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.clear' | sdTranslate\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-clear' : null\"\r\n (click)=\"onClear($event)\">\r\n <sd-icon name=\"close\" [size]=\"_icons.clear\"></sd-icon>\r\n </button>\r\n }\r\n @if (!formControl.disabled) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-chip-calendar__open sd-chip-calendar__suffix\"\r\n [class.sd-chip-calendar__open--active]=\"isOpen()\"\r\n data-chip-calendar-open\r\n [attr.aria-label]=\"'core.form.date.open-picker' | sdTranslate\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-open' : null\"\r\n (click)=\"onToggleClick($event)\">\r\n <sd-icon name=\"calendar_month\" [size]=\"_icons.open\"></sd-icon>\r\n </button>\r\n }\r\n\r\n @if (_showInlineError) {\r\n <mat-error [id]=\"errorId\">{{ _errorMessage }}</mat-error>\r\n }\r\n </mat-form-field>\r\n\r\n <!-- Popup (thi\u1EBFt k\u1EBF 3): CDK overlay role=\"dialog\" treo d\u01B0\u1EDBi khung \u00F4. Ch\u1ECDn ng\u00E0y kh\u00F4ng \u0111\u00F3ng; \u0111\u00F3ng b\u1EB1ng \u201CXong\u201D, Esc\r\n ho\u1EB7c b\u1EA5m ra ngo\u00E0i. why: mat-menu c\u0169 \u0111\u00F3ng khi Tab v\u00E0 kh\u00F4ng ph\u1EA3i dialog (A3). Kh\u00F4ng aria-hidden \u1EDF \u0111\u00E2u c\u1EA3:\r\n l\u01B0\u1EDBi ng\u00E0y, n\u00FAt chuy\u1EC3n th\u00E1ng v\u00E0 \u00F4 \u0111ang ch\u1ECDn \u0111\u1EC1u ph\u1EA3i \u0111\u1ECDc \u0111\u01B0\u1EE3c. -->\r\n <ng-template\r\n cdkConnectedOverlay\r\n [cdkConnectedOverlayOrigin]=\"overlayOrigin()!\"\r\n [cdkConnectedOverlayOpen]=\"isOpen()\"\r\n [cdkConnectedOverlayPositions]=\"positions\"\r\n [cdkConnectedOverlayPush]=\"true\"\r\n [cdkConnectedOverlayViewportMargin]=\"8\"\r\n cdkConnectedOverlayPanelClass=\"sd-chip-calendar-pane\"\r\n (attach)=\"onAttach()\"\r\n (overlayOutsideClick)=\"onOutsideClick($event)\"\r\n (overlayKeydown)=\"onOverlayKeydown($event)\">\r\n @let _days = days();\r\n @let _maxCount = effectiveMaxCount();\r\n @let _full = full();\r\n <div\r\n class=\"sd-chip-calendar-panel\"\r\n role=\"dialog\"\r\n cdkTrapFocus\r\n [id]=\"panelId\"\r\n [attr.aria-label]=\"_label || ('core.form.chip-calendar.dialog-label' | sdTranslate)\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-panel' : null\">\r\n <div class=\"sd-chip-calendar-panel__head\">\r\n <div class=\"sd-chip-calendar-panel__summary\">\r\n <span class=\"sd-chip-calendar-panel__count\">{{\r\n 'core.form.chip-calendar.selected-count' | sdTranslate: { count: _days.length }\r\n }}</span>\r\n <span class=\"sd-chip-calendar-panel__limit\">\r\n {{\r\n _maxCount > 0\r\n ? ('core.form.chip-calendar.max-count' | sdTranslate: { max: _maxCount })\r\n : ('core.form.chip-calendar.no-limit' | sdTranslate)\r\n }}\r\n </span>\r\n </div>\r\n <!-- why: v\u00F9ng live lu\u00F4n c\u00F3 m\u1EB7t (r\u1ED7ng khi ch\u01B0a \u0111\u1EE7) \u0111\u1EC3 screen reader \u0111\u1ECDc c\u00E2u \u201C\u0111\u00E3 \u0111\u1EE7\u201D ngay khi n\u00F3 xu\u1EA5t hi\u1EC7n. -->\r\n <p class=\"sd-chip-calendar-panel__full\" aria-live=\"polite\">\r\n @if (_full) {\r\n {{ 'core.form.chip-calendar.full' | sdTranslate: { max: _maxCount } }}\r\n }\r\n </p>\r\n </div>\r\n\r\n <mat-calendar\r\n [headerComponent]=\"calendarHeader\"\r\n [startAt]=\"openAt()\"\r\n [minDate]=\"resolvedMinDate()\"\r\n [maxDate]=\"resolvedMaxDate()\"\r\n [dateFilter]=\"calendarFilter()\"\r\n [dateClass]=\"calendarDateClass()\"\r\n (selectedChange)=\"onSelectDate($event)\">\r\n </mat-calendar>\r\n\r\n <div class=\"sd-chip-calendar-panel__footer\">\r\n @if (clearable()) {\r\n <sd-button\r\n data-chip-calendar-clear-all\r\n type=\"text\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [disabled]=\"!hasRemovable()\"\r\n [autoId]=\"autoId() ? autoId() + '-clear-all' : undefined\"\r\n [title]=\"'core.form.chip-calendar.clear-all' | sdTranslate\"\r\n (click)=\"onClear()\"></sd-button>\r\n } @else {\r\n <span></span>\r\n }\r\n <sd-button\r\n data-chip-calendar-done\r\n type=\"fill\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [autoId]=\"autoId() ? autoId() + '-done' : undefined\"\r\n [title]=\"'core.form.chip-calendar.done' | sdTranslate\"\r\n (click)=\"close(true)\"></sd-button>\r\n </div>\r\n </div>\r\n </ng-template>\r\n }\r\n </div>\r\n}\r\n", styles: [":host{display:block}:host(.sd-has-label){padding-top:4px}:host(.sd-label-top){padding-top:0}:host(.sd-viewed){padding-top:0}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:var(--sd-chip-calendar-bg)}mat-form-field{width:100%}.sd-chip-calendar__view-trigger{display:flex;align-items:center;width:100%;cursor:pointer}.sd-chip-calendar__view-trigger:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color, var(--sd-primary));outline-offset:2px}.sd-chip-calendar-panel{display:flex;flex-direction:column;gap:4px;box-sizing:border-box;width:var(--sd-chip-calendar-panel-width, 296px);padding:12px 8px 8px;border:1px solid color-mix(in srgb,var(--sd-border) 60%,var(--sd-surface));border-radius:var(--sd-panel-radius, 10px);background-color:var(--sd-select-panel-bg, var(--sd-surface));box-shadow:var(--sd-shadow-md, none);color:var(--sd-text);animation:sd-chip-calendar-panel-in var(--sd-duration-fast, .12s) var(--sd-ease-standard, ease-out);--mat-datepicker-calendar-date-text-color: var(--sd-text);--mat-datepicker-calendar-date-hover-state-background-color: color-mix(in srgb, var(--sd-text) 5%, transparent);--mat-datepicker-calendar-date-focus-state-background-color: transparent;--mat-datepicker-calendar-date-today-outline-color: var(--sd-primary);--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-disabled-text);--mat-datepicker-calendar-date-today-disabled-state-outline-color: transparent;--mat-datepicker-calendar-header-text-color: var(--sd-text-secondary);--mat-datepicker-calendar-header-text-size: var(--sd-font-size-11, 11px);--mat-datepicker-calendar-header-text-weight: var(--sd-font-weight-medium, 500);--mat-datepicker-calendar-header-divider-color: transparent;--mat-datepicker-calendar-text-size: var(--sd-font-size-13, 13px)}@keyframes sd-chip-calendar-panel-in{0%{opacity:0;transform:scale(.98)}to{opacity:1;transform:none}}@media(prefers-reduced-motion:reduce){.sd-chip-calendar-panel{animation:none}}.sd-chip-calendar-panel__head{padding:0 8px}.sd-chip-calendar-panel__summary{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.sd-chip-calendar-panel__count{font-size:var(--sd-font-size-13, 13px);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel__limit{font-size:var(--sd-font-size-12, 12px);color:var(--sd-text-secondary)}.sd-chip-calendar-panel__full{margin:0;font-size:var(--sd-font-size-12, 12px);line-height:16px;color:var(--sd-warning-dark)}.sd-chip-calendar-panel__full:empty{display:none}.sd-chip-calendar-panel__footer{display:flex;align-items:center;justify-content:space-between;margin-top:4px;padding:8px 4px 0;border-top:1px solid var(--sd-select-panel-divider, var(--sd-border))}.sd-chip-calendar-panel ::ng-deep .mat-calendar-content{padding:0}.sd-chip-calendar-panel ::ng-deep .mat-calendar-table-header th{padding:0;line-height:24px}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-label{visibility:hidden}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell-content{font-variant-numeric:tabular-nums}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected{--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-600, var(--sd-primary-dark));--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary);--mat-datepicker-calendar-date-today-outline-color: transparent}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{background-color:var(--sd-primary);color:var(--sd-primary-contrast);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked{--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-primary-dark);--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-light);--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary-light)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{background-color:var(--sd-primary-light);color:var(--sd-primary-dark)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell:focus-visible>.mat-calendar-body-cell-content{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}@media(forced-colors:active){.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{forced-color-adjust:none;background-color:Highlight;color:HighlightText}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{forced-color-adjust:auto;border:1px solid GrayText;background-color:Canvas;color:GrayText}}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field{--sd-chip-calendar-field-height: var(--sd-control-height-md, 40px);--sd-chip-calendar-chip-height: 24px;--sd-chip-calendar-chip-font-size: var(--sd-font-size-13, 13px);--sd-chip-calendar-chip-padding: 8px;--sd-chip-calendar-suffix-size: 28px;--mat-form-field-container-height: var(--sd-chip-calendar-field-height)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-sm{--sd-chip-calendar-field-height: var(--sd-control-height-sm, 32px);--sd-chip-calendar-chip-height: 20px;--sd-chip-calendar-chip-font-size: var(--sd-font-size-12, 12px);--sd-chip-calendar-suffix-size: 24px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-lg{--sd-chip-calendar-field-height: var(--sd-control-height-lg, 48px);--sd-chip-calendar-chip-height: 28px;--sd-chip-calendar-chip-font-size: var(--sd-font-size-14, 14px);--sd-chip-calendar-chip-padding: 10px;--sd-chip-calendar-suffix-size: 32px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-form-field-infix{min-height:var(--sd-chip-calendar-field-height);padding-top:calc((var(--sd-chip-calendar-field-height) - var(--sd-chip-calendar-chip-height)) / 2);padding-bottom:calc((var(--sd-chip-calendar-field-height) - var(--sd-chip-calendar-chip-height)) / 2);border-top-width:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mdc-evolution-chip-set__chips{gap:4px;margin:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-chip-set .mdc-evolution-chip{margin:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-form-field-infix input.mat-mdc-chip-input.mat-mdc-input-element{flex:1 1 0;min-width:0;height:var(--sd-chip-calendar-chip-height);margin:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row{--mdc-chip-container-height: var(--sd-chip-calendar-chip-height);--mat-chip-container-height: var(--sd-chip-calendar-chip-height);--mdc-chip-container-shape-radius: var(--sd-radius-6, 6px);--mat-chip-container-shape-radius: var(--sd-radius-6, 6px);--mdc-chip-outline-width: 1px;--mat-chip-outline-width: 1px;--mdc-chip-outline-color: var(--sd-border);--mat-chip-outline-color: var(--sd-border);--mdc-chip-elevated-container-color: var(--sd-surface);--mat-chip-elevated-container-color: var(--sd-surface);--mdc-chip-label-text-color: var(--sd-text);--mat-chip-label-text-color: var(--sd-text);--mdc-chip-label-text-size: var(--sd-chip-calendar-chip-font-size);--mat-chip-label-text-size: var(--sd-chip-calendar-chip-font-size);--mdc-chip-label-text-weight: var(--sd-font-weight-regular, 400);--mat-chip-label-text-weight: var(--sd-font-weight-regular, 400);--mdc-chip-with-trailing-icon-trailing-icon-color: var(--sd-text-secondary);--mat-chip-with-trailing-icon-trailing-icon-color: var(--sd-text-secondary);--mdc-chip-trailing-action-state-layer-color: transparent;--mat-chip-trailing-action-state-layer-color: transparent;--mdc-chip-selected-trailing-action-state-layer-color: transparent;--mat-chip-selected-trailing-action-state-layer-color: transparent}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mdc-evolution-chip__action--primary{padding-left:var(--sd-chip-calendar-chip-padding);padding-right:2px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mdc-evolution-chip__action--trailing{padding-left:0;padding-right:3px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .sd-chip-calendar__chip-text{font-variant-numeric:tabular-nums;white-space:nowrap}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove .mat-icon{width:var(--sd-icon-size);height:var(--sd-icon-size);font-size:var(--sd-icon-size);line-height:var(--sd-icon-size)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove{position:relative;box-sizing:content-box;margin-right:3px;padding:2px;border-radius:50%;color:var(--sd-text-secondary);opacity:1}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove:hover{background-color:var(--sd-surface-muted);color:var(--sd-text)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip--locked.mat-mdc-chip-row{--mdc-chip-elevated-container-color: var(--sd-chip-calendar-chip-locked-bg);--mat-chip-elevated-container-color: var(--sd-chip-calendar-chip-locked-bg)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip--locked.mat-mdc-chip-row .mdc-evolution-chip__text-label{display:inline-flex;align-items:center}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip--locked.mat-mdc-chip-row .mdc-evolution-chip__action--primary{padding-right:3px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__lock{box-sizing:content-box;margin-left:2px;padding:2px;color:var(--sd-text-muted)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more{display:inline-flex;align-items:center;box-sizing:border-box;height:var(--sd-chip-calendar-chip-height);padding:0 8px;border:0;border-radius:var(--sd-radius-6, 6px);background-color:var(--sd-surface-muted);color:var(--sd-text-secondary);font:inherit;font-size:var(--sd-chip-calendar-chip-font-size);font-weight:var(--sd-font-weight-medium, 500);cursor:pointer}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more:hover{background-color:var(--sd-chip-calendar-more-hover-bg)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__suffix.sd-clear-btn,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open{width:var(--sd-chip-calendar-suffix-size);height:var(--sd-chip-calendar-suffix-size)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open{display:inline-flex;align-items:center;justify-content:center;padding:0;border:0;border-radius:var(--sd-radius-6, 6px);background:transparent;color:var(--sd-text-secondary);cursor:pointer}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open:hover{background-color:color-mix(in srgb,var(--sd-text) 5%,transparent)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open--active{color:var(--sd-primary)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-chip-calendar-field--open{--mdc-outlined-text-field-outline-color: var(--sd-primary);--mat-form-field-outlined-outline-color: var(--sd-primary);--mdc-outlined-text-field-hover-outline-color: var(--sd-primary);--mat-form-field-outlined-hover-outline-color: var(--sd-primary);--mdc-outlined-text-field-label-text-color: var(--sd-primary);--mat-form-field-outlined-label-text-color: var(--sd-primary);--mdc-outlined-text-field-hover-label-text-color: var(--sd-primary);--mat-form-field-outlined-hover-label-text-color: var(--sd-primary)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-chip-calendar-field--open .mat-mdc-text-field-wrapper{box-shadow:var(--sd-control-ring, none)}@media(pointer:coarse){:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-chip-remove:after{content:\"\";position:absolute;inset:50% auto auto 50%;width:24px;height:24px;transform:translate(-50%,-50%)}}@media(prefers-reduced-motion:no-preference){:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-chip-remove{transition:background-color var(--sd-duration-fast, .12s) ease}}\n"], dependencies: [{ kind: "component", type: SdIcon, selector: "sd-icon", inputs: ["name", "fontIcon", "color", "set", "fontSet", "size", "strokeWidth", "absoluteStrokeWidth", "ariaLabel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.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: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i3.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "ngmodule", type: MatChipsModule }, { kind: "component", type: i5.MatChipGrid, selector: "mat-chip-grid", inputs: ["disabled", "placeholder", "required", "value", "errorStateMatcher"], outputs: ["change", "valueChange"] }, { kind: "directive", type: i5.MatChipInput, selector: "input[matChipInputFor]", inputs: ["matChipInputFor", "matChipInputAddOnBlur", "matChipInputSeparatorKeyCodes", "placeholder", "id", "disabled", "readonly", "matChipInputDisabledInteractive"], outputs: ["matChipInputTokenEnd"], exportAs: ["matChipInput", "matChipInputFor"] }, { kind: "directive", type: i5.MatChipRemove, selector: "[matChipRemove]" }, { kind: "component", type: i5.MatChipRow, selector: "mat-chip-row, [mat-chip-row], mat-basic-chip-row, [mat-basic-chip-row]", inputs: ["editable"], outputs: ["edited"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "component", type: i6.MatCalendar, selector: "mat-calendar", inputs: ["headerComponent", "startAt", "startView", "selected", "minDate", "maxDate", "dateFilter", "dateClass", "comparisonStart", "comparisonEnd", "startDateAccessibleName", "endDateAccessibleName"], outputs: ["selectedChange", "yearSelected", "monthSelected", "viewChanged", "_userSelection", "_userDragDrop"], exportAs: ["matCalendar"] }, { kind: "ngmodule", type: MatNativeDateModule }, { kind: "ngmodule", type: OverlayModule }, { kind: "directive", type: i7.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush", "cdkConnectedOverlayDisposeOnNavigation"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i8.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "size", "fontSet", "title", "width", "tooltip", "prefixIcon", "suffixIcon", "disabled", "openOnHover", "loading", "block", "htmlType", "indicator", "indicatorColor", "indicatorMax", "indicatorLabel"], outputs: ["click"] }, { kind: "component", type: SdLabel, selector: "sd-label", inputs: ["label", "description", "required", "helperText", "for", "labelId"] }, { kind: "component", type: SdView, selector: "sd-view", inputs: ["label", "value", "display", "hyperlink", "labelTemplate", "valueTemplate", "selectedItems"] }, { kind: "pipe", type: SdTranslatePipe, name: "sdTranslate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
719
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.25", type: SdChipCalendar, isStandalone: true, selector: "sd-chip-calendar", inputs: { autoIdInput: { classPropertyName: "autoIdInput", publicName: "autoId", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, labelPlacement: { classPropertyName: "labelPlacement", publicName: "labelPlacement", isSignal: true, isRequired: false, transformFunction: null }, floatLabel: { classPropertyName: "floatLabel", publicName: "floatLabel", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, form: { classPropertyName: "form", publicName: "form", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, removable: { classPropertyName: "removable", publicName: "removable", isSignal: true, isRequired: false, transformFunction: null }, hideInlineError: { classPropertyName: "hideInlineError", publicName: "hideInlineError", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, minCount: { classPropertyName: "minCount", publicName: "minCount", isSignal: true, isRequired: false, transformFunction: null }, maxCount: { classPropertyName: "maxCount", publicName: "maxCount", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, dateFilter: { classPropertyName: "dateFilter", publicName: "dateFilter", isSignal: true, isRequired: false, transformFunction: null }, startAt: { classPropertyName: "startAt", publicName: "startAt", isSignal: true, isRequired: false, transformFunction: null }, clearable: { classPropertyName: "clearable", publicName: "clearable", isSignal: true, isRequired: false, transformFunction: null }, maxVisible: { classPropertyName: "maxVisible", publicName: "maxVisible", isSignal: true, isRequired: false, transformFunction: null }, displayFormat: { classPropertyName: "displayFormat", publicName: "displayFormat", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, viewed: { classPropertyName: "viewed", publicName: "viewed", isSignal: true, isRequired: false, transformFunction: null }, transform: { classPropertyName: "transform", publicName: "transform", isSignal: true, isRequired: false, transformFunction: null }, hyperlink: { classPropertyName: "hyperlink", publicName: "hyperlink", isSignal: true, isRequired: false, transformFunction: null }, model: { classPropertyName: "model", publicName: "model", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { model: "modelChange", sdChange: "sdChange" }, host: { properties: { "class.sd-has-label": "!!label()", "class.sd-viewed": "isViewed()", "class.sd-label-top": "labelPlacement() === 'top'" } }, queries: [{ propertyName: "sdViewDef", first: true, predicate: SdViewDefDirective, descendants: true, isSignal: true }, { propertyName: "sdLabelDef", first: true, predicate: SdLabelDefDirective, descendants: true, isSignal: true }, { propertyName: "sdLabelTemplate", first: true, predicate: ["sdLabel"], descendants: true, isSignal: true }, { propertyName: "sdValueTemplate", first: true, predicate: ["sdValue"], descendants: true, isSignal: true }], viewQueries: [{ propertyName: "calendar", first: true, predicate: MatCalendar, descendants: true, isSignal: true }, { propertyName: "field", first: true, predicate: MatFormField, descendants: true, isSignal: true }, { propertyName: "input", first: true, predicate: ["input"], descendants: true, isSignal: true }], ngImport: i0, template: "@let _label = label();\r\n@let _appearance = appearance();\r\n@let _required = required();\r\n@let _isViewed = isViewed();\r\n@let _hideInlineError = hideInlineError();\r\n@let _sdViewDef = sdViewDef();\r\n@let _labelTemplate = (sdLabelTemplate() ?? sdLabelDef()?.templateRef) || undefined;\r\n@let _valueTemplate = (sdValueTemplate() ?? _sdViewDef?.templateRef) || undefined;\r\n@let _errorMessage = errorMessage();\r\n@let _size = size();\r\n@let _labelTop = labelPlacement() === 'top';\r\n@let _icons = iconSizes();\r\n<!-- why: m\u1ED9t c\u1ED5ng gate duy nh\u1EA5t cho <mat-error>, aria-invalid v\u00E0 aria-describedby. -->\r\n@let _errorVisible = isErrorShown();\r\n@let _showInlineError = !_hideInlineError && _errorVisible;\r\n@let _viewTemplate = _sdViewDef?.templateRef;\r\n\r\n@if (_isViewed) {\r\n <sd-view\r\n [label]=\"_label\"\r\n [labelTemplate]=\"_labelTemplate\"\r\n [value]=\"formControl.value\"\r\n [display]=\"viewText()\"\r\n [hyperlink]=\"hyperlink()\"\r\n [valueTemplate]=\"_valueTemplate\">\r\n </sd-view>\r\n} @else {\r\n @if ((!_appearance || _labelTop) && _labelTemplate) {\r\n <ng-container *ngTemplateOutlet=\"_labelTemplate\"></ng-container>\r\n }\r\n @if ((!_appearance || _labelTop) && _label && !_labelTemplate) {\r\n <sd-label [label]=\"_label\" [required]=\"_required\" [for]=\"_labelTop ? inputId : null\"></sd-label>\r\n }\r\n\r\n <!-- why: div ch\u1EC9 l\u00E0 h\u1ED9p layout \u2014 aria-hidden=\"true\" c\u0169 \u1EA9n C\u1EA2 c\u00E2y con (chip, \u00F4 nh\u1EADp, <mat-error>)\r\n kh\u1ECFi accessibility tree. \u1EDE \u0111\u00E2y (click) KH\u00D4NG ph\u1EA3i ti\u1EC7n \u00EDch chu\u1ED9t th\u1EEBa nh\u01B0 c\u00E1c control kh\u00E1c:\r\n khi sdViewDef \u0111ang hi\u1EC3n th\u1ECB th\u00EC kh\u00F4ng c\u00F3 ph\u1EA7n t\u1EED focus \u0111\u01B0\u1EE3c n\u00E0o b\u00EAn trong, n\u00EAn click l\u00E0 l\u1ED1i\r\n v\u00E0o DUY NH\u1EA4T. V\u00EC v\u1EADy handler \u0111\u01B0\u1EE3c chuy\u1EC3n h\u1EB3n xu\u1ED1ng ph\u1EA7n t\u1EED view v\u00E0 ph\u1EA7n t\u1EED \u0111\u00F3 nh\u1EADn\r\n role=\"button\" + tabindex=\"0\" + keydown Enter/Space; div ngo\u00E0i kh\u00F4ng c\u00F2n handler n\u00E0o. -->\r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"!!_viewTemplate\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\">\r\n @if (_viewTemplate && !isFocused) {\r\n <!-- why: KH\u00D4NG \u0111\u1EB7t aria-label \u2014 n\u1ED9i dung sdViewDef ch\u00EDnh l\u00E0 nh\u00E3n nh\u00ECn th\u1EA5y \u0111\u01B0\u1EE3c, aria-label\r\n s\u1EBD ghi \u0111\u00E8 v\u00E0 l\u00E0m AT \u0111\u1ECDc kh\u00E1c ch\u1EEF tr\u00EAn m\u00E0n h\u00ECnh. -->\r\n <div\r\n class=\"sd-chip-calendar__view-trigger\"\r\n role=\"button\"\r\n tabindex=\"0\"\r\n (click)=\"onClick()\"\r\n (keydown.enter)=\"onViewKeydown($event)\"\r\n (keydown.space)=\"onViewKeydown($event)\">\r\n <ng-container *ngTemplateOutlet=\"_viewTemplate; context: { value: formControl.value }\"></ng-container>\r\n </div>\r\n } @else {\r\n <mat-form-field\r\n class=\"sd-chip-calendar-field\"\r\n [class.sd-md]=\"_size === 'md'\"\r\n [class.sd-sm]=\"_size === 'sm'\"\r\n [class.sd-lg]=\"_size === 'lg'\"\r\n [class.sd-chip-calendar-field--open]=\"isOpen()\"\r\n [class.hide-inline-error]=\"_hideInlineError\"\r\n [class.sd-label-top]=\"_labelTop\"\r\n [appearance]=\"_appearance\"\r\n [floatLabel]=\"floatLabel()\"\r\n (click)=\"onFieldClick()\">\r\n @if (_appearance && _label && !_labelTop) {\r\n <mat-label>{{ _label }}</mat-label>\r\n }\r\n <mat-chip-grid [formControl]=\"formControl\" #chipList [class.sd-md]=\"_size === 'md'\" [class.sd-sm]=\"_size === 'sm'\">\r\n <!-- why: chip l\u00E0 ng\u00E0y \u0111\u00E3 chu\u1EA9n ho\u00E1 (yyyy/MM/dd), hi\u1EC7n theo ng\u00E0y (B2) v\u00E0 g\u1ED9p \u201C+N\u201D khi popup \u0111\u00F3ng (B3). `removable` \u00E1p\r\n c\u1EA3 cho Backspace / Delete tr\u00EAn chip (A1); chip c\u00F3 t\u00EAn \u0111\u1EA7y \u0111\u1EE7, n\u00FAt \u2715 c\u00F3 t\u00EAn ri\u00EAng (A6). -->\r\n @for (item of visibleDays(); track item) {\r\n @let _removable = isRemovable(item);\r\n <mat-chip-row\r\n class=\"sd-chip-calendar__chip\"\r\n [class.sd-chip-calendar__chip--locked]=\"!_removable\"\r\n [removable]=\"_removable\"\r\n [aria-label]=\"chipLabel(item)\"\r\n (removed)=\"onRemove(item)\"\r\n [disabled]=\"inputControl.disabled\"\r\n (click)=\"onClickChip($event, item)\"\r\n [value]=\"item\">\r\n <span class=\"sd-chip-calendar__chip-text\">{{ formatDay(item) }}</span>\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 \u2715 \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o \u00F4 trailing c\u1EE7a mat-chip-row ([matChipRemove]). -->\r\n @if (!inputControl.disabled && _removable) {\r\n <sd-icon matChipRemove name=\"close\" [size]=\"_icons.chip\" [ariaLabel]=\"removeLabel(item)\"></sd-icon>\r\n }\r\n @if (!inputControl.disabled && !_removable) {\r\n <sd-icon\r\n class=\"sd-chip-calendar__lock\"\r\n name=\"lock\"\r\n [size]=\"_icons.chip\"\r\n [matTooltip]=\"'core.form.chip-calendar.locked' | sdTranslate\"></sd-icon>\r\n }\r\n </mat-chip-row>\r\n }\r\n @if (hiddenCount() > 0) {\r\n <button\r\n type=\"button\"\r\n class=\"sd-chip-calendar__more\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.more' | sdTranslate: { count: hiddenCount() }\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-more' : null\"\r\n (click)=\"onMoreClick($event)\">\r\n +{{ hiddenCount() }}\r\n </button>\r\n }\r\n\r\n <input\r\n class=\"sd-chip-input\"\r\n [formControl]=\"inputControl\"\r\n [id]=\"inputId\"\r\n [placeholder]=\"effectivePlaceholder()\"\r\n [matChipInputFor]=\"chipList\"\r\n autocomplete=\"off\"\r\n [errorStateMatcher]=\"matcher\"\r\n [required]=\"_required\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n (keydown)=\"onInputKeydown($event)\"\r\n matInput\r\n [attr.data-autoId]=\"autoId()\"\r\n [attr.data-disabled]=\"dataDisabled()\"\r\n [attr.data-empty]=\"dataEmpty()\"\r\n [attr.data-value]=\"dataValue()\"\r\n [attr.data-count]=\"dataCount()\"\r\n [attr.data-required]=\"dataRequired()\"\r\n [attr.data-error-message]=\"dataErrorMessage()\"\r\n [attr.aria-invalid]=\"_errorVisible ? 'true' : null\"\r\n [attr.aria-describedby]=\"_errorMessage ? errorId : null\"\r\n readonly\r\n #input />\r\n </mat-chip-grid>\r\n\r\n @if (_hideInlineError && _errorVisible) {\r\n <sd-icon matSuffix class=\"sd-error-icon\" [matTooltip]=\"_errorMessage\" matTooltipPosition=\"above\" name=\"error\"></sd-icon>\r\n }\r\n @if (_hideInlineError && _errorVisible) {\r\n <span class=\"sd-visually-hidden\" [id]=\"errorId\" matSuffix>{{ _errorMessage }}</span>\r\n }\r\n <!-- Suffix (thi\u1EBFt k\u1EBF 2): n\u00FAt b\u1ECF h\u1EBFt (hover-gated nh\u01B0 sd-date, lu\u00F4n hi\u1EC7n khi popup m\u1EDF) r\u1ED3i n\u00FAt l\u1ECBch. \u1EA8n khi disabled. -->\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 matSuffix \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o v\u00F9ng suffix. -->\r\n @if (!formControl.disabled && clearable() && !_required && hasRemovable()) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-clear-btn sd-chip-calendar__suffix\"\r\n [class.sd-hover]=\"!isOpen()\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.clear' | sdTranslate\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-clear' : null\"\r\n (click)=\"onClear($event)\">\r\n <sd-icon name=\"close\" [size]=\"_icons.clear\"></sd-icon>\r\n </button>\r\n }\r\n @if (!formControl.disabled) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-chip-calendar__open sd-chip-calendar__suffix\"\r\n [class.sd-chip-calendar__open--active]=\"isOpen()\"\r\n data-chip-calendar-open\r\n [attr.aria-label]=\"'core.form.date.open-picker' | sdTranslate\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-open' : null\"\r\n (click)=\"onToggleClick($event)\">\r\n <sd-icon name=\"calendar_month\" [size]=\"_icons.open\"></sd-icon>\r\n </button>\r\n }\r\n\r\n @if (_showInlineError) {\r\n <mat-error [id]=\"errorId\">{{ _errorMessage }}</mat-error>\r\n }\r\n </mat-form-field>\r\n\r\n <!-- Popup (thi\u1EBFt k\u1EBF 3): CDK overlay role=\"dialog\" treo d\u01B0\u1EDBi khung \u00F4. Ch\u1ECDn ng\u00E0y kh\u00F4ng \u0111\u00F3ng; \u0111\u00F3ng b\u1EB1ng \u201CXong\u201D, Esc\r\n ho\u1EB7c b\u1EA5m ra ngo\u00E0i. why: mat-menu c\u0169 \u0111\u00F3ng khi Tab v\u00E0 kh\u00F4ng ph\u1EA3i dialog (A3). Kh\u00F4ng aria-hidden \u1EDF \u0111\u00E2u c\u1EA3:\r\n l\u01B0\u1EDBi ng\u00E0y, n\u00FAt chuy\u1EC3n th\u00E1ng v\u00E0 \u00F4 \u0111ang ch\u1ECDn \u0111\u1EC1u ph\u1EA3i \u0111\u1ECDc \u0111\u01B0\u1EE3c. -->\r\n <ng-template\r\n cdkConnectedOverlay\r\n [cdkConnectedOverlayOrigin]=\"overlayOrigin()!\"\r\n [cdkConnectedOverlayOpen]=\"isOpen()\"\r\n [cdkConnectedOverlayPositions]=\"positions\"\r\n [cdkConnectedOverlayPush]=\"true\"\r\n [cdkConnectedOverlayViewportMargin]=\"8\"\r\n cdkConnectedOverlayPanelClass=\"sd-chip-calendar-pane\"\r\n (attach)=\"onAttach()\"\r\n (overlayOutsideClick)=\"onOutsideClick($event)\"\r\n (overlayKeydown)=\"onOverlayKeydown($event)\">\r\n @let _days = days();\r\n @let _maxCount = effectiveMaxCount();\r\n @let _full = full();\r\n <div\r\n class=\"sd-chip-calendar-panel\"\r\n role=\"dialog\"\r\n cdkTrapFocus\r\n [id]=\"panelId\"\r\n [attr.aria-label]=\"_label || ('core.form.chip-calendar.dialog-label' | sdTranslate)\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-panel' : null\">\r\n <div class=\"sd-chip-calendar-panel__head\">\r\n <div class=\"sd-chip-calendar-panel__summary\">\r\n <span class=\"sd-chip-calendar-panel__count\">{{\r\n 'core.form.chip-calendar.selected-count' | sdTranslate: { count: _days.length }\r\n }}</span>\r\n <span class=\"sd-chip-calendar-panel__limit\">\r\n {{\r\n _maxCount > 0\r\n ? ('core.form.chip-calendar.max-count' | sdTranslate: { max: _maxCount })\r\n : ('core.form.chip-calendar.no-limit' | sdTranslate)\r\n }}\r\n </span>\r\n </div>\r\n <!-- why: v\u00F9ng live lu\u00F4n c\u00F3 m\u1EB7t (r\u1ED7ng khi ch\u01B0a \u0111\u1EE7) \u0111\u1EC3 screen reader \u0111\u1ECDc c\u00E2u \u201C\u0111\u00E3 \u0111\u1EE7\u201D ngay khi n\u00F3 xu\u1EA5t hi\u1EC7n. -->\r\n <p class=\"sd-chip-calendar-panel__full\" aria-live=\"polite\">\r\n @if (_full) {\r\n {{ 'core.form.chip-calendar.full' | sdTranslate: { max: _maxCount } }}\r\n }\r\n </p>\r\n </div>\r\n\r\n <mat-calendar\r\n [headerComponent]=\"calendarHeader\"\r\n [startAt]=\"openAt()\"\r\n [minDate]=\"resolvedMinDate()\"\r\n [maxDate]=\"resolvedMaxDate()\"\r\n [dateFilter]=\"calendarFilter()\"\r\n [dateClass]=\"calendarDateClass()\"\r\n (selectedChange)=\"onSelectDate($event)\">\r\n </mat-calendar>\r\n\r\n <div class=\"sd-chip-calendar-panel__footer\">\r\n @if (clearable()) {\r\n <sd-button\r\n data-chip-calendar-clear-all\r\n type=\"text\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [disabled]=\"!hasRemovable()\"\r\n [autoId]=\"autoId() ? autoId() + '-clear-all' : undefined\"\r\n [title]=\"'core.form.chip-calendar.clear-all' | sdTranslate\"\r\n (click)=\"onClear()\"></sd-button>\r\n } @else {\r\n <span></span>\r\n }\r\n <sd-button\r\n data-chip-calendar-done\r\n type=\"fill\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [autoId]=\"autoId() ? autoId() + '-done' : undefined\"\r\n [title]=\"'core.form.chip-calendar.done' | sdTranslate\"\r\n (click)=\"close(true)\"></sd-button>\r\n </div>\r\n </div>\r\n </ng-template>\r\n }\r\n </div>\r\n}\r\n", styles: [":host{display:block}:host(.sd-has-label){padding-top:4px}:host(.sd-label-top){padding-top:0}:host(.sd-viewed){padding-top:0}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:var(--sd-chip-calendar-bg)}mat-form-field{width:100%}.sd-chip-calendar__view-trigger{display:flex;align-items:center;width:100%;cursor:pointer}.sd-chip-calendar__view-trigger:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color, var(--sd-primary));outline-offset:2px}.sd-chip-calendar-panel{display:flex;flex-direction:column;gap:4px;box-sizing:border-box;width:var(--sd-chip-calendar-panel-width, 296px);padding:12px 8px 8px;border:1px solid color-mix(in srgb,var(--sd-border) 60%,var(--sd-surface));border-radius:var(--sd-panel-radius, 10px);background-color:var(--sd-select-panel-bg, var(--sd-surface));box-shadow:var(--sd-shadow-md, none);color:var(--sd-text);animation:sd-chip-calendar-panel-in var(--sd-duration-fast, .12s) var(--sd-ease-standard, ease-out);--mat-datepicker-calendar-date-text-color: var(--sd-text);--mat-datepicker-calendar-date-hover-state-background-color: color-mix(in srgb, var(--sd-text) 5%, transparent);--mat-datepicker-calendar-date-focus-state-background-color: transparent;--mat-datepicker-calendar-date-today-outline-color: var(--sd-primary);--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-disabled-text);--mat-datepicker-calendar-date-today-disabled-state-outline-color: transparent;--mat-datepicker-calendar-header-text-color: var(--sd-text-secondary);--mat-datepicker-calendar-header-text-size: var(--sd-font-size-11, 11px);--mat-datepicker-calendar-header-text-weight: var(--sd-font-weight-medium, 500);--mat-datepicker-calendar-header-divider-color: transparent;--mat-datepicker-calendar-text-size: var(--sd-font-size-13, 13px)}@keyframes sd-chip-calendar-panel-in{0%{opacity:0;transform:scale(.98)}to{opacity:1;transform:none}}@media(prefers-reduced-motion:reduce){.sd-chip-calendar-panel{animation:none}}.sd-chip-calendar-panel__head{padding:0 8px}.sd-chip-calendar-panel__summary{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.sd-chip-calendar-panel__count{font-size:var(--sd-font-size-13, 13px);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel__limit{font-size:var(--sd-font-size-12, 12px);color:var(--sd-text-secondary)}.sd-chip-calendar-panel__full{margin:0;font-size:var(--sd-font-size-12, 12px);line-height:16px;color:var(--sd-warning-dark)}.sd-chip-calendar-panel__full:empty{display:none}.sd-chip-calendar-panel__footer{display:flex;align-items:center;justify-content:space-between;margin-top:4px;padding:8px 4px 0;border-top:1px solid var(--sd-select-panel-divider, var(--sd-border))}.sd-chip-calendar-panel ::ng-deep .mat-calendar-content{padding:0}.sd-chip-calendar-panel ::ng-deep .mat-calendar-table-header th{padding:0;line-height:24px}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-label{visibility:hidden}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell-content{font-variant-numeric:tabular-nums}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected{--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-600, var(--sd-primary-dark));--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary);--mat-datepicker-calendar-date-today-outline-color: transparent}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{background-color:var(--sd-primary);color:var(--sd-primary-contrast);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked{--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-primary-dark);--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-light);--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary-light)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{background-color:var(--sd-primary-light);color:var(--sd-primary-dark)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell:focus-visible>.mat-calendar-body-cell-content{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}@media(forced-colors:active){.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{forced-color-adjust:none;background-color:Highlight;color:HighlightText}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{forced-color-adjust:auto;border:1px solid GrayText;background-color:Canvas;color:GrayText}}.sd-chip-calendar__open{display:inline-flex;align-items:center;justify-content:center;width:var(--sd-chip-row-suffix-size);height:var(--sd-chip-row-suffix-size);padding:0;border:0;border-radius:var(--sd-radius-6, 6px);background:transparent;color:var(--sd-text-secondary);cursor:pointer}.sd-chip-calendar__open:hover{background-color:color-mix(in srgb,var(--sd-text) 5%,transparent)}.sd-chip-calendar__open:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}.sd-chip-calendar__open--active{color:var(--sd-primary)}@media(prefers-reduced-motion:no-preference){.sd-chip-calendar__open{transition:background-color var(--sd-duration-fast, .12s) ease}}\n"], dependencies: [{ kind: "component", type: SdIcon, selector: "sd-icon", inputs: ["name", "fontIcon", "color", "set", "fontSet", "size", "strokeWidth", "absoluteStrokeWidth", "ariaLabel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.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: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "component", type: i3.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3.MatLabel, selector: "mat-label" }, { kind: "directive", type: i3.MatError, selector: "mat-error, [matError]", inputs: ["id"] }, { kind: "directive", type: i3.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "ngmodule", type: MatChipsModule }, { kind: "component", type: i5.MatChipGrid, selector: "mat-chip-grid", inputs: ["disabled", "placeholder", "required", "value", "errorStateMatcher"], outputs: ["change", "valueChange"] }, { kind: "directive", type: i5.MatChipInput, selector: "input[matChipInputFor]", inputs: ["matChipInputFor", "matChipInputAddOnBlur", "matChipInputSeparatorKeyCodes", "placeholder", "id", "disabled", "readonly", "matChipInputDisabledInteractive"], outputs: ["matChipInputTokenEnd"], exportAs: ["matChipInput", "matChipInputFor"] }, { kind: "directive", type: i5.MatChipRemove, selector: "[matChipRemove]" }, { kind: "component", type: i5.MatChipRow, selector: "mat-chip-row, [mat-chip-row], mat-basic-chip-row, [mat-basic-chip-row]", inputs: ["editable"], outputs: ["edited"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "component", type: i6.MatCalendar, selector: "mat-calendar", inputs: ["headerComponent", "startAt", "startView", "selected", "minDate", "maxDate", "dateFilter", "dateClass", "comparisonStart", "comparisonEnd", "startDateAccessibleName", "endDateAccessibleName"], outputs: ["selectedChange", "yearSelected", "monthSelected", "viewChanged", "_userSelection", "_userDragDrop"], exportAs: ["matCalendar"] }, { kind: "ngmodule", type: MatNativeDateModule }, { kind: "ngmodule", type: OverlayModule }, { kind: "directive", type: i7.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush", "cdkConnectedOverlayDisposeOnNavigation"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i8.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "component", type: SdButton, selector: "sd-button", inputs: ["autoId", "type", "color", "size", "fontSet", "title", "width", "tooltip", "prefixIcon", "suffixIcon", "disabled", "openOnHover", "loading", "block", "htmlType", "indicator", "indicatorColor", "indicatorMax", "indicatorLabel"], outputs: ["click"] }, { kind: "component", type: SdLabel, selector: "sd-label", inputs: ["label", "description", "required", "helperText", "for", "labelId"] }, { kind: "component", type: SdView, selector: "sd-view", inputs: ["label", "value", "display", "hyperlink", "labelTemplate", "valueTemplate", "selectedItems"] }, { kind: "pipe", type: SdTranslatePipe, name: "sdTranslate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
717
720
|
}
|
|
718
721
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: SdChipCalendar, decorators: [{
|
|
719
722
|
type: Component,
|
|
@@ -738,7 +741,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImpo
|
|
|
738
741
|
SdTranslatePipe,
|
|
739
742
|
SdLabel,
|
|
740
743
|
SdView,
|
|
741
|
-
], template: "@let _label = label();\r\n@let _appearance = appearance();\r\n@let _required = required();\r\n@let _isViewed = isViewed();\r\n@let _hideInlineError = hideInlineError();\r\n@let _sdViewDef = sdViewDef();\r\n@let _labelTemplate = (sdLabelTemplate() ?? sdLabelDef()?.templateRef) || undefined;\r\n@let _valueTemplate = (sdValueTemplate() ?? _sdViewDef?.templateRef) || undefined;\r\n@let _errorMessage = errorMessage();\r\n@let _size = size();\r\n@let _labelTop = labelPlacement() === 'top';\r\n@let _icons = iconSizes();\r\n<!-- why: m\u1ED9t c\u1ED5ng gate duy nh\u1EA5t cho <mat-error>, aria-invalid v\u00E0 aria-describedby. -->\r\n@let _errorVisible = isErrorShown();\r\n@let _showInlineError = !_hideInlineError && _errorVisible;\r\n@let _viewTemplate = _sdViewDef?.templateRef;\r\n\r\n@if (_isViewed) {\r\n <sd-view\r\n [label]=\"_label\"\r\n [labelTemplate]=\"_labelTemplate\"\r\n [value]=\"formControl.value\"\r\n [display]=\"viewText()\"\r\n [hyperlink]=\"hyperlink()\"\r\n [valueTemplate]=\"_valueTemplate\">\r\n </sd-view>\r\n} @else {\r\n @if ((!_appearance || _labelTop) && _labelTemplate) {\r\n <ng-container *ngTemplateOutlet=\"_labelTemplate\"></ng-container>\r\n }\r\n @if ((!_appearance || _labelTop) && _label && !_labelTemplate) {\r\n <sd-label [label]=\"_label\" [required]=\"_required\" [for]=\"_labelTop ? inputId : null\"></sd-label>\r\n }\r\n\r\n <!-- why: div ch\u1EC9 l\u00E0 h\u1ED9p layout \u2014 aria-hidden=\"true\" c\u0169 \u1EA9n C\u1EA2 c\u00E2y con (chip, \u00F4 nh\u1EADp, <mat-error>)\r\n kh\u1ECFi accessibility tree. \u1EDE \u0111\u00E2y (click) KH\u00D4NG ph\u1EA3i ti\u1EC7n \u00EDch chu\u1ED9t th\u1EEBa nh\u01B0 c\u00E1c control kh\u00E1c:\r\n khi sdViewDef \u0111ang hi\u1EC3n th\u1ECB th\u00EC kh\u00F4ng c\u00F3 ph\u1EA7n t\u1EED focus \u0111\u01B0\u1EE3c n\u00E0o b\u00EAn trong, n\u00EAn click l\u00E0 l\u1ED1i\r\n v\u00E0o DUY NH\u1EA4T. V\u00EC v\u1EADy handler \u0111\u01B0\u1EE3c chuy\u1EC3n h\u1EB3n xu\u1ED1ng ph\u1EA7n t\u1EED view v\u00E0 ph\u1EA7n t\u1EED \u0111\u00F3 nh\u1EADn\r\n role=\"button\" + tabindex=\"0\" + keydown Enter/Space; div ngo\u00E0i kh\u00F4ng c\u00F2n handler n\u00E0o. -->\r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"!!_viewTemplate\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\">\r\n @if (_viewTemplate && !isFocused) {\r\n <!-- why: KH\u00D4NG \u0111\u1EB7t aria-label \u2014 n\u1ED9i dung sdViewDef ch\u00EDnh l\u00E0 nh\u00E3n nh\u00ECn th\u1EA5y \u0111\u01B0\u1EE3c, aria-label\r\n s\u1EBD ghi \u0111\u00E8 v\u00E0 l\u00E0m AT \u0111\u1ECDc kh\u00E1c ch\u1EEF tr\u00EAn m\u00E0n h\u00ECnh. -->\r\n <div\r\n class=\"sd-chip-calendar__view-trigger\"\r\n role=\"button\"\r\n tabindex=\"0\"\r\n (click)=\"onClick()\"\r\n (keydown.enter)=\"onViewKeydown($event)\"\r\n (keydown.space)=\"onViewKeydown($event)\">\r\n <ng-container *ngTemplateOutlet=\"_viewTemplate; context: { value: formControl.value }\"></ng-container>\r\n </div>\r\n } @else {\r\n <mat-form-field\r\n class=\"sd-chip-calendar-field\"\r\n [class.sd-md]=\"_size === 'md'\"\r\n [class.sd-sm]=\"_size === 'sm'\"\r\n [class.sd-lg]=\"_size === 'lg'\"\r\n [class.sd-chip-calendar-field--open]=\"isOpen()\"\r\n [class.hide-inline-error]=\"_hideInlineError\"\r\n [class.sd-label-top]=\"_labelTop\"\r\n [appearance]=\"_appearance\"\r\n [floatLabel]=\"floatLabel()\"\r\n (click)=\"onFieldClick()\">\r\n @if (_appearance && _label && !_labelTop) {\r\n <mat-label>{{ _label }}</mat-label>\r\n }\r\n <mat-chip-grid [formControl]=\"formControl\" #chipList [class.sd-md]=\"_size === 'md'\" [class.sd-sm]=\"_size === 'sm'\">\r\n <!-- why: chip l\u00E0 ng\u00E0y \u0111\u00E3 chu\u1EA9n ho\u00E1 (yyyy/MM/dd), hi\u1EC7n theo ng\u00E0y (B2) v\u00E0 g\u1ED9p \u201C+N\u201D khi popup \u0111\u00F3ng (B3). `removable` \u00E1p\r\n c\u1EA3 cho Backspace / Delete tr\u00EAn chip (A1); chip c\u00F3 t\u00EAn \u0111\u1EA7y \u0111\u1EE7, n\u00FAt \u2715 c\u00F3 t\u00EAn ri\u00EAng (A6). -->\r\n @for (item of visibleDays(); track item) {\r\n @let _itemRemovable = isRemovable(item);\r\n <mat-chip-row\r\n class=\"sd-chip-calendar__chip\"\r\n [class.sd-chip-calendar__chip--locked]=\"!_itemRemovable\"\r\n [removable]=\"_itemRemovable\"\r\n [aria-label]=\"chipLabel(item)\"\r\n (removed)=\"onRemove(item)\"\r\n [disabled]=\"inputControl.disabled\"\r\n (click)=\"onClickChip($event, item)\"\r\n [value]=\"item\">\r\n <span class=\"sd-chip-calendar__chip-text\">{{ formatDay(item) }}</span>\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 \u2715 \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o \u00F4 trailing c\u1EE7a mat-chip-row ([matChipRemove]). -->\r\n @if (!inputControl.disabled && _itemRemovable) {\r\n <sd-icon matChipRemove name=\"close\" [size]=\"_icons.chip\" [ariaLabel]=\"removeLabel(item)\"></sd-icon>\r\n }\r\n @if (!inputControl.disabled && !_itemRemovable) {\r\n <sd-icon\r\n class=\"sd-chip-calendar__lock\"\r\n name=\"lock\"\r\n [size]=\"_icons.chip\"\r\n [matTooltip]=\"'core.form.chip-calendar.locked' | sdTranslate\"></sd-icon>\r\n }\r\n </mat-chip-row>\r\n }\r\n @if (hiddenCount() > 0) {\r\n <button\r\n type=\"button\"\r\n class=\"sd-chip-calendar__more\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.more' | sdTranslate: { count: hiddenCount() }\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-more' : null\"\r\n (click)=\"onMoreClick($event)\">\r\n +{{ hiddenCount() }}\r\n </button>\r\n }\r\n\r\n <input\r\n class=\"sd-chip-input\"\r\n [formControl]=\"inputControl\"\r\n [id]=\"inputId\"\r\n [placeholder]=\"effectivePlaceholder()\"\r\n [matChipInputFor]=\"chipList\"\r\n autocomplete=\"off\"\r\n [errorStateMatcher]=\"matcher\"\r\n [required]=\"_required\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n (keydown)=\"onInputKeydown($event)\"\r\n matInput\r\n [attr.data-autoId]=\"autoId()\"\r\n [attr.data-disabled]=\"dataDisabled()\"\r\n [attr.data-empty]=\"dataEmpty()\"\r\n [attr.data-value]=\"dataValue()\"\r\n [attr.data-count]=\"dataCount()\"\r\n [attr.data-required]=\"dataRequired()\"\r\n [attr.data-error-message]=\"dataErrorMessage()\"\r\n [attr.aria-invalid]=\"_errorVisible ? 'true' : null\"\r\n [attr.aria-describedby]=\"_errorMessage ? errorId : null\"\r\n readonly\r\n #input />\r\n </mat-chip-grid>\r\n\r\n @if (_hideInlineError && _errorVisible) {\r\n <sd-icon matSuffix class=\"sd-error-icon\" [matTooltip]=\"_errorMessage\" matTooltipPosition=\"above\" name=\"error\"></sd-icon>\r\n }\r\n @if (_hideInlineError && _errorVisible) {\r\n <span class=\"sd-visually-hidden\" [id]=\"errorId\" matSuffix>{{ _errorMessage }}</span>\r\n }\r\n <!-- Suffix (thi\u1EBFt k\u1EBF 2): n\u00FAt b\u1ECF h\u1EBFt (hover-gated nh\u01B0 sd-date, lu\u00F4n hi\u1EC7n khi popup m\u1EDF) r\u1ED3i n\u00FAt l\u1ECBch. \u1EA8n khi disabled. -->\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 matSuffix \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o v\u00F9ng suffix. -->\r\n @if (!formControl.disabled && clearable() && !_required && hasRemovable()) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-clear-btn sd-chip-calendar__suffix\"\r\n [class.sd-hover]=\"!isOpen()\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.clear' | sdTranslate\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-clear' : null\"\r\n (click)=\"onClear($event)\">\r\n <sd-icon name=\"close\" [size]=\"_icons.clear\"></sd-icon>\r\n </button>\r\n }\r\n @if (!formControl.disabled) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-chip-calendar__open sd-chip-calendar__suffix\"\r\n [class.sd-chip-calendar__open--active]=\"isOpen()\"\r\n data-chip-calendar-open\r\n [attr.aria-label]=\"'core.form.date.open-picker' | sdTranslate\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-open' : null\"\r\n (click)=\"onToggleClick($event)\">\r\n <sd-icon name=\"calendar_month\" [size]=\"_icons.open\"></sd-icon>\r\n </button>\r\n }\r\n\r\n @if (_showInlineError) {\r\n <mat-error [id]=\"errorId\">{{ _errorMessage }}</mat-error>\r\n }\r\n </mat-form-field>\r\n\r\n <!-- Popup (thi\u1EBFt k\u1EBF 3): CDK overlay role=\"dialog\" treo d\u01B0\u1EDBi khung \u00F4. Ch\u1ECDn ng\u00E0y kh\u00F4ng \u0111\u00F3ng; \u0111\u00F3ng b\u1EB1ng \u201CXong\u201D, Esc\r\n ho\u1EB7c b\u1EA5m ra ngo\u00E0i. why: mat-menu c\u0169 \u0111\u00F3ng khi Tab v\u00E0 kh\u00F4ng ph\u1EA3i dialog (A3). Kh\u00F4ng aria-hidden \u1EDF \u0111\u00E2u c\u1EA3:\r\n l\u01B0\u1EDBi ng\u00E0y, n\u00FAt chuy\u1EC3n th\u00E1ng v\u00E0 \u00F4 \u0111ang ch\u1ECDn \u0111\u1EC1u ph\u1EA3i \u0111\u1ECDc \u0111\u01B0\u1EE3c. -->\r\n <ng-template\r\n cdkConnectedOverlay\r\n [cdkConnectedOverlayOrigin]=\"overlayOrigin()!\"\r\n [cdkConnectedOverlayOpen]=\"isOpen()\"\r\n [cdkConnectedOverlayPositions]=\"positions\"\r\n [cdkConnectedOverlayPush]=\"true\"\r\n [cdkConnectedOverlayViewportMargin]=\"8\"\r\n cdkConnectedOverlayPanelClass=\"sd-chip-calendar-pane\"\r\n (attach)=\"onAttach()\"\r\n (overlayOutsideClick)=\"onOutsideClick($event)\"\r\n (overlayKeydown)=\"onOverlayKeydown($event)\">\r\n @let _days = days();\r\n @let _maxCount = effectiveMaxCount();\r\n @let _full = full();\r\n <div\r\n class=\"sd-chip-calendar-panel\"\r\n role=\"dialog\"\r\n cdkTrapFocus\r\n [id]=\"panelId\"\r\n [attr.aria-label]=\"_label || ('core.form.chip-calendar.dialog-label' | sdTranslate)\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-panel' : null\">\r\n <div class=\"sd-chip-calendar-panel__head\">\r\n <div class=\"sd-chip-calendar-panel__summary\">\r\n <span class=\"sd-chip-calendar-panel__count\">{{\r\n 'core.form.chip-calendar.selected-count' | sdTranslate: { count: _days.length }\r\n }}</span>\r\n <span class=\"sd-chip-calendar-panel__limit\">\r\n {{\r\n _maxCount > 0\r\n ? ('core.form.chip-calendar.max-count' | sdTranslate: { max: _maxCount })\r\n : ('core.form.chip-calendar.no-limit' | sdTranslate)\r\n }}\r\n </span>\r\n </div>\r\n <!-- why: v\u00F9ng live lu\u00F4n c\u00F3 m\u1EB7t (r\u1ED7ng khi ch\u01B0a \u0111\u1EE7) \u0111\u1EC3 screen reader \u0111\u1ECDc c\u00E2u \u201C\u0111\u00E3 \u0111\u1EE7\u201D ngay khi n\u00F3 xu\u1EA5t hi\u1EC7n. -->\r\n <p class=\"sd-chip-calendar-panel__full\" aria-live=\"polite\">\r\n @if (_full) {\r\n {{ 'core.form.chip-calendar.full' | sdTranslate: { max: _maxCount } }}\r\n }\r\n </p>\r\n </div>\r\n\r\n <mat-calendar\r\n [headerComponent]=\"calendarHeader\"\r\n [startAt]=\"openAt()\"\r\n [minDate]=\"resolvedMinDate()\"\r\n [maxDate]=\"resolvedMaxDate()\"\r\n [dateFilter]=\"calendarFilter()\"\r\n [dateClass]=\"calendarDateClass()\"\r\n (selectedChange)=\"onSelectDate($event)\">\r\n </mat-calendar>\r\n\r\n <div class=\"sd-chip-calendar-panel__footer\">\r\n @if (clearable()) {\r\n <sd-button\r\n data-chip-calendar-clear-all\r\n type=\"text\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [disabled]=\"!hasRemovable()\"\r\n [autoId]=\"autoId() ? autoId() + '-clear-all' : undefined\"\r\n [title]=\"'core.form.chip-calendar.clear-all' | sdTranslate\"\r\n (click)=\"onClear()\"></sd-button>\r\n } @else {\r\n <span></span>\r\n }\r\n <sd-button\r\n data-chip-calendar-done\r\n type=\"fill\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [autoId]=\"autoId() ? autoId() + '-done' : undefined\"\r\n [title]=\"'core.form.chip-calendar.done' | sdTranslate\"\r\n (click)=\"close(true)\"></sd-button>\r\n </div>\r\n </div>\r\n </ng-template>\r\n }\r\n </div>\r\n}\r\n", styles: [":host{display:block}:host(.sd-has-label){padding-top:4px}:host(.sd-label-top){padding-top:0}:host(.sd-viewed){padding-top:0}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:var(--sd-chip-calendar-bg)}mat-form-field{width:100%}.sd-chip-calendar__view-trigger{display:flex;align-items:center;width:100%;cursor:pointer}.sd-chip-calendar__view-trigger:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color, var(--sd-primary));outline-offset:2px}.sd-chip-calendar-panel{display:flex;flex-direction:column;gap:4px;box-sizing:border-box;width:var(--sd-chip-calendar-panel-width, 296px);padding:12px 8px 8px;border:1px solid color-mix(in srgb,var(--sd-border) 60%,var(--sd-surface));border-radius:var(--sd-panel-radius, 10px);background-color:var(--sd-select-panel-bg, var(--sd-surface));box-shadow:var(--sd-shadow-md, none);color:var(--sd-text);animation:sd-chip-calendar-panel-in var(--sd-duration-fast, .12s) var(--sd-ease-standard, ease-out);--mat-datepicker-calendar-date-text-color: var(--sd-text);--mat-datepicker-calendar-date-hover-state-background-color: color-mix(in srgb, var(--sd-text) 5%, transparent);--mat-datepicker-calendar-date-focus-state-background-color: transparent;--mat-datepicker-calendar-date-today-outline-color: var(--sd-primary);--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-disabled-text);--mat-datepicker-calendar-date-today-disabled-state-outline-color: transparent;--mat-datepicker-calendar-header-text-color: var(--sd-text-secondary);--mat-datepicker-calendar-header-text-size: var(--sd-font-size-11, 11px);--mat-datepicker-calendar-header-text-weight: var(--sd-font-weight-medium, 500);--mat-datepicker-calendar-header-divider-color: transparent;--mat-datepicker-calendar-text-size: var(--sd-font-size-13, 13px)}@keyframes sd-chip-calendar-panel-in{0%{opacity:0;transform:scale(.98)}to{opacity:1;transform:none}}@media(prefers-reduced-motion:reduce){.sd-chip-calendar-panel{animation:none}}.sd-chip-calendar-panel__head{padding:0 8px}.sd-chip-calendar-panel__summary{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.sd-chip-calendar-panel__count{font-size:var(--sd-font-size-13, 13px);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel__limit{font-size:var(--sd-font-size-12, 12px);color:var(--sd-text-secondary)}.sd-chip-calendar-panel__full{margin:0;font-size:var(--sd-font-size-12, 12px);line-height:16px;color:var(--sd-warning-dark)}.sd-chip-calendar-panel__full:empty{display:none}.sd-chip-calendar-panel__footer{display:flex;align-items:center;justify-content:space-between;margin-top:4px;padding:8px 4px 0;border-top:1px solid var(--sd-select-panel-divider, var(--sd-border))}.sd-chip-calendar-panel ::ng-deep .mat-calendar-content{padding:0}.sd-chip-calendar-panel ::ng-deep .mat-calendar-table-header th{padding:0;line-height:24px}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-label{visibility:hidden}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell-content{font-variant-numeric:tabular-nums}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected{--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-600, var(--sd-primary-dark));--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary);--mat-datepicker-calendar-date-today-outline-color: transparent}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{background-color:var(--sd-primary);color:var(--sd-primary-contrast);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked{--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-primary-dark);--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-light);--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary-light)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{background-color:var(--sd-primary-light);color:var(--sd-primary-dark)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell:focus-visible>.mat-calendar-body-cell-content{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}@media(forced-colors:active){.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{forced-color-adjust:none;background-color:Highlight;color:HighlightText}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{forced-color-adjust:auto;border:1px solid GrayText;background-color:Canvas;color:GrayText}}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field{--sd-chip-calendar-field-height: var(--sd-control-height-md, 40px);--sd-chip-calendar-chip-height: 24px;--sd-chip-calendar-chip-font-size: var(--sd-font-size-13, 13px);--sd-chip-calendar-chip-padding: 8px;--sd-chip-calendar-suffix-size: 28px;--mat-form-field-container-height: var(--sd-chip-calendar-field-height)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-sm{--sd-chip-calendar-field-height: var(--sd-control-height-sm, 32px);--sd-chip-calendar-chip-height: 20px;--sd-chip-calendar-chip-font-size: var(--sd-font-size-12, 12px);--sd-chip-calendar-suffix-size: 24px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-lg{--sd-chip-calendar-field-height: var(--sd-control-height-lg, 48px);--sd-chip-calendar-chip-height: 28px;--sd-chip-calendar-chip-font-size: var(--sd-font-size-14, 14px);--sd-chip-calendar-chip-padding: 10px;--sd-chip-calendar-suffix-size: 32px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-form-field-infix{min-height:var(--sd-chip-calendar-field-height);padding-top:calc((var(--sd-chip-calendar-field-height) - var(--sd-chip-calendar-chip-height)) / 2);padding-bottom:calc((var(--sd-chip-calendar-field-height) - var(--sd-chip-calendar-chip-height)) / 2);border-top-width:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mdc-evolution-chip-set__chips{gap:4px;margin:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-chip-set .mdc-evolution-chip{margin:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-form-field-infix input.mat-mdc-chip-input.mat-mdc-input-element{flex:1 1 0;min-width:0;height:var(--sd-chip-calendar-chip-height);margin:0}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row{--mdc-chip-container-height: var(--sd-chip-calendar-chip-height);--mat-chip-container-height: var(--sd-chip-calendar-chip-height);--mdc-chip-container-shape-radius: var(--sd-radius-6, 6px);--mat-chip-container-shape-radius: var(--sd-radius-6, 6px);--mdc-chip-outline-width: 1px;--mat-chip-outline-width: 1px;--mdc-chip-outline-color: var(--sd-border);--mat-chip-outline-color: var(--sd-border);--mdc-chip-elevated-container-color: var(--sd-surface);--mat-chip-elevated-container-color: var(--sd-surface);--mdc-chip-label-text-color: var(--sd-text);--mat-chip-label-text-color: var(--sd-text);--mdc-chip-label-text-size: var(--sd-chip-calendar-chip-font-size);--mat-chip-label-text-size: var(--sd-chip-calendar-chip-font-size);--mdc-chip-label-text-weight: var(--sd-font-weight-regular, 400);--mat-chip-label-text-weight: var(--sd-font-weight-regular, 400);--mdc-chip-with-trailing-icon-trailing-icon-color: var(--sd-text-secondary);--mat-chip-with-trailing-icon-trailing-icon-color: var(--sd-text-secondary);--mdc-chip-trailing-action-state-layer-color: transparent;--mat-chip-trailing-action-state-layer-color: transparent;--mdc-chip-selected-trailing-action-state-layer-color: transparent;--mat-chip-selected-trailing-action-state-layer-color: transparent}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mdc-evolution-chip__action--primary{padding-left:var(--sd-chip-calendar-chip-padding);padding-right:2px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mdc-evolution-chip__action--trailing{padding-left:0;padding-right:3px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .sd-chip-calendar__chip-text{font-variant-numeric:tabular-nums;white-space:nowrap}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove .mat-icon{width:var(--sd-icon-size);height:var(--sd-icon-size);font-size:var(--sd-icon-size);line-height:var(--sd-icon-size)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove{position:relative;box-sizing:content-box;margin-right:3px;padding:2px;border-radius:50%;color:var(--sd-text-secondary);opacity:1}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip.mat-mdc-chip-row .mat-mdc-chip-remove:hover{background-color:var(--sd-surface-muted);color:var(--sd-text)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip--locked.mat-mdc-chip-row{--mdc-chip-elevated-container-color: var(--sd-chip-calendar-chip-locked-bg);--mat-chip-elevated-container-color: var(--sd-chip-calendar-chip-locked-bg)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip--locked.mat-mdc-chip-row .mdc-evolution-chip__text-label{display:inline-flex;align-items:center}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__chip--locked.mat-mdc-chip-row .mdc-evolution-chip__action--primary{padding-right:3px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__lock{box-sizing:content-box;margin-left:2px;padding:2px;color:var(--sd-text-muted)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more{display:inline-flex;align-items:center;box-sizing:border-box;height:var(--sd-chip-calendar-chip-height);padding:0 8px;border:0;border-radius:var(--sd-radius-6, 6px);background-color:var(--sd-surface-muted);color:var(--sd-text-secondary);font:inherit;font-size:var(--sd-chip-calendar-chip-font-size);font-weight:var(--sd-font-weight-medium, 500);cursor:pointer}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more:hover{background-color:var(--sd-chip-calendar-more-hover-bg)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__suffix.sd-clear-btn,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open{width:var(--sd-chip-calendar-suffix-size);height:var(--sd-chip-calendar-suffix-size)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open{display:inline-flex;align-items:center;justify-content:center;padding:0;border:0;border-radius:var(--sd-radius-6, 6px);background:transparent;color:var(--sd-text-secondary);cursor:pointer}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open:hover{background-color:color-mix(in srgb,var(--sd-text) 5%,transparent)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open--active{color:var(--sd-primary)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-chip-calendar-field--open{--mdc-outlined-text-field-outline-color: var(--sd-primary);--mat-form-field-outlined-outline-color: var(--sd-primary);--mdc-outlined-text-field-hover-outline-color: var(--sd-primary);--mat-form-field-outlined-hover-outline-color: var(--sd-primary);--mdc-outlined-text-field-label-text-color: var(--sd-primary);--mat-form-field-outlined-label-text-color: var(--sd-primary);--mdc-outlined-text-field-hover-label-text-color: var(--sd-primary);--mat-form-field-outlined-hover-label-text-color: var(--sd-primary)}:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field.sd-chip-calendar-field--open .mat-mdc-text-field-wrapper{box-shadow:var(--sd-control-ring, none)}@media(pointer:coarse){:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-chip-remove:after{content:\"\";position:absolute;inset:50% auto auto 50%;width:24px;height:24px;transform:translate(-50%,-50%)}}@media(prefers-reduced-motion:no-preference){:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__more,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .sd-chip-calendar__open,:host ::ng-deep .mat-mdc-form-field.sd-chip-calendar-field .mat-mdc-chip-remove{transition:background-color var(--sd-duration-fast, .12s) ease}}\n"] }]
|
|
744
|
+
], template: "@let _label = label();\r\n@let _appearance = appearance();\r\n@let _required = required();\r\n@let _isViewed = isViewed();\r\n@let _hideInlineError = hideInlineError();\r\n@let _sdViewDef = sdViewDef();\r\n@let _labelTemplate = (sdLabelTemplate() ?? sdLabelDef()?.templateRef) || undefined;\r\n@let _valueTemplate = (sdValueTemplate() ?? _sdViewDef?.templateRef) || undefined;\r\n@let _errorMessage = errorMessage();\r\n@let _size = size();\r\n@let _labelTop = labelPlacement() === 'top';\r\n@let _icons = iconSizes();\r\n<!-- why: m\u1ED9t c\u1ED5ng gate duy nh\u1EA5t cho <mat-error>, aria-invalid v\u00E0 aria-describedby. -->\r\n@let _errorVisible = isErrorShown();\r\n@let _showInlineError = !_hideInlineError && _errorVisible;\r\n@let _viewTemplate = _sdViewDef?.templateRef;\r\n\r\n@if (_isViewed) {\r\n <sd-view\r\n [label]=\"_label\"\r\n [labelTemplate]=\"_labelTemplate\"\r\n [value]=\"formControl.value\"\r\n [display]=\"viewText()\"\r\n [hyperlink]=\"hyperlink()\"\r\n [valueTemplate]=\"_valueTemplate\">\r\n </sd-view>\r\n} @else {\r\n @if ((!_appearance || _labelTop) && _labelTemplate) {\r\n <ng-container *ngTemplateOutlet=\"_labelTemplate\"></ng-container>\r\n }\r\n @if ((!_appearance || _labelTop) && _label && !_labelTemplate) {\r\n <sd-label [label]=\"_label\" [required]=\"_required\" [for]=\"_labelTop ? inputId : null\"></sd-label>\r\n }\r\n\r\n <!-- why: div ch\u1EC9 l\u00E0 h\u1ED9p layout \u2014 aria-hidden=\"true\" c\u0169 \u1EA9n C\u1EA2 c\u00E2y con (chip, \u00F4 nh\u1EADp, <mat-error>)\r\n kh\u1ECFi accessibility tree. \u1EDE \u0111\u00E2y (click) KH\u00D4NG ph\u1EA3i ti\u1EC7n \u00EDch chu\u1ED9t th\u1EEBa nh\u01B0 c\u00E1c control kh\u00E1c:\r\n khi sdViewDef \u0111ang hi\u1EC3n th\u1ECB th\u00EC kh\u00F4ng c\u00F3 ph\u1EA7n t\u1EED focus \u0111\u01B0\u1EE3c n\u00E0o b\u00EAn trong, n\u00EAn click l\u00E0 l\u1ED1i\r\n v\u00E0o DUY NH\u1EA4T. V\u00EC v\u1EADy handler \u0111\u01B0\u1EE3c chuy\u1EC3n h\u1EB3n xu\u1ED1ng ph\u1EA7n t\u1EED view v\u00E0 ph\u1EA7n t\u1EED \u0111\u00F3 nh\u1EADn\r\n role=\"button\" + tabindex=\"0\" + keydown Enter/Space; div ngo\u00E0i kh\u00F4ng c\u00F2n handler n\u00E0o. -->\r\n <div\r\n class=\"d-flex align-items-center\"\r\n [class.sd-view]=\"!!_viewTemplate\"\r\n [class.c-focused]=\"isFocused\"\r\n [class.c-disabled]=\"formControl.disabled\">\r\n @if (_viewTemplate && !isFocused) {\r\n <!-- why: KH\u00D4NG \u0111\u1EB7t aria-label \u2014 n\u1ED9i dung sdViewDef ch\u00EDnh l\u00E0 nh\u00E3n nh\u00ECn th\u1EA5y \u0111\u01B0\u1EE3c, aria-label\r\n s\u1EBD ghi \u0111\u00E8 v\u00E0 l\u00E0m AT \u0111\u1ECDc kh\u00E1c ch\u1EEF tr\u00EAn m\u00E0n h\u00ECnh. -->\r\n <div\r\n class=\"sd-chip-calendar__view-trigger\"\r\n role=\"button\"\r\n tabindex=\"0\"\r\n (click)=\"onClick()\"\r\n (keydown.enter)=\"onViewKeydown($event)\"\r\n (keydown.space)=\"onViewKeydown($event)\">\r\n <ng-container *ngTemplateOutlet=\"_viewTemplate; context: { value: formControl.value }\"></ng-container>\r\n </div>\r\n } @else {\r\n <mat-form-field\r\n class=\"sd-chip-calendar-field\"\r\n [class.sd-md]=\"_size === 'md'\"\r\n [class.sd-sm]=\"_size === 'sm'\"\r\n [class.sd-lg]=\"_size === 'lg'\"\r\n [class.sd-chip-calendar-field--open]=\"isOpen()\"\r\n [class.hide-inline-error]=\"_hideInlineError\"\r\n [class.sd-label-top]=\"_labelTop\"\r\n [appearance]=\"_appearance\"\r\n [floatLabel]=\"floatLabel()\"\r\n (click)=\"onFieldClick()\">\r\n @if (_appearance && _label && !_labelTop) {\r\n <mat-label>{{ _label }}</mat-label>\r\n }\r\n <mat-chip-grid [formControl]=\"formControl\" #chipList [class.sd-md]=\"_size === 'md'\" [class.sd-sm]=\"_size === 'sm'\">\r\n <!-- why: chip l\u00E0 ng\u00E0y \u0111\u00E3 chu\u1EA9n ho\u00E1 (yyyy/MM/dd), hi\u1EC7n theo ng\u00E0y (B2) v\u00E0 g\u1ED9p \u201C+N\u201D khi popup \u0111\u00F3ng (B3). `removable` \u00E1p\r\n c\u1EA3 cho Backspace / Delete tr\u00EAn chip (A1); chip c\u00F3 t\u00EAn \u0111\u1EA7y \u0111\u1EE7, n\u00FAt \u2715 c\u00F3 t\u00EAn ri\u00EAng (A6). -->\r\n @for (item of visibleDays(); track item) {\r\n @let _removable = isRemovable(item);\r\n <mat-chip-row\r\n class=\"sd-chip-calendar__chip\"\r\n [class.sd-chip-calendar__chip--locked]=\"!_removable\"\r\n [removable]=\"_removable\"\r\n [aria-label]=\"chipLabel(item)\"\r\n (removed)=\"onRemove(item)\"\r\n [disabled]=\"inputControl.disabled\"\r\n (click)=\"onClickChip($event, item)\"\r\n [value]=\"item\">\r\n <span class=\"sd-chip-calendar__chip-text\">{{ formatDay(item) }}</span>\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 \u2715 \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o \u00F4 trailing c\u1EE7a mat-chip-row ([matChipRemove]). -->\r\n @if (!inputControl.disabled && _removable) {\r\n <sd-icon matChipRemove name=\"close\" [size]=\"_icons.chip\" [ariaLabel]=\"removeLabel(item)\"></sd-icon>\r\n }\r\n @if (!inputControl.disabled && !_removable) {\r\n <sd-icon\r\n class=\"sd-chip-calendar__lock\"\r\n name=\"lock\"\r\n [size]=\"_icons.chip\"\r\n [matTooltip]=\"'core.form.chip-calendar.locked' | sdTranslate\"></sd-icon>\r\n }\r\n </mat-chip-row>\r\n }\r\n @if (hiddenCount() > 0) {\r\n <button\r\n type=\"button\"\r\n class=\"sd-chip-calendar__more\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.more' | sdTranslate: { count: hiddenCount() }\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-more' : null\"\r\n (click)=\"onMoreClick($event)\">\r\n +{{ hiddenCount() }}\r\n </button>\r\n }\r\n\r\n <input\r\n class=\"sd-chip-input\"\r\n [formControl]=\"inputControl\"\r\n [id]=\"inputId\"\r\n [placeholder]=\"effectivePlaceholder()\"\r\n [matChipInputFor]=\"chipList\"\r\n autocomplete=\"off\"\r\n [errorStateMatcher]=\"matcher\"\r\n [required]=\"_required\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n (keydown)=\"onInputKeydown($event)\"\r\n matInput\r\n [attr.data-autoId]=\"autoId()\"\r\n [attr.data-disabled]=\"dataDisabled()\"\r\n [attr.data-empty]=\"dataEmpty()\"\r\n [attr.data-value]=\"dataValue()\"\r\n [attr.data-count]=\"dataCount()\"\r\n [attr.data-required]=\"dataRequired()\"\r\n [attr.data-error-message]=\"dataErrorMessage()\"\r\n [attr.aria-invalid]=\"_errorVisible ? 'true' : null\"\r\n [attr.aria-describedby]=\"_errorMessage ? errorId : null\"\r\n readonly\r\n #input />\r\n </mat-chip-grid>\r\n\r\n @if (_hideInlineError && _errorVisible) {\r\n <sd-icon matSuffix class=\"sd-error-icon\" [matTooltip]=\"_errorMessage\" matTooltipPosition=\"above\" name=\"error\"></sd-icon>\r\n }\r\n @if (_hideInlineError && _errorVisible) {\r\n <span class=\"sd-visually-hidden\" [id]=\"errorId\" matSuffix>{{ _errorMessage }}</span>\r\n }\r\n <!-- Suffix (thi\u1EBFt k\u1EBF 2): n\u00FAt b\u1ECF h\u1EBFt (hover-gated nh\u01B0 sd-date, lu\u00F4n hi\u1EC7n khi popup m\u1EDF) r\u1ED3i n\u00FAt l\u1ECBch. \u1EA8n khi disabled. -->\r\n <!-- why: m\u1ED7i kh\u1ED1i @if m\u1ED9t ph\u1EA7n t\u1EED g\u1ED1c, \u0111\u1EC3 matSuffix \u0111\u01B0\u1EE3c chi\u1EBFu v\u00E0o v\u00F9ng suffix. -->\r\n @if (!formControl.disabled && clearable() && !_required && hasRemovable()) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-clear-btn sd-chip-calendar__suffix\"\r\n [class.sd-hover]=\"!isOpen()\"\r\n [attr.aria-label]=\"'core.form.chip-calendar.clear' | sdTranslate\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-clear' : null\"\r\n (click)=\"onClear($event)\">\r\n <sd-icon name=\"close\" [size]=\"_icons.clear\"></sd-icon>\r\n </button>\r\n }\r\n @if (!formControl.disabled) {\r\n <button\r\n type=\"button\"\r\n matSuffix\r\n class=\"sd-chip-calendar__open sd-chip-calendar__suffix\"\r\n [class.sd-chip-calendar__open--active]=\"isOpen()\"\r\n data-chip-calendar-open\r\n [attr.aria-label]=\"'core.form.date.open-picker' | sdTranslate\"\r\n aria-haspopup=\"dialog\"\r\n [attr.aria-expanded]=\"isOpen()\"\r\n [attr.aria-controls]=\"isOpen() ? panelId : null\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-open' : null\"\r\n (click)=\"onToggleClick($event)\">\r\n <sd-icon name=\"calendar_month\" [size]=\"_icons.open\"></sd-icon>\r\n </button>\r\n }\r\n\r\n @if (_showInlineError) {\r\n <mat-error [id]=\"errorId\">{{ _errorMessage }}</mat-error>\r\n }\r\n </mat-form-field>\r\n\r\n <!-- Popup (thi\u1EBFt k\u1EBF 3): CDK overlay role=\"dialog\" treo d\u01B0\u1EDBi khung \u00F4. Ch\u1ECDn ng\u00E0y kh\u00F4ng \u0111\u00F3ng; \u0111\u00F3ng b\u1EB1ng \u201CXong\u201D, Esc\r\n ho\u1EB7c b\u1EA5m ra ngo\u00E0i. why: mat-menu c\u0169 \u0111\u00F3ng khi Tab v\u00E0 kh\u00F4ng ph\u1EA3i dialog (A3). Kh\u00F4ng aria-hidden \u1EDF \u0111\u00E2u c\u1EA3:\r\n l\u01B0\u1EDBi ng\u00E0y, n\u00FAt chuy\u1EC3n th\u00E1ng v\u00E0 \u00F4 \u0111ang ch\u1ECDn \u0111\u1EC1u ph\u1EA3i \u0111\u1ECDc \u0111\u01B0\u1EE3c. -->\r\n <ng-template\r\n cdkConnectedOverlay\r\n [cdkConnectedOverlayOrigin]=\"overlayOrigin()!\"\r\n [cdkConnectedOverlayOpen]=\"isOpen()\"\r\n [cdkConnectedOverlayPositions]=\"positions\"\r\n [cdkConnectedOverlayPush]=\"true\"\r\n [cdkConnectedOverlayViewportMargin]=\"8\"\r\n cdkConnectedOverlayPanelClass=\"sd-chip-calendar-pane\"\r\n (attach)=\"onAttach()\"\r\n (overlayOutsideClick)=\"onOutsideClick($event)\"\r\n (overlayKeydown)=\"onOverlayKeydown($event)\">\r\n @let _days = days();\r\n @let _maxCount = effectiveMaxCount();\r\n @let _full = full();\r\n <div\r\n class=\"sd-chip-calendar-panel\"\r\n role=\"dialog\"\r\n cdkTrapFocus\r\n [id]=\"panelId\"\r\n [attr.aria-label]=\"_label || ('core.form.chip-calendar.dialog-label' | sdTranslate)\"\r\n [attr.data-autoid]=\"autoId() ? autoId() + '-panel' : null\">\r\n <div class=\"sd-chip-calendar-panel__head\">\r\n <div class=\"sd-chip-calendar-panel__summary\">\r\n <span class=\"sd-chip-calendar-panel__count\">{{\r\n 'core.form.chip-calendar.selected-count' | sdTranslate: { count: _days.length }\r\n }}</span>\r\n <span class=\"sd-chip-calendar-panel__limit\">\r\n {{\r\n _maxCount > 0\r\n ? ('core.form.chip-calendar.max-count' | sdTranslate: { max: _maxCount })\r\n : ('core.form.chip-calendar.no-limit' | sdTranslate)\r\n }}\r\n </span>\r\n </div>\r\n <!-- why: v\u00F9ng live lu\u00F4n c\u00F3 m\u1EB7t (r\u1ED7ng khi ch\u01B0a \u0111\u1EE7) \u0111\u1EC3 screen reader \u0111\u1ECDc c\u00E2u \u201C\u0111\u00E3 \u0111\u1EE7\u201D ngay khi n\u00F3 xu\u1EA5t hi\u1EC7n. -->\r\n <p class=\"sd-chip-calendar-panel__full\" aria-live=\"polite\">\r\n @if (_full) {\r\n {{ 'core.form.chip-calendar.full' | sdTranslate: { max: _maxCount } }}\r\n }\r\n </p>\r\n </div>\r\n\r\n <mat-calendar\r\n [headerComponent]=\"calendarHeader\"\r\n [startAt]=\"openAt()\"\r\n [minDate]=\"resolvedMinDate()\"\r\n [maxDate]=\"resolvedMaxDate()\"\r\n [dateFilter]=\"calendarFilter()\"\r\n [dateClass]=\"calendarDateClass()\"\r\n (selectedChange)=\"onSelectDate($event)\">\r\n </mat-calendar>\r\n\r\n <div class=\"sd-chip-calendar-panel__footer\">\r\n @if (clearable()) {\r\n <sd-button\r\n data-chip-calendar-clear-all\r\n type=\"text\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [disabled]=\"!hasRemovable()\"\r\n [autoId]=\"autoId() ? autoId() + '-clear-all' : undefined\"\r\n [title]=\"'core.form.chip-calendar.clear-all' | sdTranslate\"\r\n (click)=\"onClear()\"></sd-button>\r\n } @else {\r\n <span></span>\r\n }\r\n <sd-button\r\n data-chip-calendar-done\r\n type=\"fill\"\r\n color=\"primary\"\r\n size=\"sm\"\r\n [autoId]=\"autoId() ? autoId() + '-done' : undefined\"\r\n [title]=\"'core.form.chip-calendar.done' | sdTranslate\"\r\n (click)=\"close(true)\"></sd-button>\r\n </div>\r\n </div>\r\n </ng-template>\r\n }\r\n </div>\r\n}\r\n", styles: [":host{display:block}:host(.sd-has-label){padding-top:4px}:host(.sd-label-top){padding-top:0}:host(.sd-viewed){padding-top:0}.sd-view:not(.c-focused):not(.c-disabled):hover{background-color:var(--sd-chip-calendar-bg)}mat-form-field{width:100%}.sd-chip-calendar__view-trigger{display:flex;align-items:center;width:100%;cursor:pointer}.sd-chip-calendar__view-trigger:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color, var(--sd-primary));outline-offset:2px}.sd-chip-calendar-panel{display:flex;flex-direction:column;gap:4px;box-sizing:border-box;width:var(--sd-chip-calendar-panel-width, 296px);padding:12px 8px 8px;border:1px solid color-mix(in srgb,var(--sd-border) 60%,var(--sd-surface));border-radius:var(--sd-panel-radius, 10px);background-color:var(--sd-select-panel-bg, var(--sd-surface));box-shadow:var(--sd-shadow-md, none);color:var(--sd-text);animation:sd-chip-calendar-panel-in var(--sd-duration-fast, .12s) var(--sd-ease-standard, ease-out);--mat-datepicker-calendar-date-text-color: var(--sd-text);--mat-datepicker-calendar-date-hover-state-background-color: color-mix(in srgb, var(--sd-text) 5%, transparent);--mat-datepicker-calendar-date-focus-state-background-color: transparent;--mat-datepicker-calendar-date-today-outline-color: var(--sd-primary);--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-disabled-text);--mat-datepicker-calendar-date-today-disabled-state-outline-color: transparent;--mat-datepicker-calendar-header-text-color: var(--sd-text-secondary);--mat-datepicker-calendar-header-text-size: var(--sd-font-size-11, 11px);--mat-datepicker-calendar-header-text-weight: var(--sd-font-weight-medium, 500);--mat-datepicker-calendar-header-divider-color: transparent;--mat-datepicker-calendar-text-size: var(--sd-font-size-13, 13px)}@keyframes sd-chip-calendar-panel-in{0%{opacity:0;transform:scale(.98)}to{opacity:1;transform:none}}@media(prefers-reduced-motion:reduce){.sd-chip-calendar-panel{animation:none}}.sd-chip-calendar-panel__head{padding:0 8px}.sd-chip-calendar-panel__summary{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.sd-chip-calendar-panel__count{font-size:var(--sd-font-size-13, 13px);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel__limit{font-size:var(--sd-font-size-12, 12px);color:var(--sd-text-secondary)}.sd-chip-calendar-panel__full{margin:0;font-size:var(--sd-font-size-12, 12px);line-height:16px;color:var(--sd-warning-dark)}.sd-chip-calendar-panel__full:empty{display:none}.sd-chip-calendar-panel__footer{display:flex;align-items:center;justify-content:space-between;margin-top:4px;padding:8px 4px 0;border-top:1px solid var(--sd-select-panel-divider, var(--sd-border))}.sd-chip-calendar-panel ::ng-deep .mat-calendar-content{padding:0}.sd-chip-calendar-panel ::ng-deep .mat-calendar-table-header th{padding:0;line-height:24px}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-label{visibility:hidden}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell-content{font-variant-numeric:tabular-nums}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected{--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-600, var(--sd-primary-dark));--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary);--mat-datepicker-calendar-date-today-outline-color: transparent}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{background-color:var(--sd-primary);color:var(--sd-primary-contrast);font-weight:var(--sd-font-weight-semibold, 600)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked{--mat-datepicker-calendar-date-disabled-state-text-color: var(--sd-primary-dark);--mat-datepicker-calendar-date-hover-state-background-color: var(--sd-primary-light);--mat-datepicker-calendar-date-focus-state-background-color: var(--sd-primary-light)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{background-color:var(--sd-primary-light);color:var(--sd-primary-dark)}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell:focus-visible>.mat-calendar-body-cell-content{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}@media(forced-colors:active){.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-selected>.mat-calendar-body-cell-content{forced-color-adjust:none;background-color:Highlight;color:HighlightText}.sd-chip-calendar-panel ::ng-deep .mat-calendar-body-cell.sd-chip-calendar-locked>.mat-calendar-body-cell-content{forced-color-adjust:auto;border:1px solid GrayText;background-color:Canvas;color:GrayText}}.sd-chip-calendar__open{display:inline-flex;align-items:center;justify-content:center;width:var(--sd-chip-row-suffix-size);height:var(--sd-chip-row-suffix-size);padding:0;border:0;border-radius:var(--sd-radius-6, 6px);background:transparent;color:var(--sd-text-secondary);cursor:pointer}.sd-chip-calendar__open:hover{background-color:color-mix(in srgb,var(--sd-text) 5%,transparent)}.sd-chip-calendar__open:focus-visible{outline:var(--sd-focus-ring-width, 2px) solid var(--sd-focus-ring-color);outline-offset:1px}.sd-chip-calendar__open--active{color:var(--sd-primary)}@media(prefers-reduced-motion:no-preference){.sd-chip-calendar__open{transition:background-color var(--sd-duration-fast, .12s) ease}}\n"] }]
|
|
742
745
|
}], ctorParameters: () => [], propDecorators: { calendar: [{ type: i0.ViewChild, args: [i0.forwardRef(() => MatCalendar), { isSignal: true }] }], field: [{ type: i0.ViewChild, args: [i0.forwardRef(() => MatFormField), { isSignal: true }] }], autoIdInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoId", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], appearance: [{ type: i0.Input, args: [{ isSignal: true, alias: "appearance", required: false }] }], labelPlacement: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelPlacement", required: false }] }], floatLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "floatLabel", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], form: [{ type: i0.Input, args: [{ isSignal: true, alias: "form", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], removable: [{ type: i0.Input, args: [{ isSignal: true, alias: "removable", required: false }] }], hideInlineError: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideInlineError", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], minCount: [{ type: i0.Input, args: [{ isSignal: true, alias: "minCount", required: false }] }], maxCount: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxCount", required: false }] }], min: [{ type: i0.Input, args: [{ isSignal: true, alias: "min", required: false }] }], max: [{ type: i0.Input, args: [{ isSignal: true, alias: "max", required: false }] }], minDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "minDate", required: false }] }], maxDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxDate", required: false }] }], dateFilter: [{ type: i0.Input, args: [{ isSignal: true, alias: "dateFilter", required: false }] }], startAt: [{ type: i0.Input, args: [{ isSignal: true, alias: "startAt", required: false }] }], clearable: [{ type: i0.Input, args: [{ isSignal: true, alias: "clearable", required: false }] }], maxVisible: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxVisible", required: false }] }], displayFormat: [{ type: i0.Input, args: [{ isSignal: true, alias: "displayFormat", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], viewed: [{ type: i0.Input, args: [{ isSignal: true, alias: "viewed", required: false }] }], transform: [{ type: i0.Input, args: [{ isSignal: true, alias: "transform", required: false }] }], hyperlink: [{ type: i0.Input, args: [{ isSignal: true, alias: "hyperlink", required: false }] }], model: [{ type: i0.Input, args: [{ isSignal: true, alias: "model", required: false }] }, { type: i0.Output, args: ["modelChange"] }], sdChange: [{ type: i0.Output, args: ["sdChange"] }], input: [{ type: i0.ViewChild, args: ['input', { isSignal: true }] }], sdViewDef: [{ type: i0.ContentChild, args: [i0.forwardRef(() => SdViewDefDirective), { isSignal: true }] }], sdLabelDef: [{ type: i0.ContentChild, args: [i0.forwardRef(() => SdLabelDefDirective), { isSignal: true }] }], sdLabelTemplate: [{ type: i0.ContentChild, args: ['sdLabel', { isSignal: true }] }], sdValueTemplate: [{ type: i0.ContentChild, args: ['sdValue', { isSignal: true }] }] } });
|
|
743
746
|
|
|
744
747
|
/**
|