Skip to content

Conversation

@AlexAndBear
Copy link
Contributor

@AlexAndBear AlexAndBear commented Sep 22, 2025

Description

image

Enables the dark mode for the date picker. Note this works with Chrome-Like browsers and Safari but not with Firefox

Related Issue

How Has This Been Tested?

  • test environment:
  • test case 1:
  • test case 2:
  • ...

Types of changes

  • Bugfix
  • Enhancement (a change that doesn't break existing code or deployments)
  • Breaking change (a modification that affects current functionality)
  • Technical debt (addressing code that needs refactoring or improvements)
  • Tests (adding or improving tests)
  • Documentation (updates or additions to documentation)
  • Maintenance (like dependency updates or tooling adjustments)

Copilot AI review requested due to automatic review settings September 22, 2025 10:18
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds dark mode support to the OcDatePicker component, enabling the date picker to adapt its appearance based on the current theme. The implementation uses the color-scheme: dark CSS property to activate browser-native dark styling for date inputs.

  • Added isDark prop to OcDatePicker component
  • Integrated theme store across components using OcDatePicker
  • Added CSS styling for dark mode date picker appearance

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
packages/design-system/src/components/OcDatepicker/OcDatepicker.vue Added isDark prop and dark mode CSS styling
packages/web-runtime/src/components/Modals/AppTokenModal.vue Added theme store integration and isDark prop binding
packages/web-pkg/src/components/Modals/DatePickerModal.vue Added theme store integration and isDark prop binding
packages/web-pkg/src/components/Filters/DateFilter.vue Added theme store integration and isDark prop binding
packages/web-pkg/src/components/CreateLinkModal.vue Added theme store integration and isDark prop binding
packages/design-system/src/components/OcDatepicker/OcDatepicker.spec.ts Updated tests to include required isDark prop
packages/design-system/docs/components/OcDatepicker/handler.vue Added isDark prop to documentation example
packages/design-system/docs/components/OcDatepicker/default.vue Added isDark prop to documentation example

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

}
.oc-date-picker-dark input::-webkit-calendar-picker-indicator {
filter: invert(0);
Copy link

Copilot AI Sep 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The filter: invert(0) rule appears to be a no-op since it doesn't change the appearance. Consider removing this rule or clarifying its purpose with a comment if it's intentionally preventing other filter applications.

Suggested change
filter: invert(0);

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does 😠

@AlexAndBear
Copy link
Contributor Author

@JammingBen should I move the css to the tailwind component, even if there are no matching utility classes to apply ?

@JammingBen
Copy link
Contributor

@JammingBen should I move the css to the tailwind component, even if there are no matching utility classes to apply ?

I'd say yes, or at least to the already existing style block to avoid having 2 style blocks.

@AlexAndBear
Copy link
Contributor Author

@JammingBen should I move the css to the tailwind component, even if there are no matching utility classes to apply ?

I'd say yes, or at least to the already existing style block to avoid having 2 style blocks.

👍 adjusted

@AlexAndBear AlexAndBear merged commit 385a29f into main Sep 22, 2025
28 checks passed
@AlexAndBear AlexAndBear deleted the issues/1224 branch September 22, 2025 13:40
@openclouders openclouders mentioned this pull request Sep 22, 2025
1 task
openclouders pushed a commit that referenced this pull request Sep 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Datepicker does not follow dark mode styling

3 participants