@@ -27,9 +27,14 @@ import '@vaadin/tabs/vaadin-tab';
2727 * Custom property | Description | Default
2828 * ----------------|-------------|-------------
2929 * `--anchor-nav-inner-max-width` | `max-width` of "container" part. | `auto`
30- * `--anchor-nav-inner-background` | `background` of "container" part. | `#ffffff `
30+ * `--anchor-nav-inner-background` | `background` of "container" part. | `var(--lumo-base-color) `
3131 * `--anchor-nav-inner-padding` | `padding` of "container" part. | `0 0 20vh 0`
32+ * `--anchor-nav-tabs-background` | `background` of "tabs" part. | `var(--lumo-base-color)`
3233 * `--anchor-nav-tabs-stuck-box-shadow` | `box-shadow` of "tabs" part when stuck to top of viewport. | `0 4px 5px -6px rgba(0, 0, 0, 0.4)`
34+ * `--anchor-nav-header-padding` | `padding` of "header" part. | `0 var(--lumo-space-m)`
35+ *
36+ * Some of the custom properties rely on Lumo design tokens for colors and spacing. When not using the Lumo theme, those
37+ * need to be re-defined in order to ensure a proper look and feel.
3338 *
3439 * The following shadow DOM parts are available for styling:
3540 *
@@ -56,7 +61,9 @@ export class AnchorNavElement extends ElementMixin(LitElement) {
5661 --anchor-nav-inner-max-width: auto;
5762 --anchor-nav-inner-background: var(--lumo-base-color);
5863 --anchor-nav-inner-padding: 0;
64+ --anchor-nav-tabs-background: var(--lumo-base-color);
5965 --anchor-nav-tabs-stuck-box-shadow: 0 4px 5px -6px rgba(0, 0, 0, 0.4);
66+ --anchor-nav-header-padding: 0 var(--lumo-space-m);
6067 /*
6168 * Chrome scrollbar z-index bugfix
6269 * https://github.com/PolymerElements/iron-list/issues/137#issuecomment-176457768
@@ -90,7 +97,7 @@ export class AnchorNavElement extends ElementMixin(LitElement) {
9097 position: -webkit-sticky;
9198 position: sticky;
9299 top: 0 !important;
93- background: var(--lumo-base-color );
100+ background: var(--anchor-nav-tabs-background );
94101 z-index: 2;
95102 }
96103
@@ -112,7 +119,7 @@ export class AnchorNavElement extends ElementMixin(LitElement) {
112119 }
113120
114121 ::slotted([slot='header']) {
115- padding: 0 var(--lumo-space-m );
122+ padding: var(--anchor-nav-header-padding );
116123 }
117124
118125 :host([theme~='expand-last']) ::slotted(vcf-anchor-nav-section:last-of-type) {
0 commit comments