Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
5744cd9
feat: add input segments
paulodetarsofm Jul 18, 2023
67b445a
refactor: input segments improvements
paulodetarsofm Jul 18, 2023
4032e7f
fix(textfield): convert pseudo :read-only to attribute
paulodetarsofm Jul 18, 2023
bcd9d71
feat(time-field): add new time field component
paulodetarsofm Jul 18, 2023
107c0b4
refactor: remove `_` from private properties and methods and convert …
paulodetarsofm Jul 19, 2023
018b50b
refactor: add new `@internationalized/number` package
paulodetarsofm Jul 20, 2023
03a31dd
refactor: reduce cognitive complexity for `handleTypedValue()` method
paulodetarsofm Jul 20, 2023
50a3b74
refactor: reduce cognitive complexity for `handleClear()` method
paulodetarsofm Jul 20, 2023
6997981
refactor: reduce cognitive complexity for `setNewDateTime()` method
paulodetarsofm Jul 20, 2023
e3f1587
refactor: add correct placeholder for year
paulodetarsofm Jul 20, 2023
a23f778
refactor: reduce cognitive complexity for `getSegmentValueAndLimits()…
paulodetarsofm Jul 21, 2023
ebe93c3
refactor: reduce cognitive complexity for `updateHour()` method
paulodetarsofm Jul 21, 2023
7dca5fc
refactor: add missing comments and minor code improvements
paulodetarsofm Jul 21, 2023
d8cfe99
refactor: preserve white spaces inside literal segments
paulodetarsofm Jul 21, 2023
ba56c75
refactor: add types to variables
paulodetarsofm Jul 21, 2023
a9303e1
refactor: formatting year
paulodetarsofm Jul 21, 2023
1dc517b
refactor: increment/decrement year when is `undefined`
paulodetarsofm Jul 21, 2023
f4ad083
feat: add logic to update day if needed
paulodetarsofm Jul 24, 2023
5e07468
fix: improve logic to update the day
paulodetarsofm Jul 24, 2023
81755e6
fix: package version
paulodetarsofm Jul 24, 2023
f93dd8e
fix: add missing references
paulodetarsofm Jul 24, 2023
4e9e085
refactor: maintain alphabetical order
paulodetarsofm Jul 24, 2023
85a3aa8
fix: duplicate identifier 'ClassInfo'
paulodetarsofm Aug 1, 2023
a88a69a
refactor: upgrade `@internationalized/date` package version used by t…
paulodetarsofm Aug 1, 2023
dcf80b9
refactor: minor code improvements and comments
paulodetarsofm Aug 1, 2023
9dc01f6
refactor: add new items to to-do list
paulodetarsofm Aug 15, 2023
bd8163e
refactor: add missing "time-field" entry
paulodetarsofm Aug 15, 2023
e54ffba
refactor: update packages version
paulodetarsofm Aug 15, 2023
52b91a5
refactor: use `import type` when possible
paulodetarsofm Aug 15, 2023
6987ce6
refactor: remove unnecessary configuration
paulodetarsofm Aug 15, 2023
1255d42
refactor: remove unnecessary code
paulodetarsofm Aug 15, 2023
9a65a6a
refactor: code and comments improvements
paulodetarsofm Aug 16, 2023
72fbfff
refactor: remove unused files
paulodetarsofm Aug 16, 2023
7afa951
refactor: update `@spectrum-css/calendar`
paulodetarsofm Aug 16, 2023
de22124
refactor: move `input-segments` from `/packages` to `/tools`
paulodetarsofm Aug 16, 2023
6b74960
fix: segment text colour
paulodetarsofm Aug 16, 2023
8eabd8e
refactor(calendar): remove unnecessary code
paulodetarsofm Aug 16, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/calendar/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,5 @@ import { Calendar } from '@spectrum-web-components/calendar';
- Implement keyboard navigation
- Add support for other types of calendars - [React Calendar: International Calendars](https://react-spectrum.adobe.com/react-spectrum/Calendar.html#international-calendars)
- Include `aria-label` in calendar for accessibility - [React Calendar: Labeling](https://react-spectrum.adobe.com/react-spectrum/Calendar.html#labeling)
- Complete documentation
- Add/Review unit tests
4 changes: 2 additions & 2 deletions packages/calendar/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@
"lit-html"
],
"dependencies": {
"@internationalized/date": "^3.2.0",
"@internationalized/date": "^3.2.1",
"@internationalized/number": "^3.1.0",
"@spectrum-web-components/action-button": "^0.35.0",
"@spectrum-web-components/base": "^0.35.0",
"@spectrum-web-components/icons-workflow": "^0.35.0",
"@spectrum-web-components/reactive-controllers": "^0.35.0"
},
"devDependencies": {
"@spectrum-css/calendar": "^3.2.6"
"@spectrum-css/calendar": "^4.0.3"
},
"types": "./src/index.d.ts",
"customElements": "custom-elements.json",
Expand Down
7 changes: 2 additions & 5 deletions packages/calendar/src/Calendar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import { NumberFormatter } from '@internationalized/number';
import {
CSSResultArray,
html,
PropertyValueMap,
PropertyValues,
SpectrumElement,
TemplateResult,
} from '@spectrum-web-components/base';
Expand Down Expand Up @@ -121,9 +121,7 @@ export class Calendar extends SpectrumElement {
this.setInitialCalendarDate();
}

protected override willUpdate(
changedProperties: PropertyValueMap<this>
): void {
protected override willUpdate(changedProperties: PropertyValues): void {
if (changedProperties.has('selectedDate')) {
this.setCurrentCalendarDate();
}
Expand Down Expand Up @@ -339,7 +337,6 @@ export class Calendar extends SpectrumElement {

public handleDayClick(calendarDate: CalendarDate): void {
this.selectedDate = calendarDate.toDate(this.timeZone);
this.setCurrentCalendarDate();

this.dispatchEvent(
new CustomEvent('change', {
Expand Down
Loading