codexly-ui 0.6.14 → 0.6.15
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/fesm2022/codexly-ui.mjs +71 -19
- package/fesm2022/codexly-ui.mjs.map +1 -1
- package/package.json +1 -1
- package/types/codexly-ui.d.ts +26 -5
package/fesm2022/codexly-ui.mjs
CHANGED
|
@@ -9986,44 +9986,96 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.15", ngImpo
|
|
|
9986
9986
|
}]
|
|
9987
9987
|
}], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: true }] }], collapsed: [{ type: i0.Input, args: [{ isSignal: true, alias: "collapsed", required: false }] }], style: [{ type: i0.Input, args: [{ isSignal: true, alias: "style", required: false }] }] } });
|
|
9988
9988
|
|
|
9989
|
+
/** Optional replacement for the auto-generated `<h1>` — project this when the title needs
|
|
9990
|
+
* inline content next to it (a status badge, a monospace order number, extra spans) that a
|
|
9991
|
+
* plain `title` string input can't express. The `title`/`subtitle` inputs are ignored when
|
|
9992
|
+
* this is present; ClxPageHeaderComponent's own text-2xl/font-weight/truncate styling is
|
|
9993
|
+
* NOT applied automatically to projected content — style the projected `<h1>` yourself. */
|
|
9994
|
+
class ClxPageHeaderTitleDirective {
|
|
9995
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.15", ngImport: i0, type: ClxPageHeaderTitleDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
9996
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.15", type: ClxPageHeaderTitleDirective, isStandalone: true, selector: "[clxPageHeaderTitle]", ngImport: i0 });
|
|
9997
|
+
}
|
|
9998
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.15", ngImport: i0, type: ClxPageHeaderTitleDirective, decorators: [{
|
|
9999
|
+
type: Directive,
|
|
10000
|
+
args: [{ selector: '[clxPageHeaderTitle]', standalone: true }]
|
|
10001
|
+
}] });
|
|
10002
|
+
|
|
9989
10003
|
/**
|
|
9990
|
-
* Standard page title block: title + optional subtitle on the
|
|
9991
|
-
* slot (button, select, badge...) on the right. Replaces the
|
|
9992
|
-
* `<h1 class="text-2xl font-semibold">` + `<p>` pattern repeated across every page.
|
|
10004
|
+
* Standard page title block: an optional back button, title + optional subtitle on the
|
|
10005
|
+
* left, a free-content slot (button, select, badge...) on the right. Replaces the
|
|
10006
|
+
* hand-rolled `<h1 class="text-2xl font-semibold">` + `<p>` pattern repeated across every page.
|
|
10007
|
+
*
|
|
10008
|
+
* For detail pages whose title needs inline content (a status badge, a monospace order
|
|
10009
|
+
* number) that a plain `title` string can't express, project a `[clxPageHeaderTitle]`
|
|
10010
|
+
* block instead of using the `title`/`subtitle` inputs.
|
|
9993
10011
|
*/
|
|
9994
10012
|
class ClxPageHeaderComponent {
|
|
9995
|
-
|
|
10013
|
+
_themeSvc = inject(ClxThemeService);
|
|
10014
|
+
title = input('', ...(ngDevMode ? [{ debugName: "title" }] : /* istanbul ignore next */ []));
|
|
9996
10015
|
subtitle = input(undefined, ...(ngDevMode ? [{ debugName: "subtitle" }] : /* istanbul ignore next */ []));
|
|
10016
|
+
/** Set to show the back button — `[showBack]="true" (back)="goBack()"`. */
|
|
10017
|
+
showBack = input(false, ...(ngDevMode ? [{ debugName: "showBack" }] : /* istanbul ignore next */ []));
|
|
10018
|
+
back = output();
|
|
10019
|
+
_titleSlot = contentChild(ClxPageHeaderTitleDirective, ...(ngDevMode ? [{ debugName: "_titleSlot" }] : /* istanbul ignore next */ []));
|
|
10020
|
+
_hasCustomTitle = computed(() => !!this._titleSlot(), ...(ngDevMode ? [{ debugName: "_hasCustomTitle" }] : /* istanbul ignore next */ []));
|
|
10021
|
+
_color = computed(() => this._themeSvc.config().primaryColor, ...(ngDevMode ? [{ debugName: "_color" }] : /* istanbul ignore next */ []));
|
|
9997
10022
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.15", ngImport: i0, type: ClxPageHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
9998
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.15", type: ClxPageHeaderComponent, isStandalone: true, selector: "clx-page-header", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired:
|
|
9999
|
-
|
|
10000
|
-
<
|
|
10001
|
-
|
|
10002
|
-
|
|
10023
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.15", type: ClxPageHeaderComponent, isStandalone: true, selector: "clx-page-header", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, subtitle: { classPropertyName: "subtitle", publicName: "subtitle", isSignal: true, isRequired: false, transformFunction: null }, showBack: { classPropertyName: "showBack", publicName: "showBack", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { back: "back" }, host: { classAttribute: "flex items-center gap-3 flex-wrap" }, queries: [{ propertyName: "_titleSlot", first: true, predicate: ClxPageHeaderTitleDirective, descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
10024
|
+
@if (showBack()) {
|
|
10025
|
+
<button clx-button variant="ghost" [color]="_color()" icon="arrow_back" [iconOnly]="true"
|
|
10026
|
+
(click)="back.emit()"></button>
|
|
10027
|
+
}
|
|
10028
|
+
|
|
10029
|
+
<div class="flex-1 min-w-0 flex items-center justify-between flex-wrap gap-3">
|
|
10030
|
+
@if (_hasCustomTitle()) {
|
|
10031
|
+
<div class="min-w-0">
|
|
10032
|
+
<ng-content select="[clxPageHeaderTitle]" />
|
|
10033
|
+
</div>
|
|
10034
|
+
} @else {
|
|
10035
|
+
<div class="min-w-0">
|
|
10036
|
+
<h1 class="text-2xl font-(--clx-font-weight-emphasis) text-clx-text-label truncate">{{ title() }}</h1>
|
|
10037
|
+
@if (subtitle()) {
|
|
10038
|
+
<p class="text-sm text-clx-text-muted mt-0.5">{{ subtitle() }}</p>
|
|
10039
|
+
}
|
|
10040
|
+
</div>
|
|
10003
10041
|
}
|
|
10042
|
+
<ng-content />
|
|
10004
10043
|
</div>
|
|
10005
|
-
|
|
10006
|
-
`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
10044
|
+
`, isInline: true, dependencies: [{ kind: "component", type: ClxButtonComponent, selector: "button[clx-button], a[clx-button]", inputs: ["variant", "color", "size", "shape", "loading", "disabled", "block", "icon", "iconPosition", "iconOnly", "badge", "badgeColor"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
10007
10045
|
}
|
|
10008
10046
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.15", ngImport: i0, type: ClxPageHeaderComponent, decorators: [{
|
|
10009
10047
|
type: Component,
|
|
10010
10048
|
args: [{
|
|
10011
10049
|
selector: 'clx-page-header',
|
|
10012
10050
|
standalone: true,
|
|
10051
|
+
imports: [ClxButtonComponent],
|
|
10013
10052
|
encapsulation: ViewEncapsulation.None,
|
|
10014
10053
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
10015
|
-
host: { class: 'flex items-center
|
|
10054
|
+
host: { class: 'flex items-center gap-3 flex-wrap' },
|
|
10016
10055
|
template: `
|
|
10017
|
-
|
|
10018
|
-
<
|
|
10019
|
-
|
|
10020
|
-
|
|
10056
|
+
@if (showBack()) {
|
|
10057
|
+
<button clx-button variant="ghost" [color]="_color()" icon="arrow_back" [iconOnly]="true"
|
|
10058
|
+
(click)="back.emit()"></button>
|
|
10059
|
+
}
|
|
10060
|
+
|
|
10061
|
+
<div class="flex-1 min-w-0 flex items-center justify-between flex-wrap gap-3">
|
|
10062
|
+
@if (_hasCustomTitle()) {
|
|
10063
|
+
<div class="min-w-0">
|
|
10064
|
+
<ng-content select="[clxPageHeaderTitle]" />
|
|
10065
|
+
</div>
|
|
10066
|
+
} @else {
|
|
10067
|
+
<div class="min-w-0">
|
|
10068
|
+
<h1 class="text-2xl font-(--clx-font-weight-emphasis) text-clx-text-label truncate">{{ title() }}</h1>
|
|
10069
|
+
@if (subtitle()) {
|
|
10070
|
+
<p class="text-sm text-clx-text-muted mt-0.5">{{ subtitle() }}</p>
|
|
10071
|
+
}
|
|
10072
|
+
</div>
|
|
10021
10073
|
}
|
|
10074
|
+
<ng-content />
|
|
10022
10075
|
</div>
|
|
10023
|
-
<ng-content />
|
|
10024
10076
|
`,
|
|
10025
10077
|
}]
|
|
10026
|
-
}], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required:
|
|
10078
|
+
}], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], subtitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "subtitle", required: false }] }], showBack: [{ type: i0.Input, args: [{ isSignal: true, alias: "showBack", required: false }] }], back: [{ type: i0.Output, args: ["back"] }], _titleSlot: [{ type: i0.ContentChild, args: [i0.forwardRef(() => ClxPageHeaderTitleDirective), { isSignal: true }] }] } });
|
|
10027
10079
|
|
|
10028
10080
|
class ClxProfileComponent {
|
|
10029
10081
|
// ── Inputs ──────────────────────────────────────────────────────────────────
|
|
@@ -15755,5 +15807,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.15", ngImpo
|
|
|
15755
15807
|
* Generated bundle index. Do not edit.
|
|
15756
15808
|
*/
|
|
15757
15809
|
|
|
15758
|
-
export { CLX_ADDON_BORDER, CLX_ADDON_TEXT, CLX_ALERT_OPTIONS, CLX_ALERT_RESOLVE, CLX_BG_ADDON, CLX_BG_DISABLED, CLX_BG_ICON_WRAP, CLX_BG_SECTION, CLX_BG_SURFACE, CLX_BORDER_DEFAULT, CLX_BORDER_DISABLED, CLX_BORDER_MEDIUM, CLX_COLOR_HEX, CLX_COLOR_HEX_100, CLX_COLOR_MAP, CLX_FONT_CATALOG, CLX_FONT_WEIGHT_MAP, CLX_MODAL_ANIM_CONFIG, CLX_MODAL_DATA, CLX_MODAL_REF, CLX_OPTION_DISABLED, CLX_PLACEHOLDER, CLX_RADIO_GROUP, CLX_RADIUS_MAP, CLX_TEXT_BODY, CLX_TEXT_DISABLED, CLX_TEXT_HEADING, CLX_TEXT_HINT, CLX_TEXT_IDLE, CLX_TEXT_INPUT, CLX_TEXT_LABEL, CLX_TEXT_OPTION, CLX_TEXT_SUBTITLE, CLX_TEXT_TITLE, CLX_THEME_CONFIG, CLX_THEME_DEFAULTS, CLX_TOAST_DEFAULTS, ClxAlertComponent, ClxAlertService, ClxAnimateDirective, ClxAnimateGroupDirective, ClxAnimateService, ClxAppLayoutComponent, ClxAvatarComponent, ClxBadgeComponent, ClxBrandComponent, ClxButtonComponent, ClxButtonGroupComponent, ClxCardBodyDirective, ClxCardComponent, ClxCardFooterDirective, ClxCardHeaderActionsDirective, ClxCardHeaderDirective, ClxCarouselComponent, ClxCarouselDirective, ClxCartComponent, ClxCartSummaryDrawer, ClxCellDirective, ClxCheckboxComponent, ClxColorPickerComponent, ClxColumnDefDirective, ClxDateRangePickerComponent, ClxDatepickerComponent, ClxDrawerComponent, ClxDrawerService, ClxEditorComponent, ClxEditorLinkModalComponent, ClxFabComponent, ClxFilterPanelComponent, ClxHeaderCellDirective, ClxIconComponent, ClxInputComponent, ClxListComponent, ClxListItemComponent, ClxMenuComponent, ClxMenuItemComponent, ClxModalComponent, ClxModalService, ClxNavGroupComponent, ClxNumberComponent, ClxPageEmptyComponent, ClxPageHeaderComponent, ClxPageNotFoundComponent, ClxPageServerErrorComponent, ClxPageUnauthorizedComponent, ClxPaginationComponent, ClxProductComponent, ClxProductDetailComponent, ClxProfileComponent, ClxProgressBarComponent, ClxRadioComponent, ClxRadioGroupComponent, ClxRatingComponent, ClxSelectComponent, ClxSkeletonComponent, ClxSliderComponent, ClxSpinnerComponent, ClxStatCardComponent, ClxStepComponent, ClxStepperComponent, ClxSwitchComponent, ClxTabDirective, ClxTableComponent, ClxTabsComponent, ClxTagComponent, ClxTextareaComponent, ClxThemeService, ClxTimelineComponent, ClxTimelineItemComponent, ClxTimepickerComponent, ClxToastComponent, ClxToastContainerComponent, ClxToastService, ClxTooltipComponent, ClxTooltipDirective, ClxTreeComponent, ClxUploadComponent, ClxWishlistComponent, ClxWizardComponent, TIMEPICKER_SIZE_MAP, parseColorInput, provideCodexlyTheme, resolveColor, resolveContainerRadius, resolveRadius };
|
|
15810
|
+
export { CLX_ADDON_BORDER, CLX_ADDON_TEXT, CLX_ALERT_OPTIONS, CLX_ALERT_RESOLVE, CLX_BG_ADDON, CLX_BG_DISABLED, CLX_BG_ICON_WRAP, CLX_BG_SECTION, CLX_BG_SURFACE, CLX_BORDER_DEFAULT, CLX_BORDER_DISABLED, CLX_BORDER_MEDIUM, CLX_COLOR_HEX, CLX_COLOR_HEX_100, CLX_COLOR_MAP, CLX_FONT_CATALOG, CLX_FONT_WEIGHT_MAP, CLX_MODAL_ANIM_CONFIG, CLX_MODAL_DATA, CLX_MODAL_REF, CLX_OPTION_DISABLED, CLX_PLACEHOLDER, CLX_RADIO_GROUP, CLX_RADIUS_MAP, CLX_TEXT_BODY, CLX_TEXT_DISABLED, CLX_TEXT_HEADING, CLX_TEXT_HINT, CLX_TEXT_IDLE, CLX_TEXT_INPUT, CLX_TEXT_LABEL, CLX_TEXT_OPTION, CLX_TEXT_SUBTITLE, CLX_TEXT_TITLE, CLX_THEME_CONFIG, CLX_THEME_DEFAULTS, CLX_TOAST_DEFAULTS, ClxAlertComponent, ClxAlertService, ClxAnimateDirective, ClxAnimateGroupDirective, ClxAnimateService, ClxAppLayoutComponent, ClxAvatarComponent, ClxBadgeComponent, ClxBrandComponent, ClxButtonComponent, ClxButtonGroupComponent, ClxCardBodyDirective, ClxCardComponent, ClxCardFooterDirective, ClxCardHeaderActionsDirective, ClxCardHeaderDirective, ClxCarouselComponent, ClxCarouselDirective, ClxCartComponent, ClxCartSummaryDrawer, ClxCellDirective, ClxCheckboxComponent, ClxColorPickerComponent, ClxColumnDefDirective, ClxDateRangePickerComponent, ClxDatepickerComponent, ClxDrawerComponent, ClxDrawerService, ClxEditorComponent, ClxEditorLinkModalComponent, ClxFabComponent, ClxFilterPanelComponent, ClxHeaderCellDirective, ClxIconComponent, ClxInputComponent, ClxListComponent, ClxListItemComponent, ClxMenuComponent, ClxMenuItemComponent, ClxModalComponent, ClxModalService, ClxNavGroupComponent, ClxNumberComponent, ClxPageEmptyComponent, ClxPageHeaderComponent, ClxPageHeaderTitleDirective, ClxPageNotFoundComponent, ClxPageServerErrorComponent, ClxPageUnauthorizedComponent, ClxPaginationComponent, ClxProductComponent, ClxProductDetailComponent, ClxProfileComponent, ClxProgressBarComponent, ClxRadioComponent, ClxRadioGroupComponent, ClxRatingComponent, ClxSelectComponent, ClxSkeletonComponent, ClxSliderComponent, ClxSpinnerComponent, ClxStatCardComponent, ClxStepComponent, ClxStepperComponent, ClxSwitchComponent, ClxTabDirective, ClxTableComponent, ClxTabsComponent, ClxTagComponent, ClxTextareaComponent, ClxThemeService, ClxTimelineComponent, ClxTimelineItemComponent, ClxTimepickerComponent, ClxToastComponent, ClxToastContainerComponent, ClxToastService, ClxTooltipComponent, ClxTooltipDirective, ClxTreeComponent, ClxUploadComponent, ClxWishlistComponent, ClxWizardComponent, TIMEPICKER_SIZE_MAP, parseColorInput, provideCodexlyTheme, resolveColor, resolveContainerRadius, resolveRadius };
|
|
15759
15811
|
//# sourceMappingURL=codexly-ui.mjs.map
|