datastake-daf 0.6.773 → 0.6.774

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.
@@ -0,0 +1,84 @@
1
+ import { useState, useEffect, useMemo } from "react";
2
+
3
+ export const useViewFormUrlParams = ({
4
+ params,
5
+ pathname,
6
+ search,
7
+ searchParams,
8
+ setSearchParams,
9
+ push,
10
+ }) => {
11
+ const [namespace, setNamespace] = useState(params.namespace);
12
+ const [id, setId] = useState(params.id);
13
+ const [group, setGroup] = useState(params.group);
14
+ const [subsection, setSubsection] = useState(params.subsection);
15
+ const [source, setSource] = useState(searchParams.get("source") || null);
16
+ const [version, setVersion] = useState(searchParams.get("version") || null);
17
+
18
+ useEffect(() => {
19
+ if (
20
+ (id && params.id !== id) ||
21
+ (namespace && namespace !== params.namespace)
22
+ ) {
23
+ setGroup(undefined);
24
+ setSubsection(undefined);
25
+ } else {
26
+ setGroup(params.group);
27
+ setSubsection(params.subsection);
28
+ }
29
+ setNamespace(params.namespace);
30
+ setId(params.id);
31
+ }, [params, id, namespace]);
32
+
33
+ useEffect(() => {
34
+ if (source && version) {
35
+ const newParams = new URLSearchParams(searchParams);
36
+ newParams.set("source", source);
37
+ newParams.set("version", version);
38
+ setSearchParams(newParams);
39
+ }
40
+ }, [source, version]);
41
+
42
+ const updateSourceAndVersion = (newSource, newVersion) => {
43
+ const newParams = new URLSearchParams(searchParams);
44
+ if (newSource && newVersion) {
45
+ newParams.set("source", newSource);
46
+ newParams.set("version", newVersion);
47
+ } else {
48
+ newParams.delete("source");
49
+ newParams.delete("version");
50
+ }
51
+ setSearchParams(newParams);
52
+ setSource(newSource);
53
+ setVersion(newVersion);
54
+ };
55
+
56
+ const clearSourceAndVersion = () => {
57
+ updateSourceAndVersion(null, null);
58
+ };
59
+
60
+ const match = useMemo(
61
+ () => ({
62
+ params,
63
+ path: pathname,
64
+ }),
65
+ [params, pathname],
66
+ );
67
+
68
+ return {
69
+ namespace,
70
+ id,
71
+ group,
72
+ subsection,
73
+ source,
74
+ version,
75
+ params,
76
+ searchParams,
77
+ setSource,
78
+ setVersion,
79
+ updateSourceAndVersion,
80
+ clearSourceAndVersion,
81
+ match,
82
+ search,
83
+ };
84
+ }
@@ -1,151 +1,40 @@
1
- import React, { useState, useMemo, useEffect, useCallback } from 'react';
2
- import { Widget, StickyTable, SearchFilters } from '../../../../../../../../src/index.js';
3
- import { useWidgetFetch } from '../../../../../../hooks/useWidgetFetch.js';
4
- import { getColumns } from './config.js';
5
- import { getRedirectLink } from '../../../../../../../utils.js';
1
+ import React, { useState } from 'react';
2
+ import { Widget } from '../../../../../../../../src/index.js';
6
3
 
7
- // Constants
8
- export const ACTIVITIES_TAB = 'activities';
9
- export const PARTNERS_TAB = 'partners';
10
- export const INCIDENTS_TAB = 'incidents';
4
+ const ACTIVITIES_TAB = 'activities';
5
+ const PARTNERS_TAB = 'partners';
6
+ const INCIDENTS_TAB = 'incidents';
11
7
 
12
- export const DEFAULT_SEARCH_FIELDS = ["name", "datastakeId"];
13
- const URL_PATTERN = /\/summary\/[^/]+\/(.+)/;
14
8
 
