Skip to content

Commit 07a2437

Browse files
Merge branch 'main' into w2p-124085_add-themeable-MyDSpace-components_contribute-main
2 parents 7f15ced + ec6940a commit 07a2437

File tree

1,320 files changed

+40322
-22320
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,320 files changed

+40322
-22320
lines changed

.eslintrc.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,8 @@
294294
"rules": {
295295
// Custom DSpace Angular rules
296296
"dspace-angular-html/themed-component-usages": "error",
297-
"dspace-angular-html/no-disabled-attribute-on-button": "error"
297+
"dspace-angular-html/no-disabled-attribute-on-button": "error",
298+
"@angular-eslint/template/prefer-control-flow": "error"
298299
}
299300
},
300301
{

angular.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,10 @@
5858
"input": "src/themes/dspace/styles/theme.scss",
5959
"inject": false,
6060
"bundleName": "dspace-theme"
61-
}
61+
},
62+
"node_modules/leaflet/dist/leaflet.css",
63+
"node_modules/leaflet.markercluster/dist/MarkerCluster.Default.css",
64+
"node_modules/leaflet.markercluster/dist/MarkerCluster.css"
6265
],
6366
"scripts": [],
6467
"baseHref": "/"

config/config.example.yml

Lines changed: 63 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,9 @@ ssr:
2424
# disabled (false) by default to boost server performance at the expense of loading smoothness.
2525
inlineCriticalCss: false
2626
# Path prefixes to enable SSR for. By default these are limited to paths of primary DSpace objects.
27-
paths: [ '/home', '/items/', '/entities/', '/collections/', '/communities/', '/bitstream/', '/bitstreams/', '/handle/' ]
27+
# NOTE: The "/handle/" path ensures Handle redirects work via SSR. The "/reload/" path ensures
28+
# hard refreshes (e.g. after login) trigger SSR while fully reloading the page.
29+
paths: [ '/home', '/items/', '/entities/', '/collections/', '/communities/', '/bitstream/', '/bitstreams/', '/handle/', '/reload/' ]
2830
# Whether to enable rendering of Search component on SSR.
2931
# If set to true the component will be included in the HTML returned from the server side rendering.
3032
# If set to false the component will not be included in the HTML returned from the server side rendering.
@@ -33,6 +35,19 @@ ssr:
3335
# If set to true the component will be included in the HTML returned from the server side rendering.
3436
# If set to false the component will not be included in the HTML returned from the server side rendering.
3537
enableBrowseComponent: false
38+
# Enable state transfer from the server-side application to the client-side application.
39+
# Defaults to true.
40+
# Note: When using an external application cache layer, it's recommended not to transfer the state to avoid caching it.
41+
# Disabling it ensures that dynamic state information is not inadvertently cached, which can improve security and
42+
# ensure that users always use the most up-to-date state.
43+
transferState: true
44+
# When a different REST base URL is used for the server-side application, the generated state contains references to
45+
# REST resources with the internal URL configured. By default, these internal URLs are replaced with public URLs.
46+
# Disable this setting to avoid URL replacement during SSR. In this the state is not transferred to avoid security issues.
47+
replaceRestUrl: true
48+
# Enable request performance profiling data collection and printing the results in the server console.
49+
# Defaults to false. Enabling in production is NOT recommended
50+
#enablePerformanceProfiler: false
3651

3752
# The REST API server settings
3853
# NOTE: these settings define which (publicly available) REST API to use. They are usually
@@ -43,6 +58,9 @@ rest:
4358
port: 443
4459
# NOTE: Space is capitalized because 'namespace' is a reserved string in TypeScript
4560
nameSpace: /server
61+
# Provide a different REST url to be used during SSR execution. It must contain the whole url including protocol, server port and
62+
# server namespace (uncomment to use it).
63+
#ssrBaseUrl: http://localhost:8080/server
4664

4765
# Caching settings
4866
cache:
@@ -332,15 +350,25 @@ item:
332350
# Rounded to the nearest size in the list of selectable sizes on the
333351
# settings menu. See pageSizeOptions in 'pagination-component-options.model.ts'.
334352
pageSize: 5
353+
# Show the bitstream access status label on the item page
354+
showAccessStatuses: false
335355

336356
# Community Page Config
337357
community:
358+
# Default tab to be shown when browsing a Community. Valid values are: comcols, search, or browse_<field>
359+
# <field> must be any of the configured "browse by" fields, e.g., dateissued, author, title, or subject
360+
# When the default tab is not the 'search' tab, the search tab is moved to the last position
361+
defaultBrowseTab: search
338362
# Search tab config
339363
searchSection:
340364
showSidebar: true
341365

