@internetarchive/ia-book-actions 1.1.0-alpha1 → 1.1.0-alpha3
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@internetarchive/ia-book-actions",
|
|
3
|
-
"version": "1.1.0-
|
|
3
|
+
"version": "1.1.0-alpha3",
|
|
4
4
|
"description": "Bookreader actions for borrowable book",
|
|
5
5
|
"author": "Internet Archive",
|
|
6
6
|
"license": "AGPL-3.0-only",
|
|
@@ -20,11 +20,10 @@
|
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@internetarchive/icon-info": "^1.2.6",
|
|
22
22
|
"@internetarchive/local-cache": "^0.2.1",
|
|
23
|
-
"@internetarchive/modal-manager": "
|
|
23
|
+
"@internetarchive/modal-manager": "1.0.3-alpha.1",
|
|
24
24
|
"@internetarchive/shared-resize-observer": "^0.2.0",
|
|
25
|
-
"@internetarchive/toast-manager": "0.1.0",
|
|
26
25
|
"install-deps": "^1.1.0",
|
|
27
|
-
"lit": "^2.
|
|
26
|
+
"lit": "^2.8.0",
|
|
28
27
|
"playwright": "^1.43.1"
|
|
29
28
|
},
|
|
30
29
|
"devDependencies": {
|
package/src/ia-book-actions.js
CHANGED
|
@@ -4,7 +4,7 @@ import { html, css, LitElement, nothing } from 'lit';
|
|
|
4
4
|
|
|
5
5
|
import { SharedResizeObserver } from '@internetarchive/shared-resize-observer';
|
|
6
6
|
import { ModalConfig } from '@internetarchive/modal-manager';
|
|
7
|
-
import { ToastConfig } from '@internetarchive/toast-manager';
|
|
7
|
+
// import { ToastConfig } from '@internetarchive/toast-manager';
|
|
8
8
|
import { LocalCache } from '@internetarchive/local-cache';
|
|
9
9
|
|
|
10
10
|
import './components/collapsible-action-group.js';
|
|
@@ -90,7 +90,7 @@ export default class IABookActions extends LitElement {
|
|
|
90
90
|
this.lendingOptions = {};
|
|
91
91
|
this.borrowType = null; // 'browsed'|'borrowed'
|
|
92
92
|
this.browseTimer = undefined; // timeout
|
|
93
|
-
this.timerExecutionSeconds =
|
|
93
|
+
this.timerExecutionSeconds = 10;
|
|
94
94
|
|
|
95
95
|
/** @deprecated */
|
|
96
96
|
this.toast = undefined;
|
|
@@ -403,7 +403,10 @@ export default class IABookActions extends LitElement {
|
|
|
403
403
|
></ia-activity-indicator>`
|
|
404
404
|
: 'Keep reading'}
|
|
405
405
|
</button>
|
|
406
|
-
<span
|
|
406
|
+
<span
|
|
407
|
+
style="position: absolute; visibility: none; height: 1px; width: 1px; overflow: hidden;"
|
|
408
|
+
>Renewing loan, one moment please.</span
|
|
409
|
+
>
|
|
407
410
|
<button
|
|
408
411
|
disabled
|
|
409
412
|
style="${modalButtonStyle.iaButton} ${modalButtonStyle.return}"
|
|
@@ -502,6 +505,7 @@ export default class IABookActions extends LitElement {
|
|
|
502
505
|
secondsLeft = secondsLeft > 60 ? secondsLeft : 60;
|
|
503
506
|
}
|
|
504
507
|
|
|
508
|
+
// eslint-disable-next-line no-undef
|
|
505
509
|
const config = new ToastConfig();
|
|
506
510
|
config.dismissOnClick = true;
|
|
507
511
|
config.texts = this.loanRenewHelper?.getMessageTexts(
|
|
@@ -985,17 +989,6 @@ export default class IABookActions extends LitElement {
|
|
|
985
989
|
--toastBGColor: #333;
|
|
986
990
|
--toastFontColor: #fff;
|
|
987
991
|
}
|
|
988
|
-
|
|
989
|
-
.sr-only {
|
|
990
|
-
position: absolute;
|
|
991
|
-
left: -9999px;
|
|
992
|
-
width: 1px;
|
|
993
|
-
height: 1px;
|
|
994
|
-
margin: 0;
|
|
995
|
-
padding: 0;
|
|
996
|
-
border: none;
|
|
997
|
-
overflow: hidden;
|
|
998
|
-
}
|
|
999
992
|
`;
|
|
1000
993
|
}
|
|
1001
994
|
}
|