Skip to content

Commit

Permalink
UIQM-580: Move QuickMarcView, PrintPopup and getHeaders to stripes-ma…
Browse files Browse the repository at this point in the history
…rc-components.
  • Loading branch information
Dmytro-Melnyshyn committed Oct 24, 2023
1 parent 3720ece commit c051337
Show file tree
Hide file tree
Showing 17 changed files with 4 additions and 696 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

* [UIQM-571](https://issues.folio.org/browse/UIQM-571) Added `marc-records-editor.item.put` to Derive and Create Bib permissions to fix issue with broken links after deriving or creating a record.
* [UIQM-543](https://issues.folio.org/browse/UIQM-543) Remove eslint deps that are already listed in eslint-config-stripes.
* [UIQM-580](https://issues.folio.org/browse/UIQM-580) Move QuickMarcView, PrintPopup and getHeaders to stripes-marc-components.

## [7.0.1](https://github.com/folio-org/ui-quick-marc/tree/v7.0.1) (2023-10-13)

Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@folio/quick-marc",
"version": "7.0.1",
"version": "7.1.0",
"description": "Quick MARC editor",
"main": "index.js",
"repository": "",
Expand Down Expand Up @@ -155,6 +155,7 @@
"@folio/stripes": "^9.0.0",
"@folio/stripes-cli": "^3.0.0",
"@folio/stripes-core": "^10.0.0",
"@folio/stripes-marc-components": "^1.0.0",
"@folio/stripes-testing": "^4.2.0",
"@formatjs/cli": "^6.1.3",
"core-js": "^3.6.1",
Expand Down Expand Up @@ -186,6 +187,7 @@
},
"peerDependencies": {
"@folio/stripes": "^9.0.0",
"@folio/stripes-marc-components": "^1.0.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-intl": "^6.4.4",
Expand Down
26 changes: 0 additions & 26 deletions src/QuickMarcEditor/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -1529,32 +1529,6 @@ export const hydrateForLinkSuggestions = (marcRecord, fields) => ({
_actionType: 'view',
});

export const getHeaders = (tenant, token, locale, method = 'GET') => {
// This is taken from stripes-connect/OkapiResource.js
const headers = {
POST: {
Accept: 'application/json',
},
DELETE: {
Accept: 'text/plain',
},
GET: {
Accept: 'application/json',
},
PUT: {
Accept: 'text/plain',
},
};

return {
...headers[method],
'Accept-Language': locale,
'Content-Type': 'application/json',
'X-Okapi-Tenant': tenant,
...(token && { 'X-Okapi-Token': token }),
};
};

export const changeTenantHeader = (ky, tenantId) => {
return ky.extend({
hooks: {
Expand Down
14 changes: 0 additions & 14 deletions src/QuickMarcView/MarcContent/MarcContent.css

This file was deleted.

69 changes: 0 additions & 69 deletions src/QuickMarcView/MarcContent/MarcContent.js

This file was deleted.

67 changes: 0 additions & 67 deletions src/QuickMarcView/MarcContent/MarcContent.test.js

This file was deleted.

1 change: 0 additions & 1 deletion src/QuickMarcView/MarcContent/index.js

This file was deleted.

3 changes: 0 additions & 3 deletions src/QuickMarcView/MarcField.css

This file was deleted.

122 changes: 0 additions & 122 deletions src/QuickMarcView/MarcField.js

This file was deleted.

22 changes: 0 additions & 22 deletions src/QuickMarcView/PrintPopup/PrintPopup.css

This file was deleted.

Loading

0 comments on commit c051337

Please sign in to comment.