342366
# Collection Page Config
343367
collection:
368+
# Default tab to be shown when browsing a Collection. Valid values are: search, or browse_<field>
369+
# <field> must be any of the configured "browse by" fields, e.g., dateissued, author, title, or subject
370+
# When the default tab is not the 'search' tab, the search tab is moved to the last position
371+
defaultBrowseTab: search
344372
# Search tab config
345373
searchSection:
346374
showSidebar: true
@@ -518,7 +546,6 @@ notifyMetrics:
518546
config: 'NOTIFY.outgoing.delivered'
519547
description: 'admin-notify-dashboard.NOTIFY.outgoing.delivered.description'
520548

521-
522549
# Live Region configuration
523550
# Live Region as defined by w3c, https://www.w3.org/TR/wai-aria-1.1/#terms:
524551
# Live regions are perceivable regions of a web page that are typically updated as a
@@ -532,3 +559,37 @@ liveRegion:
532559
messageTimeOutDurationMs: 30000
533560
# The visibility of the live region. Setting this to true is only useful for debugging purposes.
534561
isVisible: false
562+
563+
# Geospatial Map display options
564+
geospatialMapViewer:
565+
# Which fields to use for parsing as geospatial points in search maps
566+
# (note, the item page field component allows any field(s) to be used
567+
# and is set as an input when declaring the component)
568+
spatialMetadataFields:
569+
- 'dcterms.spatial'
570+
# Which discovery configuration to use for 'geospatial search', used
571+
# in the browse map
572+
spatialFacetDiscoveryConfiguration: 'geospatial'
573+
# Which filter / facet name to use for faceted geospatial search
574+
# used in the browse map
575+
spatialPointFilterName: 'point'
576+
# Whether item page geospatial metadata should be displayed
577+
# (assumes they are wrapped in a test for this config in the template as
578+
# per the default templates supplied with DSpace for untyped-item and publication)
579+
enableItemPageFields: false
580+
# Whether the browse map should be enabled and included in the browse menu
581+
enableBrowseMap: false
582+
# Whether a 'map view' mode should be included alongside list and grid views
583+
# in search result pages
584+
enableSearchViewMode: false
585+
# The tile provider(s) to use for the map tiles drawn in the leaflet maps.
586+
# (see https://leaflet-extras.github.io/leaflet-providers/preview/) for a full list
587+
tileProviders:
588+
- 'OpenStreetMap.Mapnik'
589+
# Starting centre point for the map, as lat and lng coordinates. This is useful
590+
# to set the centre of the map when the map is first loaded and if there are no
591+
# points, shapes or markers to display.
592+
# Defaults to the centre of Istanbul
593+
defaultCentrePoint:
594+
lat: 41.015137
595+
lng: 28.979530

cypress/e2e/admin-sidebar.cy.ts

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { testA11y } from 'cypress/support/utils';
2-
import { Options } from 'cypress-axe';
32

43
describe('Admin Sidebar', () => {
54
beforeEach(() => {
@@ -16,13 +15,6 @@ describe('Admin Sidebar', () => {
1615
cy.get('ds-expandable-admin-sidebar-section').click({ multiple: true });
1716

1817
// Analyze <ds-admin-sidebar> for accessibility
19-
testA11y('ds-admin-sidebar',
20-
{
21-
rules: {
22-
// Currently all expandable sections have nested interactive elements
23-
// See https://github.com/DSpace/dspace-angular/issues/2178
24-
'nested-interactive': { enabled: false },
25-
},
26-
} as Options);
18+
testA11y('ds-admin-sidebar');
2719
});
2820
});

cypress/e2e/community-list.cy.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,13 @@ describe('Community List Page', () => {
1212
cy.get('[data-test="expand-button"]').click({ multiple: true });
1313

1414
// Analyze <ds-community-list-page> for accessibility issues
15-
testA11y('ds-community-list-page');
15+
testA11y('ds-community-list-page', {
16+
rules: {
17+
// When expanding a cdk node on the community-list page, the 'aria-posinset' property becomes 0.
18+
// 0 is not a valid value for 'aria-posinset' so the test fails.
19+
// see https://github.com/DSpace/dspace-angular/issues/4068
20+
'aria-valid-attr-value': { enabled: false },
21+
},
22+
});
1623
});
1724
});

cypress/e2e/submission.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ describe('New Submission page', () => {
217217
});
218218

219219
// Close popup window
220-
cy.get('ds-dynamic-lookup-relation-modal button.close').click();
220+
cy.get('ds-dynamic-lookup-relation-modal button.btn-close').click();
221221

222222
// Back on the form, click the discard button to remove new submission
223223
// Clicking it will display a confirmation, which we will confirm with another click

cypress/tsconfig.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
11
{
22
"extends": "../tsconfig.json",
33
"include": [
4-
"**/*.ts"
4+
"**/*.ts",
5+
"../cypress.config.ts"
56
],
67
"compilerOptions": {
78
"sourceMap": false,
9+
"typeRoots": [
10+
"../node_modules",
11+
"../node_modules/@types",
12+
"../src/typings.d.ts"
13+
],
814
"types": [
915
"cypress",
1016
"cypress-axe",

0 commit comments

Comments
 (0)