15
- // Configuration
16
- export const TABS_CONFIG = [
17
- { label: "straatos::activities", value: ACTIVITIES_TAB },
18
- { label: "straatos::partners", value: PARTNERS_TAB },
19
- { label: "straatos::incidents", value: INCIDENTS_TAB, disabled: true },
20
- ];
21
-
22
- // Helper functions
23
- export const getSearchFields = (activeTab) => DEFAULT_SEARCH_FIELDS;
24
-
25
- export const buildSearchFilter = (search, fields) =>
26
- search ? { search: { qs: search, fields } } : {};
27
-
28
- export const extractTypeFromUrl = (url) => {
29
- const match = url.match(URL_PATTERN);
30
- if (!match) {
31
- throw new Error(`Invalid URL format: ${url}`);
32
- }
33
- return match[1];
34
- };
35
-
36
- export const ensureArray = (data) => Array.isArray(data) ? data : [];
37
-
38
- const AssociatedInformation = ({
39
- id,
40
- navigate,
41
- getSummaryDetail,
42
- loading = false,
43
- projectId,
44
- basepath = "planting-cycle",
45
- endpoint = "associated-information",
46
- tabsConfig = TABS_CONFIG,
47
- searchFieldsMap = getSearchFields,
48
- t = (s) => s
9
+ const AssociatedInformation = ({
10
+ activityData,
11
+ loading = false,
12
+ t = (s) => s
49
13
  }) => {
50
14
  const [activeTab, setActiveTab] = useState(ACTIVITIES_TAB);
51
- const [search, setSearch] = useState('');
52
-
53
- const searchFields = useMemo(() => searchFieldsMap(activeTab), [activeTab, searchFieldsMap]);
54
-
55
- const filters = useMemo(() => ({
56
- type: activeTab,
57
- ...buildSearchFilter(search, searchFields)
58
- }), [activeTab, search, searchFields]);
59
-
60
- const defaultConfig = useMemo(() => ({
61
- basepath,
62
- url: `/summary/${id}/${endpoint}`,
63
- filters,
64
- stop: !id,
65
- }), [id, filters, basepath, endpoint]);
66
-
67
- const customGetData = useMemo(() => {
68
- if (!getSummaryDetail || !id) return undefined;
69
-
70
- return (rest) => {
71
- const { url, filters: restFilters } = rest;
72
- const type = extractTypeFromUrl(url);
73
- const params = {
74
- ...(restFilters || {}),
75
- type: restFilters?.type || activeTab
76
- };
77
- return getSummaryDetail(id, type, params);
78
- };
79
- }, [getSummaryDetail, id, activeTab]);
80
-
81
- const { loading: associatedInformationLoading, data: associatedInformationData, setData } = useWidgetFetch({
82
- config: defaultConfig,
83
- getData: customGetData
84
- });
85
-
86
- // Reset data and search when tab changes
87
- useEffect(() => {
88
- setData([]);
89
- setSearch('');
90
- }, [activeTab, setData]);
91
-
92
- const handleSearch = useCallback((activeFilter, searchValue) => {
93
- setSearch(searchValue || '');
94
- }, []);
95
-
96
- const handleTabChange = useCallback((value) => {
97
- setActiveTab(value);
98
- }, []);
99
-
100
- const columns = useMemo(() => getColumns({
101
- t,
102
- activeTab,
103
- view: activeTab,
104
- projectId,
105
- navigate,
106
- getRedirectLink,
107
- }), [t, activeTab, projectId, navigate]);
108
-
109
- const tableDataSource = useMemo(() =>
110
- ensureArray(associatedInformationData),
111
- [associatedInformationData]
112
- );
113
-
114
- const translatedTabs = useMemo(() =>
115
- tabsConfig.map(tab => ({ ...tab, label: t(tab.label) })),
116
- [tabsConfig, t]
117
- );
118
15
 
119
16
  return (
120
17
  <section>
121
- <Widget
122
- className="v2-widget no-px no-p-body h-w-btn-header with-border-header"
18
+
19
+ <Widget
20
+ className="v2-widget no-px h-w-btn-header no-p-body"
123
21
  title={t("Associated Information")}
124
22
  tabsConfig={{
125
- tabs: translatedTabs,
23
+ tabs: [
24
+ { label: t("straatos::activities"), value: ACTIVITIES_TAB },
25
+ { label: t("straatos::partners"), value: PARTNERS_TAB },
26
+ { label: t("straatos::incidents"), value: INCIDENTS_TAB },
27
+ ],
126
28
  value: activeTab,
127
- onChange: handleTabChange,
29
+ onChange: (value) => {
30
+ setActiveTab(value);
31
+ // setData([]);
32
+ },
128
33
  }}
129
34
  >
130
- <div className='mt-6 ml-6 mr-6'>
131
- <SearchFilters
132
- t={t}
133
- showFilter={false}
134
- hasError={false}
135
- canClear={true}
136
- setHasError={() => {}}
137
- onSearch={handleSearch}
138
- activeFilters={{ search }}
139
- />
140
- </div>
141
- <div className='mb-6'>
142
- <StickyTable
143
- columns={columns}
144
- dataSource={tableDataSource}
145
- loading={associatedInformationLoading || loading}
146
- />
147
- </div>
148
- </Widget>
35
+ <div>
36
+ </div>
37
+ </Widget>
149
38
  </section>
150
39
  );
151
40
  };
@@ -8,6 +8,7 @@ const JobsTimeline = ({
8
8
  t = (s) => s
9
9
  }) => {
10
10
 
11
+ console.log('dayJobsTimeline', dayJobsTimeline);
11
12
  const jobsData = Array.isArray(dayJobsTimeline)
12
13
  ? dayJobsTimeline
13
14
  : (dayJobsTimeline?.jobsTimeline || dayJobsTimeline?.jobs || dayJobsTimeline?.timeline || []);
@@ -6,12 +6,13 @@ import CommunityParticipation from './components/CommunityParticipation/index.js
6
6
  import AssociatedInformation from './components/AssociatedInformation/index.jsx';
7
7
  import KeyInformation from './components/KeyInformation/index.jsx';
8
8
 
9
- const PlantingCycleSummary = ({ header, activityData, loading = false, id, projectId, t = () => { }, getSummaryDetail, navigate }) => {
9
+ const PlantingCycleSummary = ({ header, activityData, loading = false, id, t = () => { }, getSummaryDetail }) => {
10
+
10
11
  return (
11
12
  <DashboardLayout
12
13
  header={
13
14
  <Header
14
- title={header?.title + ' Summary' || ''}
15
+ title={header?.title || ''}
15
16
  supportText={header?.supportText || ''}
16
17
  onDownload={header?.onDownload}
17
18
  downloadDisabled={header?.downloadDisabled}
@@ -27,7 +28,7 @@ const PlantingCycleSummary = ({ header, activityData, loading = false, id, proje
27
28
  <CycleOutcomes id={id} getSummaryDetail={getSummaryDetail} loading={loading} t={t} />
28
29
  <CycleIndicators id={id} getSummaryDetail={getSummaryDetail} loading={loading} t={t} />
29
30
  <CommunityParticipation id={id} getSummaryDetail={getSummaryDetail} loading={loading} t={t} />
30
- <AssociatedInformation id={id} projectId={projectId} getSummaryDetail={getSummaryDetail} loading={loading} t={t} navigate={navigate} />
31
+ <AssociatedInformation id={id} getSummaryDetail={getSummaryDetail} loading={loading} t={t} />
31
32
  </DashboardLayout>
32
33
  )
33
34
  }
@@ -61,4 +61,6 @@ export const removeKeysFromObject = (obj = {}, keys = []) => {
61
61
  }
62
62
  }
63
63
  return result;
64
- }
64
+ }
65
+
66
+ export const hasKeyInObject = (obj, key) => Object.keys(obj || {}).includes(key);
package/src/hooks.js CHANGED
@@ -13,4 +13,5 @@ export { useFirebase } from "./@daf/hooks/useFirebase.js"
13
13
  export { useIsDatastake } from "./@daf/hooks/useIsDatastake.js"
14
14
  export { useWidgetFetch } from "./@daf/hooks/useWidgetFetch.js"
15
15
  export { useAdminDashboard } from "./@daf/hooks/useAdminDashboard.js"
16
- export { useGetQueryParams } from "./@daf/hooks/useGetQueryParams.js"
16
+ export { useGetQueryParams } from "./@daf/hooks/useGetQueryParams.js"
17
+ export { useViewFormUrlParams } from "./@daf/hooks/useViewFormUrlParams.js"
package/src/utils.js CHANGED
@@ -27,7 +27,7 @@ export { default as locales } from './constants/locales/index.js';
27
27
 
28
28
  export { getTagColor } from "./@daf/utils/productTag.js";
29
29
 
30
- export { convertUndefinedToNull } from './@daf/utils/object'
30
+ export { convertUndefinedToNull, hasKeyInObject, removeKeysFromObject } from './@daf/utils/object'
31
31
 
32
32
  export { default as ErrorFormat, formatErrors } from './helpers/ErrorFormater'
33
33
 
@@ -1,330 +0,0 @@
1
- /* Isolated Mapbox GL CSS - Scoped to prevent Leaflet conflicts */
2
-
3
- /* Mapbox GL Core Styles - Scoped with .mapbox-gl-scope */
4
- .mapbox-gl-scope .mapboxgl-map {
5
- font: 12px/20px Helvetica Neue, Arial, Helvetica, sans-serif;
6
- overflow: hidden;
7
- position: relative;
8
- -webkit-tap-highlight-color: rgb(0 0 0/0);
9
- }
10
-
11
- .mapbox-gl-scope .mapboxgl-canvas {
12
- left: 0;
13
- position: absolute;
14
- top: 0;
15
- }
16
-
17
- .mapbox-gl-scope .mapboxgl-map:-webkit-full-screen {
18
- height: 100%;
19
- width: 100%;
20
- }
21
-
22
- .mapbox-gl-scope .mapboxgl-canary {
23
- background-color: salmon;
24
- }
25
-
26
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-interactive,
27
- .mapbox-gl-scope .mapboxgl-ctrl-group button.mapboxgl-ctrl-compass {
28
- cursor: grab;
29
- -webkit-user-select: none;
30
- user-select: none;
31
- }
32
-
33
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-interactive.mapboxgl-track-pointer {
34
- cursor: pointer;
35
- }
36
-
37
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-interactive:active,
38
- .mapbox-gl-scope .mapboxgl-ctrl-group button.mapboxgl-ctrl-compass:active {
39
- cursor: grabbing;
40
- }
41
-
42
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate,
43
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate .mapboxgl-canvas {
44
- touch-action: pan-x pan-y;
45
- }
46
-
47
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-touch-drag-pan,
48
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-touch-drag-pan .mapboxgl-canvas {
49
- touch-action: pinch-zoom;
50
- }
51
-
52
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate.mapboxgl-touch-drag-pan,
53
- .mapbox-gl-scope .mapboxgl-canvas-container.mapboxgl-touch-zoom-rotate.mapboxgl-touch-drag-pan .mapboxgl-canvas {
54
- touch-action: none;
55
- }
56
-
57
- /* Control positioning */
58
- .mapbox-gl-scope .mapboxgl-ctrl-bottom,
59
- .mapbox-gl-scope .mapboxgl-ctrl-bottom-left,
60
- .mapbox-gl-scope .mapboxgl-ctrl-bottom-right,
61
- .mapbox-gl-scope .mapboxgl-ctrl-left,
62
- .mapbox-gl-scope .mapboxgl-ctrl-right,
63
- .mapbox-gl-scope .mapboxgl-ctrl-top,
64
- .mapbox-gl-scope .mapboxgl-ctrl-top-left,
65
- .mapbox-gl-scope .mapboxgl-ctrl-top-right {
66
- pointer-events: none;
67
- position: absolute;
68
- z-index: 2;
69
- }
70
-
71
- .mapbox-gl-scope .mapboxgl-ctrl-top-left {
72
- left: 0;
73
- top: 0;
74
- }
75
-
76
- .mapbox-gl-scope .mapboxgl-ctrl-top {
77
- left: 50%;
78
- top: 0;
79
- transform: translateX(-50%);
80
- }
81
-
82
- .mapbox-gl-scope .mapboxgl-ctrl-top-right {
83
- right: 0;
84
- top: 0;
85
- }
86
-
87
- .mapbox-gl-scope .mapboxgl-ctrl-right {
88
- right: 0;
89
- top: 50%;
90
- transform: translateY(-50%);
91
- }
92
-
93
- .mapbox-gl-scope .mapboxgl-ctrl-bottom-right {
94
- bottom: 0;
95
- right: 0;
96
- }
97
-
98
- .mapbox-gl-scope .mapboxgl-ctrl-bottom {
99
- bottom: 0;
100
- left: 50%;
101
- transform: translateX(-50%);
102
- }
103
-
104
- .mapbox-gl-scope .mapboxgl-ctrl-bottom-left {
105
- bottom: 0;
106
- left: 0;
107
- }
108
-
109
- .mapbox-gl-scope .mapboxgl-ctrl-left {
110
- left: 0;
111
- top: 50%;
112
- transform: translateY(-50%);
113
- }
114
-
115
- .mapbox-gl-scope .mapboxgl-ctrl {
116
- clear: both;
117
- pointer-events: auto;
118
- transform: translate(0);
119
- }
120
-
121
- .mapbox-gl-scope .mapboxgl-ctrl-top-left .mapboxgl-ctrl {
122
- float: left;
123
- margin: 10px 0 0 10px;
124
- }
125
-
126
- .mapbox-gl-scope .mapboxgl-ctrl-top .mapboxgl-ctrl {
127
- float: left;
128
- margin: 10px 0;
129
- }
130
-
131
- .mapbox-gl-scope .mapboxgl-ctrl-top-right .mapboxgl-ctrl {
132
- float: right;
133
- margin: 10px 10px 0 0;
134
- }
135
-
136
- .mapbox-gl-scope .mapboxgl-ctrl-bottom-right .mapboxgl-ctrl,
137
- .mapbox-gl-scope .mapboxgl-ctrl-right .mapboxgl-ctrl {
138
- float: right;
139
- margin: 0 10px 10px 0;
140
- }
141
-
142
- .mapbox-gl-scope .mapboxgl-ctrl-bottom .mapboxgl-ctrl {
143
- float: left;
144
- margin: 10px 0;
145
- }
146
-
147
- .mapbox-gl-scope .mapboxgl-ctrl-bottom-left .mapboxgl-ctrl,
148
- .mapbox-gl-scope .mapboxgl-ctrl-left .mapboxgl-ctrl {
149
- float: left;
150
- margin: 0 0 10px 10px;
151
- }
152
-
153
- /* Control group styling */
154
- .mapbox-gl-scope .mapboxgl-ctrl-group {
155
- background: #fff;
156
- border-radius: 4px;
157
- }
158
-
159
- .mapbox-gl-scope .mapboxgl-ctrl-group:not(:empty) {
160
- box-shadow: 0 0 0 2px #0000001a;
161
- }
162
-
163
- .mapbox-gl-scope .mapboxgl-ctrl-group button {
164
- background-color: initial;
165
- border: 0;
166
- box-sizing: border-box;
167
- cursor: pointer;
168
- display: block;
169
- height: 29px;
170
- outline: none;
171
- overflow: hidden;
172
- padding: 0;
173
- width: 29px;
174
- }
175
-
176
- .mapbox-gl-scope .mapboxgl-ctrl-group button+button {
177
- border-top: 1px solid #ddd;
178
- }
179
-
180
- .mapbox-gl-scope .mapboxgl-ctrl button .mapboxgl-ctrl-icon {
181
- background-position: 50%;
182
- background-repeat: no-repeat;
183
- display: block;
184
- height: 100%;
185
- width: 100%;
186
- }
187
-
188
- .mapbox-gl-scope .mapboxgl-ctrl-attrib-button:focus,
189
- .mapbox-gl-scope .mapboxgl-ctrl-group button:focus {
190
- box-shadow: 0 0 2px 2px #0096ff;
191
- }
192
-
193
- .mapbox-gl-scope .mapboxgl-ctrl button:disabled {
194
- cursor: not-allowed;
195
- }
196
-
197
- .mapbox-gl-scope .mapboxgl-ctrl button:disabled .mapboxgl-ctrl-icon {
198
- opacity: .25;
199
- }
200
-
201
- .mapbox-gl-scope .mapboxgl-ctrl-group button:first-child {
202
- border-radius: 4px 4px 0 0;
203
- }
204
-
205
- .mapbox-gl-scope .mapboxgl-ctrl-group button:last-child {
206
- border-radius: 0 0 4px 4px;
207
- }
208
-
209
- .mapbox-gl-scope .mapboxgl-ctrl-group button:only-child {
210
- border-radius: inherit;
211
- }
212
-
213
- .mapbox-gl-scope .mapboxgl-ctrl button:not(:disabled):hover {
214
- background-color: #0000000d;
215
- }
216
-
217
- /* Marker styles */
218
- .mapbox-gl-scope .mapboxgl-marker {
219
- position: absolute;
220
- z-index: 1;
221
- }
222
-
223
- .mapbox-gl-scope .mapboxgl-marker svg {
224
- display: block;
225
- }
226
-
227
- /* Popup styles */
228
- .mapbox-gl-scope .mapboxgl-popup {
229
- position: absolute;
230
- text-align: center;
231
- margin-bottom: 20px;
232
- }
233
-
234
- .mapbox-gl-scope .mapboxgl-popup-content-wrapper {
235
- padding: 1px;
236
- text-align: left;
237
- border-radius: 12px;
238
- }
239
-
240
- .mapbox-gl-scope .mapboxgl-popup-content {
241
- margin: 13px 24px 13px 20px;
242
- line-height: 1.3;
243
- font-size: 13px;
244
- min-height: 1px;
245
- }
246
-
247
- .mapbox-gl-scope .mapboxgl-popup-content p {
248
- margin: 17px 0;
249
- }
250
-
251
- .mapbox-gl-scope .mapboxgl-popup-tip-container {
252
- width: 40px;
253
- height: 20px;
254
- position: absolute;
255
- left: 50%;
256
- margin-top: -1px;
257
- margin-left: -20px;
258
- overflow: hidden;
259
- pointer-events: none;
260
- }
261
-
262
- .mapbox-gl-scope .mapboxgl-popup-tip {
263
- width: 17px;
264
- height: 17px;
265
- padding: 1px;
266
- margin: -10px auto 0;
267
- pointer-events: auto;
268
- -webkit-transform: rotate(45deg);
269
- -moz-transform: rotate(45deg);
270
- -ms-transform: rotate(45deg);
271
- transform: rotate(45deg);
272
- }
273
-
274
- .mapbox-gl-scope .mapboxgl-popup-content-wrapper,
275
- .mapbox-gl-scope .mapboxgl-popup-tip {
276
- background: white;
277
- color: #333;
278
- box-shadow: 0 3px 14px rgba(0, 0, 0, 0.4);
279
- }
280
-
281
- .mapbox-gl-scope .mapboxgl-popup-close-button {
282
- position: absolute;
283
- top: 0;
284
- right: 0;
285
- border: none;
286
- text-align: center;
287
- width: 24px;
288
- height: 24px;
289
- font: 16px/24px Tahoma, Verdana, sans-serif;
290
- color: #757575;
291
- text-decoration: none;
292
- background: transparent;
293
- }
294
-
295
- .mapbox-gl-scope .mapboxgl-popup-close-button:hover,
296
- .mapbox-gl-scope .mapboxgl-popup-close-button:focus {
297
- color: #585858;
298
- }
299
-
300
- /* Attribution */
301
- .mapbox-gl-scope .mapboxgl-ctrl-attribution {
302
- background: #fff;
303
- background: rgba(255, 255, 255, 0.8);
304
- margin: 0;
305
- }
306
-
307
- .mapbox-gl-scope .mapboxgl-ctrl-attribution,
308
- .mapbox-gl-scope .mapboxgl-ctrl-scale-line {
309
- padding: 0 5px;
310
- color: #333;
311
- line-height: 1.4;
312
- }
313
-
314
- .mapbox-gl-scope .mapboxgl-ctrl-attribution a {
315
- text-decoration: none;
316
- }
317
-
318
- .mapbox-gl-scope .mapboxgl-ctrl-attribution a:hover,
319
- .mapbox-gl-scope .mapboxgl-ctrl-attribution a:focus {
320
- text-decoration: underline;
321
- }
322
-
323
- /* Hide attribution by default */
324
- .mapbox-gl-scope .mapboxgl-ctrl-attribution {
325
- display: none !important;
326
- }
327
-
328
- .mapbox-gl-scope .mapboxgl-ctrl-logo {
329
- display: none !important;
330
- }