@sd-angular/core 19.0.0-beta.99 → 19.0.4
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/README.md +9 -11
- package/assets/images/coming-soon.svg +23 -0
- package/assets/images/data-empty.svg +21 -0
- package/assets/images/expired.svg +22 -0
- package/assets/images/file-error.svg +28 -0
- package/assets/images/filter-empty.svg +20 -0
- package/assets/images/filter-required.svg +21 -0
- package/assets/images/forbidden.svg +15 -0
- package/assets/images/image-error.svg +27 -0
- package/assets/images/maintenance.svg +23 -0
- package/assets/images/not-found.svg +20 -0
- package/assets/images/offline.svg +20 -0
- package/assets/images/submitted.svg +18 -0
- package/assets/images/success.svg +18 -0
- package/assets/images/unauthorized.svg +22 -0
- package/assets/images/unknown-error.svg +18 -0
- package/assets/scss/README.md +433 -353
- package/assets/scss/core/_inline-edit.scss +105 -0
- package/assets/scss/core/form.scss +58 -1
- package/assets/scss/core/image.scss +35 -0
- package/assets/scss/core/utilities/_base.scss +6 -6
- package/assets/scss/core/utilities/_grid.scss +4 -3
- package/assets/scss/core/utilities/_index.scss +1 -1
- package/assets/scss/core/utilities/_sizing.scss +2 -2
- package/assets/scss/sd-core.scss +1 -2
- package/components/autoid-inspector/src/autoid-inspector.component.d.ts +18 -0
- package/components/autoid-inspector/src/models/autoid-element.model.d.ts +45 -1
- package/components/autoid-inspector/src/models/autoid-export-format.model.d.ts +19 -0
- package/components/autoid-inspector/src/services/autoid-export.service.d.ts +10 -2
- package/components/autoid-inspector/src/services/autoid-scanner.service.d.ts +26 -3
- package/components/badge/src/badge.component.d.ts +20 -3
- package/components/button/src/button.component.d.ts +3 -3
- package/components/ckeditor-styles/index.d.ts +1 -0
- package/components/ckeditor-styles/src/ckeditor-styles.component.d.ts +25 -0
- package/components/form-generic/src/components/form-builder/form-builder.component.d.ts +13 -15
- package/components/form-generic/src/components/form-render/form-render.component.d.ts +1 -2
- package/components/form-generic/src/components/sd-feel-expression/sd-feel-expression.component.d.ts +1 -2
- package/components/form-generic/src/models/form-generic-component.model.d.ts +5 -6
- package/components/form-generic/src/models/form-generic-expression.model.d.ts +1 -1
- package/components/history/models/history.model.d.ts +2 -2
- package/components/index.d.ts +2 -0
- package/components/inform/index.d.ts +2 -0
- package/components/inform/src/inform-action.directive.d.ts +9 -0
- package/components/inform/src/inform.component.d.ts +59 -0
- package/components/modal/src/modal.component.d.ts +2 -1
- package/components/modal-resizable/index.d.ts +1 -0
- package/components/modal-resizable/src/modal-resizable.component.d.ts +29 -0
- package/components/operator/index.d.ts +1 -0
- package/components/operator/src/operator.component.d.ts +34 -0
- package/components/query-bar/index.d.ts +2 -0
- package/components/query-bar/src/components/actions-bar/actions-bar.component.d.ts +28 -0
- package/components/query-bar/src/components/build-chip/build-chip.component.d.ts +67 -0
- package/components/query-bar/src/components/chip-popover/chip-popover.component.d.ts +73 -0
- package/components/query-bar/src/components/field-picker/field-picker.component.d.ts +37 -0
- package/components/query-bar/src/components/inline-chip/inline-chip.component.d.ts +76 -0
- package/components/query-bar/src/components/inline-value-chip/inline-value-chip.component.d.ts +67 -0
- package/components/query-bar/src/components/popover-chip/popover-chip.component.d.ts +35 -0
- package/components/query-bar/src/components/saved-filters-menu/saved-filters-menu.component.d.ts +39 -0
- package/components/query-bar/src/query-bar.component.d.ts +137 -0
- package/components/query-bar/src/query-bar.model.d.ts +136 -0
- package/components/query-builder/index.d.ts +2 -0
- package/components/query-builder/src/query-builder.component.d.ts +98 -22
- package/components/query-builder/src/query-builder.model.d.ts +118 -0
- package/components/query-builder/src/query-builder.serializer.d.ts +32 -0
- package/components/section/src/section.component.d.ts +3 -3
- package/components/side-drawer/src/side-drawer.component.d.ts +1 -2
- package/components/stepper/index.d.ts +2 -0
- package/components/stepper/src/step.component.d.ts +17 -0
- package/components/stepper/src/stepper.component.d.ts +32 -0
- package/components/tab/index.d.ts +2 -0
- package/components/tab/src/tab-group.component.d.ts +36 -0
- package/components/tab/src/tab.component.d.ts +13 -0
- package/components/tab-router/src/decorators/tab.decorator.d.ts +2 -2
- package/components/tab-router/src/models/tab-router.model.d.ts +2 -2
- package/components/table/index.d.ts +1 -0
- package/components/table/src/components/column-title/column-title.component.d.ts +1 -1
- package/components/table/src/components/config/config.component.d.ts +3 -1
- package/components/table/src/components/desktop-cell/desktop-cell.component.d.ts +3 -3
- package/components/table/src/components/filter/column-filter/column-filter.component.d.ts +3 -7
- package/components/table/src/components/selector-action/selector-action.component.d.ts +3 -1
- package/components/table/src/configurations/table.configuration.d.ts +3 -3
- package/components/table/src/directives/index.d.ts +1 -0
- package/components/table/src/directives/sd-table-cell-def.directive.d.ts +12 -4
- package/components/table/src/directives/sd-table-column-filter-def.directive.d.ts +12 -4
- package/components/table/src/directives/sd-table-expand-def.directive.d.ts +10 -4
- package/components/table/src/directives/sd-table-filter-def.directive.d.ts +3 -3
- package/components/table/src/directives/sd-table-footer-def.directive.d.ts +12 -4
- package/components/table/src/directives/sd-table-group-def.directive.d.ts +44 -0
- package/components/table/src/directives/sd-table-title-def.directive.d.ts +10 -4
- package/components/table/src/models/index.d.ts +1 -0
- package/components/table/src/models/table-column.model.d.ts +13 -13
- package/components/table/src/models/table-command.model.d.ts +3 -2
- package/components/table/src/models/table-item.model.d.ts +19 -4
- package/components/table/src/models/table-option-export.model.d.ts +3 -3
- package/components/table/src/models/table-option-group.model.d.ts +19 -2
- package/components/table/src/models/table-option-selector.model.d.ts +17 -1
- package/components/table/src/models/table-option-tree.model.d.ts +96 -8
- package/components/table/src/models/table-option.model.d.ts +11 -2
- package/components/table/src/pipes/sd-group.pipe.d.ts +15 -1
- package/components/table/src/services/table-filter/table-filter.model.d.ts +9 -9
- package/components/table/src/services/table-filter/table-filter.service.d.ts +2 -2
- package/components/table/src/services/tree/tree.util.d.ts +43 -2
- package/components/table/src/table.component.d.ts +37 -13
- package/components/upload-file/src/upload-file.component.d.ts +2 -0
- package/components/view/src/view.component.d.ts +35 -1
- package/directives/src/sd-desktop.directive.d.ts +2 -4
- package/directives/src/sd-mobile.directive.d.ts +2 -4
- package/fesm2022/sd-angular-core-components-anchor.mjs +75 -49
- package/fesm2022/sd-angular-core-components-anchor.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-autoid-inspector.mjs +254 -29
- package/fesm2022/sd-angular-core-components-autoid-inspector.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-avatar.mjs +2 -2
- package/fesm2022/sd-angular-core-components-avatar.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-badge.mjs +18 -3
- package/fesm2022/sd-angular-core-components-badge.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-button.mjs +3 -5
- package/fesm2022/sd-angular-core-components-button.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-ckeditor-styles.mjs +38 -0
- package/fesm2022/sd-angular-core-components-ckeditor-styles.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-document-builder.mjs +10 -8
- package/fesm2022/sd-angular-core-components-document-builder.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-editor.mjs +3 -2
- package/fesm2022/sd-angular-core-components-editor.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-form-generic.mjs +153 -243
- package/fesm2022/sd-angular-core-components-form-generic.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-history.mjs +3 -2
- package/fesm2022/sd-angular-core-components-history.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-inform.mjs +190 -0
- package/fesm2022/sd-angular-core-components-inform.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-mini-editor.mjs +4 -3
- package/fesm2022/sd-angular-core-components-mini-editor.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-modal-resizable.mjs +158 -0
- package/fesm2022/sd-angular-core-components-modal-resizable.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-modal.mjs +2 -2
- package/fesm2022/sd-angular-core-components-modal.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-operator.mjs +77 -0
- package/fesm2022/sd-angular-core-components-operator.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-preview.mjs +4 -4
- package/fesm2022/sd-angular-core-components-preview.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-query-bar.mjs +1384 -0
- package/fesm2022/sd-angular-core-components-query-bar.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-query-builder.mjs +669 -57
- package/fesm2022/sd-angular-core-components-query-builder.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-quick-action.mjs +2 -2
- package/fesm2022/sd-angular-core-components-quick-action.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-section.mjs +2 -4
- package/fesm2022/sd-angular-core-components-section.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-side-drawer.mjs +3 -5
- package/fesm2022/sd-angular-core-components-side-drawer.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-splitter.mjs +5 -2
- package/fesm2022/sd-angular-core-components-splitter.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-stepper.mjs +138 -0
- package/fesm2022/sd-angular-core-components-stepper.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-tab-router.mjs +3 -3
- package/fesm2022/sd-angular-core-components-tab-router.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-tab.mjs +143 -0
- package/fesm2022/sd-angular-core-components-tab.mjs.map +1 -0
- package/fesm2022/sd-angular-core-components-table.mjs +577 -225
- package/fesm2022/sd-angular-core-components-table.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-upload-file.mjs +36 -25
- package/fesm2022/sd-angular-core-components-upload-file.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components-view.mjs +44 -9
- package/fesm2022/sd-angular-core-components-view.mjs.map +1 -1
- package/fesm2022/sd-angular-core-components.mjs +2 -0
- package/fesm2022/sd-angular-core-components.mjs.map +1 -1
- package/fesm2022/sd-angular-core-directives.mjs +19 -21
- package/fesm2022/sd-angular-core-directives.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-autocomplete.mjs +45 -16
- package/fesm2022/sd-angular-core-forms-autocomplete.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-checkbox.mjs +97 -87
- package/fesm2022/sd-angular-core-forms-checkbox.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-chip-calendar.mjs +92 -61
- package/fesm2022/sd-angular-core-forms-chip-calendar.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-chip.mjs +89 -52
- package/fesm2022/sd-angular-core-forms-chip.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-date-range.mjs +63 -10
- package/fesm2022/sd-angular-core-forms-date-range.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-date.mjs +39 -15
- package/fesm2022/sd-angular-core-forms-date.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-datetime.mjs +33 -14
- package/fesm2022/sd-angular-core-forms-datetime.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-directives.mjs +18 -24
- package/fesm2022/sd-angular-core-forms-directives.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-inline-text.mjs +167 -0
- package/fesm2022/sd-angular-core-forms-inline-text.mjs.map +1 -0
- package/fesm2022/sd-angular-core-forms-input-color.mjs +119 -0
- package/fesm2022/sd-angular-core-forms-input-color.mjs.map +1 -0
- package/fesm2022/sd-angular-core-forms-input-number.mjs +73 -15
- package/fesm2022/sd-angular-core-forms-input-number.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-input.mjs +86 -29
- package/fesm2022/sd-angular-core-forms-input.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-models.mjs +44 -2
- package/fesm2022/sd-angular-core-forms-models.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-radio.mjs +130 -175
- package/fesm2022/sd-angular-core-forms-radio.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-select.mjs +66 -23
- package/fesm2022/sd-angular-core-forms-select.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-switch.mjs +95 -98
- package/fesm2022/sd-angular-core-forms-switch.mjs.map +1 -1
- package/fesm2022/sd-angular-core-forms-textarea.mjs +33 -12
- package/fesm2022/sd-angular-core-forms-textarea.mjs.map +1 -1
- package/fesm2022/sd-angular-core-i18n.mjs +65 -0
- package/fesm2022/sd-angular-core-i18n.mjs.map +1 -1
- package/fesm2022/sd-angular-core-modules-auth.mjs +4 -4
- package/fesm2022/sd-angular-core-modules-auth.mjs.map +1 -1
- package/fesm2022/sd-angular-core-modules-authom.mjs +1 -1
- package/fesm2022/sd-angular-core-modules-authom.mjs.map +1 -1
- package/fesm2022/sd-angular-core-modules-layout.mjs +23 -23
- package/fesm2022/sd-angular-core-modules-layout.mjs.map +1 -1
- package/fesm2022/sd-angular-core-modules-permission.mjs +3 -3
- package/fesm2022/sd-angular-core-modules-permission.mjs.map +1 -1
- package/fesm2022/sd-angular-core-pipes.mjs +2 -2
- package/fesm2022/sd-angular-core-pipes.mjs.map +1 -1
- package/fesm2022/sd-angular-core-services-api.mjs +3 -3
- package/fesm2022/sd-angular-core-services-api.mjs.map +1 -1
- package/fesm2022/sd-angular-core-services-cache.mjs +3 -2
- package/fesm2022/sd-angular-core-services-cache.mjs.map +1 -1
- package/fesm2022/sd-angular-core-services-confirm.mjs +1 -1
- package/fesm2022/sd-angular-core-services-confirm.mjs.map +1 -1
- package/fesm2022/sd-angular-core-services-excel.mjs +6 -5
- package/fesm2022/sd-angular-core-services-excel.mjs.map +1 -1
- package/fesm2022/sd-angular-core-services-notify.mjs +43 -12
- package/fesm2022/sd-angular-core-services-notify.mjs.map +1 -1
- package/fesm2022/sd-angular-core-services-storage.mjs +2 -2
- package/fesm2022/sd-angular-core-services-storage.mjs.map +1 -1
- package/fesm2022/sd-angular-core-utilities-models.mjs.map +1 -1
- package/forms/autocomplete/src/autocomplete.component.d.ts +24 -10
- package/forms/checkbox/src/checkbox.component.d.ts +21 -20
- package/forms/chip/src/chip.component.d.ts +25 -20
- package/forms/chip-calendar/src/chip-calendar.component.d.ts +27 -22
- package/forms/date/src/date.component.d.ts +23 -9
- package/forms/date-range/src/date-range.component.d.ts +28 -5
- package/forms/datetime/src/datetime.component.d.ts +21 -8
- package/forms/directives/src/item-def.directive.d.ts +10 -5
- package/forms/directives/src/label-def.directive.d.ts +3 -2
- package/forms/directives/src/suffix-def.directive.d.ts +3 -2
- package/forms/directives/src/view-def.directive.d.ts +9 -9
- package/forms/inline-text/index.d.ts +1 -0
- package/forms/inline-text/src/inline-text.component.d.ts +76 -0
- package/forms/input/src/input.component.d.ts +31 -13
- package/forms/input-color/index.d.ts +1 -0
- package/forms/input-color/src/input-color.component.d.ts +34 -0
- package/forms/input-number/src/input-number.component.d.ts +25 -9
- package/forms/models/index.d.ts +1 -0
- package/forms/models/src/sd-custom-validator.model.d.ts +13 -1
- package/forms/models/src/sd-viewed.d.ts +38 -0
- package/forms/radio/src/radio.component.d.ts +37 -38
- package/forms/select/src/select.component.d.ts +36 -14
- package/forms/switch/src/switch.component.d.ts +22 -23
- package/forms/textarea/src/textarea.component.d.ts +18 -8
- package/i18n/src/en.d.ts +11 -0
- package/modules/auth/configurations/auth.configuration.d.ts +4 -4
- package/modules/layout/configurations/layout.configuration.d.ts +3 -3
- package/modules/permission/src/configurations/permission.configuration.d.ts +3 -3
- package/package.json +77 -41
- package/sd-angular-core-19.0.4.tgz +0 -0
- package/services/confirm/src/lib/components/dialog-confirm/dialog-confirm.component.d.ts +3 -3
- package/services/confirm/src/lib/confirm.service.d.ts +9 -9
- package/services/notify/src/components/toast/toast.component.d.ts +16 -1
- package/services/notify/src/notify.model.d.ts +17 -0
- package/utilities/models/src/icon.model.d.ts +1 -1
- package/assets/scss/bootstrap-4.6.2/_alert.scss +0 -52
- package/assets/scss/bootstrap-4.6.2/_badge.scss +0 -54
- package/assets/scss/bootstrap-4.6.2/_breadcrumb.scss +0 -42
- package/assets/scss/bootstrap-4.6.2/_button-group.scss +0 -163
- package/assets/scss/bootstrap-4.6.2/_buttons.scss +0 -142
- package/assets/scss/bootstrap-4.6.2/_card.scss +0 -286
- package/assets/scss/bootstrap-4.6.2/_carousel.scss +0 -200
- package/assets/scss/bootstrap-4.6.2/_close.scss +0 -40
- package/assets/scss/bootstrap-4.6.2/_code.scss +0 -48
- package/assets/scss/bootstrap-4.6.2/_custom-forms.scss +0 -526
- package/assets/scss/bootstrap-4.6.2/_dropdown.scss +0 -192
- package/assets/scss/bootstrap-4.6.2/_forms.scss +0 -347
- package/assets/scss/bootstrap-4.6.2/_functions.scss +0 -190
- package/assets/scss/bootstrap-4.6.2/_grid.scss +0 -73
- package/assets/scss/bootstrap-4.6.2/_images.scss +0 -42
- package/assets/scss/bootstrap-4.6.2/_input-group.scss +0 -211
- package/assets/scss/bootstrap-4.6.2/_jumbotron.scss +0 -17
- package/assets/scss/bootstrap-4.6.2/_list-group.scss +0 -154
- package/assets/scss/bootstrap-4.6.2/_media.scss +0 -8
- package/assets/scss/bootstrap-4.6.2/_mixins.scss +0 -47
- package/assets/scss/bootstrap-4.6.2/_modal.scss +0 -240
- package/assets/scss/bootstrap-4.6.2/_nav.scss +0 -125
- package/assets/scss/bootstrap-4.6.2/_navbar.scss +0 -332
- package/assets/scss/bootstrap-4.6.2/_pagination.scss +0 -74
- package/assets/scss/bootstrap-4.6.2/_popover.scss +0 -170
- package/assets/scss/bootstrap-4.6.2/_print.scss +0 -132
- package/assets/scss/bootstrap-4.6.2/_progress.scss +0 -47
- package/assets/scss/bootstrap-4.6.2/_reboot.scss +0 -484
- package/assets/scss/bootstrap-4.6.2/_root.scss +0 -19
- package/assets/scss/bootstrap-4.6.2/_spinners.scss +0 -65
- package/assets/scss/bootstrap-4.6.2/_tables.scss +0 -185
- package/assets/scss/bootstrap-4.6.2/_toasts.scss +0 -46
- package/assets/scss/bootstrap-4.6.2/_tooltip.scss +0 -115
- package/assets/scss/bootstrap-4.6.2/_transitions.scss +0 -26
- package/assets/scss/bootstrap-4.6.2/_type.scss +0 -125
- package/assets/scss/bootstrap-4.6.2/_utilities.scss +0 -18
- package/assets/scss/bootstrap-4.6.2/_variables.scss +0 -1150
- package/assets/scss/bootstrap-4.6.2/bootstrap-grid.scss +0 -30
- package/assets/scss/bootstrap-4.6.2/bootstrap-reboot.scss +0 -12
- package/assets/scss/bootstrap-4.6.2/bootstrap.scss +0 -44
- package/assets/scss/bootstrap-4.6.2/mixins/_alert.scss +0 -13
- package/assets/scss/bootstrap-4.6.2/mixins/_background-variant.scss +0 -23
- package/assets/scss/bootstrap-4.6.2/mixins/_badge.scss +0 -17
- package/assets/scss/bootstrap-4.6.2/mixins/_border-radius.scss +0 -76
- package/assets/scss/bootstrap-4.6.2/mixins/_box-shadow.scss +0 -20
- package/assets/scss/bootstrap-4.6.2/mixins/_breakpoints.scss +0 -123
- package/assets/scss/bootstrap-4.6.2/mixins/_buttons.scss +0 -110
- package/assets/scss/bootstrap-4.6.2/mixins/_caret.scss +0 -62
- package/assets/scss/bootstrap-4.6.2/mixins/_clearfix.scss +0 -7
- package/assets/scss/bootstrap-4.6.2/mixins/_deprecate.scss +0 -10
- package/assets/scss/bootstrap-4.6.2/mixins/_float.scss +0 -14
- package/assets/scss/bootstrap-4.6.2/mixins/_forms.scss +0 -195
- package/assets/scss/bootstrap-4.6.2/mixins/_gradients.scss +0 -45
- package/assets/scss/bootstrap-4.6.2/mixins/_grid-framework.scss +0 -80
- package/assets/scss/bootstrap-4.6.2/mixins/_grid.scss +0 -69
- package/assets/scss/bootstrap-4.6.2/mixins/_hover.scss +0 -37
- package/assets/scss/bootstrap-4.6.2/mixins/_image.scss +0 -36
- package/assets/scss/bootstrap-4.6.2/mixins/_list-group.scss +0 -21
- package/assets/scss/bootstrap-4.6.2/mixins/_lists.scss +0 -7
- package/assets/scss/bootstrap-4.6.2/mixins/_nav-divider.scss +0 -11
- package/assets/scss/bootstrap-4.6.2/mixins/_pagination.scss +0 -22
- package/assets/scss/bootstrap-4.6.2/mixins/_reset-text.scss +0 -17
- package/assets/scss/bootstrap-4.6.2/mixins/_resize.scss +0 -6
- package/assets/scss/bootstrap-4.6.2/mixins/_screen-reader.scss +0 -34
- package/assets/scss/bootstrap-4.6.2/mixins/_size.scss +0 -7
- package/assets/scss/bootstrap-4.6.2/mixins/_table-row.scss +0 -39
- package/assets/scss/bootstrap-4.6.2/mixins/_text-emphasis.scss +0 -17
- package/assets/scss/bootstrap-4.6.2/mixins/_text-hide.scss +0 -11
- package/assets/scss/bootstrap-4.6.2/mixins/_text-truncate.scss +0 -8
- package/assets/scss/bootstrap-4.6.2/mixins/_transition.scss +0 -26
- package/assets/scss/bootstrap-4.6.2/mixins/_visibility.scss +0 -8
- package/assets/scss/bootstrap-4.6.2/utilities/_align.scss +0 -8
- package/assets/scss/bootstrap-4.6.2/utilities/_background.scss +0 -19
- package/assets/scss/bootstrap-4.6.2/utilities/_borders.scss +0 -75
- package/assets/scss/bootstrap-4.6.2/utilities/_clearfix.scss +0 -3
- package/assets/scss/bootstrap-4.6.2/utilities/_display.scss +0 -26
- package/assets/scss/bootstrap-4.6.2/utilities/_embed.scss +0 -39
- package/assets/scss/bootstrap-4.6.2/utilities/_flex.scss +0 -51
- package/assets/scss/bootstrap-4.6.2/utilities/_float.scss +0 -11
- package/assets/scss/bootstrap-4.6.2/utilities/_interactions.scss +0 -5
- package/assets/scss/bootstrap-4.6.2/utilities/_overflow.scss +0 -5
- package/assets/scss/bootstrap-4.6.2/utilities/_position.scss +0 -32
- package/assets/scss/bootstrap-4.6.2/utilities/_screenreaders.scss +0 -11
- package/assets/scss/bootstrap-4.6.2/utilities/_shadows.scss +0 -6
- package/assets/scss/bootstrap-4.6.2/utilities/_sizing.scss +0 -20
- package/assets/scss/bootstrap-4.6.2/utilities/_spacing.scss +0 -73
- package/assets/scss/bootstrap-4.6.2/utilities/_stretched-link.scss +0 -19
- package/assets/scss/bootstrap-4.6.2/utilities/_text.scss +0 -72
- package/assets/scss/bootstrap-4.6.2/utilities/_visibility.scss +0 -13
- package/assets/scss/bootstrap-4.6.2/vendor/_rfs.scss +0 -228
- package/assets/scss/core/bootstrap.scss +0 -13
- package/components/table/index.d.ts.map +0 -1
- package/components/table/sd-angular-core-components-table.d.ts.map +0 -1
- package/components/table/src/components/column-title/column-title.component.d.ts.map +0 -1
- package/components/table/src/components/command/desktop-command.component.d.ts.map +0 -1
- package/components/table/src/components/command/pipes/command.pipe.d.ts.map +0 -1
- package/components/table/src/components/command/pipes/filter.pipe.d.ts.map +0 -1
- package/components/table/src/components/config/config.component.d.ts.map +0 -1
- package/components/table/src/components/desktop-cell/desktop-cell.component.d.ts.map +0 -1
- package/components/table/src/components/desktop-cell/view/view.component.d.ts.map +0 -1
- package/components/table/src/components/filter/column-filter/column-filter.component.d.ts.map +0 -1
- package/components/table/src/components/filter/external-filter/external-filter.component.d.ts.map +0 -1
- package/components/table/src/components/filter/index.d.ts.map +0 -1
- package/components/table/src/components/filter/mobile-filter/mobile-filter.component.d.ts.map +0 -1
- package/components/table/src/components/index.d.ts.map +0 -1
- package/components/table/src/components/popup-export/popup-export.component.d.ts.map +0 -1
- package/components/table/src/components/selector-action/action-filter.pipe.d.ts.map +0 -1
- package/components/table/src/components/selector-action/selector-action.component.d.ts.map +0 -1
- package/components/table/src/configurations/index.d.ts.map +0 -1
- package/components/table/src/configurations/table.configuration.d.ts.map +0 -1
- package/components/table/src/directives/index.d.ts.map +0 -1
- package/components/table/src/directives/sd-column-resize.directive.d.ts.map +0 -1
- package/components/table/src/directives/sd-table-cell-def.directive.d.ts.map +0 -1
- package/components/table/src/directives/sd-table-column-filter-def.directive.d.ts.map +0 -1
- package/components/table/src/directives/sd-table-expand-def.directive.d.ts.map +0 -1
- package/components/table/src/directives/sd-table-filter-def.directive.d.ts.map +0 -1
- package/components/table/src/directives/sd-table-footer-def.directive.d.ts.map +0 -1
- package/components/table/src/directives/sd-table-title-def.directive.d.ts.map +0 -1
- package/components/table/src/directives/sticky-shadow.directive.d.ts.map +0 -1
- package/components/table/src/models/index.d.ts.map +0 -1
- package/components/table/src/models/table-column.model.d.ts.map +0 -1
- package/components/table/src/models/table-command.model.d.ts.map +0 -1
- package/components/table/src/models/table-item.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-config.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-expand.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-export.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-group.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-paginate.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-reload.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-selector.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-sort.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-style.model.d.ts.map +0 -1
- package/components/table/src/models/table-option-tree.model.d.ts.map +0 -1
- package/components/table/src/models/table-option.model.d.ts.map +0 -1
- package/components/table/src/pipes/filter-values.pipe.d.ts.map +0 -1
- package/components/table/src/pipes/index.d.ts.map +0 -1
- package/components/table/src/pipes/sd-group.pipe.d.ts.map +0 -1
- package/components/table/src/pipes/sd-tree.pipe.d.ts.map +0 -1
- package/components/table/src/pipes/selection-disabled.pipe.d.ts.map +0 -1
- package/components/table/src/pipes/selection-visible-select-all.pipe.d.ts.map +0 -1
- package/components/table/src/pipes/selection-visible.pipe.d.ts.map +0 -1
- package/components/table/src/services/column-width.util.d.ts.map +0 -1
- package/components/table/src/services/config.service.d.ts.map +0 -1
- package/components/table/src/services/index.d.ts.map +0 -1
- package/components/table/src/services/table-export/table-export.service.d.ts.map +0 -1
- package/components/table/src/services/table-filter/table-filter.model.d.ts.map +0 -1
- package/components/table/src/services/table-filter/table-filter.service.d.ts.map +0 -1
- package/components/table/src/services/table-format/table-format.service.d.ts.map +0 -1
- package/components/table/src/services/tree/tree.util.d.ts.map +0 -1
- package/components/table/src/table.component.d.ts.map +0 -1
- package/sd-angular-core-19.0.0-beta.99.tgz +0 -0
package/assets/scss/README.md
CHANGED
|
@@ -1,29 +1,33 @@
|
|
|
1
|
-
#
|
|
1
|
+
# `@sd-angular/core` — Assets & SCSS Reference
|
|
2
|
+
|
|
3
|
+
> **Mục đích tài liệu này (cho người + AI agent):** liệt kê chính xác mọi utility class, design token, font, image, theme mixin mà `@sd-angular/core` ship trong `assets/`. AI agent chỉ được sinh template dùng class **nằm trong danh sách dưới đây** — nếu cần class mới, phải tạo trong `core/utilities/*.scss` trước.
|
|
4
|
+
|
|
5
|
+
---
|
|
2
6
|
|
|
3
7
|
## Mục lục
|
|
4
8
|
|
|
5
9
|
1. [Cài đặt vào Angular](#1-cài-đặt-vào-angular)
|
|
6
|
-
2. [
|
|
7
|
-
3. [
|
|
8
|
-
4. [
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
10
|
+
2. [Cấu trúc thư mục `assets/`](#2-cấu-trúc-thư-mục-assets)
|
|
11
|
+
3. [Hệ thống màu sắc](#3-hệ-thống-màu-sắc) — `--sd-*` tokens + `.text-*` / `.bg-*` / `.border-*`
|
|
12
|
+
4. [Typography tokens](#4-typography-tokens) — `T{size}{weight}` + `fs-*` + `font-weight-*`
|
|
13
|
+
5. [Layout & Grid](#5-layout--grid) — `row` / `col-*` / `grid-container` / `grid-cols-*`
|
|
14
|
+
6. [Flexbox utilities](#6-flexbox-utilities) — `d-flex` + `flex-*` + `align-*` + `justify-*`
|
|
15
|
+
7. [Spacing](#7-spacing) — `m-*` / `p-*` / `gap-*`
|
|
16
|
+
8. [Sizing](#8-sizing) — `w-*` / `h-*` / `min-*` / `max-*`
|
|
17
|
+
9. [Border & radius](#9-border--radius) — `border` / `border-{side}` / `rounded-*`
|
|
18
|
+
10. [Display, position, overflow, visibility](#10-display-position-overflow-visibility)
|
|
19
|
+
11. [Cursor, vertical-align, misc](#11-cursor-vertical-align-misc)
|
|
20
|
+
12. [Elevation (mat-elevation-z0–z8)](#12-elevation-mat-elevation-z0z8)
|
|
21
|
+
13. [Reset / Reboot baseline](#13-reset--reboot-baseline)
|
|
22
|
+
14. [Custom theme](#14-custom-theme)
|
|
23
|
+
15. [Fonts & Images shipped](#15-fonts--images-shipped)
|
|
24
|
+
16. [What is NOT shipped](#16-what-is-not-shipped) — anti-confusion cho AI
|
|
21
25
|
|
|
22
26
|
---
|
|
23
27
|
|
|
24
28
|
## 1. Cài đặt vào Angular
|
|
25
29
|
|
|
26
|
-
|
|
30
|
+
`angular.json`:
|
|
27
31
|
|
|
28
32
|
```json
|
|
29
33
|
"styles": [
|
|
@@ -32,45 +36,114 @@ Thêm vào `angular.json` (trong phần `styles` của build target):
|
|
|
32
36
|
]
|
|
33
37
|
```
|
|
34
38
|
|
|
35
|
-
`sd-core.scss`
|
|
39
|
+
`sd-core.scss` là entry point duy nhất — auto-load reset, utilities, color theme, form overrides, scrollbar, Angular Material theme. Không cần import partial nào riêng lẻ.
|
|
40
|
+
|
|
41
|
+
> Convention chung: **mọi utility class đều có `!important`** để đảm bảo override được Angular Material (thường có specificity cao).
|
|
36
42
|
|
|
37
43
|
---
|
|
38
44
|
|
|
39
|
-
## 2.
|
|
45
|
+
## 2. Cấu trúc thư mục `assets/`
|
|
46
|
+
|
|
47
|
+
```
|
|
48
|
+
projects/sd-angular/assets/
|
|
49
|
+
├── fonts/
|
|
50
|
+
│ ├── fonts.scss # @font-face khai báo cho Roboto + Material Icons + Material Symbols
|
|
51
|
+
│ ├── material-icons/ # 2 file .woff2 (icons-v145 + outlined-v110)
|
|
52
|
+
│ ├── material-symbols/ # 1 file .woff2 (symbols-v29)
|
|
53
|
+
│ └── roboto/ # 4 file .woff2 (regular, italic, 500, 600 — latin + vietnamese)
|
|
54
|
+
├── images/ # SVG illustrations (18 file — empty-state, error, success...)
|
|
55
|
+
│ ├── coming-soon.svg # Trang chưa sẵn sàng
|
|
56
|
+
│ ├── data-empty.svg # Empty state cho table/list
|
|
57
|
+
│ ├── expired.svg # Session expired
|
|
58
|
+
│ ├── file-error.svg # Upload file lỗi
|
|
59
|
+
│ ├── filter-empty.svg # Không match filter
|
|
60
|
+
│ ├── filter-required.svg # Yêu cầu bộ lọc trước khi load
|
|
61
|
+
│ ├── forbidden.svg # 403
|
|
62
|
+
│ ├── image-error.svg # Image load fail
|
|
63
|
+
│ ├── maintenance.svg # Trang đang bảo trì
|
|
64
|
+
│ ├── not-found.svg # 404
|
|
65
|
+
│ ├── offline.svg # Mất mạng
|
|
66
|
+
│ ├── submitted.svg # Gửi form thành công
|
|
67
|
+
│ ├── success.svg # Generic success
|
|
68
|
+
│ ├── unauthorized.svg # 401
|
|
69
|
+
│ └── unknown-error.svg # 500 / fallback
|
|
70
|
+
└── scss/
|
|
71
|
+
├── sd-core.scss # ENTRY (chỉ file này được import từ host app)
|
|
72
|
+
├── ckeditor5.scss # Override style cho CKEditor 5 (opt-in)
|
|
73
|
+
├── core/
|
|
74
|
+
│ ├── color.scss # Color map + CSS var declarations
|
|
75
|
+
│ ├── form.scss # Override Angular Material form (input/select/checkbox/radio)
|
|
76
|
+
│ ├── image.scss # Tiện ích background-image cho 18 illustration SVG ở trên
|
|
77
|
+
│ ├── scrollbar.scss # Custom scrollbar (webkit + firefox)
|
|
78
|
+
│ └── utilities/
|
|
79
|
+
│ ├── _index.scss # Forward toàn bộ partial bên dưới
|
|
80
|
+
│ ├── _base.scss # Reset/reboot baseline (box-sizing, body, headings, forms…)
|
|
81
|
+
│ ├── _border.scss # rounded-* + border + border-{side}
|
|
82
|
+
│ ├── _display.scss # d-none/block/inline/inline-block/flex/inline-flex/grid
|
|
83
|
+
│ ├── _elevation.scss # mat-elevation-z0–z8
|
|
84
|
+
│ ├── _flexbox.scss # flex-1/none/auto, direction, wrap, grow/shrink, align/justify
|
|
85
|
+
│ ├── _gap.scss # gap-* / gap-x-* / gap-y-*
|
|
86
|
+
│ ├── _grid.scss # row/col 12-column + .grid-container + col-span-*
|
|
87
|
+
│ ├── _misc.scss # align-{middle…}, cursor-*, visible/invisible
|
|
88
|
+
│ ├── _overflow.scss # overflow-*
|
|
89
|
+
│ ├── _position.scss # position-relative/absolute/fixed/sticky/static
|
|
90
|
+
│ ├── _sizing.scss # w-* / h-* + min/max + w-full/screen/auto/fit
|
|
91
|
+
│ ├── _spacing.scss # m-*, p-* (mt/mr/mb/ml/mx/my, pt/pr/pb/pl/px/py) + m-auto
|
|
92
|
+
│ └── _typography.scss # T{n}{M|R} tokens + fs-* + font-weight-* + text-*
|
|
93
|
+
└── themes/
|
|
94
|
+
├── default.scss # sd.theme() mixin — override `--sd-*` color tokens
|
|
95
|
+
└── material-theme.scss # Angular Material M2 theme baseline
|
|
96
|
+
```
|
|
40
97
|
|
|
41
|
-
|
|
98
|
+
---
|
|
42
99
|
|
|
43
|
-
|
|
100
|
+
## 3. Hệ thống màu sắc
|
|
44
101
|
|
|
45
|
-
|
|
102
|
+
Màu được định nghĩa dưới dạng **CSS custom properties** với prefix `--sd-*`, cho phép override runtime (không cần recompile SCSS).
|
|
103
|
+
|
|
104
|
+
### 3.1 Color tokens
|
|
105
|
+
|
|
106
|
+
| Token | CSS variable | Default | Dùng cho |
|
|
46
107
|
|---|---|---|---|
|
|
47
|
-
| `primary`
|
|
48
|
-
| `primary-light`
|
|
49
|
-
| `primary-dark`
|
|
50
|
-
| `info`
|
|
51
|
-
| `info-light`
|
|
52
|
-
| `info-dark`
|
|
53
|
-
| `success`
|
|
54
|
-
| `success-light`
|
|
55
|
-
| `success-dark`
|
|
56
|
-
| `warning`
|
|
57
|
-
| `warning-light`
|
|
58
|
-
| `warning-dark`
|
|
59
|
-
| `error`
|
|
60
|
-
| `error-light`
|
|
61
|
-
| `error-dark`
|
|
62
|
-
| `secondary`
|
|
63
|
-
| `secondary-light`
|
|
64
|
-
| `secondary-dark`
|
|
65
|
-
| `light`
|
|
66
|
-
| `dark`
|
|
67
|
-
| `black500`
|
|
68
|
-
| `black400`
|
|
69
|
-
| `black300`
|
|
70
|
-
| `black200`
|
|
71
|
-
| `black100`
|
|
72
|
-
|
|
73
|
-
###
|
|
108
|
+
| `primary` | `--sd-primary` | `#2A66F4` | Màu chủ đạo — button, checkbox, accent |
|
|
109
|
+
| `primary-light` | `--sd-primary-light` | `#EAF1FF` | Background nhẹ của primary |
|
|
110
|
+
| `primary-dark` | `--sd-primary-dark` | `#1C4AD9` | Hover/active state của primary |
|
|
111
|
+
| `info` | `--sd-info` | `#2962FF` | Link, thông tin, badge info |
|
|
112
|
+
| `info-light` | `--sd-info-light` | `#E7E9FF` | Background nhẹ của info |
|
|
113
|
+
| `info-dark` | `--sd-info-dark` | `#2240CC` | Hover state của info |
|
|
114
|
+
| `success` | `--sd-success` | `#4CAF50` | Trạng thái thành công, validation OK |
|
|
115
|
+
| `success-light` | `--sd-success-light` | `#DBEFDC` | Background nhẹ của success |
|
|
116
|
+
| `success-dark` | `--sd-success-dark` | `#39833C` | Hover state của success |
|
|
117
|
+
| `warning` | `--sd-warning` | `#FF9600` | Cảnh báo, trạng thái cần chú ý |
|
|
118
|
+
| `warning-light` | `--sd-warning-light` | `#FFEACC` | Background nhẹ của warning |
|
|
119
|
+
| `warning-dark` | `--sd-warning-dark` | `#BF7000` | Hover state của warning |
|
|
120
|
+
| `error` | `--sd-error` | `#F82C13` | Lỗi, validation fail, trạng thái nguy hiểm |
|
|
121
|
+
| `error-light` | `--sd-error-light` | `#FED5D0` | Background nhẹ của error |
|
|
122
|
+
| `error-dark` | `--sd-error-dark` | `#BA200E` | Hover state của error |
|
|
123
|
+
| `secondary` | `--sd-secondary` | `#212121` | Text phụ, icon secondary |
|
|
124
|
+
| `secondary-light` | `--sd-secondary-light` | `#E9E9E9` | Background nhẹ |
|
|
125
|
+
| `secondary-dark` | `--sd-secondary-dark` | `#000000` | — |
|
|
126
|
+
| `light` | `--sd-light` | `#F8F9FA` | Background trang, surface nhẹ |
|
|
127
|
+
| `dark` | `--sd-dark` | `#343A40` | Text đậm, dark surface |
|
|
128
|
+
| `black500` | `--sd-black500` | `#212121` | Text chính |
|
|
129
|
+
| `black400` | `--sd-black400` | `#757575` | Text phụ, placeholder |
|
|
130
|
+
| `black300` | `--sd-black300` | `#BFBFBF` | Divider, border nhẹ |
|
|
131
|
+
| `black200` | `--sd-black200` | `#E6E6E6` | Border mặc định, separator |
|
|
132
|
+
| `black100` | `--sd-black100` | `#F2F2F2` | Background disabled, row hover |
|
|
133
|
+
|
|
134
|
+
### 3.2 Color utility classes
|
|
135
|
+
|
|
136
|
+
Mọi token ở §3.1 đều sinh 3 class:
|
|
137
|
+
|
|
138
|
+
| Pattern | Ví dụ |
|
|
139
|
+
|---|---|
|
|
140
|
+
| `.text-{token}` | `text-primary`, `text-error`, `text-black400` |
|
|
141
|
+
| `.bg-{token}` | `bg-primary-light`, `bg-error-light`, `bg-white` |
|
|
142
|
+
| `.border-{token}` | `border-primary`, `border-black200` |
|
|
143
|
+
|
|
144
|
+
`white` / `black` luôn có sẵn ngoài bảng trên: `.text-white` / `.text-black` / `.bg-white` / `.bg-black`.
|
|
145
|
+
|
|
146
|
+
### 3.3 Dùng màu trong component SCSS
|
|
74
147
|
|
|
75
148
|
```scss
|
|
76
149
|
@use '@sd-angular/core/assets/scss/core/color.scss' as color;
|
|
@@ -83,194 +156,74 @@ Màu được định nghĩa dưới dạng **CSS custom properties** có tiền
|
|
|
83
156
|
}
|
|
84
157
|
```
|
|
85
158
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
```html
|
|
89
|
-
<!-- Text color -->
|
|
90
|
-
<span class="text-primary">Primary</span>
|
|
91
|
-
<span class="text-error">Lỗi</span>
|
|
92
|
-
<span class="text-secondary">Phụ</span>
|
|
93
|
-
<span class="text-success">Thành công</span>
|
|
94
|
-
<span class="text-warning">Cảnh báo</span>
|
|
95
|
-
|
|
96
|
-
<!-- Background color -->
|
|
97
|
-
<div class="bg-primary-light">...</div>
|
|
98
|
-
<div class="bg-error-light">...</div>
|
|
99
|
-
<div class="bg-white">...</div>
|
|
100
|
-
|
|
101
|
-
<!-- Border color -->
|
|
102
|
-
<div class="border-primary">...</div>
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
Tất cả token đều có class: `.text-{token}`, `.bg-{token}`, `.border-{token}`.
|
|
106
|
-
|
|
107
|
-
---
|
|
108
|
-
|
|
109
|
-
## 3. Custom theme
|
|
110
|
-
|
|
111
|
-
Trong `styles.scss` của ứng dụng, import theme mixin và Angular Material, sau đó gọi `sd.theme()` với các màu muốn override.
|
|
112
|
-
|
|
113
|
-
Chỉ cần khai báo các màu muốn **thay đổi** — màu không khai báo sẽ dùng giá trị mặc định.
|
|
159
|
+
Hoặc đọc trực tiếp CSS var (recommended cho runtime override):
|
|
114
160
|
|
|
115
161
|
```scss
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
html {
|
|
121
|
-
@include sd.theme(
|
|
122
|
-
(
|
|
123
|
-
primary: #AE7129,
|
|
124
|
-
primary-light: #F4F2F1,
|
|
125
|
-
primary-dark: #6B4414,
|
|
126
|
-
)
|
|
127
|
-
);
|
|
162
|
+
.my-element {
|
|
163
|
+
color: var(--sd-primary);
|
|
164
|
+
background: var(--sd-primary-light);
|
|
128
165
|
}
|
|
129
|
-
|
|
130
|
-
// --- Angular Material M2 Palette ---
|
|
131
|
-
|
|
132
|
-
$custom-primary-palette: mat.m2-define-palette((
|
|
133
|
-
50: #F4F2F1,
|
|
134
|
-
100: #E7E1DA,
|
|
135
|
-
200: #DAC8B4,
|
|
136
|
-
300: #D1AC80,
|
|
137
|
-
400: #CD9450,
|
|
138
|
-
500: #AE7129,
|
|
139
|
-
600: #8D5A1E,
|
|
140
|
-
700: #6B4414,
|
|
141
|
-
800: #4B2F0E,
|
|
142
|
-
900: #34210A,
|
|
143
|
-
contrast: (
|
|
144
|
-
600: white,
|
|
145
|
-
700: white,
|
|
146
|
-
800: white,
|
|
147
|
-
900: white,
|
|
148
|
-
)
|
|
149
|
-
));
|
|
150
|
-
|
|
151
|
-
$custom-accent-palette: mat.m2-define-palette((
|
|
152
|
-
50: #F1F3F1,
|
|
153
|
-
100: #DCE5DD,
|
|
154
|
-
200: #BBD3BC,
|
|
155
|
-
300: #8FC291,
|
|
156
|
-
400: #67B76A,
|
|
157
|
-
500: #4CAF50,
|
|
158
|
-
600: #3A8C3D,
|
|
159
|
-
700: #29692C,
|
|
160
|
-
800: #1C471E,
|
|
161
|
-
900: #132F14,
|
|
162
|
-
contrast: (
|
|
163
|
-
700: white,
|
|
164
|
-
800: white,
|
|
165
|
-
900: white,
|
|
166
|
-
)
|
|
167
|
-
));
|
|
168
|
-
|
|
169
|
-
$custom-warn-palette: mat.m2-define-palette((
|
|
170
|
-
50: #F5F0F0,
|
|
171
|
-
100: #EAD9D6,
|
|
172
|
-
200: #E4B0AA,
|
|
173
|
-
300: #E6786B,
|
|
174
|
-
400: #EE4430,
|
|
175
|
-
500: #F82C13,
|
|
176
|
-
600: #D11801,
|
|
177
|
-
700: #9A1100,
|
|
178
|
-
800: #680B00,
|
|
179
|
-
900: #440700,
|
|
180
|
-
contrast: (
|
|
181
|
-
600: white,
|
|
182
|
-
700: white,
|
|
183
|
-
800: white,
|
|
184
|
-
900: white,
|
|
185
|
-
)
|
|
186
|
-
));
|
|
187
|
-
|
|
188
|
-
$custom-theme: mat.m2-define-light-theme((
|
|
189
|
-
color: (
|
|
190
|
-
primary: $custom-primary-palette,
|
|
191
|
-
accent: $custom-accent-palette,
|
|
192
|
-
warn: $custom-warn-palette,
|
|
193
|
-
),
|
|
194
|
-
density: -3,
|
|
195
|
-
));
|
|
196
|
-
|
|
197
|
-
@include mat.all-component-themes($custom-theme);
|
|
198
166
|
```
|
|
199
167
|
|
|
200
|
-
> **Lưu ý:** `sd.theme()` và `mat.all-component-themes()` đều cần được gọi trong `styles.scss`, không phải trong component SCSS.
|
|
201
|
-
|
|
202
168
|
---
|
|
203
169
|
|
|
204
|
-
## 4.
|
|
170
|
+
## 4. Typography tokens
|
|
205
171
|
|
|
206
|
-
|
|
172
|
+
### 4.1 Design token classes — `T{size}{weight}`
|
|
207
173
|
|
|
208
|
-
|
|
174
|
+
Quy ước: `M` = Medium (500), `R` = Regular (400). Mỗi class gồm `font-size` + `font-weight` + `line-height` chuẩn hóa.
|
|
209
175
|
|
|
210
|
-
|
|
176
|
+
| Class | Font size | Weight | Line height |
|
|
177
|
+
|---|---|---|---|
|
|
178
|
+
| `T48M` / `T48R` | 48px | 500 / 400 | 56px |
|
|
179
|
+
| `T32M` / `T32R` | 32px | 500 / 400 | 48px |
|
|
180
|
+
| `T24M` / `T24R` | 24px / 20px* | 500 / 400 | 28px |
|
|
181
|
+
| `T20M` / `T20R` | 20px | 500 / 400 | 28px |
|
|
182
|
+
| `T18M` / `T18R` | 18px | 500 / 400 | 28px |
|
|
183
|
+
| `T16M` / `T16R` | 16px | 500 / 400 | 24px |
|
|
184
|
+
| `T14M` / `T14R` | 14px | 500 / 400 | 20px |
|
|
185
|
+
| `T12M` / `T12R`† | 12px | 500 / 400 | 16px |
|
|
186
|
+
| `T10M` / `T10R` | 10px | 500 / 400 | 12px |
|
|
211
187
|
|
|
212
|
-
|
|
188
|
+
\* `T24R` font-size 20px (quirk lịch sử — `T24M` là 24px). Khi cần 24px/400, dùng `T20R` 20px hoặc cặp `fs-24 + font-weight-normal`.
|
|
189
|
+
† `T12R` dùng `!important` vì hay bị Angular Material override.
|
|
213
190
|
|
|
214
|
-
|
|
215
|
-
m-{n} mt-{n} mr-{n} mb-{n} ml-{n} mx-{n} my-{n}
|
|
216
|
-
p-{n} pt-{n} pr-{n} pb-{n} pl-{n} px-{n} py-{n}
|
|
217
|
-
```
|
|
191
|
+
### 4.2 Font-size utilities (px-based)
|
|
218
192
|
|
|
219
|
-
Ví dụ: `m-0`, `mt-8`, `px-16`, `py-24`, `mb-4`
|
|
220
|
-
|
|
221
|
-
**Auto margin:**
|
|
222
193
|
```
|
|
223
|
-
|
|
194
|
+
fs-0 fs-1 … fs-200
|
|
224
195
|
```
|
|
225
196
|
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
### Sizing — Width & Height
|
|
197
|
+
Dùng khi cần override nhanh, **không thay** design token. Output: `font-size: {n}px !important`.
|
|
229
198
|
|
|
230
|
-
|
|
199
|
+
### 4.3 Font-weight
|
|
231
200
|
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
| Class | CSS |
|
|
201
|
+
| Class | weight |
|
|
235
202
|
|---|---|
|
|
236
|
-
| `
|
|
237
|
-
| `
|
|
238
|
-
| `
|
|
239
|
-
| `
|
|
240
|
-
| `
|
|
241
|
-
| `h-full` | `height: 100%` |
|
|
242
|
-
| `h-100` | `height: 100%` (alias) |
|
|
243
|
-
| `h-auto` | `height: auto` |
|
|
244
|
-
| `h-screen` | `height: 100vh` |
|
|
245
|
-
| `h-fit` | `height: fit-content` |
|
|
246
|
-
| `min-h-full` | `min-height: 100%` |
|
|
247
|
-
| `min-h-screen` | `min-height: 100vh` |
|
|
248
|
-
| `min-w-full` | `min-width: 100%` |
|
|
249
|
-
| `max-h-full` | `max-height: 100%` |
|
|
250
|
-
| `max-w-full` | `max-width: 100%` |
|
|
251
|
-
|
|
252
|
-
---
|
|
253
|
-
|
|
254
|
-
### Border
|
|
203
|
+
| `font-weight-light` | 300 |
|
|
204
|
+
| `font-weight-normal` | 400 |
|
|
205
|
+
| `font-weight-medium` | 500 |
|
|
206
|
+
| `font-weight-bold` | 600 |
|
|
207
|
+
| `font-weight-bolder` | 700 |
|
|
255
208
|
|
|
256
|
-
|
|
209
|
+
### 4.4 Text alignment / wrap / transform
|
|
257
210
|
|
|
258
|
-
|
|
211
|
+
```
|
|
212
|
+
text-left text-center text-right text-justify
|
|
213
|
+
text-wrap text-nowrap text-ellipsis text-break
|
|
214
|
+
text-uppercase text-lowercase text-capitalize
|
|
215
|
+
```
|
|
259
216
|
|
|
260
|
-
| Class
|
|
217
|
+
| Class | Output |
|
|
261
218
|
|---|---|
|
|
262
|
-
| `
|
|
263
|
-
| `
|
|
264
|
-
| `border-top` | `border-top: 1px solid var(--sd-black200)` |
|
|
265
|
-
| `border-bottom` | `border-bottom: 1px solid var(--sd-black200)` |
|
|
266
|
-
| `border-left` | `border-left: 1px solid var(--sd-black200)` |
|
|
267
|
-
| `border-right` | `border-right: 1px solid var(--sd-black200)` |
|
|
219
|
+
| `text-ellipsis` | `white-space: nowrap; overflow: hidden; text-overflow: ellipsis` (yêu cầu container có width cố định) |
|
|
220
|
+
| `text-break` | `overflow-wrap: break-word; word-break: break-word` (xuống dòng giữa ký tự — URL, hash, mã dài) |
|
|
268
221
|
|
|
269
222
|
---
|
|
270
223
|
|
|
271
|
-
|
|
224
|
+
## 5. Layout & Grid
|
|
272
225
|
|
|
273
|
-
|
|
226
|
+
### 5.1 Flexbox row/col 12-column
|
|
274
227
|
|
|
275
228
|
```html
|
|
276
229
|
<div class="row">
|
|
@@ -279,35 +232,36 @@ m-auto mt-auto mr-auto mb-auto ml-auto mx-auto my-auto
|
|
|
279
232
|
</div>
|
|
280
233
|
```
|
|
281
234
|
|
|
282
|
-
`.row` là flex container có gutter `16px
|
|
235
|
+
`.row` là flex container có gutter `16px` (margin âm trừ gutter + padding nửa gutter trên `> *`).
|
|
283
236
|
|
|
284
237
|
**Gutter variants:**
|
|
285
238
|
|
|
286
|
-
| Class
|
|
239
|
+
| Class | Gutter |
|
|
287
240
|
|---|---|
|
|
288
|
-
| `row`
|
|
241
|
+
| `row` | 16px (mặc định) |
|
|
289
242
|
| `row-md` | 8px |
|
|
290
243
|
| `row-sm` | 4px |
|
|
291
244
|
| `row-xs` | 2px |
|
|
292
245
|
|
|
293
|
-
**
|
|
246
|
+
**Auto-width column:** `.col` (chiếm phần còn lại, `flex: 1 1 0%`).
|
|
247
|
+
|
|
248
|
+
**Responsive columns** (mobile-first — class chỉ kích hoạt khi viewport ≥ breakpoint):
|
|
294
249
|
|
|
295
|
-
|
|
|
250
|
+
| Pattern | Min-width |
|
|
296
251
|
|---|---|
|
|
297
|
-
| `col-sm-{1-12}` | ≥ 576px |
|
|
298
|
-
| `col-md-{1-12}` | ≥ 768px |
|
|
299
|
-
| `col-lg-{1-12}` | ≥ 992px |
|
|
300
|
-
| `col-xl-{1-12}` | ≥ 1200px |
|
|
252
|
+
| `col-sm-{1-12}` / `col-sm` | ≥ 576px |
|
|
253
|
+
| `col-md-{1-12}` / `col-md` | ≥ 768px |
|
|
254
|
+
| `col-lg-{1-12}` / `col-lg` | ≥ 992px |
|
|
255
|
+
| `col-xl-{1-12}` / `col-xl` | ≥ 1200px |
|
|
301
256
|
|
|
302
|
-
Ví dụ:
|
|
303
257
|
```html
|
|
304
258
|
<div class="row">
|
|
305
|
-
<!--
|
|
259
|
+
<!-- 100% trên mobile, 50% từ md+, 33% từ lg+ -->
|
|
306
260
|
<div class="col-md-6 col-lg-4">...</div>
|
|
307
261
|
</div>
|
|
308
262
|
```
|
|
309
263
|
|
|
310
|
-
|
|
264
|
+
### 5.2 CSS Grid container
|
|
311
265
|
|
|
312
266
|
```html
|
|
313
267
|
<div class="grid-container grid-cols-3">
|
|
@@ -317,208 +271,334 @@ Ví dụ:
|
|
|
317
271
|
</div>
|
|
318
272
|
```
|
|
319
273
|
|
|
320
|
-
| Class
|
|
274
|
+
| Class | Mô tả |
|
|
321
275
|
|---|---|
|
|
322
|
-
| `grid-container`
|
|
323
|
-
| `grid-cols-{1-12}`
|
|
324
|
-
| `col-span-{1-12}`
|
|
325
|
-
| `col-span-full`
|
|
326
|
-
| `row-span-{1-12}`
|
|
327
|
-
| `row-span-full`
|
|
276
|
+
| `grid-container` | `display: grid`, `column-gap: 8px`, `row-gap: 0` |
|
|
277
|
+
| `grid-cols-{1-12}` | Số cột |
|
|
278
|
+
| `col-span-{1-12}` | Item chiếm n cột |
|
|
279
|
+
| `col-span-full` | Item chiếm toàn bộ chiều ngang |
|
|
280
|
+
| `row-span-{1-12}` | Item chiếm n hàng |
|
|
281
|
+
| `row-span-full` | Item chiếm toàn bộ chiều dọc |
|
|
328
282
|
|
|
329
|
-
|
|
283
|
+
> Các class `col-span-*` / `row-span-*` chỉ có hiệu lực **bên trong** `.grid-container` (selector nested).
|
|
330
284
|
|
|
331
|
-
|
|
285
|
+
---
|
|
332
286
|
|
|
333
|
-
|
|
287
|
+
## 6. Flexbox utilities
|
|
334
288
|
|
|
335
|
-
| Class
|
|
289
|
+
| Class | CSS |
|
|
336
290
|
|---|---|
|
|
337
|
-
| `flex-1`
|
|
338
|
-
| `flex-none`
|
|
339
|
-
| `flex-auto`
|
|
291
|
+
| `flex-1` | `flex: 1` |
|
|
292
|
+
| `flex-none` | `flex: none` |
|
|
293
|
+
| `flex-auto` | `flex: auto` |
|
|
294
|
+
| `flex-row` | `flex-direction: row` |
|
|
295
|
+
| `flex-column` | `flex-direction: column` |
|
|
296
|
+
| `flex-row-reverse` | `flex-direction: row-reverse` |
|
|
297
|
+
| `flex-column-reverse` | `flex-direction: column-reverse` |
|
|
298
|
+
| `flex-wrap` | `flex-wrap: wrap` |
|
|
299
|
+
| `flex-nowrap` | `flex-wrap: nowrap` |
|
|
300
|
+
| `flex-grow-0` / `flex-grow-1` | `flex-grow: 0 / 1` |
|
|
301
|
+
| `flex-shrink-0` / `flex-shrink-1` | `flex-shrink: 0 / 1` |
|
|
340
302
|
|
|
341
|
-
**
|
|
342
|
-
```
|
|
343
|
-
flex-row flex-column flex-row-reverse flex-column-reverse
|
|
344
|
-
```
|
|
303
|
+
**align-items:** `align-items-start`, `align-items-end`, `align-items-center`, `align-items-baseline`, `align-items-stretch`.
|
|
345
304
|
|
|
346
|
-
**
|
|
347
|
-
```
|
|
348
|
-
flex-wrap flex-nowrap
|
|
349
|
-
```
|
|
305
|
+
**align-self:** `align-self-start`, `align-self-end`, `align-self-center`, `align-self-stretch`, `align-self-auto`.
|
|
350
306
|
|
|
351
|
-
**
|
|
352
|
-
```
|
|
353
|
-
flex-grow-0 flex-grow-1 flex-shrink-0 flex-shrink-1
|
|
354
|
-
```
|
|
307
|
+
**align-content:** `align-content-start`, `align-content-end`, `align-content-center`, `align-content-between`, `align-content-around`, `align-content-stretch`.
|
|
355
308
|
|
|
356
|
-
**
|
|
357
|
-
```
|
|
358
|
-
align-items-start align-items-end align-items-center
|
|
359
|
-
align-items-baseline align-items-stretch
|
|
360
|
-
```
|
|
309
|
+
**justify-content:** `justify-content-start`, `justify-content-end`, `justify-content-center`, `justify-content-between`, `justify-content-around`, `justify-content-evenly`.
|
|
361
310
|
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
311
|
+
---
|
|
312
|
+
|
|
313
|
+
## 7. Spacing
|
|
314
|
+
|
|
315
|
+
### 7.1 Margin / Padding (px-based, 0–200)
|
|
367
316
|
|
|
368
|
-
**Align content:**
|
|
369
317
|
```
|
|
370
|
-
|
|
371
|
-
|
|
318
|
+
m-{n} mt-{n} mr-{n} mb-{n} ml-{n} mx-{n} my-{n}
|
|
319
|
+
p-{n} pt-{n} pr-{n} pb-{n} pl-{n} px-{n} py-{n}
|
|
372
320
|
```
|
|
373
321
|
|
|
374
|
-
|
|
322
|
+
Ví dụ: `m-0`, `mt-8`, `px-16`, `py-24`, `mb-4`.
|
|
323
|
+
|
|
324
|
+
**Auto margin:** `m-auto`, `mt-auto`, `mr-auto`, `mb-auto`, `ml-auto`, `mx-auto`, `my-auto`.
|
|
325
|
+
|
|
326
|
+
### 7.2 Gap (px-based, 0–200)
|
|
327
|
+
|
|
375
328
|
```
|
|
376
|
-
|
|
377
|
-
justify-content-between justify-content-around justify-content-evenly
|
|
329
|
+
gap-{n} gap-x-{n} gap-y-{n}
|
|
378
330
|
```
|
|
379
331
|
|
|
332
|
+
Ví dụ: `gap-8`, `gap-x-16`, `gap-y-4`.
|
|
333
|
+
|
|
380
334
|
---
|
|
381
335
|
|
|
382
|
-
|
|
336
|
+
## 8. Sizing
|
|
383
337
|
|
|
384
|
-
|
|
338
|
+
### 8.1 Width / Height theo px (0–200)
|
|
339
|
+
|
|
340
|
+
```
|
|
341
|
+
w-{n} h-{n}
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
### 8.2 Width / Height theo %/keyword
|
|
345
|
+
|
|
346
|
+
| Class | CSS |
|
|
385
347
|
|---|---|
|
|
386
|
-
| `
|
|
387
|
-
| `
|
|
388
|
-
| `
|
|
389
|
-
| `
|
|
390
|
-
| `
|
|
391
|
-
| `
|
|
392
|
-
| `
|
|
348
|
+
| `w-full` / `w-100` | `width: 100%` (`w-100` là alias của `w-full`) |
|
|
349
|
+
| `w-auto` | `width: auto` |
|
|
350
|
+
| `w-screen` | `width: 100vw` |
|
|
351
|
+
| `w-fit` | `width: fit-content` |
|
|
352
|
+
| `h-full` / `h-100` | `height: 100%` |
|
|
353
|
+
| `h-auto` | `height: auto` |
|
|
354
|
+
| `h-screen` | `height: 100vh` |
|
|
355
|
+
| `h-fit` | `height: fit-content` |
|
|
356
|
+
| `min-h-full` | `min-height: 100%` |
|
|
357
|
+
| `min-h-screen` | `min-height: 100vh` |
|
|
358
|
+
| `min-w-full` | `min-width: 100%` |
|
|
359
|
+
| `max-h-full` | `max-height: 100%` |
|
|
360
|
+
| `max-w-full` | `max-width: 100%` |
|
|
393
361
|
|
|
394
362
|
---
|
|
395
363
|
|
|
396
|
-
|
|
364
|
+
## 9. Border & radius
|
|
365
|
+
|
|
366
|
+
### 9.1 Border-radius (px-based, 0–200)
|
|
367
|
+
|
|
368
|
+
```
|
|
369
|
+
rounded-{n} // border-radius: {n}px
|
|
370
|
+
rounded-full // border-radius: 9999px (pill / circle)
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
### 9.2 Border utilities
|
|
397
374
|
|
|
398
|
-
|
|
375
|
+
Border color default = `var(--sd-black200)`.
|
|
399
376
|
|
|
400
|
-
| Class
|
|
377
|
+
| Class | CSS |
|
|
401
378
|
|---|---|
|
|
402
|
-
| `
|
|
403
|
-
| `
|
|
404
|
-
| `
|
|
379
|
+
| `border` | `border: 1px solid var(--sd-black200)` |
|
|
380
|
+
| `border-0` | `border: 0` |
|
|
381
|
+
| `border-top` | `border-top: 1px solid var(--sd-black200)` |
|
|
382
|
+
| `border-bottom` | `border-bottom: 1px solid var(--sd-black200)` |
|
|
383
|
+
| `border-left` | `border-left: 1px solid var(--sd-black200)` |
|
|
384
|
+
| `border-right` | `border-right: 1px solid var(--sd-black200)` |
|
|
405
385
|
|
|
406
|
-
|
|
386
|
+
Đổi màu border: kết hợp `.border` với `.border-{token}` (xem §3.2).
|
|
407
387
|
|
|
408
388
|
---
|
|
409
389
|
|
|
410
|
-
|
|
390
|
+
## 10. Display, position, overflow, visibility
|
|
411
391
|
|
|
412
|
-
|
|
392
|
+
### 10.1 Display
|
|
413
393
|
|
|
414
|
-
|
|
394
|
+
| Class | CSS |
|
|
395
|
+
|---|---|
|
|
396
|
+
| `d-none` | `display: none` |
|
|
397
|
+
| `d-block` | `display: block` |
|
|
398
|
+
| `d-inline` | `display: inline` |
|
|
399
|
+
| `d-inline-block` | `display: inline-block` |
|
|
400
|
+
| `d-flex` | `display: flex` |
|
|
401
|
+
| `d-inline-flex` | `display: inline-flex` |
|
|
402
|
+
| `d-grid` | `display: grid` |
|
|
415
403
|
|
|
416
|
-
|
|
417
|
-
|---|---|---|---|
|
|
418
|
-
| `T48M` / `T48R` | 48px | 500 / 400 | 56px |
|
|
419
|
-
| `T32M` / `T32R` | 32px | 500 / 400 | 48px |
|
|
420
|
-
| `T24M` / `T24R` | 24px / 20px | 500 / 400 | 28px |
|
|
421
|
-
| `T20M` / `T20R` | 20px | 500 / 400 | 28px |
|
|
422
|
-
| `T18M` / `T18R` | 18px | 500 / 400 | 28px |
|
|
423
|
-
| `T16M` / `T16R` | 16px | 500 / 400 | 24px |
|
|
424
|
-
| `T14M` / `T14R` | 14px | 500 / 400 | 20px |
|
|
425
|
-
| `T12M` / `T12R` | 12px | 500 / 400 | 16px |
|
|
426
|
-
| `T10M` / `T10R` | 10px | 500 / 400 | 12px |
|
|
427
|
-
|
|
428
|
-
#### Font-size utilities (px-based, 0–200)
|
|
404
|
+
### 10.2 Position
|
|
429
405
|
|
|
430
406
|
```
|
|
431
|
-
|
|
407
|
+
position-relative position-absolute position-fixed
|
|
408
|
+
position-sticky position-static
|
|
432
409
|
```
|
|
433
410
|
|
|
434
|
-
|
|
411
|
+
### 10.3 Overflow
|
|
412
|
+
|
|
413
|
+
| Class | CSS |
|
|
414
|
+
|---|---|
|
|
415
|
+
| `overflow-auto` | `overflow: auto` |
|
|
416
|
+
| `overflow-hidden` | `overflow: hidden` |
|
|
417
|
+
| `overflow-visible` | `overflow: visible` |
|
|
418
|
+
| `overflow-scroll` | `overflow: scroll` |
|
|
419
|
+
| `overflow-x-auto` | `overflow-x: auto` |
|
|
420
|
+
| `overflow-y-auto` | `overflow-y: auto` |
|
|
421
|
+
|
|
422
|
+
### 10.4 Visibility
|
|
423
|
+
|
|
424
|
+
| Class | CSS |
|
|
425
|
+
|---|---|
|
|
426
|
+
| `visible` | `visibility: visible` |
|
|
427
|
+
| `invisible` | `visibility: hidden` |
|
|
428
|
+
|
|
429
|
+
---
|
|
430
|
+
|
|
431
|
+
## 11. Cursor, vertical-align, misc
|
|
432
|
+
|
|
433
|
+
**Vertical-align:**
|
|
435
434
|
|
|
436
435
|
```
|
|
437
|
-
|
|
438
|
-
font-weight-normal (400)
|
|
439
|
-
font-weight-medium (500)
|
|
440
|
-
font-weight-bold (600)
|
|
441
|
-
font-weight-bolder (700)
|
|
436
|
+
align-middle align-top align-bottom align-baseline
|
|
442
437
|
```
|
|
443
438
|
|
|
444
|
-
|
|
439
|
+
**Cursor:**
|
|
445
440
|
|
|
446
441
|
```
|
|
447
|
-
|
|
442
|
+
cursor-pointer cursor-default cursor-not-allowed
|
|
448
443
|
```
|
|
449
444
|
|
|
450
|
-
|
|
445
|
+
---
|
|
451
446
|
|
|
452
|
-
|
|
453
|
-
|---|---|
|
|
454
|
-
| `text-wrap` | `white-space: normal` |
|
|
455
|
-
| `text-nowrap` | `white-space: nowrap` |
|
|
456
|
-
| `text-ellipsis` | `overflow: hidden; text-overflow: ellipsis; white-space: nowrap` |
|
|
457
|
-
| `text-break` | `overflow-wrap: break-word; word-break: break-word` |
|
|
447
|
+
## 12. Elevation (`mat-elevation-z0`–`z8`)
|
|
458
448
|
|
|
459
|
-
|
|
449
|
+
CSS shadow tĩnh, tương đương Angular Material `mat.elevation()` mixin nhưng **không cần** import Material SCSS.
|
|
460
450
|
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
451
|
+
| Class | Dùng cho |
|
|
452
|
+
|---|---|
|
|
453
|
+
| `mat-elevation-z0` | Reset shadow |
|
|
454
|
+
| `mat-elevation-z1` | Card, chip |
|
|
455
|
+
| `mat-elevation-z2` | Button raised |
|
|
456
|
+
| `mat-elevation-z3` | Card hover |
|
|
457
|
+
| `mat-elevation-z4` | App bar |
|
|
458
|
+
| `mat-elevation-z5` | — |
|
|
459
|
+
| `mat-elevation-z6` | Floating action button |
|
|
460
|
+
| `mat-elevation-z7` | — |
|
|
461
|
+
| `mat-elevation-z8` | Dialog, drawer |
|
|
464
462
|
|
|
465
463
|
---
|
|
466
464
|
|
|
467
|
-
|
|
465
|
+
## 13. Reset / Reboot baseline
|
|
466
|
+
|
|
467
|
+
`_base.scss` chạy trước mọi utility, thiết lập rendering chuẩn:
|
|
468
468
|
|
|
469
|
-
|
|
|
469
|
+
| Rule | Mục đích |
|
|
470
470
|
|---|---|
|
|
471
|
-
|
|
|
472
|
-
| `
|
|
473
|
-
| `
|
|
474
|
-
| `
|
|
475
|
-
| `
|
|
476
|
-
| `
|
|
471
|
+
| `*, *::before, *::after { box-sizing: border-box }` | Bắt buộc — thiếu là layout lệch |
|
|
472
|
+
| `html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; line-height: 1.15 }` | iOS rotation + ẩn tap highlight |
|
|
473
|
+
| `body { font-family: Roboto, 'Helvetica Neue', Arial, sans-serif; font-size: 14px; line-height: 1.5; color: #212529 }` | Baseline typography |
|
|
474
|
+
| `h1…h6` | `margin-top: 0; margin-bottom: 0.5rem` |
|
|
475
|
+
| `p, ol, ul, dl` | `margin-top: 0; margin-bottom: 1rem` |
|
|
476
|
+
| `a { color: #007bff; text-decoration: none }`, `a:hover { text-decoration: underline }` | Link mặc định |
|
|
477
|
+
| `label { display: inline-block; margin-bottom: 0.5rem }` | Form layout (mat-checkbox override ở `core/form.scss`) |
|
|
478
|
+
| `button { border-radius: 0 }`, `button:focus:not(:focus-visible) { outline: 0 }` | Reset native button |
|
|
479
|
+
| `table { border-collapse: collapse }` | Tránh double border |
|
|
480
|
+
| `th { font-weight: 600; text-align: inherit }` | Bỏ bold native browser |
|
|
481
|
+
| `textarea { overflow: auto; resize: vertical }` | Bỏ scrollbar dọc mặc định IE, chỉ resize chiều dọc |
|
|
482
|
+
| `[role="button"] { cursor: pointer }` | A11y |
|
|
483
|
+
| `[hidden] { display: none !important }` | IE10 fallback |
|
|
477
484
|
|
|
478
485
|
---
|
|
479
486
|
|
|
480
|
-
|
|
487
|
+
## 14. Custom theme
|
|
481
488
|
|
|
489
|
+
Trong `styles.scss` của host app, gọi `sd.theme()` để override màu, sau đó cấu hình Angular Material M2 palette tương ứng:
|
|
490
|
+
|
|
491
|
+
```scss
|
|
492
|
+
@use '@sd-angular/core/assets/scss/themes/default' as sd;
|
|
493
|
+
@use '@angular/material' as mat;
|
|
494
|
+
@include mat.core();
|
|
495
|
+
|
|
496
|
+
html {
|
|
497
|
+
@include sd.theme(
|
|
498
|
+
(
|
|
499
|
+
primary: #AE7129,
|
|
500
|
+
primary-light: #F4F2F1,
|
|
501
|
+
primary-dark: #6B4414,
|
|
502
|
+
)
|
|
503
|
+
);
|
|
504
|
+
}
|
|
505
|
+
|
|
506
|
+
// --- Angular Material M2 palette ---
|
|
507
|
+
|
|
508
|
+
$custom-primary-palette: mat.m2-define-palette((
|
|
509
|
+
50: #F4F2F1, 100: #E7E1DA, 200: #DAC8B4, 300: #D1AC80, 400: #CD9450,
|
|
510
|
+
500: #AE7129, 600: #8D5A1E, 700: #6B4414, 800: #4B2F0E, 900: #34210A,
|
|
511
|
+
contrast: ( 600: white, 700: white, 800: white, 900: white )
|
|
512
|
+
));
|
|
513
|
+
|
|
514
|
+
$custom-accent-palette: mat.m2-define-palette((
|
|
515
|
+
50: #F1F3F1, 100: #DCE5DD, 200: #BBD3BC, 300: #8FC291, 400: #67B76A,
|
|
516
|
+
500: #4CAF50, 600: #3A8C3D, 700: #29692C, 800: #1C471E, 900: #132F14,
|
|
517
|
+
contrast: ( 700: white, 800: white, 900: white )
|
|
518
|
+
));
|
|
519
|
+
|
|
520
|
+
$custom-warn-palette: mat.m2-define-palette((
|
|
521
|
+
50: #F5F0F0, 100: #EAD9D6, 200: #E4B0AA, 300: #E6786B, 400: #EE4430,
|
|
522
|
+
500: #F82C13, 600: #D11801, 700: #9A1100, 800: #680B00, 900: #440700,
|
|
523
|
+
contrast: ( 600: white, 700: white, 800: white, 900: white )
|
|
524
|
+
));
|
|
525
|
+
|
|
526
|
+
$custom-theme: mat.m2-define-light-theme((
|
|
527
|
+
color: ( primary: $custom-primary-palette, accent: $custom-accent-palette, warn: $custom-warn-palette ),
|
|
528
|
+
density: -3,
|
|
529
|
+
));
|
|
530
|
+
|
|
531
|
+
@include mat.all-component-themes($custom-theme);
|
|
482
532
|
```
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
533
|
+
|
|
534
|
+
> `sd.theme()` chỉ cần khai báo những token muốn override — token không khai báo giữ default.
|
|
535
|
+
> Cả `sd.theme()` và `mat.all-component-themes()` **phải** gọi trong `styles.scss`, không phải component SCSS.
|
|
486
536
|
|
|
487
537
|
---
|
|
488
538
|
|
|
489
|
-
|
|
539
|
+
## 15. Fonts & images shipped
|
|
540
|
+
|
|
541
|
+
### 15.1 Fonts
|
|
542
|
+
|
|
543
|
+
`fonts.scss` declare `@font-face` cho 3 family — host app **không cần** thêm Google Fonts link.
|
|
490
544
|
|
|
491
|
-
|
|
545
|
+
| Family | Variants | File path |
|
|
546
|
+
|---|---|---|
|
|
547
|
+
| Roboto | regular (400), 500, 600, italic | `assets/fonts/roboto/roboto-v50-latin_vietnamese-*.woff2` (4 file, latin + vietnamese subset) |
|
|
548
|
+
| Material Icons | regular + outlined | `assets/fonts/material-icons/{material-icons-v145,material-icons-outlined-v110}-latin-regular.woff2` |
|
|
549
|
+
| Material Symbols | regular | `assets/fonts/material-symbols/material-symbols-v29-latin-regular.woff2` |
|
|
492
550
|
|
|
493
|
-
|
|
551
|
+
### 15.2 Image assets (18 SVG illustrations)
|
|
552
|
+
|
|
553
|
+
Tham chiếu qua `core/image.scss` utility hoặc trực tiếp `assets/images/<name>.svg`:
|
|
554
|
+
|
|
555
|
+
| File | Dùng cho |
|
|
494
556
|
|---|---|
|
|
495
|
-
| `
|
|
496
|
-
| `
|
|
497
|
-
| `
|
|
498
|
-
| `
|
|
499
|
-
| `
|
|
500
|
-
| `
|
|
501
|
-
| `
|
|
502
|
-
| `
|
|
503
|
-
| `
|
|
557
|
+
| `coming-soon.svg` | Trang chưa sẵn sàng |
|
|
558
|
+
| `data-empty.svg` | Empty state cho table / list |
|
|
559
|
+
| `expired.svg` | Session expired |
|
|
560
|
+
| `file-error.svg` | Upload file lỗi |
|
|
561
|
+
| `filter-empty.svg` | Không kết quả khớp filter |
|
|
562
|
+
| `filter-required.svg` | Yêu cầu chọn filter trước khi load data |
|
|
563
|
+
| `forbidden.svg` | 403 Forbidden |
|
|
564
|
+
| `image-error.svg` | Image load fail |
|
|
565
|
+
| `maintenance.svg` | Đang bảo trì |
|
|
566
|
+
| `not-found.svg` | 404 Not Found |
|
|
567
|
+
| `offline.svg` | Mất mạng |
|
|
568
|
+
| `submitted.svg` | Form gửi thành công |
|
|
569
|
+
| `success.svg` | Generic success |
|
|
570
|
+
| `unauthorized.svg` | 401 Unauthorized |
|
|
571
|
+
| `unknown-error.svg` | 500 / fallback |
|
|
504
572
|
|
|
505
573
|
---
|
|
506
574
|
|
|
507
|
-
|
|
575
|
+
## 16. What is NOT shipped
|
|
508
576
|
|
|
509
|
-
|
|
510
|
-
```
|
|
511
|
-
align-middle align-top align-bottom align-baseline
|
|
512
|
-
```
|
|
577
|
+
Để AI agent không sinh class lạ:
|
|
513
578
|
|
|
514
|
-
**
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
579
|
+
- ❌ **Không có Bootstrap, Tailwind, Bulma, Foundation.** Tất cả utility ở §3–§13 là code thuần SCSS của `@sd-angular/core`. Class như `.btn`, `.btn-primary`, `.card`, `.alert`, `.navbar`, `.form-control`, `.input-group`, `.modal`, `.dropdown`, `.list-group`, `.breadcrumb`, `.carousel`, `.popover`, `.tooltip`, `.progress`, `.spinner-border`, `.badge` (Bootstrap) **KHÔNG tồn tại**.
|
|
580
|
+
- ❌ **Không có Tailwind escape syntax** (`md:flex`, `hover:bg-red-500`, `text-[14px]`…). Responsive class duy nhất là `col-sm-*` / `col-md-*` / `col-lg-*` / `col-xl-*` ở §5.1.
|
|
581
|
+
- ❌ **Không có dark mode token** sẵn — phải tự khai báo nếu cần.
|
|
582
|
+
- ❌ **Không có animation utility class** (kiểu `.fade`, `.slide-in`). Animation handle qua Angular `[@trigger]` hoặc CSS riêng của component.
|
|
583
|
+
- ❌ **Không sinh class theo px arbitrary** — `m-{n}`, `p-{n}`, `w-{n}`, `h-{n}`, `fs-{n}`, `gap-{n}`, `rounded-{n}` chỉ chạy từ **0 → 200** integer. Cần `w-250` thì phải tự viết SCSS hoặc dùng inline style.
|
|
584
|
+
- ❌ **Không có shorthand position** (kiểu `top-0`, `left-50`). Set `position-absolute` rồi viết CSS riêng cho offset.
|
|
585
|
+
- ❌ **Component selector không phải utility class.** `sd-button`, `sd-input`, `sd-anchor`… là Angular component (xem `components/*/sd-*.md`), không phải CSS class.
|
|
518
586
|
|
|
519
|
-
|
|
587
|
+
### Migration check khi đọc code cũ
|
|
520
588
|
|
|
521
|
-
| Class |
|
|
589
|
+
| Class cũ (Bootstrap) | Thay thế bằng |
|
|
522
590
|
|---|---|
|
|
523
|
-
| `
|
|
524
|
-
| `
|
|
591
|
+
| `d-flex` | `d-flex` (giữ nguyên — đã port) |
|
|
592
|
+
| `text-center` | `text-center` (giữ nguyên) |
|
|
593
|
+
| `text-truncate` | `text-ellipsis` |
|
|
594
|
+
| `font-weight-normal` | `font-weight-normal` (giữ nguyên) |
|
|
595
|
+
| `mt-2` / `mt-3` … | `mt-8` / `mt-16` … (px-based 0–200, không phải multiplier 4) |
|
|
596
|
+
| `pl-2` | `pl-8` (đổi đơn vị) |
|
|
597
|
+
| `w-100` | `w-100` hoặc `w-full` |
|
|
598
|
+
| `border-secondary` | `border-secondary` (vẫn có — secondary là token màu, không phải utility riêng) |
|
|
599
|
+
| `btn`, `btn-primary` | dùng `<sd-button [color]="primary">` |
|
|
600
|
+
| `form-control` | dùng `<sd-input>` / `<sd-select>` … |
|
|
601
|
+
| `alert` | dùng `<sd-notify>` service |
|
|
602
|
+
| `modal` | dùng `<sd-modal>` |
|
|
603
|
+
|
|
604
|
+
> Lưu ý lớn nhất: **spacing scale đã đổi từ Bootstrap multiplier (1=4px, 2=8px…) sang px tuyệt đối**. `mb-3` trong Bootstrap = 16px; trong `@sd-angular/core` `mb-3` = **3px**. Reading code cũ cần convert (× 4) cẩn thận hoặc thay bằng `mb-16`.
|