diff --git a/src/main/java/com/flowingcode/vaadin/addons/dayofweekselector/DayOfWeekSelector.java b/src/main/java/com/flowingcode/vaadin/addons/dayofweekselector/DayOfWeekSelector.java index faa5284..78b03ef 100644 --- a/src/main/java/com/flowingcode/vaadin/addons/dayofweekselector/DayOfWeekSelector.java +++ b/src/main/java/com/flowingcode/vaadin/addons/dayofweekselector/DayOfWeekSelector.java @@ -2,7 +2,7 @@ * #%L * Day of Week Selector Add-on * %% - * Copyright (C) 2023 - 2024 Flowing Code + * Copyright (C) 2023 - 2026 Flowing Code * %% * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -45,6 +45,8 @@ */ @SuppressWarnings("serial") @CssImport("./styles/fc-days-of-week-selector-styles.css") +@CssImport(value = "./styles/vaadin-context-menu-list-box.css", + themeFor = "vaadin-context-menu-list-box") @JsModule("./src/fc-days-of-week-selector.ts") @Tag("fc-days-of-week-selector") public class DayOfWeekSelector extends CustomField> { diff --git a/src/main/resources/META-INF/frontend/styles/fc-days-of-week-selector-styles.css b/src/main/resources/META-INF/frontend/styles/fc-days-of-week-selector-styles.css index 9763372..ba046f3 100644 --- a/src/main/resources/META-INF/frontend/styles/fc-days-of-week-selector-styles.css +++ b/src/main/resources/META-INF/frontend/styles/fc-days-of-week-selector-styles.css @@ -2,7 +2,7 @@ * #%L * Day of Week Selector Add-on * %% - * Copyright (C) 2023 - 2024 Flowing Code + * Copyright (C) 2023 - 2026 Flowing Code * %% * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -53,10 +53,4 @@ vaadin-horizontal-layout.fc-days-of-week-selector-buttons-layout { justify-content: center; flex-wrap: wrap; padding: 0 10px; -} - -vaadin-context-menu-overlay vaadin-context-menu-list-box::part(items) { - padding: 0 var(--lumo-space-xs); - display: inline-flex; - gap: var(--fc-days-of-week-selector-button-space, var(--lumo-space-m)); -} +} \ No newline at end of file diff --git a/src/main/resources/META-INF/frontend/styles/vaadin-context-menu-list-box.css b/src/main/resources/META-INF/frontend/styles/vaadin-context-menu-list-box.css new file mode 100644 index 0000000..85e4a22 --- /dev/null +++ b/src/main/resources/META-INF/frontend/styles/vaadin-context-menu-list-box.css @@ -0,0 +1,25 @@ +/*- + * #%L + * Day of Week Selector Add-on + * %% + * Copyright (C) 2023 - 2026 Flowing Code + * %% + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * #L% + */ + +:host([theme~='fc-day-of-week-selector-context-menu']) [part~="items"] { + padding: 0 var(--lumo-space-xs); + display: inline-flex; + gap: var(--fc-days-of-week-selector-button-space, var(--lumo-space-m)); +} \ No newline at end of file diff --git a/src/main/resources/META-INF/resources/frontend/src/fc-days-of-week-selector.ts b/src/main/resources/META-INF/resources/frontend/src/fc-days-of-week-selector.ts index b5230fe..477dd31 100644 --- a/src/main/resources/META-INF/resources/frontend/src/fc-days-of-week-selector.ts +++ b/src/main/resources/META-INF/resources/frontend/src/fc-days-of-week-selector.ts @@ -2,7 +2,7 @@ * #%L * Day of Week Selector Add-on * %% - * Copyright (C) 2025 Flowing Code + * Copyright (C) 2023 - 2026 Flowing Code * %% * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -219,7 +219,7 @@ export class DaysOfWeekSelector extends ResizeMixin(ThemableMixin(LitElement)) {
- +