@eeacms/volto-datahub 1.0.21 → 1.0.22

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/CHANGELOG.md CHANGED
@@ -4,6 +4,13 @@ All notable changes to this project will be documented in this file. Dates are d
4
4
 
5
5
  Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
6
6
 
7
+ ### [1.0.22](https://github.com/eea/volto-datahub/compare/1.0.21...1.0.22) - 6 April 2023
8
+
9
+ #### :hammer_and_wrench: Others
10
+
11
+ - Accessibility on datahub view [kreafox - [`4f4fd41`](https://github.com/eea/volto-datahub/commit/4f4fd4163f75269e281c78ea5f973241c5d34fe3)]
12
+ - Removed 'Published' from search results [Zoltan Szabo - [`476ac0f`](https://github.com/eea/volto-datahub/commit/476ac0fc666b425b27de66d5c958f90c84ece1a8)]
13
+ - Refs #250312; remove WebDAV download options [Zoltan Szabo - [`ac6ed90`](https://github.com/eea/volto-datahub/commit/ac6ed90b37b017528f1d2f3acd02365734999533)]
7
14
  ### [1.0.21](https://github.com/eea/volto-datahub/compare/1.0.20...1.0.21) - 15 March 2023
8
15
 
9
16
  #### :hammer_and_wrench: Others
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-datahub",
3
- "version": "1.0.21",
3
+ "version": "1.0.22",
4
4
  "description": "@eeacms/volto-datahub: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: IDM2 A-Team",
@@ -80,7 +80,7 @@ const DatasetItemDownloadList = (props) => {
80
80
  );
81
81
  })}
82
82
 
83
- {(dataset['EEA:FILEPATH'] || []).map((item, i) => {
83
+ {/* {(dataset['EEA:FILEPATH'] || []).map((item, i) => {
84
84
  return (
85
85
  <List.Item key={i}>
86
86
  <List.Content>
@@ -115,7 +115,7 @@ const DatasetItemDownloadList = (props) => {
115
115
  target="_blank"
116
116
  rel="noreferrer"
117
117
  >
118
- WebDAV: {item.name || item.function}
118
+ WebDAV1: {item.name || item.function}
119
119
  </a>
120
120
  {isInternalURL(item.url) && (
121
121
  <SVGIcon name={lockSVG} size="18" />
@@ -124,7 +124,7 @@ const DatasetItemDownloadList = (props) => {
124
124
  </List.Content>
125
125
  </List.Item>
126
126
  );
127
- })}
127
+ })} */}
128
128
  </List>
129
129
  </>
130
130
  )}
@@ -39,9 +39,15 @@ const DatasetItemsList = (props) => {
39
39
  return (
40
40
  <React.Fragment key={index}>
41
41
  <Accordion.Title
42
+ tabIndex={0}
42
43
  active={activeIndex === index}
43
44
  index={index}
44
45
  onClick={handleClick}
46
+ onKeyDown={(e) => {
47
+ if (e.key === 'Enter') {
48
+ handleClick(e, { index });
49
+ }
50
+ }}
45
51
  >
46
52
  <span className="dataset-title">
47
53
  {dataset.resourceTitleObject.default}
@@ -10,6 +10,8 @@ const DatasetsTab = (props) => {
10
10
  defaultAccordionOpenIndex,
11
11
  );
12
12
 
13
+ const [activeTabIndex, setActiveTabIndex] = React.useState(0);
14
+
13
15
  React.useEffect(() => {
14
16
  if (defaultAccordionOpenIndex !== undefined) {
15
17
  setActiveAccordionIndex(defaultAccordionOpenIndex);
@@ -20,7 +22,16 @@ const DatasetsTab = (props) => {
20
22
 
21
23
  const panes = (items || []).map((item, i) => ({
22
24
  menuItem: (
23
- <Menu.Item key={i}>
25
+ <Menu.Item
26
+ key={i}
27
+ tabIndex={0}
28
+ onClick={() => setActiveTabIndex(i)}
29
+ onKeyDown={(e) => {
30
+ if (e.key === 'Enter') {
31
+ setActiveTabIndex(i);
32
+ }
33
+ }}
34
+ >
24
35
  {item.date ? <span>{item.date}</span> : 'No date'}
25
36
  </Menu.Item>
26
37
  ),
@@ -39,6 +50,7 @@ const DatasetsTab = (props) => {
39
50
  return (
40
51
  <Tab
41
52
  className="datasets-tab"
53
+ activeIndex={activeTabIndex}
42
54
  menu={{ vertical: true, secondary: true, pointing: true }}
43
55
  panes={panes}
44
56
  onTabChange={() => {
@@ -164,8 +164,14 @@ const LandingPage = (props) => {
164
164
  return (
165
165
  <React.Fragment key={`tab-${tabIndex}`}>
166
166
  <Menu.Item
167
+ tabIndex={0}
167
168
  active={activeSection === section.facetField}
168
169
  onClick={() => setActiveSection(section.facetField)}
170
+ onKeyDown={(e) => {
171
+ if (e.key === 'Enter') {
172
+ setActiveSection(section.facetField);
173
+ }
174
+ }}
169
175
  >
170
176
  {section.title}
171
177
  </Menu.Item>
@@ -175,7 +181,7 @@ const LandingPage = (props) => {
175
181
  },
176
182
  render: () => {
177
183
  return (
178
- <Tab.Pane>
184
+ <Tab.Pane tabIndex={0}>
179
185
  <div className={`landing-page-cards ${activeSection}`}>
180
186
  <List>
181
187
  {sortedTiles(tiles, activeSectionConfig, appConfig).map(
@@ -204,7 +210,16 @@ const LandingPage = (props) => {
204
210
  };
205
211
 
206
212
  return (
207
- <List.Item onClick={onClickHandler} key={index}>
213
+ <List.Item
214
+ key={index}
215
+ tabIndex={0}
216
+ onClick={onClickHandler}
217
+ onKeyDown={(e) => {
218
+ if (e.key === 'Enter') {
219
+ onClickHandler();
220
+ }
221
+ }}
222
+ >
208
223
  <List.Content>
209
224
  {icon ? <Icon {...icon} type={topic.value} /> : ''}
210
225
  <Term term={topic.value} field={activeSection} />
@@ -247,7 +262,7 @@ const LandingPage = (props) => {
247
262
  <List.Content>
248
263
  <div
249
264
  key="all_series"
250
- tabIndex="-1"
265
+ tabIndex="0"
251
266
  role="button"
252
267
  onKeyDown={fixedOnClickHandler}
253
268
  onClick={fixedOnClickHandler}
@@ -32,7 +32,7 @@ const DatahubCardItem = (props) => {
32
32
  extra: (
33
33
  <div className="result-bottom">
34
34
  <div className="result-info">
35
- <span className="result-info-title">Published: </span>
35
+ {/* <span className="result-info-title">Published: </span> */}
36
36
  <DateTime format="DATE_MED" value={result.issued} />
37
37
  </div>
38
38
  {topic ? (