codexly-ui 0.5.7 → 0.5.8
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
CHANGED
|
@@ -1297,10 +1297,13 @@ class ClxCardComponent {
|
|
|
1297
1297
|
_hasHeader = computed(() => !!this._headerSlot(), ...(ngDevMode ? [{ debugName: "_hasHeader" }] : /* istanbul ignore next */ []));
|
|
1298
1298
|
_hasBody = computed(() => !!this._bodySlot(), ...(ngDevMode ? [{ debugName: "_hasBody" }] : /* istanbul ignore next */ []));
|
|
1299
1299
|
_hasFooter = computed(() => !!this._footerSlot(), ...(ngDevMode ? [{ debugName: "_hasFooter" }] : /* istanbul ignore next */ []));
|
|
1300
|
+
/** Blocks interaction only — applied to body/footer so the header (e.g. an enable/disable switch) stays clickable. */
|
|
1301
|
+
_disabledInteractionCls = computed(() => this.disabled() ? 'pointer-events-none' : '', ...(ngDevMode ? [{ debugName: "_disabledInteractionCls" }] : /* istanbul ignore next */ []));
|
|
1300
1302
|
_bodyClass = computed(() => {
|
|
1301
1303
|
const pad = this._hasBody() ? CARD_PADDING_MAP[this.padding()] : CARD_PADDING_MAP[this.padding()];
|
|
1302
|
-
return `clx-card-body flex-1 ${pad}
|
|
1304
|
+
return `clx-card-body flex-1 ${pad} ${this._disabledInteractionCls()}`.trim();
|
|
1303
1305
|
}, ...(ngDevMode ? [{ debugName: "_bodyClass" }] : /* istanbul ignore next */ []));
|
|
1306
|
+
_footerClass = computed(() => `clx-card-footer flex items-center gap-2 px-4 py-2 border-t border-clx-border-soft bg-clx-surface-2 ${this._disabledInteractionCls()}`.trim(), ...(ngDevMode ? [{ debugName: "_footerClass" }] : /* istanbul ignore next */ []));
|
|
1304
1307
|
_hostClass = computed(() => {
|
|
1305
1308
|
const variant = this.variant();
|
|
1306
1309
|
const t = resolveColor(this._color());
|
|
@@ -1319,7 +1322,7 @@ class ClxCardComponent {
|
|
|
1319
1322
|
const shadowClass = shadowInput !== undefined ? CARD_SHADOW_MAP[shadowInput] : '';
|
|
1320
1323
|
variantClass = `bg-clx-surface-2 border border-transparent ${shadowClass}`;
|
|
1321
1324
|
}
|
|
1322
|
-
const disabledCls = this.disabled() ? 'opacity-50
|
|
1325
|
+
const disabledCls = this.disabled() ? 'opacity-50' : '';
|
|
1323
1326
|
return `flex flex-col ${resolveContainerRadius(this._themeSvc.config().borderRadius)} overflow-hidden w-full ${variantClass} ${hover} ${disabledCls}`.trim();
|
|
1324
1327
|
}, ...(ngDevMode ? [{ debugName: "_hostClass" }] : /* istanbul ignore next */ []));
|
|
1325
1328
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.15", ngImport: i0, type: ClxCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -1338,7 +1341,7 @@ class ClxCardComponent {
|
|
|
1338
1341
|
</div>
|
|
1339
1342
|
|
|
1340
1343
|
@if (_hasFooter()) {
|
|
1341
|
-
<div class="
|
|
1344
|
+
<div [class]="_footerClass()">
|
|
1342
1345
|
<ng-content select="[clxCardFooter]" />
|
|
1343
1346
|
</div>
|
|
1344
1347
|
}
|
|
@@ -1371,7 +1374,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.15", ngImpo
|
|
|
1371
1374
|
</div>
|
|
1372
1375
|
|
|
1373
1376
|
@if (_hasFooter()) {
|
|
1374
|
-
<div class="
|
|
1377
|
+
<div [class]="_footerClass()">
|
|
1375
1378
|
<ng-content select="[clxCardFooter]" />
|
|
1376
1379
|
</div>
|
|
1377
1380
|
}
|