@quadrats/react 0.5.9 → 0.5.10
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/blockquote/defaultRenderBlockquoteElement.js +1 -1
- package/blockquote/index.cjs.js +1 -1
- package/divider/defaultRenderDividerElement.js +1 -1
- package/divider/index.cjs.js +1 -1
- package/embed/components/VideoIframe.d.ts +1 -1
- package/embed/components/VideoIframe.js +2 -2
- package/embed/index.cjs.js +2 -2
- package/embed/renderers/facebook/components/Facebook.js +1 -1
- package/embed/renderers/facebook/index.cjs.js +1 -1
- package/embed/renderers/instagram/components/Instagram.js +1 -1
- package/embed/renderers/instagram/index.cjs.js +1 -1
- package/embed/renderers/podcast-apple/components/PodcastApple.d.ts +2 -3
- package/embed/renderers/podcast-apple/components/PodcastApple.js +1 -1
- package/embed/renderers/podcast-apple/index.cjs.js +1 -1
- package/embed/renderers/spotify/components/Spotify.js +1 -1
- package/embed/renderers/spotify/index.cjs.js +1 -1
- package/embed/renderers/twitter/components/Twitter.js +1 -1
- package/embed/renderers/twitter/index.cjs.js +1 -1
- package/footnote/defaultRenderFootnoteElement.js +2 -2
- package/footnote/index.cjs.js +2 -2
- package/heading/defaultRenderHeadingElement.js +1 -1
- package/heading/index.cjs.js +1 -1
- package/input-block/components/InputBlock.js +1 -1
- package/input-block/index.cjs.js +1 -1
- package/link/defaultRenderLinkElement.js +1 -1
- package/link/index.cjs.js +1 -1
- package/list/defaultRenderListElements.js +3 -3
- package/list/index.cjs.js +3 -3
- package/package.json +2 -2
- package/paragraph/defaultRenderParagraphElement.js +1 -1
- package/paragraph/index.cjs.js +2 -2
- package/paragraph/renderParagraphElementWithSymbol.js +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
const defaultRenderBlockquoteElement = ({ attributes, children, }) => React.createElement("blockquote", Object.assign({}, attributes), children);
|
|
3
|
+
const defaultRenderBlockquoteElement = ({ attributes, children, }) => React.createElement("blockquote", Object.assign({}, attributes, { className: "qdr-blockquote" }), children);
|
|
4
4
|
|
|
5
5
|
export { defaultRenderBlockquoteElement };
|
package/blockquote/index.cjs.js
CHANGED
|
@@ -20,7 +20,7 @@ var isHotkey__default = /*#__PURE__*/_interopDefaultLegacy(isHotkey);
|
|
|
20
20
|
*/
|
|
21
21
|
const BLOCKQUOTE_HOTKEY = 'ctrl+opt+q';
|
|
22
22
|
|
|
23
|
-
const defaultRenderBlockquoteElement = ({ attributes, children, }) => React__default.createElement("blockquote", Object.assign({}, attributes), children);
|
|
23
|
+
const defaultRenderBlockquoteElement = ({ attributes, children, }) => React__default.createElement("blockquote", Object.assign({}, attributes, { className: "qdr-blockquote" }), children);
|
|
24
24
|
|
|
25
25
|
function createReactBlockquote(options = {}) {
|
|
26
26
|
const core = blockquote.createBlockquote(options);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
const defaultRenderDividerElement = ({ attributes, children }) => (React.createElement("div", Object.assign({}, attributes, { contentEditable: false }),
|
|
3
|
+
const defaultRenderDividerElement = ({ attributes, children }) => (React.createElement("div", Object.assign({}, attributes, { className: "qdr-divider", contentEditable: false }),
|
|
4
4
|
React.createElement("hr", null),
|
|
5
5
|
children));
|
|
6
6
|
|
package/divider/index.cjs.js
CHANGED
|
@@ -10,7 +10,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
10
10
|
|
|
11
11
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
12
12
|
|
|
13
|
-
const defaultRenderDividerElement = ({ attributes, children }) => (React__default.createElement("div", Object.assign({}, attributes, { contentEditable: false }),
|
|
13
|
+
const defaultRenderDividerElement = ({ attributes, children }) => (React__default.createElement("div", Object.assign({}, attributes, { className: "qdr-divider", contentEditable: false }),
|
|
14
14
|
React__default.createElement("hr", null),
|
|
15
15
|
children));
|
|
16
16
|
|
|
@@ -7,5 +7,5 @@ export interface VideoIframeProps<E extends EmbedElement> {
|
|
|
7
7
|
data: string;
|
|
8
8
|
element: E;
|
|
9
9
|
}
|
|
10
|
-
declare function VideoIframe<E extends EmbedElement>({ attributes, children, data: src }: VideoIframeProps<E>): JSX.Element;
|
|
10
|
+
declare function VideoIframe<E extends EmbedElement>({ attributes, children, data: src, }: VideoIframeProps<E>): JSX.Element;
|
|
11
11
|
export default VideoIframe;
|
|
@@ -2,11 +2,11 @@ import React from 'react';
|
|
|
2
2
|
import { composeRefs } from '@quadrats/react/utils';
|
|
3
3
|
import { useVideoIframeSize } from '../hooks/useVideoIframeSize.js';
|
|
4
4
|
|
|
5
|
-
function VideoIframe({ attributes, children, data: src }) {
|
|
5
|
+
function VideoIframe({ attributes, children, data: src, }) {
|
|
6
6
|
const { ref } = attributes || {};
|
|
7
7
|
const { ref: containerRef, size } = useVideoIframeSize();
|
|
8
8
|
const composedRef = ref ? composeRefs([ref, containerRef]) : containerRef;
|
|
9
|
-
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }),
|
|
9
|
+
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, className: "qdr-embed-video", contentEditable: false }),
|
|
10
10
|
React.createElement("div", { style: size },
|
|
11
11
|
React.createElement("iframe", { title: src, src: src, frameBorder: "0", width: "100%", height: "100%" })),
|
|
12
12
|
attributes ? children : undefined));
|
package/embed/index.cjs.js
CHANGED
|
@@ -32,11 +32,11 @@ function useVideoIframeSize() {
|
|
|
32
32
|
};
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
function VideoIframe({ attributes, children, data: src }) {
|
|
35
|
+
function VideoIframe({ attributes, children, data: src, }) {
|
|
36
36
|
const { ref } = attributes || {};
|
|
37
37
|
const { ref: containerRef, size } = useVideoIframeSize();
|
|
38
38
|
const composedRef = ref ? utils.composeRefs([ref, containerRef]) : containerRef;
|
|
39
|
-
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }),
|
|
39
|
+
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, className: "qdr-embed-video", contentEditable: false }),
|
|
40
40
|
React__default.createElement("div", { style: size },
|
|
41
41
|
React__default.createElement("iframe", { title: src, src: src, frameBorder: "0", width: "100%", height: "100%" })),
|
|
42
42
|
attributes ? children : undefined));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
3
|
function Facebook({ attributes, children, data: { url, width, height } }) {
|
|
4
|
-
return (React.createElement("div", Object.assign({}, attributes, { contentEditable: false }),
|
|
4
|
+
return (React.createElement("div", Object.assign({}, attributes, { className: "qdr-embed-facebook", contentEditable: false }),
|
|
5
5
|
React.createElement("iframe", { title: url, src: url, width: width, height: height, style: {
|
|
6
6
|
border: 0,
|
|
7
7
|
overflow: 'hidden',
|
|
@@ -9,7 +9,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
9
9
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
10
10
|
|
|
11
11
|
function Facebook({ attributes, children, data: { url, width, height } }) {
|
|
12
|
-
return (React__default.createElement("div", Object.assign({}, attributes, { contentEditable: false }),
|
|
12
|
+
return (React__default.createElement("div", Object.assign({}, attributes, { className: "qdr-embed-facebook", contentEditable: false }),
|
|
13
13
|
React__default.createElement("iframe", { title: url, src: url, width: width, height: height, style: {
|
|
14
14
|
border: 0,
|
|
15
15
|
overflow: 'hidden',
|
|
@@ -3,7 +3,7 @@ import { useLoadInstagramEmbedApi } from '../hooks/useLoadInstagramEmbedApi.js';
|
|
|
3
3
|
|
|
4
4
|
function Instagram({ attributes, children, data: permalink }) {
|
|
5
5
|
useLoadInstagramEmbedApi(permalink);
|
|
6
|
-
return (React.createElement("div", Object.assign({}, attributes, { contentEditable: false, style: {
|
|
6
|
+
return (React.createElement("div", Object.assign({}, attributes, { className: "qdr-embed-instagram", contentEditable: false, style: {
|
|
7
7
|
display: 'flex',
|
|
8
8
|
marginBottom: -12,
|
|
9
9
|
} }),
|
|
@@ -34,7 +34,7 @@ function useLoadInstagramEmbedApi(permalink) {
|
|
|
34
34
|
|
|
35
35
|
function Instagram({ attributes, children, data: permalink }) {
|
|
36
36
|
useLoadInstagramEmbedApi(permalink);
|
|
37
|
-
return (React__default.createElement("div", Object.assign({}, attributes, { contentEditable: false, style: {
|
|
37
|
+
return (React__default.createElement("div", Object.assign({}, attributes, { className: "qdr-embed-instagram", contentEditable: false, style: {
|
|
38
38
|
display: 'flex',
|
|
39
39
|
marginBottom: -12,
|
|
40
40
|
} }),
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
import { PropsWithChildren } from 'react';
|
|
2
2
|
import { PodcastAppleEmbedElement } from '@quadrats/common/embed/strategies/podcast-apple';
|
|
3
3
|
import { RenderElementProps } from '@quadrats/react';
|
|
4
4
|
export interface PodcastAppleProps {
|
|
5
5
|
attributes?: RenderElementProps['attributes'];
|
|
6
|
-
children?: any;
|
|
7
6
|
data: string;
|
|
8
7
|
element: PodcastAppleEmbedElement;
|
|
9
8
|
}
|
|
10
|
-
declare function PodcastApple({ attributes, children, data: src }: PodcastAppleProps): JSX.Element;
|
|
9
|
+
declare function PodcastApple({ attributes, children, data: src }: PropsWithChildren<PodcastAppleProps>): JSX.Element;
|
|
11
10
|
export default PodcastApple;
|
|
@@ -4,7 +4,7 @@ import { composeRefs } from '@quadrats/react/utils';
|
|
|
4
4
|
function PodcastApple({ attributes, children, data: src }) {
|
|
5
5
|
const containerRef = useRef(null);
|
|
6
6
|
const composedRef = composeRefs([attributes === null || attributes === void 0 ? void 0 : attributes.ref, containerRef]);
|
|
7
|
-
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }),
|
|
7
|
+
return (React.createElement("div", Object.assign({}, attributes, { className: "qdr-embed-podcast-apple", ref: composedRef, contentEditable: false }),
|
|
8
8
|
React.createElement("iframe", { title: src, src: src, frameBorder: "0", width: "100%", height: "450px" }),
|
|
9
9
|
attributes ? children : undefined));
|
|
10
10
|
}
|
|
@@ -12,7 +12,7 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
|
12
12
|
function PodcastApple({ attributes, children, data: src }) {
|
|
13
13
|
const containerRef = React.useRef(null);
|
|
14
14
|
const composedRef = utils.composeRefs([attributes === null || attributes === void 0 ? void 0 : attributes.ref, containerRef]);
|
|
15
|
-
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }),
|
|
15
|
+
return (React__default.createElement("div", Object.assign({}, attributes, { className: "qdr-embed-podcast-apple", ref: composedRef, contentEditable: false }),
|
|
16
16
|
React__default.createElement("iframe", { title: src, src: src, frameBorder: "0", width: "100%", height: "450px" }),
|
|
17
17
|
attributes ? children : undefined));
|
|
18
18
|
}
|
|
@@ -5,7 +5,7 @@ function Spotify({ attributes, children, data: src }) {
|
|
|
5
5
|
const containerRef = useRef(null);
|
|
6
6
|
const composedRef = composeRefs([attributes === null || attributes === void 0 ? void 0 : attributes.ref, containerRef]);
|
|
7
7
|
const higher = useMemo(() => (!!src.match(/\/playlist/)), [src]);
|
|
8
|
-
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }),
|
|
8
|
+
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, className: "qdr-embed-spotify", contentEditable: false }),
|
|
9
9
|
React.createElement("iframe", { title: src, src: src, frameBorder: "0", width: "100%", allow: "autoplay", "clipboard-write": "true", "encrypted-media": "true", "picture-in-picture": "true", height: higher ? '400px' : '152px', style: {
|
|
10
10
|
maxHeight: '100%',
|
|
11
11
|
height: higher ? '400px' : '152px',
|
|
@@ -13,7 +13,7 @@ function Spotify({ attributes, children, data: src }) {
|
|
|
13
13
|
const containerRef = React.useRef(null);
|
|
14
14
|
const composedRef = utils.composeRefs([attributes === null || attributes === void 0 ? void 0 : attributes.ref, containerRef]);
|
|
15
15
|
const higher = React.useMemo(() => (!!src.match(/\/playlist/)), [src]);
|
|
16
|
-
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }),
|
|
16
|
+
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, className: "qdr-embed-spotify", contentEditable: false }),
|
|
17
17
|
React__default.createElement("iframe", { title: src, src: src, frameBorder: "0", width: "100%", allow: "autoplay", "clipboard-write": "true", "encrypted-media": "true", "picture-in-picture": "true", height: higher ? '400px' : '152px', style: {
|
|
18
18
|
maxHeight: '100%',
|
|
19
19
|
height: higher ? '400px' : '152px',
|
|
@@ -6,7 +6,7 @@ function Twitter({ attributes, children, data: tweetId }) {
|
|
|
6
6
|
const tweetContainerRef = useRef(null);
|
|
7
7
|
const composedRef = composeRefs([attributes === null || attributes === void 0 ? void 0 : attributes.ref, tweetContainerRef]);
|
|
8
8
|
useLoadTwitterEmbedApi(tweetId, tweetContainerRef);
|
|
9
|
-
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }), attributes ? children : undefined));
|
|
9
|
+
return (React.createElement("div", Object.assign({}, attributes, { ref: composedRef, className: "qdr-embed-twitter", contentEditable: false }), attributes ? children : undefined));
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
export { Twitter as default };
|
|
@@ -43,7 +43,7 @@ function Twitter({ attributes, children, data: tweetId }) {
|
|
|
43
43
|
const tweetContainerRef = React.useRef(null);
|
|
44
44
|
const composedRef = utils.composeRefs([attributes === null || attributes === void 0 ? void 0 : attributes.ref, tweetContainerRef]);
|
|
45
45
|
useLoadTwitterEmbedApi(tweetId, tweetContainerRef);
|
|
46
|
-
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, contentEditable: false }), attributes ? children : undefined));
|
|
46
|
+
return (React__default.createElement("div", Object.assign({}, attributes, { ref: composedRef, className: "qdr-embed-twitter", contentEditable: false }), attributes ? children : undefined));
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
const defaultRenderTwitterEmbedElement = (props) => React__default.createElement(Twitter, Object.assign({}, props));
|
|
@@ -8,8 +8,8 @@ const defaultRenderFootnoteElement = ({ attributes, children, element, placement
|
|
|
8
8
|
const { footnote, index } = element;
|
|
9
9
|
return (React.createElement(React.Fragment, null,
|
|
10
10
|
React.createElement(Tooltip, { placement: placement, popup: footnote },
|
|
11
|
-
React.createElement("span", Object.assign({ style: { textDecoration: 'underline' } }, attributes), children)),
|
|
12
|
-
React.createElement("sup", Object.assign({}, attributes, { style: { color: 'var(--qdr-sup)', userSelect: 'none' }, contentEditable: false }), `[${index !== null && index !== void 0 ? index : 1}]`)));
|
|
11
|
+
React.createElement("span", Object.assign({ style: { textDecoration: 'underline' } }, attributes, { className: "qdr-footnote-text" }), children)),
|
|
12
|
+
React.createElement("sup", Object.assign({}, attributes, { className: "qdr-footnote-sup", style: { color: 'var(--qdr-sup)', userSelect: 'none' }, contentEditable: false }), `[${index !== null && index !== void 0 ? index : 1}]`)));
|
|
13
13
|
};
|
|
14
14
|
|
|
15
15
|
export { defaultRenderFootnoteElement };
|
package/footnote/index.cjs.js
CHANGED
|
@@ -19,8 +19,8 @@ const defaultRenderFootnoteElement = ({ attributes, children, element, placement
|
|
|
19
19
|
const { footnote, index } = element;
|
|
20
20
|
return (React__default.createElement(React__default.Fragment, null,
|
|
21
21
|
React__default.createElement(components.Tooltip, { placement: placement, popup: footnote },
|
|
22
|
-
React__default.createElement("span", Object.assign({ style: { textDecoration: 'underline' } }, attributes), children)),
|
|
23
|
-
React__default.createElement("sup", Object.assign({}, attributes, { style: { color: 'var(--qdr-sup)', userSelect: 'none' }, contentEditable: false }), `[${index !== null && index !== void 0 ? index : 1}]`)));
|
|
22
|
+
React__default.createElement("span", Object.assign({ style: { textDecoration: 'underline' } }, attributes, { className: "qdr-footnote-text" }), children)),
|
|
23
|
+
React__default.createElement("sup", Object.assign({}, attributes, { className: "qdr-footnote-sup", style: { color: 'var(--qdr-sup)', userSelect: 'none' }, contentEditable: false }), `[${index !== null && index !== void 0 ? index : 1}]`)));
|
|
24
24
|
};
|
|
25
25
|
|
|
26
26
|
function createReactFootnote(options = {}) {
|
|
@@ -13,7 +13,7 @@ const defaultRenderHeadingElement = ({ attributes, children, element, }) => {
|
|
|
13
13
|
if (!Component) {
|
|
14
14
|
return null;
|
|
15
15
|
}
|
|
16
|
-
return React.createElement(Component, Object.assign({}, attributes), children);
|
|
16
|
+
return React.createElement(Component, Object.assign({}, attributes, { className: `qdr-${Component}` }), children);
|
|
17
17
|
};
|
|
18
18
|
|
|
19
19
|
export { HEADING_COMPONENTS, defaultRenderHeadingElement };
|
package/heading/index.cjs.js
CHANGED
|
@@ -36,7 +36,7 @@ const defaultRenderHeadingElement = ({ attributes, children, element, }) => {
|
|
|
36
36
|
if (!Component) {
|
|
37
37
|
return null;
|
|
38
38
|
}
|
|
39
|
-
return React__default.createElement(Component, Object.assign({}, attributes), children);
|
|
39
|
+
return React__default.createElement(Component, Object.assign({}, attributes, { className: `qdr-${Component}` }), children);
|
|
40
40
|
};
|
|
41
41
|
|
|
42
42
|
function createReactHeading(options = {}) {
|
|
@@ -6,7 +6,7 @@ function InputBlock(props) {
|
|
|
6
6
|
const { inputRef, onBlur, onKeyDown, placeholder, } = useInputBlock(props);
|
|
7
7
|
return (React.createElement("div", Object.assign({}, attributes, { contentEditable: false, style: {
|
|
8
8
|
display: 'flex',
|
|
9
|
-
} }),
|
|
9
|
+
}, className: "qdr-input-block" }),
|
|
10
10
|
React.createElement("input", { ref: inputRef, onBlur: onBlur, onKeyDown: onKeyDown, placeholder: placeholder, style: {
|
|
11
11
|
display: 'block',
|
|
12
12
|
color: 'currentColor',
|
package/input-block/index.cjs.js
CHANGED
|
@@ -60,7 +60,7 @@ function InputBlock(props) {
|
|
|
60
60
|
const { inputRef, onBlur, onKeyDown, placeholder, } = useInputBlock(props);
|
|
61
61
|
return (React__default.createElement("div", Object.assign({}, attributes, { contentEditable: false, style: {
|
|
62
62
|
display: 'flex',
|
|
63
|
-
} }),
|
|
63
|
+
}, className: "qdr-input-block" }),
|
|
64
64
|
React__default.createElement("input", { ref: inputRef, onBlur: onBlur, onKeyDown: onKeyDown, placeholder: placeholder, style: {
|
|
65
65
|
display: 'block',
|
|
66
66
|
color: 'currentColor',
|
|
@@ -7,7 +7,7 @@ import { Tooltip } from '@quadrats/react/components';
|
|
|
7
7
|
const defaultRenderLinkElement = ({ attributes, children, element, placement = 'bottom', target = '_blank', }) => {
|
|
8
8
|
const { url } = element;
|
|
9
9
|
return (React.createElement(Tooltip, { placement: placement, popup: url },
|
|
10
|
-
React.createElement("a", Object.assign({}, attributes, { href: url, target: target }), children)));
|
|
10
|
+
React.createElement("a", Object.assign({}, attributes, { className: "qdr-link", href: url, target: target }), children)));
|
|
11
11
|
};
|
|
12
12
|
|
|
13
13
|
export { defaultRenderLinkElement };
|
package/link/index.cjs.js
CHANGED
|
@@ -17,7 +17,7 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
|
17
17
|
const defaultRenderLinkElement = ({ attributes, children, element, placement = 'bottom', target = '_blank', }) => {
|
|
18
18
|
const { url } = element;
|
|
19
19
|
return (React__default.createElement(components.Tooltip, { placement: placement, popup: url },
|
|
20
|
-
React__default.createElement("a", Object.assign({}, attributes, { href: url, target: target }), children)));
|
|
20
|
+
React__default.createElement("a", Object.assign({}, attributes, { className: "qdr-link", href: url, target: target }), children)));
|
|
21
21
|
};
|
|
22
22
|
|
|
23
23
|
function createReactLink(options = {}) {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
3
|
const defaultRenderListElements = {
|
|
4
|
-
ol: ({ attributes, children }) => React.createElement("ol", Object.assign({}, attributes), children),
|
|
5
|
-
ul: ({ attributes, children }) => React.createElement("ul", Object.assign({}, attributes), children),
|
|
6
|
-
li: ({ attributes, children }) => React.createElement("li", Object.assign({}, attributes), children),
|
|
4
|
+
ol: ({ attributes, children }) => React.createElement("ol", Object.assign({}, attributes, { className: "qdr-ol" }), children),
|
|
5
|
+
ul: ({ attributes, children }) => React.createElement("ul", Object.assign({}, attributes, { className: "qdr-ul" }), children),
|
|
6
|
+
li: ({ attributes, children }) => React.createElement("li", Object.assign({}, attributes, { className: "qdr-li" }), children),
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
export { defaultRenderListElements };
|
package/list/index.cjs.js
CHANGED
|
@@ -11,9 +11,9 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
11
11
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
12
12
|
|
|
13
13
|
const defaultRenderListElements = {
|
|
14
|
-
ol: ({ attributes, children }) => React__default.createElement("ol", Object.assign({}, attributes), children),
|
|
15
|
-
ul: ({ attributes, children }) => React__default.createElement("ul", Object.assign({}, attributes), children),
|
|
16
|
-
li: ({ attributes, children }) => React__default.createElement("li", Object.assign({}, attributes), children),
|
|
14
|
+
ol: ({ attributes, children }) => React__default.createElement("ol", Object.assign({}, attributes, { className: "qdr-ol" }), children),
|
|
15
|
+
ul: ({ attributes, children }) => React__default.createElement("ul", Object.assign({}, attributes, { className: "qdr-ul" }), children),
|
|
16
|
+
li: ({ attributes, children }) => React__default.createElement("li", Object.assign({}, attributes, { className: "qdr-li" }), children),
|
|
17
17
|
};
|
|
18
18
|
|
|
19
19
|
function createReactList(options = {}) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quadrats/react",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.10",
|
|
4
4
|
"description": "",
|
|
5
5
|
"author": "Rytass",
|
|
6
6
|
"homepage": "https://github.com/Quadrats/quadrats#readme",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"url": "https://github.com/Quadrats/quadrats/issues"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@quadrats/common": "^0.5.
|
|
23
|
+
"@quadrats/common": "^0.5.10",
|
|
24
24
|
"@quadrats/core": "^0.5.9",
|
|
25
25
|
"@quadrats/icons": "^0.5.0",
|
|
26
26
|
"@quadrats/locales": "^0.5.0",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
const defaultRenderParagraphElement = ({ attributes, children, }) => (React.createElement("p", Object.assign({}, attributes), children));
|
|
3
|
+
const defaultRenderParagraphElement = ({ attributes, children, }) => (React.createElement("p", Object.assign({}, attributes, { className: "qdr-paragraph" }), children));
|
|
4
4
|
|
|
5
5
|
export { defaultRenderParagraphElement };
|
package/paragraph/index.cjs.js
CHANGED
|
@@ -10,14 +10,14 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
10
10
|
|
|
11
11
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
12
12
|
|
|
13
|
-
const defaultRenderParagraphElement = ({ attributes, children, }) => (React__default.createElement("p", Object.assign({}, attributes), children));
|
|
13
|
+
const defaultRenderParagraphElement = ({ attributes, children, }) => (React__default.createElement("p", Object.assign({}, attributes, { className: "qdr-paragraph" }), children));
|
|
14
14
|
|
|
15
15
|
function createRenderParagraphElement(options = {}) {
|
|
16
16
|
const { render = defaultRenderParagraphElement } = options;
|
|
17
17
|
return react.createRenderElement({ type: core.PARAGRAPH_TYPE, render });
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
-
const renderParagraphElementWithSymbol = ({ attributes, children, }) => (React__default.createElement("p", Object.assign({}, attributes, { className: "qdr-paragraph__with-line-break-symbol" }), children));
|
|
20
|
+
const renderParagraphElementWithSymbol = ({ attributes, children, }) => (React__default.createElement("p", Object.assign({}, attributes, { className: "qdr-paragraph qdr-paragraph__with-line-break-symbol" }), children));
|
|
21
21
|
|
|
22
22
|
exports.createRenderParagraphElement = createRenderParagraphElement;
|
|
23
23
|
exports.defaultRenderParagraphElement = defaultRenderParagraphElement;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
const renderParagraphElementWithSymbol = ({ attributes, children, }) => (React.createElement("p", Object.assign({}, attributes, { className: "qdr-paragraph__with-line-break-symbol" }), children));
|
|
3
|
+
const renderParagraphElementWithSymbol = ({ attributes, children, }) => (React.createElement("p", Object.assign({}, attributes, { className: "qdr-paragraph qdr-paragraph__with-line-break-symbol" }), children));
|
|
4
4
|
|
|
5
5
|
export { renderParagraphElementWithSymbol };
|