mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-23 03:01:17 +00:00
* fix(ui): improve keyboard accessibility * fix(ui): remove unused toggle event * docs(changelog): note control UI keyboard access * chore(ui): keep release note in PR body * chore(ui): translate accessibility labels
29 lines
793 B
TypeScript
29 lines
793 B
TypeScript
// Shared body wrapper for settings and settings-adjacent pages. Settings
|
|
// section navigation lives in the takeover sidebar (settings-sidebar.ts).
|
|
import { html } from "lit";
|
|
import { ifDefined } from "lit/directives/if-defined.js";
|
|
|
|
export function renderSettingsWorkspace(
|
|
body: unknown,
|
|
options: {
|
|
fillHeight?: boolean;
|
|
id?: string;
|
|
role?: string;
|
|
ariaLabel?: string;
|
|
} = {},
|
|
) {
|
|
const className = options.fillHeight
|
|
? "settings-workspace settings-workspace--fill-height"
|
|
: "settings-workspace";
|
|
return html`
|
|
<section
|
|
class=${className}
|
|
id=${ifDefined(options.id)}
|
|
role=${ifDefined(options.role)}
|
|
aria-label=${ifDefined(options.ariaLabel)}
|
|
>
|
|
<div class="settings-workspace__body">${body}</div>
|
|
</section>
|
|
`;
|
|
}
|