added support classes #73
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Added additional classes to be able to implement rounding of the date selection range.

The following styles had to be applied for this case:
.mx-calendar {
.cell.in-range + .cell.active.active-end,
.cell.hovered ~ .cell.active.active-start:has(+ :not(.cell.in-range):not(.cell.active-end)),
.cell.active-start ~ .cell.hover-in-range + .cell.hovered,
.cell.active-start + .cell.hovered,
.cell.hover-in-range + .cell.hovered,
.cell.hover-in-range.range-invert + .cell.active.active-start,
.cell.active-start + .cell.active-end,
.mx-date-row:has(+ .mx-date-row .cell:first-child:not(.cell.in-range):not(.cell.active-end)) .cell.hovered + .cell.active.active-start:last-of-type,
.mx-date-row:has(.cell.hovered + .cell.active-start:last-child) + .mx-date-row:has(+ .cell.active-end),
.mx-date-row:has(.hover-in-range:last-of-type) + .mx-date-row .cell.hovered,
.mx-date-row:has(.cell.active-start:last-of-type) + .mx-date-row .cell.hovered:first-of-type,
.mx-date-row:has(.cell.hovered:last-of-type) ~ .mx-date-row .cell.active-start:has(+ .cell:not(.cell.in-range):not(.cell.active-end)),
.mx-date-row:has(.cell.hovered ~ .cell.hover-in-range:last-of-type) ~ .mx-date-row .cell.active-start:has(+ .cell:not(.cell.in-range):not(.cell.active-end)),
.mx-date-row:has(.in-range:last-of-type) + .mx-date-row .cell.active-end,
.mx-date-row:has(.cell.active-start:last-of-type) + .mx-date-row .cell.active-end {
@apply rounded-l-none;
}
}
.mx-calendar {
.cell.active-start:has(+ .cell.in-range),
.cell.active-start:has(~ .cell.hovered),
.cell.hovered:has(~ .cell.hover-in-range + .cell.active-start),
.cell.hovered:has(+ .cell.active-start + .cell:not(.cell.in-range):not(.cell.active-end)),
.cell.active.active-start:has(~ .cell.hover-in-range + .cell.hover-in-range),
.cell.hovered:has(+ .cell.hover-in-range.range-invert),
.cell.active-start:has(+ .cell.active-end),
.mx-date-row:has(+ .mx-date-row .cell:first-child:not(.cell.in-range):not(.cell.active-end)) .cell.hovered:has(+ .cell.active-start:last-of-type),
.mx-date-row:has(+ .mx-date-row .hover-in-range.range-invert) .cell.hovered,
.mx-date-row:has(+ .mx-date-row .in-range) .cell.active-start,
.mx-date-row:has(+ .mx-date-row .hover-in-range) .cell.active-start,
.mx-date-row:has(+ .mx-date-row .hovered) .cell.active-start,
.mx-date-row:has(+ .mx-date-row .active-start + .cell:not(.cell.in-range):not(.cell.active-end)) .cell.hovered,
.mx-date-row:has(+ .mx-date-row .cell.active-end) .cell.active-start {
@apply rounded-r-none;
}
}
.mx-calendar {
.cell.hover-in-range:has(+ .cell.disabled) {
@apply rounded-r-5xl;
}
}
You might want to add more classes or rename them somehow, but the idea was to be able to round at different states.