@d-i-t-a/reader 2.0.0-beta.16 → 2.0.0-beta.19
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/dist/esm/index.js +184 -12
- package/dist/esm/index.js.map +2 -2
- package/dist/injectables/style/popover.css +125 -0
- package/dist/reader.css +3 -5
- package/dist/reader.js +35 -32
- package/dist/reader.js.map +2 -2
- package/dist/reader.map.css +1 -1
- package/dist/types/model/Publication.d.ts +1 -0
- package/dist/types/modules/linefocus/LineFocusModule.d.ts +3 -0
- package/dist/types/modules/search/Popup.d.ts +2 -0
- package/dist/types/utils/EventHandler.d.ts +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2018-2020 DITA (AM Consulting LLC)
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*
|
|
16
|
+
* Developed on behalf of: DITA
|
|
17
|
+
* Licensed to: CAST under one or more contributor license agreements.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
.d2-popover {
|
|
21
|
+
position: fixed;
|
|
22
|
+
z-index: 10;
|
|
23
|
+
top: 0;
|
|
24
|
+
display: inline-block;
|
|
25
|
+
box-sizing: border-box;
|
|
26
|
+
width: 80%;
|
|
27
|
+
background: #fafafa;
|
|
28
|
+
opacity: 0;
|
|
29
|
+
border-radius: 0.5em;
|
|
30
|
+
border: 1px solid #c3c3c3;
|
|
31
|
+
box-shadow: 0px 0px 8px rgba(0, 0, 0, 0.3);
|
|
32
|
+
line-height: 0;
|
|
33
|
+
-webkit-transition-property: opacity, -webkit-transform;
|
|
34
|
+
transition-property: opacity, transform;
|
|
35
|
+
-webkit-transition-duration: 0.25s;
|
|
36
|
+
transition-duration: 0.25s;
|
|
37
|
+
-webkit-transition-timing-function: ease;
|
|
38
|
+
transition-timing-function: ease;
|
|
39
|
+
left: 50%;
|
|
40
|
+
transform: translateX(-50%) !important;
|
|
41
|
+
}
|
|
42
|
+
.d2-popover.is-active {
|
|
43
|
+
-webkit-transform: scale(1) translateZ(0);
|
|
44
|
+
transform: scale(1) translateZ(0);
|
|
45
|
+
opacity: 0.97;
|
|
46
|
+
}
|
|
47
|
+
.d2-popover.is-scrollable:after {
|
|
48
|
+
content: '';
|
|
49
|
+
position: absolute;
|
|
50
|
+
bottom: 0.3375em;
|
|
51
|
+
left: 0.3375em;
|
|
52
|
+
z-index: 14;
|
|
53
|
+
display: block;
|
|
54
|
+
height: 0.78125em;
|
|
55
|
+
width: 0.625em;
|
|
56
|
+
background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTJweCIgaGVpZ2h0PSIxNXB4IiB2aWV3Qm94PSIwIDAgMTIgMTUiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgcHJlc2VydmVBc3BlY3RSYXRpbz0ieE1pbllNaW4iPgogICAgPGcgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9IkFycm93IiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxLjAwMDAwMCwgMS4wMDAwMDApIiBzdHJva2U9ImJsYWNrIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJzcXVhcmUiPgogICAgICAgICAgICA8cGF0aCBkPSJNNSwwIEw1LDExLjUiIGlkPSJMaW5lIj48L3BhdGg+CiAgICAgICAgICAgIDxwYXRoIGQ9Ik0wLjUsNy41IEw1LjAyNzY5Mjc5LDEyLjAyNzY5MjgiIGlkPSJMaW5lIj48L3BhdGg+CiAgICAgICAgICAgIDxwYXRoIGQ9Ik00LjUsNy41IEw5LjAyNzY5Mjc5LDEyLjAyNzY5MjgiIGlkPSJMaW5lLTIiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDcuMDAwMDAwLCAxMC4wMDAwMDApIHNjYWxlKC0xLCAxKSB0cmFuc2xhdGUoLTcuMDAwMDAwLCAtMTAuMDAwMDAwKSAiPjwvcGF0aD4KICAgICAgICA8L2c+CiAgICA8L2c+Cjwvc3ZnPgo=");
|
|
57
|
+
background-size: cover;
|
|
58
|
+
opacity: 0.1;
|
|
59
|
+
transition-properties: opacity;
|
|
60
|
+
-webkit-transition-duration: 0.25s;
|
|
61
|
+
transition-duration: 0.25s;
|
|
62
|
+
-webkit-transition-timing-function: ease;
|
|
63
|
+
transition-timing-function: ease;
|
|
64
|
+
}
|
|
65
|
+
.d2-popover.is-scrollable .d2-d2-popover__wrapper:before, .d2-d2-popover.is-scrollable .d2-d2-popover__wrapper:after {
|
|
66
|
+
content: '';
|
|
67
|
+
position: absolute;
|
|
68
|
+
width: 100%;
|
|
69
|
+
height: 100%;
|
|
70
|
+
z-index: 12;
|
|
71
|
+
left: 0;
|
|
72
|
+
}
|
|
73
|
+
.d2-d2-popover.is-scrollable .d2-d2-popover__wrapper:before {
|
|
74
|
+
top: -1px;
|
|
75
|
+
height: 1.1em;
|
|
76
|
+
border-radius: 0.5em 0.5em 0 0;
|
|
77
|
+
background-image: -webkit-linear-gradient(top, #fafafa 50%, rgba(250, 250, 250, 0) 100%);
|
|
78
|
+
background-image: linear-gradient(to bottom, #fafafa 50%, rgba(250, 250, 250, 0) 100%);
|
|
79
|
+
}
|
|
80
|
+
.d2-popover.is-scrollable .d2-d2-popover__wrapper:after {
|
|
81
|
+
bottom: -1px;
|
|
82
|
+
height: 1.2em;
|
|
83
|
+
border-radius: 0 0 0.5em 0.5em;
|
|
84
|
+
background-image: -webkit-linear-gradient(bottom, #fafafa 50%, rgba(250, 250, 250, 0) 100%);
|
|
85
|
+
background-image: linear-gradient(to top, #fafafa 50%, rgba(250, 250, 250, 0) 100%);
|
|
86
|
+
}
|
|
87
|
+
.d2-popover.is-scrollable ::-webkit-scrollbar {
|
|
88
|
+
display: none;
|
|
89
|
+
}
|
|
90
|
+
.d2-popover.is-fully-scrolled:after, .d2-popover.is-fully-scrolled:before {
|
|
91
|
+
opacity: 0;
|
|
92
|
+
-webkit-transition-delay: 0;
|
|
93
|
+
transition-delay: 0;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.d2-popover-wrapper {
|
|
97
|
+
position: relative;
|
|
98
|
+
z-index: 14;
|
|
99
|
+
width: 100%;
|
|
100
|
+
height: 100%;
|
|
101
|
+
display: inline-block;
|
|
102
|
+
box-sizing: inherit;
|
|
103
|
+
overflow: hidden;
|
|
104
|
+
margin: 0;
|
|
105
|
+
background-color: #fafafa;
|
|
106
|
+
border-radius: 0.5em;
|
|
107
|
+
line-height: 0;
|
|
108
|
+
/*max-width: 353px;*/
|
|
109
|
+
}
|
|
110
|
+
.d2-popover-content {
|
|
111
|
+
position: relative;
|
|
112
|
+
width: 100%;
|
|
113
|
+
height: 100%;
|
|
114
|
+
z-index: 8;
|
|
115
|
+
display: inline-block;
|
|
116
|
+
max-height: 90vh;
|
|
117
|
+
padding: 1.1em 1.3em 1.2em;
|
|
118
|
+
box-sizing: inherit;
|
|
119
|
+
overflow: auto;
|
|
120
|
+
-webkit-overflow-scrolling: touch;
|
|
121
|
+
background: #fafafa;
|
|
122
|
+
border-radius: 0.5em;
|
|
123
|
+
-webkit-font-smoothing: subpixel-antialiased;
|
|
124
|
+
line-height: normal;
|
|
125
|
+
}
|
package/dist/reader.css
CHANGED
|
@@ -218,12 +218,11 @@ a {
|
|
|
218
218
|
user-select: none;
|
|
219
219
|
cursor: default; }
|
|
220
220
|
.loading .icon {
|
|
221
|
-
|
|
222
|
-
position: absolute;
|
|
221
|
+
position: sticky;
|
|
223
222
|
top: 50%;
|
|
224
223
|
left: 50%;
|
|
225
|
-
width:
|
|
226
|
-
height:
|
|
224
|
+
width: 4rem;
|
|
225
|
+
height: 4rem;
|
|
227
226
|
transform: translate(-50%, -50%);
|
|
228
227
|
fill: #9e9e9e; }
|
|
229
228
|
|
|
@@ -261,7 +260,6 @@ a {
|
|
|
261
260
|
height: 100%;
|
|
262
261
|
top: 0;
|
|
263
262
|
padding-top: 40vh;
|
|
264
|
-
position: fixed;
|
|
265
263
|
text-align: center;
|
|
266
264
|
width: 100%;
|
|
267
265
|
-webkit-user-select: none;
|