@dereekb/dbx-form 9.23.27 → 9.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/calendar/lib/field/schedule/calendar.schedule.field.component.d.ts +2 -2
- package/esm2020/calendar/lib/calendar.schedule.selection.days.component.mjs +1 -1
- package/esm2020/calendar/lib/calendar.schedule.selection.popover.content.component.mjs +1 -1
- package/esm2020/calendar/lib/calendar.schedule.selection.range.component.mjs +1 -1
- package/esm2020/calendar/lib/calendar.schedule.selection.store.mjs +8 -8
- package/esm2020/calendar/lib/field/schedule/calendar.schedule.field.component.mjs +1 -1
- package/esm2020/lib/form/action/form.action.directive.mjs +11 -4
- package/esm2020/lib/formly/field/selection/pickable/pickable.field.mjs +1 -1
- package/esm2020/lib/formly/field/selection/pickable/pickable.util.mjs +1 -1
- package/esm2020/lib/formly/field/selection/selection.mjs +1 -1
- package/esm2020/lib/formly/field/value/date/date.field.module.mjs +18 -6
- package/esm2020/lib/formly/field/value/date/date.value.mjs +73 -0
- package/esm2020/lib/formly/field/value/date/datetime.field.component.mjs +61 -107
- package/esm2020/lib/formly/field/value/date/datetime.field.mjs +31 -4
- package/esm2020/lib/formly/field/value/date/datetime.field.service.mjs +31 -0
- package/esm2020/lib/formly/field/value/date/datetime.mjs +26 -0
- package/esm2020/lib/formly/field/value/date/datetime.preset.mjs +31 -0
- package/esm2020/lib/formly/field/value/date/fixeddaterange.field.component.mjs +451 -0
- package/esm2020/lib/formly/field/value/date/index.mjs +5 -1
- package/esm2020/lib/formly/template/login.mjs +1 -1
- package/esm2020/mapbox/lib/field/latlng/latlng.field.component.mjs +1 -1
- package/fesm2015/dereekb-dbx-form-calendar.mjs +8 -8
- package/fesm2015/dereekb-dbx-form-calendar.mjs.map +1 -1
- package/fesm2015/dereekb-dbx-form-mapbox.mjs.map +1 -1
- package/fesm2015/dereekb-dbx-form.mjs +648 -67
- package/fesm2015/dereekb-dbx-form.mjs.map +1 -1
- package/fesm2020/dereekb-dbx-form-calendar.mjs +8 -8
- package/fesm2020/dereekb-dbx-form-calendar.mjs.map +1 -1
- package/fesm2020/dereekb-dbx-form-mapbox.mjs.map +1 -1
- package/fesm2020/dereekb-dbx-form.mjs +644 -61
- package/fesm2020/dereekb-dbx-form.mjs.map +1 -1
- package/lib/form/action/form.action.directive.d.ts +13 -7
- package/lib/formly/field/selection/pickable/pickable.util.d.ts +1 -2
- package/lib/formly/field/value/date/_date.scss +29 -0
- package/lib/formly/field/value/date/date.field.module.d.ts +18 -17
- package/lib/formly/field/value/date/date.value.d.ts +20 -0
- package/lib/formly/field/value/date/datetime.d.ts +56 -0
- package/lib/formly/field/value/date/datetime.field.component.d.ts +31 -27
- package/lib/formly/field/value/date/datetime.field.d.ts +8 -4
- package/lib/formly/field/value/date/datetime.field.service.d.ts +15 -0
- package/lib/formly/field/value/date/datetime.preset.d.ts +2 -0
- package/lib/formly/field/value/date/fixeddaterange.field.component.d.ts +154 -0
- package/lib/formly/field/value/date/index.d.ts +4 -0
- package/mapbox/esm2020/lib/field/latlng/latlng.field.component.mjs +1 -1
- package/mapbox/fesm2015/dereekb-dbx-form-mapbox.mjs.map +1 -1
- package/mapbox/fesm2020/dereekb-dbx-form-mapbox.mjs.map +1 -1
- package/mapbox/package.json +4 -4
- package/package.json +4 -4
|
@@ -176,10 +176,10 @@ class DbxCalendarScheduleSelectionStore extends ComponentStore {
|
|
|
176
176
|
this.nextToggleSelection$ = this.hasConfiguredMinMaxRange$.pipe(switchMap((hasConfiguredMinMaxRange) => {
|
|
177
177
|
let obs;
|
|
178
178
|
if (hasConfiguredMinMaxRange) {
|
|
179
|
-
obs = this.currentSelectionValue$.pipe(map((x) => (
|
|
179
|
+
obs = this.currentSelectionValue$.pipe(map((x) => (x ? 'none' : 'all')));
|
|
180
180
|
}
|
|
181
181
|
else {
|
|
182
|
-
obs = this.currentSelectionValue$.pipe(map((x) => (
|
|
182
|
+
obs = this.currentSelectionValue$.pipe(map((x) => (x ? 'none' : undefined)));
|
|
183
183
|
}
|
|
184
184
|
return obs;
|
|
185
185
|
}), shareReplay(1));
|
|
@@ -277,7 +277,7 @@ function updateStateWithFilter(state, inputFilter) {
|
|
|
277
277
|
}
|
|
278
278
|
if (minMaxDateRange) {
|
|
279
279
|
enabledFilter.minMaxDateRange = minMaxDateRange;
|
|
280
|
-
enabledFilter.setStartAsMinDate =
|
|
280
|
+
enabledFilter.setStartAsMinDate = filter?.start ? true : false; // If a start date is set, then it becomes the floor.
|
|
281
281
|
}
|
|
282
282
|
/**
|
|
283
283
|
* If the input filter has a start date, use that as the relative start to ensure indexes are compared the same,
|
|
@@ -327,7 +327,7 @@ function updateStateWithTimezoneValue(state, timezone) {
|
|
|
327
327
|
}
|
|
328
328
|
function updateStateWithDateScheduleRangeValue(state, change) {
|
|
329
329
|
const { timezoneNormal, currentSelectionValue } = state;
|
|
330
|
-
|
|
330
|
+
const currentDateScheduleRange = currentSelectionValue?.dateScheduleRange; // current range is always in system time
|
|
331
331
|
if (!calendarScheduleStartBeingUsedFromFilter(state) && timezoneNormal) {
|
|
332
332
|
// When using timezones, always return from the start of the day. Inputs are converted to the system time and used as the start of the day.
|
|
333
333
|
// Outputs remain accurate.
|
|
@@ -373,7 +373,7 @@ function updateStateWithChangedDates(state, change) {
|
|
|
373
373
|
let selectedIndexes;
|
|
374
374
|
if (change.reset || change.selectAll != null || change.set) {
|
|
375
375
|
let set = change.set ?? [];
|
|
376
|
-
|
|
376
|
+
const selectAll = change.reset === true ? state.initialSelectionState : change.selectAll;
|
|
377
377
|
switch (selectAll) {
|
|
378
378
|
case 'all':
|
|
379
379
|
if (minDate != null && maxDate != null) {
|
|
@@ -423,8 +423,8 @@ function noSelectionCalendarScheduleSelectionState(state) {
|
|
|
423
423
|
function updateStateWithChangedRange(state, change) {
|
|
424
424
|
const { inputStart: currentInputStart, inputEnd: currentInputEnd, indexFactory, minMaxDateRange } = state;
|
|
425
425
|
const { start: minDate, end: maxDate } = minMaxDateRange ?? {};
|
|
426
|
-
|
|
427
|
-
|
|
426
|
+
const inputStart = startOfDay(change.inputStart);
|
|
427
|
+
const inputEnd = endOfDay(change.inputEnd);
|
|
428
428
|
const isValidRange = minDate != null || maxDate != null ? isDateInDateRangeFunction({ start: minDate ?? undefined, end: maxDate ?? undefined }) : () => true;
|
|
429
429
|
if (!isValidRange(inputStart) || !isValidRange(inputEnd) || (isSameDateDay(inputStart, currentInputStart) && isSameDateDay(inputEnd, currentInputEnd))) {
|
|
430
430
|
return state; // if no change, return the current state.
|
|
@@ -807,7 +807,7 @@ DbxScheduleSelectionCalendarDateDaysComponent.ɵcmp = i0.ɵɵngDeclareComponent(
|
|
|
807
807
|
<div class="dbx-schedule-selection-calendar-date-days" dbxAction dbxActionAutoTrigger dbxActionEnforceModified [instantTrigger]="true" [dbxActionHandler]="updateScheduleDays">
|
|
808
808
|
<dbx-schedule-selection-calendar-date-days-form dbxActionForm [dbxFormSource]="template$" [dbxActionFormModified]="isFormModified"></dbx-schedule-selection-calendar-date-days-form>
|
|
809
809
|
</div>
|
|
810
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i3$1.DbxActionDirective, selector: "dbx-action,[dbxAction],dbx-action-context,[dbxActionContext]", exportAs: ["action", "dbxAction"] }, { kind: "directive", type: i3$1.DbxActionHandlerDirective, selector: "[dbxActionHandler]", inputs: ["dbxActionHandler"] }, { kind: "directive", type: i3$1.DbxActionEnforceModifiedDirective, selector: "[dbxActionEnforceModified]", inputs: ["dbxActionEnforceModified"] }, { kind: "directive", type: i3$1.DbxActionAutoTriggerDirective, selector: "dbxActionAutoTrigger, [dbxActionAutoTrigger]", inputs: ["dbxActionAutoTrigger", "triggerDebounce", "triggerThrottle", "triggerErrorThrottle", "fastTrigger", "instantTrigger", "triggerLimit"] }, { kind: "directive", type: i4$1.DbxActionFormDirective, selector: "[dbxActionForm]", inputs: ["dbxActionFormValidator", "dbxActionFormModified", "formDisabledOnWorking"] }, { kind: "directive", type: i4$1.DbxFormSourceDirective, selector: "[dbxFormSource]", inputs: ["dbxFormSourceMode", "dbxFormSource"] }, { kind: "component", type: DbxScheduleSelectionCalendarDateDaysFormComponent, selector: "dbx-schedule-selection-calendar-date-days-form" }] });
|
|
810
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i3$1.DbxActionDirective, selector: "dbx-action,[dbxAction],dbx-action-context,[dbxActionContext]", exportAs: ["action", "dbxAction"] }, { kind: "directive", type: i3$1.DbxActionHandlerDirective, selector: "[dbxActionHandler]", inputs: ["dbxActionHandler"] }, { kind: "directive", type: i3$1.DbxActionEnforceModifiedDirective, selector: "[dbxActionEnforceModified]", inputs: ["dbxActionEnforceModified"] }, { kind: "directive", type: i3$1.DbxActionAutoTriggerDirective, selector: "dbxActionAutoTrigger, [dbxActionAutoTrigger]", inputs: ["dbxActionAutoTrigger", "triggerDebounce", "triggerThrottle", "triggerErrorThrottle", "fastTrigger", "instantTrigger", "triggerLimit"] }, { kind: "directive", type: i4$1.DbxActionFormDirective, selector: "[dbxActionForm]", inputs: ["dbxActionFormValidator", "dbxActionFormModified", "dbxActionFormMapValue", "formDisabledOnWorking"] }, { kind: "directive", type: i4$1.DbxFormSourceDirective, selector: "[dbxFormSource]", inputs: ["dbxFormSourceMode", "dbxFormSource"] }, { kind: "component", type: DbxScheduleSelectionCalendarDateDaysFormComponent, selector: "dbx-schedule-selection-calendar-date-days-form" }] });
|
|
811
811
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DbxScheduleSelectionCalendarDateDaysComponent, decorators: [{
|
|
812
812
|
type: Component,
|
|
813
813
|
args: [{
|