marquee-content 5.0.0 → 5.0.1
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/README.md +8 -10
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -25,18 +25,20 @@ Simple Web Component for marquee/ticker rows with smooth, continuous motion.
|
|
|
25
25
|
npm install marquee-content
|
|
26
26
|
```
|
|
27
27
|
|
|
28
|
+
Optional stylesheet (sidecar):
|
|
29
|
+
|
|
28
30
|
```ts
|
|
29
|
-
import 'marquee-content/marquee-content.css'
|
|
31
|
+
import 'marquee-content/marquee-content.css';
|
|
30
32
|
```
|
|
31
33
|
|
|
32
34
|
---
|
|
33
35
|
|
|
34
36
|
## Quick Start
|
|
35
37
|
|
|
36
|
-
|
|
38
|
+
Import the package once — it registers the custom element and applies bundled Shadow DOM styles automatically:
|
|
37
39
|
|
|
38
40
|
```ts
|
|
39
|
-
import 'marquee-content'
|
|
41
|
+
import 'marquee-content';
|
|
40
42
|
```
|
|
41
43
|
|
|
42
44
|
```html
|
|
@@ -112,16 +114,12 @@ marquee?.refresh()
|
|
|
112
114
|
|
|
113
115
|
## Styling
|
|
114
116
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
```ts
|
|
118
|
-
import 'marquee-content/marquee-content.css'
|
|
119
|
-
```
|
|
117
|
+
Base styles ship with the JS bundle and are adopted into each component's Shadow DOM. You do not need a separate CSS import for the marquee to work.
|
|
120
118
|
|
|
121
119
|
Runtime style overrides:
|
|
122
120
|
|
|
123
121
|
```ts
|
|
124
|
-
import { MarqueeContent } from 'marquee-content'
|
|
122
|
+
import { MarqueeContent } from 'marquee-content';
|
|
125
123
|
|
|
126
124
|
MarqueeContent.configureStyles({
|
|
127
125
|
styleOverrides: `
|
|
@@ -164,7 +162,7 @@ export default defineConfig({
|
|
|
164
162
|
Then import the package once during app startup:
|
|
165
163
|
|
|
166
164
|
```ts
|
|
167
|
-
import 'marquee-content'
|
|
165
|
+
import 'marquee-content';
|
|
168
166
|
```
|
|
169
167
|
|
|
170
168
|
---
|