Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion api-goldens/element-ng/select/index.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,6 @@ export class SiSelectLazyOptionsDirective<T> implements SiSelectOptionsStrategy<
onFilter(filterInput?: string): void;
// (undocumented)
onValueChange(value: T[]): void;
// (undocumented)
readonly optionSource: _angular_core.InputSignal<SelectOptionSource<T>>;
readonly rows: _angular_core.WritableSignal<SelectItem<T>[]>;
readonly selectedRows: _angular_core.WritableSignal<SelectOption<T>[]>;
Expand Down
3 changes: 0 additions & 3 deletions api-goldens/element-ng/split/index.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ export class SiSplitComponent {
constructor();
readonly gutterSize: _angular_core.InputSignal<number>;
readonly orientation: _angular_core.InputSignal<SplitOrientation>;
// (undocumented)
readonly sizesChange: _angular_core.OutputEmitterRef<number[]>;
readonly stateId: _angular_core.InputSignal<string | undefined>;
}
Expand All @@ -51,7 +50,6 @@ export class SiSplitModule {
export class SiSplitPartComponent {
constructor();
readonly actions: _angular_core.InputSignal<Action[]>;
// (undocumented)
readonly collapseChanged: _angular_core.OutputEmitterRef<boolean>;
get collapsed(): boolean;
readonly collapseDirection: _angular_core.InputSignal<CollapseTo>;
Expand All @@ -70,7 +68,6 @@ export class SiSplitPartComponent {
readonly showCollapseButton: _angular_core.InputSignalWithTransform<boolean, unknown>;
readonly showHeader: _angular_core.InputSignalWithTransform<boolean, unknown>;
readonly size: _angular_core.InputSignalWithTransform<number, string | number>;
// (undocumented)
readonly stateChange: _angular_core.OutputEmitterRef<PartState>;
readonly stateId: _angular_core.InputSignal<string | undefined>;
toggleCollapse(): void;
Expand Down
8 changes: 0 additions & 8 deletions api-goldens/element-ng/status-bar/index.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,21 +41,13 @@ export class SiStatusBarComponent implements OnDestroy, OnChanges {

// @public (undocumented)
export class SiStatusBarItemComponent implements OnChanges {
// (undocumented)
readonly blink: _angular_core.InputSignalWithTransform<boolean, unknown>;
// (undocumented)
readonly clickable: _angular_core.InputSignalWithTransform<boolean, unknown>;
// (undocumented)
readonly color: _angular_core.InputSignal<string | undefined>;
// (undocumented)
readonly heading: _angular_core.InputSignal<TranslatableString>;
// (undocumented)
readonly significanceChange: _angular_core.OutputEmitterRef<void>;
// (undocumented)
readonly status: _angular_core.InputSignal<ExtendedStatusType | undefined>;
// (undocumented)
readonly value: _angular_core.InputSignal<number | TranslatableString>;
// (undocumented)
readonly valueOnly: _angular_core.InputSignalWithTransform<boolean | undefined, unknown>;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ export class SiSelectLazyOptionsDirective<T> implements SiSelectOptionsStrategy<
*/
readonly selectedRows = signal<SelectOption<T>[]>([]);

/**
* Lazy source that resolves selected values and provides the options displayed by the select.
* Implement `getAllOptions` when the select has no filter, or `getOptionsForSearch` when it has one.
*/
readonly optionSource = input.required<SelectOptionSource<T>>();

private valueChange = new Subject<void>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ import { SelectOption } from '../si-select.types';
}
})
export class SiSelectInputComponent<T> {
/**
* Base ID used to associate the input with its label.
*/
readonly baseId = input.required<string>();
/**
* Aria labelledby of the select.
Expand All @@ -67,19 +70,39 @@ export class SiSelectInputComponent<T> {
* @defaultValue null
*/
readonly ariaLabel = input<string | null>(null);
/** @defaultValue false */
/**
* Whether the listbox is open.
*
* @defaultValue false
*/
readonly open = input(false, { transform: booleanAttribute });
/**
* Text shown when no option is selected.
*/
readonly placeholder = input<TranslatableString>();
/**
* ID of the associated listbox.
*/
readonly controls = input.required<string>();
/**
* Custom template for rendering selected options.
*/
readonly optionTemplate = input<
TemplateRef<{
$implicit: SelectOption<T>;
}>
>();

/** @defaultValue false */
/**
* Whether the input is read-only.
*
* @defaultValue false
*/
readonly readonly = input(false, { transform: booleanAttribute });

/**
* Emits when the user requests to open the listbox.
*/
readonly openListbox = output<void>();
protected readonly selectionStrategy = inject<SiSelectSelectionStrategy<T>>(
SiSelectSelectionStrategy<T>
Expand Down
15 changes: 15 additions & 0 deletions projects/element-ng/select/select-list/si-select-list.base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,21 +29,36 @@ import { SelectGroup, SelectOption } from '../si-select.types';
}
})
export abstract class SiSelectListBase<T> implements OnInit, OnDestroy {
/**
* Base ID used to associate the listbox with its label.
*/
readonly baseId = input.required<string>();
/**
* Custom template for rendering options.
*/
readonly optionTemplate = input<
TemplateRef<{
$implicit: SelectOption<T>;
}>
>();
/**
* Custom template for rendering option groups.
*/
readonly groupTemplate = input<
TemplateRef<{
$implicit: SelectGroup<T>;
}>
>();
/** @defaultValue null */
readonly labelledby = input<string | null>(null);
/**
* Custom template for actions displayed below the options.
*/
readonly actionsTemplate = input<TemplateRef<any>>();

/**
* Emits when the listbox should close.
*/
readonly closeOverlay = output<void>();

protected readonly selectionStrategy =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,19 @@ import { SelectOption } from '../si-select.types';
}
})
export class SiSelectOptionRowComponent {
/**
* Option displayed by the row.
*/
readonly option = input.required<SelectOption<unknown>>();
/**
* Custom template for rendering the option.
*/
readonly optionTemplate = input<TemplateRef<unknown>>();
/** @defaultValue false */
/**
* Whether the option is selected.
*
* @defaultValue false
*/
readonly selected = input(false, { transform: booleanAttribute });
protected readonly icons = addIcons({ elementOk });
}
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ import { SelectOption } from '../si-select.types';
}
})
export class SiSelectOptionComponent {
/**
* Option to render.
*/
readonly option = input.required<SelectOption<unknown>>();
/**
* Custom template for rendering the option.
*/
readonly optionTemplate = input<TemplateRef<unknown>>();
}
6 changes: 5 additions & 1 deletion projects/element-ng/skip-links/si-skip-links.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ import { SiSkipLinkTargetDirective } from './si-skip-link-target.directive';
styleUrl: './si-skip-links.component.scss'
})
export class SiSkipLinksComponent {
/** @defaultValue [] */
/**
* Targets displayed as skip links.
*
* @defaultValue []
*/
readonly skipLinks = input<readonly SiSkipLinkTargetDirective[]>([]);

protected jumpToLabel = t(() => $localize`:@@SI_SKIP_LINKS.JUMP_TO:Jump to {{link}}`);
Expand Down
6 changes: 6 additions & 0 deletions projects/element-ng/split/si-split-part.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,13 @@ export class SiSplitPartComponent {
*/
readonly expanded = input(true, { transform: booleanAttribute });

/**
* Emits when the part is collapsed or expanded.
*/
readonly collapseChanged = output<boolean>();
/**
* Emits the part's expanded state and size after it is toggled.
*/
readonly stateChange = output<PartState>();

/** @internal */
Expand Down
3 changes: 3 additions & 0 deletions projects/element-ng/split/si-split.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ export class SiSplitComponent {
*/
readonly stateId = input<string>();

/**
* Emits the sizes of all parts as percentages when the user resizes a gutter.
*/
readonly sizesChange = output<number[]>();

@WebComponentContentChildren(SiSplitPartComponent)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,44 @@ import { SiTranslatePipe, TranslatableString } from '@siemens/element-translate-
})
export class SiStatusBarItemComponent implements OnChanges {
private readonly statusIcons = inject(STATUS_ICON_CONFIG);
/**
* Status that determines the displayed icon and color.
*/
readonly status = input<ExtendedStatusType>();
/**
* Value displayed by the status bar item.
*/
readonly value = input.required<TranslatableString | number>();
/**
* Heading displayed for the status bar item.
*/
readonly heading = input.required<TranslatableString>();
/**
* Custom background color for the item.
*/
readonly color = input<string>();
/** @defaultValue false */
/**
* Whether the item blinks to highlight its status.
*
* @defaultValue false
*/
readonly blink = input(false, { transform: booleanAttribute });
/** @defaultValue false */
/**
* Whether only the value is displayed.
*
* @defaultValue false
*/
readonly valueOnly = input<boolean | undefined, unknown>(false, { transform: booleanAttribute });
/** @defaultValue false */
/**
* Whether the item has an interactive appearance.
*
* @defaultValue false
*/
readonly clickable = input(false, { transform: booleanAttribute });

/**
* Emits when the value changes between an empty and non-empty state.
*/
readonly significanceChange = output<void>();

private readonly bg = viewChild.required<ElementRef>('bg');
Expand Down
Loading