Skip to content

Commit

Permalink
fix: switch to EG locale in example cause its my country
Browse files Browse the repository at this point in the history
  • Loading branch information
logaretm committed Feb 19, 2025
1 parent 44d61b6 commit f68dacb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 15 deletions.
18 changes: 3 additions & 15 deletions packages/playground/src/App.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<script setup lang="ts">
import DateField from '@/components/DateField.vue';
import Calendar from '@/components/Calendar.vue';
import { createCalendar, IslamicUmalquraCalendar } from '@internationalized/date';
const calendar = createCalendar('islamic-umalqura');
// You need to be careful with the time component of the date object.
// JS date objects fills the date time with the current time component.
Expand All @@ -11,20 +13,6 @@ const max = new Date('2025-01-20');

<template>
<div class="flex flex-col gap-4">
<!-- <DateField
name="date"
label="Date"
:format-options="{
day: '2-digit',
month: 'numeric',
year: 'numeric',
hour: '2-digit',
hour12: true,
minute: '2-digit',
second: '2-digit',
}"
/> -->

<Calendar label="Calendar" :value="value" readonly />
<DateField label="Hijri Date" :value="new Date('2025-02-11')" :calendar="calendar" locale="ar-EG" />
</div>
</template>
2 changes: 2 additions & 0 deletions packages/playground/src/components/DateField.vue
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ const { pickerProps, pickerTriggerProps } = usePicker({
</template>

<style scoped lang="postcss">
@reference "../style.css";
.InputDate {
font-family: 'Monaspace Neon Var';
@apply relative w-full;
Expand Down

0 comments on commit f68dacb

Please sign in to comment.