@dereekb/dbx-form 11.1.8 → 12.0.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/calendar.module.d.ts +1 -14
- package/calendar/lib/calendar.schedule.selection.cell.component.d.ts +8 -5
- package/calendar/lib/calendar.schedule.selection.component.d.ts +13 -10
- package/calendar/lib/calendar.schedule.selection.d.ts +6 -6
- package/calendar/lib/calendar.schedule.selection.days.component.d.ts +1 -1
- package/calendar/lib/calendar.schedule.selection.days.form.component.d.ts +1 -1
- package/calendar/lib/calendar.schedule.selection.dialog.button.component.d.ts +4 -4
- package/calendar/lib/calendar.schedule.selection.dialog.component.d.ts +5 -5
- package/calendar/lib/calendar.schedule.selection.popover.button.component.d.ts +4 -2
- package/calendar/lib/calendar.schedule.selection.popover.component.d.ts +1 -1
- package/calendar/lib/calendar.schedule.selection.popover.content.component.d.ts +1 -1
- package/calendar/lib/calendar.schedule.selection.range.component.d.ts +19 -17
- package/calendar/lib/calendar.schedule.selection.store.d.ts +2 -2
- package/calendar/lib/calendar.schedule.selection.store.provide.d.ts +1 -1
- package/calendar/lib/calendar.schedule.selection.toggle.button.component.d.ts +8 -12
- package/calendar/lib/field/schedule/calendar.schedule.field.component.d.ts +22 -22
- package/calendar/lib/field/schedule/calendar.schedule.module.d.ts +2 -10
- package/esm2022/calendar/lib/calendar.module.mjs +19 -101
- package/esm2022/calendar/lib/calendar.schedule.selection.cell.component.mjs +27 -28
- package/esm2022/calendar/lib/calendar.schedule.selection.component.mjs +38 -55
- package/esm2022/calendar/lib/calendar.schedule.selection.days.component.mjs +17 -13
- package/esm2022/calendar/lib/calendar.schedule.selection.days.form.component.mjs +11 -12
- package/esm2022/calendar/lib/calendar.schedule.selection.dialog.button.component.mjs +18 -21
- package/esm2022/calendar/lib/calendar.schedule.selection.dialog.component.mjs +12 -9
- package/esm2022/calendar/lib/calendar.schedule.selection.mjs +3 -2
- package/esm2022/calendar/lib/calendar.schedule.selection.popover.button.component.mjs +22 -18
- package/esm2022/calendar/lib/calendar.schedule.selection.popover.component.mjs +12 -9
- package/esm2022/calendar/lib/calendar.schedule.selection.popover.content.component.mjs +13 -10
- package/esm2022/calendar/lib/calendar.schedule.selection.range.component.mjs +52 -70
- package/esm2022/calendar/lib/calendar.schedule.selection.store.mjs +5 -5
- package/esm2022/calendar/lib/calendar.schedule.selection.store.provide.mjs +9 -8
- package/esm2022/calendar/lib/calendar.schedule.selection.toggle.button.component.mjs +48 -50
- package/esm2022/calendar/lib/field/schedule/calendar.schedule.field.component.mjs +17 -14
- package/esm2022/calendar/lib/field/schedule/calendar.schedule.module.mjs +8 -40
- package/esm2022/lib/form/action/form.action.directive.mjs +58 -55
- package/esm2022/lib/form/action/form.action.module.mjs +9 -9
- package/esm2022/lib/form/action/transition/form.action.transition.module.mjs +9 -8
- package/esm2022/lib/form/action/transition/form.action.transition.safety.directive.mjs +14 -11
- package/esm2022/lib/form/form.mjs +1 -1
- package/esm2022/lib/form/form.module.mjs +4 -4
- package/esm2022/lib/form/io/form.changes.directive.mjs +11 -16
- package/esm2022/lib/form/io/form.input.directive.mjs +24 -38
- package/esm2022/lib/form/io/form.io.module.mjs +15 -9
- package/esm2022/lib/form/io/form.loading.directive.mjs +22 -42
- package/esm2022/lib/form.module.mjs +4 -4
- package/esm2022/lib/form.providers.mjs +32 -0
- package/esm2022/lib/formly/field/checklist/checklist.field.mjs +5 -5
- package/esm2022/lib/formly/field/checklist/checklist.item.field.component.mjs +51 -47
- package/esm2022/lib/formly/field/checklist/checklist.item.field.content.default.component.mjs +41 -29
- package/esm2022/lib/formly/field/checklist/checklist.item.field.mjs +3 -3
- package/esm2022/lib/formly/field/checklist/checklist.item.field.module.mjs +8 -45
- package/esm2022/lib/formly/field/checklist/checklist.item.mjs +1 -1
- package/esm2022/lib/formly/field/component/component.field.component.mjs +11 -8
- package/esm2022/lib/formly/field/component/component.field.module.mjs +8 -14
- package/esm2022/lib/formly/field/field.mjs +1 -1
- package/esm2022/lib/formly/field/form.field.module.mjs +4 -4
- package/esm2022/lib/formly/field/selection/list/list.field.component.mjs +17 -14
- package/esm2022/lib/formly/field/selection/list/list.field.module.mjs +8 -58
- package/esm2022/lib/formly/field/selection/pickable/pickable.chip.field.component.mjs +17 -13
- package/esm2022/lib/formly/field/selection/pickable/pickable.field.directive.mjs +16 -16
- package/esm2022/lib/formly/field/selection/pickable/pickable.field.module.mjs +8 -68
- package/esm2022/lib/formly/field/selection/pickable/pickable.list.field.component.mjs +71 -54
- package/esm2022/lib/formly/field/selection/pickable/pickable.util.mjs +2 -2
- package/esm2022/lib/formly/field/selection/searchable/searchable.chip.field.component.mjs +21 -16
- package/esm2022/lib/formly/field/selection/searchable/searchable.field.autocomplete.item.component.mjs +51 -49
- package/esm2022/lib/formly/field/selection/searchable/searchable.field.directive.mjs +35 -27
- package/esm2022/lib/formly/field/selection/searchable/searchable.field.mjs +1 -1
- package/esm2022/lib/formly/field/selection/searchable/searchable.field.module.mjs +8 -65
- package/esm2022/lib/formly/field/selection/searchable/searchable.mjs +1 -1
- package/esm2022/lib/formly/field/selection/searchable/searchable.text.field.component.mjs +48 -30
- package/esm2022/lib/formly/field/selection/searchable/text.chip.field.mjs +2 -2
- package/esm2022/lib/formly/field/selection/selection.field.mjs +1 -1
- package/esm2022/lib/formly/field/selection/selection.mjs +1 -1
- package/esm2022/lib/formly/field/selection/selection.module.mjs +4 -4
- package/esm2022/lib/formly/field/selection/sourceselect/sourceselect.field.component.mjs +20 -21
- package/esm2022/lib/formly/field/selection/sourceselect/sourceselect.field.module.mjs +6 -73
- package/esm2022/lib/formly/field/selection/sourceselect/sourceselect.mjs +1 -1
- package/esm2022/lib/formly/field/texteditor/texteditor.field.component.mjs +37 -22
- package/esm2022/lib/formly/field/texteditor/texteditor.field.mjs +2 -2
- package/esm2022/lib/formly/field/texteditor/texteditor.field.module.mjs +8 -33
- package/esm2022/lib/formly/field/value/array/array.field.component.mjs +72 -50
- package/esm2022/lib/formly/field/value/array/array.field.module.mjs +8 -44
- package/esm2022/lib/formly/field/value/boolean/boolean.field.mjs +2 -2
- package/esm2022/lib/formly/field/value/boolean/boolean.field.module.mjs +4 -4
- package/esm2022/lib/formly/field/value/date/date.field.module.mjs +5 -9
- package/esm2022/lib/formly/field/value/date/date.value.mjs +1 -1
- package/esm2022/lib/formly/field/value/date/datetime.field.component.mjs +8 -8
- package/esm2022/lib/formly/field/value/date/datetime.field.service.mjs +4 -4
- package/esm2022/lib/formly/field/value/date/datetime.mjs +1 -1
- package/esm2022/lib/formly/field/value/date/fixeddaterange.field.component.mjs +8 -8
- package/esm2022/lib/formly/field/value/number/number.field.mjs +1 -1
- package/esm2022/lib/formly/field/value/number/number.field.module.mjs +4 -4
- package/esm2022/lib/formly/field/value/phone/phone.field.component.mjs +4 -4
- package/esm2022/lib/formly/field/value/phone/phone.field.module.mjs +4 -4
- package/esm2022/lib/formly/field/value/text/text.address.field.mjs +1 -1
- package/esm2022/lib/formly/field/value/text/text.field.mjs +1 -1
- package/esm2022/lib/formly/field/value/text/text.field.module.mjs +4 -4
- package/esm2022/lib/formly/field/value/value.module.mjs +4 -4
- package/esm2022/lib/formly/field/wrapper/autotouch.wrapper.component.mjs +9 -7
- package/esm2022/lib/formly/field/wrapper/expand.wrapper.component.mjs +19 -24
- package/esm2022/lib/formly/field/wrapper/expand.wrapper.delegate.mjs +7 -4
- package/esm2022/lib/formly/field/wrapper/flex.wrapper.component.mjs +11 -8
- package/esm2022/lib/formly/field/wrapper/form.wrapper.module.mjs +8 -39
- package/esm2022/lib/formly/field/wrapper/index.mjs +2 -1
- package/esm2022/lib/formly/field/wrapper/info.wrapper.component.mjs +19 -16
- package/esm2022/lib/formly/field/wrapper/section.wrapper.component.mjs +11 -7
- package/esm2022/lib/formly/field/wrapper/style.wrapper.component.mjs +16 -11
- package/esm2022/lib/formly/field/wrapper/subsection.wrapper.component.mjs +11 -8
- package/esm2022/lib/formly/field/wrapper/toggle.wrapper.component.mjs +21 -17
- package/esm2022/lib/formly/field/wrapper/working.wrapper.component.mjs +11 -8
- package/esm2022/lib/formly/field/wrapper/wrapper.mjs +1 -1
- package/esm2022/lib/formly/form/form.form.module.mjs +4 -4
- package/esm2022/lib/formly/form/search.form.component.mjs +4 -4
- package/esm2022/lib/formly/formly.component.template.mjs +29 -0
- package/esm2022/lib/formly/formly.context.directive.mjs +6 -5
- package/esm2022/lib/formly/formly.context.mjs +12 -8
- package/esm2022/lib/formly/formly.directive.mjs +29 -44
- package/esm2022/lib/formly/formly.form.component.mjs +24 -18
- package/esm2022/lib/formly/formly.module.mjs +10 -14
- package/esm2022/lib/formly/index.mjs +2 -1
- package/esm2022/lib/formly/template/login.mjs +1 -1
- package/esm2022/lib/formly/template/timezone.mjs +1 -1
- package/esm2022/lib/index.mjs +2 -1
- package/esm2022/lib/layout/form.layout.module.mjs +4 -4
- package/esm2022/lib/layout/form.spacer.component.mjs +3 -3
- package/esm2022/lib/validator/available.mjs +1 -1
- package/esm2022/lib/validator/boolean.mjs +1 -1
- package/esm2022/lib/validator/field.mjs +2 -2
- package/esm2022/lib/validator/number.mjs +1 -1
- package/esm2022/lib/validator/phone.mjs +1 -1
- package/esm2022/mapbox/lib/field/latlng/latlng.field.component.mjs +65 -47
- package/esm2022/mapbox/lib/field/latlng/latlng.field.marker.component.mjs +13 -10
- package/esm2022/mapbox/lib/field/latlng/latlng.module.mjs +10 -43
- package/esm2022/mapbox/lib/field/zoom/zoom.field.component.mjs +32 -26
- package/esm2022/mapbox/lib/field/zoom/zoom.module.mjs +8 -36
- package/esm2022/mapbox/lib/mapbox.module.mjs +4 -4
- package/fesm2022/dereekb-dbx-form-calendar.mjs +340 -457
- package/fesm2022/dereekb-dbx-form-calendar.mjs.map +1 -1
- package/fesm2022/dereekb-dbx-form-mapbox.mjs +114 -141
- package/fesm2022/dereekb-dbx-form-mapbox.mjs.map +1 -1
- package/fesm2022/dereekb-dbx-form.mjs +935 -1106
- package/fesm2022/dereekb-dbx-form.mjs.map +1 -1
- package/lib/extension/calendar/_calendar.scss +3 -3
- package/lib/form/_form.scss +3 -3
- package/lib/form/action/form.action.directive.d.ts +35 -16
- package/lib/form/action/form.action.module.d.ts +4 -3
- package/lib/form/action/transition/form.action.transition.module.d.ts +4 -2
- package/lib/form/action/transition/form.action.transition.safety.directive.d.ts +4 -2
- package/lib/form/io/form.changes.directive.d.ts +3 -4
- package/lib/form/io/form.input.directive.d.ts +7 -10
- package/lib/form/io/form.io.module.d.ts +8 -2
- package/lib/form/io/form.loading.directive.d.ts +10 -11
- package/lib/form.providers.d.ts +8 -0
- package/lib/formly/_formly.scss +3 -3
- package/lib/formly/field/checklist/_checklist.scss +3 -3
- package/lib/formly/field/checklist/checklist.field.d.ts +7 -7
- package/lib/formly/field/checklist/checklist.item.d.ts +7 -9
- package/lib/formly/field/checklist/checklist.item.field.component.d.ts +19 -18
- package/lib/formly/field/checklist/checklist.item.field.content.default.component.d.ts +5 -5
- package/lib/formly/field/checklist/checklist.item.field.d.ts +1 -1
- package/lib/formly/field/checklist/checklist.item.field.module.d.ts +3 -11
- package/lib/formly/field/component/_component.scss +3 -3
- package/lib/formly/field/component/component.field.component.d.ts +1 -1
- package/lib/formly/field/component/component.field.module.d.ts +2 -4
- package/lib/formly/field/field.d.ts +8 -5
- package/lib/formly/field/selection/list/_list.scss +3 -3
- package/lib/formly/field/selection/list/list.field.component.d.ts +7 -5
- package/lib/formly/field/selection/list/list.field.module.d.ts +2 -12
- package/lib/formly/field/selection/pickable/_pickable.scss +3 -3
- package/lib/formly/field/selection/pickable/pickable.chip.field.component.d.ts +1 -1
- package/lib/formly/field/selection/pickable/pickable.field.directive.d.ts +25 -23
- package/lib/formly/field/selection/pickable/pickable.field.module.d.ts +2 -13
- package/lib/formly/field/selection/pickable/pickable.list.field.component.d.ts +15 -14
- package/lib/formly/field/selection/searchable/_searchable.scss +3 -3
- package/lib/formly/field/selection/searchable/searchable.chip.field.component.d.ts +4 -4
- package/lib/formly/field/selection/searchable/searchable.d.ts +3 -3
- package/lib/formly/field/selection/searchable/searchable.field.autocomplete.item.component.d.ts +8 -12
- package/lib/formly/field/selection/searchable/searchable.field.directive.d.ts +30 -25
- package/lib/formly/field/selection/searchable/searchable.field.module.d.ts +2 -13
- package/lib/formly/field/selection/searchable/searchable.text.field.component.d.ts +6 -8
- package/lib/formly/field/selection/selection.d.ts +5 -5
- package/lib/formly/field/selection/sourceselect/_sourceselect.scss +3 -3
- package/lib/formly/field/selection/sourceselect/sourceselect.d.ts +1 -1
- package/lib/formly/field/selection/sourceselect/sourceselect.field.component.d.ts +5 -3
- package/lib/formly/field/selection/sourceselect/sourceselect.field.module.d.ts +2 -17
- package/lib/formly/field/texteditor/_texteditor.scss +9 -9
- package/lib/formly/field/texteditor/texteditor.field.component.d.ts +5 -4
- package/lib/formly/field/texteditor/texteditor.field.module.d.ts +2 -8
- package/lib/formly/field/value/array/_array.scss +5 -5
- package/lib/formly/field/value/array/array.field.component.d.ts +16 -18
- package/lib/formly/field/value/array/array.field.d.ts +8 -5
- package/lib/formly/field/value/array/array.field.module.d.ts +2 -10
- package/lib/formly/field/value/boolean/_boolean.scss +3 -3
- package/lib/formly/field/value/date/_date.scss +5 -5
- package/lib/formly/field/value/date/date.field.module.d.ts +8 -9
- package/lib/formly/field/value/date/datetime.field.service.d.ts +1 -1
- package/lib/formly/field/value/date/fixeddaterange.field.component.d.ts +13 -13
- package/lib/formly/field/value/number/_number.scss +2 -2
- package/lib/formly/field/value/phone/_phone.scss +6 -6
- package/lib/formly/field/value/phone/phone.field.component.d.ts +6 -5
- package/lib/formly/field/value/text/_text.scss +3 -3
- package/lib/formly/field/wrapper/_wrapper.scss +3 -3
- package/lib/formly/field/wrapper/autotouch.wrapper.component.d.ts +1 -1
- package/lib/formly/field/wrapper/expand.wrapper.component.d.ts +1 -1
- package/lib/formly/field/wrapper/expand.wrapper.delegate.d.ts +2 -0
- package/lib/formly/field/wrapper/flex.wrapper.component.d.ts +4 -4
- package/lib/formly/field/wrapper/form.wrapper.module.d.ts +2 -8
- package/lib/formly/field/wrapper/index.d.ts +1 -0
- package/lib/formly/field/wrapper/info.wrapper.component.d.ts +2 -2
- package/lib/formly/field/wrapper/section.wrapper.component.d.ts +1 -1
- package/lib/formly/field/wrapper/style.wrapper.component.d.ts +5 -3
- package/lib/formly/field/wrapper/subsection.wrapper.component.d.ts +1 -1
- package/lib/formly/field/wrapper/toggle.wrapper.component.d.ts +2 -1
- package/lib/formly/field/wrapper/working.wrapper.component.d.ts +2 -2
- package/lib/formly/form/_form.scss +3 -3
- package/lib/formly/formly.component.template.d.ts +19 -0
- package/lib/formly/formly.context.d.ts +11 -7
- package/lib/formly/formly.context.directive.d.ts +2 -2
- package/lib/formly/formly.directive.d.ts +10 -10
- package/lib/formly/formly.form.component.d.ts +18 -13
- package/lib/formly/formly.module.d.ts +1 -1
- package/lib/formly/index.d.ts +1 -0
- package/lib/index.d.ts +1 -0
- package/lib/layout/_layout.scss +3 -3
- package/lib/style/_all-typography.scss +1 -1
- package/lib/style/_theming.scss +1 -1
- package/mapbox/lib/field/latlng/latlng.field.component.d.ts +25 -23
- package/mapbox/lib/field/latlng/latlng.field.marker.component.d.ts +2 -1
- package/mapbox/lib/field/latlng/latlng.module.d.ts +2 -11
- package/mapbox/lib/field/zoom/zoom.field.component.d.ts +13 -13
- package/mapbox/lib/field/zoom/zoom.module.d.ts +3 -10
- package/package.json +10 -11
- package/mapbox/esm2022/dereekb-dbx-form-mapbox.mjs +0 -5
- package/mapbox/esm2022/index.mjs +0 -3
- package/mapbox/esm2022/lib/field/index.mjs +0 -3
- package/mapbox/esm2022/lib/field/latlng/index.mjs +0 -5
- package/mapbox/esm2022/lib/field/latlng/latlng.field.component.mjs +0 -244
- package/mapbox/esm2022/lib/field/latlng/latlng.field.marker.component.mjs +0 -31
- package/mapbox/esm2022/lib/field/latlng/latlng.field.mjs +0 -35
- package/mapbox/esm2022/lib/field/latlng/latlng.module.mjs +0 -59
- package/mapbox/esm2022/lib/field/zoom/index.mjs +0 -4
- package/mapbox/esm2022/lib/field/zoom/zoom.field.component.mjs +0 -140
- package/mapbox/esm2022/lib/field/zoom/zoom.field.mjs +0 -23
- package/mapbox/esm2022/lib/field/zoom/zoom.module.mjs +0 -57
- package/mapbox/esm2022/lib/mapbox.module.mjs +0 -16
- package/mapbox/fesm2022/dereekb-dbx-form-mapbox.mjs +0 -566
- package/mapbox/fesm2022/dereekb-dbx-form-mapbox.mjs.map +0 -1
- package/mapbox/package.json +0 -21
|
@@ -1,28 +1,29 @@
|
|
|
1
1
|
import { formlyField, propsAndConfigForFieldConfig, DEFAULT_LAT_LNG_TEXT_FIELD_PLACEHOLDER, validatorsForFieldConfig, DEFAULT_LAT_LNG_TEXT_FIELD_PATTERN_MESSAGE } from '@dereekb/dbx-form';
|
|
2
|
-
import { LAT_LNG_PATTERN, isSameLatLngPoint, isDefaultLatLngPoint, isValidLatLngPoint, latLngStringFunction, latLngPointFunction, latLngPoint } from '@dereekb/util';
|
|
3
|
-
import
|
|
2
|
+
import { LAT_LNG_PATTERN, isSameLatLngPoint, isDefaultLatLngPoint, isValidLatLngPoint, defaultLatLngPoint, latLngStringFunction, latLngPointFunction, latLngPoint } from '@dereekb/util';
|
|
3
|
+
import * as i3 from '@angular/forms';
|
|
4
|
+
import { ReactiveFormsModule, FormsModule } from '@angular/forms';
|
|
5
|
+
import { CompactContextStore, mapCompactModeObs } from '@dereekb/dbx-web';
|
|
4
6
|
import * as i0 from '@angular/core';
|
|
5
|
-
import { inject, Component, ChangeDetectionStrategy,
|
|
7
|
+
import { inject, Component, ChangeDetectionStrategy, Injector, NgModule } from '@angular/core';
|
|
6
8
|
import { FieldType } from '@ngx-formly/material';
|
|
7
9
|
import { combineLatest, map, shareReplay, BehaviorSubject, of, switchMap, startWith, distinctUntilChanged, skipWhile, filter, skip, throttleTime, first } from 'rxjs';
|
|
8
10
|
import { SubscriptionObject, filterMaybe, asObservableFromGetter } from '@dereekb/rxjs';
|
|
9
11
|
import { GeolocationService } from '@ng-web-apis/geolocation';
|
|
10
|
-
import * as
|
|
11
|
-
import { DbxMapboxInjectionStore, DbxMapboxMapStore, provideMapboxStoreIfParentIsUnavailable, DbxMapboxModule, DbxMapboxService, mapboxZoomLevel, MAPBOX_MIN_ZOOM_LEVEL, MAPBOX_MAX_ZOOM_LEVEL } from '@dereekb/dbx-web/mapbox';
|
|
12
|
-
import
|
|
13
|
-
import {
|
|
12
|
+
import * as i3$1 from '@dereekb/dbx-web/mapbox';
|
|
13
|
+
import { DbxMapboxMarkerComponent, DbxMapboxInjectionStore, DbxMapboxMapStore, provideMapboxStoreIfParentIsUnavailable, DbxMapboxModule, DbxMapboxService, mapboxZoomLevel, MAPBOX_MIN_ZOOM_LEVEL, MAPBOX_MAX_ZOOM_LEVEL } from '@dereekb/dbx-web/mapbox';
|
|
14
|
+
import { toSignal } from '@angular/core/rxjs-interop';
|
|
15
|
+
import { NgClass } from '@angular/common';
|
|
16
|
+
import * as i5 from '@angular/material/button';
|
|
17
|
+
import { MatButtonModule } from '@angular/material/button';
|
|
18
|
+
import * as i6 from '@angular/material/form-field';
|
|
19
|
+
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
14
20
|
import * as i2 from '@angular/material/icon';
|
|
15
21
|
import { MatIconModule } from '@angular/material/icon';
|
|
16
|
-
import * as
|
|
17
|
-
import { MatButtonModule } from '@angular/material/button';
|
|
18
|
-
import * as i3$1 from '@angular/forms';
|
|
19
|
-
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
20
|
-
import * as i6 from '@angular/material/input';
|
|
22
|
+
import * as i7 from '@angular/material/input';
|
|
21
23
|
import { MatInputModule } from '@angular/material/input';
|
|
22
|
-
import * as
|
|
23
|
-
import * as i8 from 'ngx-mapbox-gl';
|
|
24
|
+
import * as i4 from 'ngx-mapbox-gl';
|
|
24
25
|
import { NgxMapboxGLModule } from 'ngx-mapbox-gl';
|
|
25
|
-
import * as i1
|
|
26
|
+
import * as i1 from '@ngx-formly/core';
|
|
26
27
|
import { FormlyModule } from '@ngx-formly/core';
|
|
27
28
|
|
|
28
29
|
function mapboxLatLngField(config = {}) {
|
|
@@ -68,18 +69,21 @@ class DbxFormMapboxLatLngFieldMarkerComponent {
|
|
|
68
69
|
return undefined;
|
|
69
70
|
}
|
|
70
71
|
}), shareReplay(1));
|
|
71
|
-
|
|
72
|
-
static
|
|
73
|
-
|
|
74
|
-
|
|
72
|
+
markerSignal = toSignal(this.marker$);
|
|
73
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngFieldMarkerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
74
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: DbxFormMapboxLatLngFieldMarkerComponent, isStandalone: true, selector: "ng-component", ngImport: i0, template: `
|
|
75
|
+
<dbx-mapbox-marker [marker]="markerSignal()"></dbx-mapbox-marker>
|
|
76
|
+
`, isInline: true, dependencies: [{ kind: "component", type: DbxMapboxMarkerComponent, selector: "dbx-mapbox-marker", inputs: ["marker"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
75
77
|
}
|
|
76
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
78
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngFieldMarkerComponent, decorators: [{
|
|
77
79
|
type: Component,
|
|
78
80
|
args: [{
|
|
79
81
|
template: `
|
|
80
|
-
<dbx-mapbox-marker [marker]="
|
|
82
|
+
<dbx-mapbox-marker [marker]="markerSignal()"></dbx-mapbox-marker>
|
|
81
83
|
`,
|
|
82
|
-
|
|
84
|
+
imports: [DbxMapboxMarkerComponent],
|
|
85
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
86
|
+
standalone: true
|
|
83
87
|
}]
|
|
84
88
|
}] });
|
|
85
89
|
|
|
@@ -98,15 +102,7 @@ class DbxFormMapboxLatLngFieldComponent extends FieldType {
|
|
|
98
102
|
compact = inject(CompactContextStore, { optional: true });
|
|
99
103
|
dbxMapboxInjectionStore = inject(DbxMapboxInjectionStore, { optional: true });
|
|
100
104
|
dbxMapboxMapStore = inject(DbxMapboxMapStore);
|
|
101
|
-
ngZone = inject(NgZone);
|
|
102
105
|
injector = inject(Injector);
|
|
103
|
-
_latLngStringFunction;
|
|
104
|
-
_latLngPointFunction;
|
|
105
|
-
compactClass$ = mapCompactModeObs(this.compact?.mode$, {
|
|
106
|
-
compact: 'dbx-mapbox-input-field-compact'
|
|
107
|
-
});
|
|
108
|
-
_useCurrentLocationDisabled = new BehaviorSubject(false);
|
|
109
|
-
useCurrentLocationDisabled$ = this._useCurrentLocationDisabled.asObservable();
|
|
110
106
|
_sub = new SubscriptionObject();
|
|
111
107
|
_geoSub = new SubscriptionObject();
|
|
112
108
|
_centerSub = new SubscriptionObject();
|
|
@@ -114,6 +110,13 @@ class DbxFormMapboxLatLngFieldComponent extends FieldType {
|
|
|
114
110
|
_clickSub = new SubscriptionObject();
|
|
115
111
|
_zoom = new BehaviorSubject(12);
|
|
116
112
|
_markerConfig = new BehaviorSubject(of(DEFAULT_DBX_FORM_MAPBOX_LAT_LNG_MARKER_CONFIG));
|
|
113
|
+
_latLngStringFunction;
|
|
114
|
+
_latLngPointFunction;
|
|
115
|
+
compactClass$ = mapCompactModeObs(this.compact?.mode$, {
|
|
116
|
+
compact: 'dbx-mapbox-input-field-compact'
|
|
117
|
+
}).pipe(filterMaybe());
|
|
118
|
+
_useCurrentLocationDisabled = new BehaviorSubject(false);
|
|
119
|
+
useCurrentLocationDisabled$ = this._useCurrentLocationDisabled.asObservable();
|
|
117
120
|
_formControlObs = new BehaviorSubject(undefined);
|
|
118
121
|
formControl$ = this._formControlObs.pipe(filterMaybe());
|
|
119
122
|
value$ = this.formControl$.pipe(switchMap((control) => control.valueChanges.pipe(startWith(control.value))), shareReplay(1));
|
|
@@ -127,6 +130,9 @@ class DbxFormMapboxLatLngFieldComponent extends FieldType {
|
|
|
127
130
|
skipWhile(isDefaultLatLngPoint), filter(isValidLatLngPoint));
|
|
128
131
|
zoom$ = this._zoom.asObservable();
|
|
129
132
|
markerConfig$ = this._markerConfig.asObservable().pipe(switchMap((x) => x), shareReplay(1));
|
|
133
|
+
useCurrentLocationDisabledSignal = toSignal(this._useCurrentLocationDisabled, { initialValue: false });
|
|
134
|
+
compactClassSignal = toSignal(this.compactClass$, { initialValue: '' });
|
|
135
|
+
latLngSignal = toSignal(this.latLng$, { initialValue: defaultLatLngPoint() });
|
|
130
136
|
get zoom() {
|
|
131
137
|
return Math.min(this.field.props.zoom || 12, 18);
|
|
132
138
|
}
|
|
@@ -197,9 +203,7 @@ class DbxFormMapboxLatLngFieldComponent extends FieldType {
|
|
|
197
203
|
this._sub.subscription = this.dbxMapboxMapStore.center$.subscribe((center) => {
|
|
198
204
|
this.dbxMapboxMapStore.centerGivenMargin$.pipe(first()).subscribe(() => {
|
|
199
205
|
if (!this.isReadonlyOrDisabled) {
|
|
200
|
-
this.
|
|
201
|
-
this.setValue(center);
|
|
202
|
-
});
|
|
206
|
+
this.setValue(center);
|
|
203
207
|
}
|
|
204
208
|
});
|
|
205
209
|
});
|
|
@@ -265,92 +269,80 @@ class DbxFormMapboxLatLngFieldComponent extends FieldType {
|
|
|
265
269
|
this.formControl.markAsTouched();
|
|
266
270
|
this.formControl.markAsDirty();
|
|
267
271
|
}
|
|
268
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
269
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
270
|
-
<div class="dbx-mapbox-input-field" [ngClass]="(
|
|
271
|
-
|
|
272
|
-
<
|
|
273
|
-
<mgl-
|
|
274
|
-
|
|
275
|
-
|
|
272
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngFieldComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
273
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: DbxFormMapboxLatLngFieldComponent, isStandalone: true, selector: "ng-component", providers: [provideMapboxStoreIfParentIsUnavailable()], usesInheritance: true, ngImport: i0, template: `
|
|
274
|
+
<div class="dbx-mapbox-input-field" [ngClass]="compactClassSignal()" [formGroup]="formGroup">
|
|
275
|
+
@if (showMap) {
|
|
276
|
+
<div class="dbx-mapbox-input-field-map">
|
|
277
|
+
<mgl-map dbxMapboxMap>
|
|
278
|
+
<mgl-marker [lngLat]="latLngSignal()" [draggable]="!isReadonlyOrDisabled" (markerDragEnd)="onMarkerDragEnd($event)"></mgl-marker>
|
|
279
|
+
</mgl-map>
|
|
280
|
+
</div>
|
|
281
|
+
}
|
|
276
282
|
<div class="dbx-mapbox-input-field-input">
|
|
277
|
-
|
|
278
|
-
<mat-icon
|
|
279
|
-
|
|
283
|
+
@if (showCenterButton) {
|
|
284
|
+
<button mat-icon-button (click)="flyToMarker()">
|
|
285
|
+
<mat-icon>my_location</mat-icon>
|
|
286
|
+
</button>
|
|
287
|
+
}
|
|
280
288
|
<mat-form-field class="dbx-mapbox-input-field-input-field">
|
|
281
289
|
<mat-label>Coordinates</mat-label>
|
|
282
290
|
<input type="text" matInput [placeholder]="placeholder" [formControl]="formControl" />
|
|
283
|
-
|
|
291
|
+
@if (useCurrentLocationDisabledSignal()) {
|
|
292
|
+
<mat-hint class="dbx-hint dbx-warn">Could not access your current location.</mat-hint>
|
|
293
|
+
}
|
|
284
294
|
</mat-form-field>
|
|
285
295
|
</div>
|
|
286
296
|
</div>
|
|
287
|
-
`, isInline: true, styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"], dependencies: [{ kind: "directive", type:
|
|
297
|
+
`, isInline: true, styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i2.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: DbxMapboxModule }, { kind: "directive", type: i3$1.DbxMapboxMapDirective, selector: "[dbxMapboxMap]" }, { kind: "component", type: i4.MapComponent, selector: "mgl-map", inputs: ["accessToken", "collectResourceTiming", "crossSourceCollisions", "customMapboxApiUrl", "fadeDuration", "hash", "refreshExpiredTiles", "failIfMajorPerformanceCaveat", "bearingSnap", "interactive", "pitchWithRotate", "clickTolerance", "attributionControl", "logoPosition", "maxTileCacheSize", "localIdeographFontFamily", "preserveDrawingBuffer", "trackResize", "transformRequest", "bounds", "antialias", "locale", "cooperativeGestures", "minZoom", "maxZoom", "minPitch", "maxPitch", "scrollZoom", "dragRotate", "touchPitch", "touchZoomRotate", "doubleClickZoom", "keyboard", "dragPan", "boxZoom", "style", "center", "maxBounds", "zoom", "bearing", "pitch", "fitBoundsOptions", "renderWorldCopies", "projection", "movingMethod", "movingOptions", "fitBounds", "fitScreenCoordinates", "centerWithPanTo", "panToOptions", "cursorStyle"], outputs: ["mapResize", "mapRemove", "mapMouseDown", "mapMouseUp", "mapMouseMove", "mapClick", "mapDblClick", "mapMouseOver", "mapMouseOut", "mapContextMenu", "mapTouchStart", "mapTouchEnd", "mapTouchMove", "mapTouchCancel", "mapWheel", "moveStart", "move", "moveEnd", "mapDragStart", "mapDrag", "mapDragEnd", "zoomStart", "zoomEvt", "zoomEnd", "rotateStart", "rotate", "rotateEnd", "pitchStart", "pitchEvt", "pitchEnd", "boxZoomStart", "boxZoomEnd", "boxZoomCancel", "webGlContextLost", "webGlContextRestored", "mapLoad", "mapCreate", "idle", "render", "mapError", "data", "styleData", "sourceData", "dataLoading", "styleDataLoading", "sourceDataLoading", "styleImageMissing", "load"] }, { kind: "component", type: i4.MarkerComponent, selector: "mgl-marker", inputs: ["offset", "anchor", "clickTolerance", "feature", "lngLat", "draggable", "popupShown", "className", "pitchAlignment", "rotationAlignment"], outputs: ["markerDragStart", "markerDragEnd", "markerDrag"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i5.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i6.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i6.MatLabel, selector: "mat-label" }, { kind: "directive", type: i6.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i7.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
288
298
|
}
|
|
289
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
299
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngFieldComponent, decorators: [{
|
|
290
300
|
type: Component,
|
|
291
301
|
args: [{ template: `
|
|
292
|
-
<div class="dbx-mapbox-input-field" [ngClass]="(
|
|
293
|
-
|
|
294
|
-
<
|
|
295
|
-
<mgl-
|
|
296
|
-
|
|
297
|
-
|
|
302
|
+
<div class="dbx-mapbox-input-field" [ngClass]="compactClassSignal()" [formGroup]="formGroup">
|
|
303
|
+
@if (showMap) {
|
|
304
|
+
<div class="dbx-mapbox-input-field-map">
|
|
305
|
+
<mgl-map dbxMapboxMap>
|
|
306
|
+
<mgl-marker [lngLat]="latLngSignal()" [draggable]="!isReadonlyOrDisabled" (markerDragEnd)="onMarkerDragEnd($event)"></mgl-marker>
|
|
307
|
+
</mgl-map>
|
|
308
|
+
</div>
|
|
309
|
+
}
|
|
298
310
|
<div class="dbx-mapbox-input-field-input">
|
|
299
|
-
|
|
300
|
-
<mat-icon
|
|
301
|
-
|
|
311
|
+
@if (showCenterButton) {
|
|
312
|
+
<button mat-icon-button (click)="flyToMarker()">
|
|
313
|
+
<mat-icon>my_location</mat-icon>
|
|
314
|
+
</button>
|
|
315
|
+
}
|
|
302
316
|
<mat-form-field class="dbx-mapbox-input-field-input-field">
|
|
303
317
|
<mat-label>Coordinates</mat-label>
|
|
304
318
|
<input type="text" matInput [placeholder]="placeholder" [formControl]="formControl" />
|
|
305
|
-
|
|
319
|
+
@if (useCurrentLocationDisabledSignal()) {
|
|
320
|
+
<mat-hint class="dbx-hint dbx-warn">Could not access your current location.</mat-hint>
|
|
321
|
+
}
|
|
306
322
|
</mat-form-field>
|
|
307
323
|
</div>
|
|
308
324
|
</div>
|
|
309
|
-
`, providers: [provideMapboxStoreIfParentIsUnavailable()], styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"] }]
|
|
325
|
+
`, providers: [provideMapboxStoreIfParentIsUnavailable()], imports: [NgClass, ReactiveFormsModule, MatIconModule, DbxMapboxModule, MatButtonModule, MatFormFieldModule, MatInputModule], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"] }]
|
|
310
326
|
}] });
|
|
311
327
|
|
|
328
|
+
const importsAndExports$1 = [DbxFormMapboxLatLngFieldComponent];
|
|
312
329
|
class DbxFormMapboxLatLngModule {
|
|
313
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
314
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
315
|
-
|
|
316
|
-
MatButtonModule,
|
|
317
|
-
DbxTextModule,
|
|
318
|
-
DbxMapboxModule,
|
|
319
|
-
FormsModule,
|
|
320
|
-
ReactiveFormsModule,
|
|
321
|
-
MatInputModule, i1$2.FormlyModule, NgxMapboxGLModule], exports: [DbxFormMapboxLatLngFieldMarkerComponent] });
|
|
322
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxFormMapboxLatLngModule, imports: [CommonModule,
|
|
323
|
-
MatIconModule,
|
|
324
|
-
MatButtonModule,
|
|
325
|
-
DbxTextModule,
|
|
326
|
-
DbxMapboxModule,
|
|
327
|
-
FormsModule,
|
|
328
|
-
ReactiveFormsModule,
|
|
329
|
-
MatInputModule,
|
|
330
|
-
FormlyModule.forChild({
|
|
330
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
331
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngModule, imports: [DbxFormMapboxLatLngFieldComponent, i1.FormlyModule], exports: [DbxFormMapboxLatLngFieldComponent] });
|
|
332
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngModule, imports: [importsAndExports$1, FormlyModule.forChild({
|
|
331
333
|
types: [{ name: 'mapbox-latlng-picker', component: DbxFormMapboxLatLngFieldComponent, wrappers: ['style', 'form-field'] }]
|
|
332
|
-
})
|
|
333
|
-
NgxMapboxGLModule] });
|
|
334
|
+
})] });
|
|
334
335
|
}
|
|
335
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
336
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxLatLngModule, decorators: [{
|
|
336
337
|
type: NgModule,
|
|
337
338
|
args: [{
|
|
338
339
|
imports: [
|
|
339
|
-
|
|
340
|
-
MatIconModule,
|
|
341
|
-
MatButtonModule,
|
|
342
|
-
DbxTextModule,
|
|
343
|
-
DbxMapboxModule,
|
|
344
|
-
FormsModule,
|
|
345
|
-
ReactiveFormsModule,
|
|
346
|
-
MatInputModule,
|
|
340
|
+
...importsAndExports$1,
|
|
347
341
|
FormlyModule.forChild({
|
|
348
342
|
types: [{ name: 'mapbox-latlng-picker', component: DbxFormMapboxLatLngFieldComponent, wrappers: ['style', 'form-field'] }]
|
|
349
|
-
})
|
|
350
|
-
NgxMapboxGLModule
|
|
343
|
+
})
|
|
351
344
|
],
|
|
352
|
-
|
|
353
|
-
exports: [DbxFormMapboxLatLngFieldMarkerComponent]
|
|
345
|
+
exports: importsAndExports$1
|
|
354
346
|
}]
|
|
355
347
|
}] });
|
|
356
348
|
|
|
@@ -380,11 +372,11 @@ class DbxFormMapboxZoomFieldComponent extends FieldType {
|
|
|
380
372
|
compact = inject(CompactContextStore, { optional: true });
|
|
381
373
|
dbxMapboxService = inject(DbxMapboxService);
|
|
382
374
|
dbxMapboxMapStore = inject(DbxMapboxMapStore);
|
|
383
|
-
ngZone = inject(NgZone);
|
|
384
375
|
_undoZoomLimit = false;
|
|
385
376
|
compactClass$ = mapCompactModeObs(this.compact?.mode$, {
|
|
386
377
|
compact: 'dbx-mapbox-input-field-compact'
|
|
387
|
-
});
|
|
378
|
+
}).pipe(filterMaybe());
|
|
379
|
+
compactClassSignal = toSignal(this.compactClass$, { initialValue: '' });
|
|
388
380
|
_sub = new SubscriptionObject();
|
|
389
381
|
_center = new BehaviorSubject(undefined);
|
|
390
382
|
_formControlObs = new BehaviorSubject(undefined);
|
|
@@ -450,9 +442,7 @@ class DbxFormMapboxZoomFieldComponent extends FieldType {
|
|
|
450
442
|
}
|
|
451
443
|
this._sub.subscription = this.dbxMapboxMapStore.zoom$.subscribe((zoom) => {
|
|
452
444
|
if (!this.isReadonlyOrDisabled) {
|
|
453
|
-
this.
|
|
454
|
-
this.setValue(zoom);
|
|
455
|
-
});
|
|
445
|
+
this.setValue(zoom);
|
|
456
446
|
}
|
|
457
447
|
});
|
|
458
448
|
}
|
|
@@ -470,12 +460,14 @@ class DbxFormMapboxZoomFieldComponent extends FieldType {
|
|
|
470
460
|
this.formControl.markAsTouched();
|
|
471
461
|
this.formControl.markAsDirty();
|
|
472
462
|
}
|
|
473
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
474
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
475
|
-
<div class="dbx-mapbox-input-field" [ngClass]="(
|
|
476
|
-
|
|
477
|
-
<
|
|
478
|
-
|
|
463
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxZoomFieldComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
464
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: DbxFormMapboxZoomFieldComponent, isStandalone: true, selector: "ng-component", providers: [provideMapboxStoreIfParentIsUnavailable()], usesInheritance: true, ngImport: i0, template: `
|
|
465
|
+
<div class="dbx-mapbox-input-field" [ngClass]="compactClassSignal()" [formGroup]="formGroup">
|
|
466
|
+
@if (showMap) {
|
|
467
|
+
<div class="dbx-mapbox-input-field-map">
|
|
468
|
+
<mgl-map dbxMapboxMap></mgl-map>
|
|
469
|
+
</div>
|
|
470
|
+
}
|
|
479
471
|
<div class="dbx-mapbox-input-field-input">
|
|
480
472
|
<mat-form-field class="dbx-mapbox-input-field-input-field">
|
|
481
473
|
<mat-label>Zoom Level</mat-label>
|
|
@@ -483,15 +475,17 @@ class DbxFormMapboxZoomFieldComponent extends FieldType {
|
|
|
483
475
|
</mat-form-field>
|
|
484
476
|
</div>
|
|
485
477
|
</div>
|
|
486
|
-
`, isInline: true, styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"], dependencies: [{ kind: "directive", type:
|
|
478
|
+
`, isInline: true, styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: DbxMapboxModule }, { kind: "directive", type: i3$1.DbxMapboxMapDirective, selector: "[dbxMapboxMap]" }, { kind: "component", type: i4.MapComponent, selector: "mgl-map", inputs: ["accessToken", "collectResourceTiming", "crossSourceCollisions", "customMapboxApiUrl", "fadeDuration", "hash", "refreshExpiredTiles", "failIfMajorPerformanceCaveat", "bearingSnap", "interactive", "pitchWithRotate", "clickTolerance", "attributionControl", "logoPosition", "maxTileCacheSize", "localIdeographFontFamily", "preserveDrawingBuffer", "trackResize", "transformRequest", "bounds", "antialias", "locale", "cooperativeGestures", "minZoom", "maxZoom", "minPitch", "maxPitch", "scrollZoom", "dragRotate", "touchPitch", "touchZoomRotate", "doubleClickZoom", "keyboard", "dragPan", "boxZoom", "style", "center", "maxBounds", "zoom", "bearing", "pitch", "fitBoundsOptions", "renderWorldCopies", "projection", "movingMethod", "movingOptions", "fitBounds", "fitScreenCoordinates", "centerWithPanTo", "panToOptions", "cursorStyle"], outputs: ["mapResize", "mapRemove", "mapMouseDown", "mapMouseUp", "mapMouseMove", "mapClick", "mapDblClick", "mapMouseOver", "mapMouseOut", "mapContextMenu", "mapTouchStart", "mapTouchEnd", "mapTouchMove", "mapTouchCancel", "mapWheel", "moveStart", "move", "moveEnd", "mapDragStart", "mapDrag", "mapDragEnd", "zoomStart", "zoomEvt", "zoomEnd", "rotateStart", "rotate", "rotateEnd", "pitchStart", "pitchEvt", "pitchEnd", "boxZoomStart", "boxZoomEnd", "boxZoomCancel", "webGlContextLost", "webGlContextRestored", "mapLoad", "mapCreate", "idle", "render", "mapError", "data", "styleData", "sourceData", "dataLoading", "styleDataLoading", "sourceDataLoading", "styleImageMissing", "load"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.MinValidator, selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]", inputs: ["min"] }, { kind: "directive", type: i3.MaxValidator, selector: "input[type=number][max][formControlName],input[type=number][max][formControl],input[type=number][max][ngModel]", inputs: ["max"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i3.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i6.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i6.MatLabel, selector: "mat-label" }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i7.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
487
479
|
}
|
|
488
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
480
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxZoomFieldComponent, decorators: [{
|
|
489
481
|
type: Component,
|
|
490
482
|
args: [{ template: `
|
|
491
|
-
<div class="dbx-mapbox-input-field" [ngClass]="(
|
|
492
|
-
|
|
493
|
-
<
|
|
494
|
-
|
|
483
|
+
<div class="dbx-mapbox-input-field" [ngClass]="compactClassSignal()" [formGroup]="formGroup">
|
|
484
|
+
@if (showMap) {
|
|
485
|
+
<div class="dbx-mapbox-input-field-map">
|
|
486
|
+
<mgl-map dbxMapboxMap></mgl-map>
|
|
487
|
+
</div>
|
|
488
|
+
}
|
|
495
489
|
<div class="dbx-mapbox-input-field-input">
|
|
496
490
|
<mat-form-field class="dbx-mapbox-input-field-input-field">
|
|
497
491
|
<mat-label>Zoom Level</mat-label>
|
|
@@ -499,59 +493,38 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
|
|
|
499
493
|
</mat-form-field>
|
|
500
494
|
</div>
|
|
501
495
|
</div>
|
|
502
|
-
`, providers: [provideMapboxStoreIfParentIsUnavailable()], styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"] }]
|
|
496
|
+
`, providers: [provideMapboxStoreIfParentIsUnavailable()], imports: [NgClass, DbxMapboxModule, FormsModule, ReactiveFormsModule, MatFormFieldModule, MatInputModule], changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, styles: [".dbx-mapbox-input-field .dbx-mapbox-input-field-map{height:220px;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-map mgl-map{height:100%;width:100%}.dbx-mapbox-input-field .dbx-mapbox-input-field-input{display:flex;align-items:center}.dbx-mapbox-input-field .dbx-mapbox-input-field-input .dbx-mapbox-input-field-input-field{width:calc(100% - 40px)}.dbx-mapbox-input-field-compact .dbx-latlng-field-input{min-height:120px;height:300px;max-height:calc(var(--vh100) * .5)}\n"] }]
|
|
503
497
|
}] });
|
|
504
498
|
|
|
499
|
+
const importsAndExports = [DbxFormMapboxZoomFieldComponent];
|
|
505
500
|
class DbxFormMapboxZoomModule {
|
|
506
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
507
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
508
|
-
|
|
509
|
-
MatButtonModule,
|
|
510
|
-
DbxTextModule,
|
|
511
|
-
DbxMapboxModule,
|
|
512
|
-
FormsModule,
|
|
513
|
-
ReactiveFormsModule,
|
|
514
|
-
MatInputModule, i1$2.FormlyModule, NgxMapboxGLModule] });
|
|
515
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxFormMapboxZoomModule, imports: [CommonModule,
|
|
516
|
-
MatIconModule,
|
|
517
|
-
MatButtonModule,
|
|
518
|
-
DbxTextModule,
|
|
519
|
-
DbxMapboxModule,
|
|
520
|
-
FormsModule,
|
|
521
|
-
ReactiveFormsModule,
|
|
522
|
-
MatInputModule,
|
|
523
|
-
FormlyModule.forChild({
|
|
501
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxZoomModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
502
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxZoomModule, imports: [DbxFormMapboxZoomFieldComponent, i1.FormlyModule, NgxMapboxGLModule], exports: [DbxFormMapboxZoomFieldComponent] });
|
|
503
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxZoomModule, imports: [importsAndExports, FormlyModule.forChild({
|
|
524
504
|
types: [{ name: 'mapbox-zoom-picker', component: DbxFormMapboxZoomFieldComponent, wrappers: ['style', 'form-field'] }]
|
|
525
505
|
}),
|
|
526
506
|
NgxMapboxGLModule] });
|
|
527
507
|
}
|
|
528
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
508
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxZoomModule, decorators: [{
|
|
529
509
|
type: NgModule,
|
|
530
510
|
args: [{
|
|
531
511
|
imports: [
|
|
532
|
-
|
|
533
|
-
MatIconModule,
|
|
534
|
-
MatButtonModule,
|
|
535
|
-
DbxTextModule,
|
|
536
|
-
DbxMapboxModule,
|
|
537
|
-
FormsModule,
|
|
538
|
-
ReactiveFormsModule,
|
|
539
|
-
MatInputModule,
|
|
512
|
+
...importsAndExports,
|
|
540
513
|
FormlyModule.forChild({
|
|
541
514
|
types: [{ name: 'mapbox-zoom-picker', component: DbxFormMapboxZoomFieldComponent, wrappers: ['style', 'form-field'] }]
|
|
542
515
|
}),
|
|
543
516
|
NgxMapboxGLModule
|
|
544
517
|
],
|
|
545
|
-
|
|
518
|
+
exports: importsAndExports
|
|
546
519
|
}]
|
|
547
520
|
}] });
|
|
548
521
|
|
|
549
522
|
class DbxFormMapboxModule {
|
|
550
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
551
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
552
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
523
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
524
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxModule, exports: [DbxFormMapboxLatLngModule, DbxFormMapboxZoomModule] });
|
|
525
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxModule, imports: [DbxFormMapboxLatLngModule, DbxFormMapboxZoomModule] });
|
|
553
526
|
}
|
|
554
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
527
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DbxFormMapboxModule, decorators: [{
|
|
555
528
|
type: NgModule,
|
|
556
529
|
args: [{
|
|
557
530
|
exports: [DbxFormMapboxLatLngModule, DbxFormMapboxZoomModule]
|