@limetech/lime-elements 37.70.4 → 37.70.6
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/CHANGELOG.md +16 -0
- package/dist/cjs/limel-markdown.cjs.entry.js +1 -1
- package/dist/cjs/limel-prosemirror-adapter.cjs.entry.js +2 -2
- package/dist/cjs/limel-prosemirror-adapter.cjs.entry.js.map +1 -1
- package/dist/cjs/{markdown-parser-ba7cc71e.js → markdown-parser-d1887ec8.js} +12466 -421
- package/dist/cjs/markdown-parser-d1887ec8.js.map +1 -0
- package/dist/collection/components/markdown/markdown-parser.js +23 -0
- package/dist/collection/components/markdown/markdown-parser.js.map +1 -1
- package/dist/collection/components/text-editor/utils/html-converter.js +2 -2
- package/dist/collection/components/text-editor/utils/html-converter.js.map +1 -1
- package/dist/collection/style/mixins.scss +0 -95
- package/dist/esm/limel-markdown.entry.js +1 -1
- package/dist/esm/limel-prosemirror-adapter.entry.js +2 -2
- package/dist/esm/limel-prosemirror-adapter.entry.js.map +1 -1
- package/dist/esm/{markdown-parser-3c0af898.js → markdown-parser-90f72b15.js} +12466 -422
- package/dist/esm/markdown-parser-90f72b15.js.map +1 -0
- package/dist/lime-elements/lime-elements.esm.js +1 -1
- package/dist/lime-elements/p-26e8b51d.entry.js +2 -0
- package/dist/lime-elements/p-26e8b51d.entry.js.map +1 -0
- package/dist/lime-elements/p-3e8afa19.js +8 -0
- package/dist/lime-elements/p-3e8afa19.js.map +1 -0
- package/dist/lime-elements/{p-da20ff72.entry.js → p-4bfcb8c7.entry.js} +2 -2
- package/dist/lime-elements/style/mixins.scss +0 -95
- package/dist/scss/mixins.scss +0 -95
- package/dist/types/components/markdown/markdown-parser.d.ts +8 -0
- package/package.json +2 -1
- package/dist/cjs/markdown-parser-ba7cc71e.js.map +0 -1
- package/dist/collection/util/3d-tilt-hover-effect.js +0 -124
- package/dist/collection/util/3d-tilt-hover-effect.js.map +0 -1
- package/dist/esm/markdown-parser-3c0af898.js.map +0 -1
- package/dist/lime-elements/p-086509a5.js +0 -8
- package/dist/lime-elements/p-086509a5.js.map +0 -1
- package/dist/lime-elements/p-7098482d.entry.js +0 -2
- package/dist/lime-elements/p-7098482d.entry.js.map +0 -1
- package/dist/types/util/3d-tilt-hover-effect.d.ts +0 -93
- /package/dist/lime-elements/{p-da20ff72.entry.js.map → p-4bfcb8c7.entry.js.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as t,h as e}from"./p-443111b3.js";import{m as r}from"./p-
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as t,h as e}from"./p-443111b3.js";import{m as r}from"./p-3e8afa19.js";import"./p-eab67c09.js";const o='@charset "UTF-8";code{font-family:ui-monospace, "Cascadia Code", "Source Code Pro", Menlo, Consolas, "DejaVu Sans Mono", monospace;font-size:0.8125rem;letter-spacing:-0.0125rem;color:rgb(var(--contrast-1300));-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none;display:inline-block;border-radius:0.25rem;padding:0.03125rem 0.25rem;background-color:rgb(var(--contrast-600))}pre>code{display:block;margin:0.5rem 0;padding:0.5rem 0.75rem;overflow:auto;white-space:pre-wrap}h1{font-size:1.5rem}h2{font-size:1.25rem}h3{font-size:1.125rem}h4{font-size:1rem}h5{font-size:0.875rem}h6{font-size:0.75rem}h1,h2{margin-top:0.5rem;margin-bottom:0.5rem;letter-spacing:-0.03125rem;font-weight:500}h3,h4{margin-top:0.75rem;margin-bottom:0.25rem;font-weight:600}h5,h6{margin-top:0.5rem;margin-bottom:0.125rem;font-weight:600}h1,h2,h3,h4,h5,h6{word-break:break-word;hyphens:auto;-webkit-hyphens:auto}:not([contenteditable=true]) h1,:not([contenteditable=true]) h2,:not([contenteditable=true]) h3,:not([contenteditable=true]) h4,:not([contenteditable=true]) h5,:not([contenteditable=true]) h6{text-wrap:balance}[contenteditable=true] h1,[contenteditable=true] h2,[contenteditable=true] h3,[contenteditable=true] h4,[contenteditable=true] h5,[contenteditable=true] h6{text-wrap:initial}:host(limel-markdown.truncate-paragraphs) p{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}p,li{font-size:0.875rem;word-break:break-word;hyphens:auto;-webkit-hyphens:auto}a{word-break:break-all}p{margin-top:0;margin-bottom:0.5rem}p:only-child{margin-bottom:0}a{transition:color 0.2s ease;color:var(--markdown-hyperlink-color, rgb(var(--color-blue-dark)));text-decoration:none}a:hover{color:var(--markdown-hyperlink-color--hovered, rgb(var(--color-blue-default)))}hr{margin:1.75rem 0 2rem 0;border-width:0;border-top:1px solid rgb(var(--contrast-500))}ul{list-style:none}ul li{position:relative;margin-left:0.75rem}ul li:before{content:"";position:absolute;left:-0.5rem;top:0.5rem;width:0.25rem;height:0.25rem;border-radius:50%;background-color:rgb(var(--contrast-700));display:block}ol{margin-top:0.25rem;padding-left:1rem}ul{margin-top:0.25rem;padding-left:0}ul ul,ul ol,ol ol,ol ul{margin-left:0}li{margin-bottom:0.25rem}:host(limel-markdown:not(.no-table-styles)) table{table-layout:auto;min-width:100%;border-collapse:collapse;border-spacing:0;background:transparent;margin:0.75rem 0;border:1px solid rgb(var(--contrast-400))}:host(limel-markdown:not(.no-table-styles)) th,:host(limel-markdown:not(.no-table-styles)) td{text-align:left;vertical-align:top;transition:background-color 0.2s ease;font-size:0.875rem}:host(limel-markdown:not(.no-table-styles)) td{padding:0.5rem 0.375rem 0.75rem 0.375rem}:host(limel-markdown:not(.no-table-styles)) tr th{background-color:rgb(var(--contrast-400));padding:0.25rem 0.375rem;font-weight:normal}:host(limel-markdown:not(.no-table-styles)) tr th:only-child{text-align:center}:host(limel-markdown:not(.no-table-styles)) tbody tr:nth-child(odd) td{background-color:rgb(var(--contrast-200))}:host(limel-markdown:not(.no-table-styles)) tbody tr:hover td{background-color:rgb(var(--contrast-300))}blockquote{position:relative;font-weight:100;font-size:0.875rem;max-width:100%;line-height:1.4;margin:0;padding:0.5rem 1.25rem;border-radius:0.05rem 0.75rem;background-color:rgb(var(--contrast-300))}blockquote:before,blockquote:after{position:absolute;font-size:2.75rem;opacity:0.4}blockquote:before{content:"“";left:0;top:-0.75rem}blockquote:after{content:"”";right:0;bottom:-2rem}dl{display:grid;grid-template-columns:1fr 2fr;grid-template-rows:1fr;margin-bottom:2rem;border:1px solid rgb(var(--contrast-400));border-radius:0.375rem;background-color:rgb(var(--contrast-200))}dl dt,dl dd{padding:0.375rem 0.5rem;font-size:0.875rem;margin:0}dl dt:nth-of-type(even),dl dd:nth-of-type(even){background-color:rgb(var(--contrast-300))}dl dt:first-child{border-top-left-radius:0.375rem}dl dt:last-child{border-bottom-left-radius:0.375rem}dl dd:first-child{border-top-right-radius:0.375rem}dl dd:last-child{border-bottom-right-radius:0.375rem}hr{border-top:1px solid rgb(var(--contrast-700))}img{max-width:100%}.MsoNormal{margin:0}';const n=class{constructor(e){t(this,e);this.value=undefined;this.whitelist=undefined}async textChanged(){var t;try{const e=await r(this.value,{forceHardLineBreaks:true,whitelist:(t=this.whitelist)!==null&&t!==void 0?t:[]});this.rootElement.innerHTML=e}catch(t){console.error(t)}}async componentDidLoad(){this.textChanged()}render(){return[e("div",{id:"markdown",ref:t=>this.rootElement=t})]}static get watchers(){return{value:["textChanged"]}}};n.style=o;export{n as limel_markdown};
|
|
2
|
+
//# sourceMappingURL=p-4bfcb8c7.entry.js.map
|
|
@@ -456,98 +456,3 @@ $clickable-normal-state-transitions: (
|
|
|
456
456
|
clip-path: inset(50%);
|
|
457
457
|
white-space: nowrap;
|
|
458
458
|
}
|
|
459
|
-
|
|
460
|
-
// This mixin designed to enhance the visual effects,
|
|
461
|
-
// when the `tiltFollowingTheCursor` utility function from `3d-tilt-hover-effect.ts`
|
|
462
|
-
// is implemented in a component.
|
|
463
|
-
// This adds styles to a `<div class"limel-3d-hover-effect-glow" />`, needed to create
|
|
464
|
-
// a glow effect on a 3D element when the parent element is hovered.
|
|
465
|
-
// when the `tiltFollowingTheCursor` utility function from `3d-tilt-hover-effect.ts`
|
|
466
|
-
// Parts of these styles are controlled by the `titleFollowingTheCursor` function.
|
|
467
|
-
@mixin limel-3d-hover-effect-glow($the3dElement, $border-radius) {
|
|
468
|
-
.limel-3d-hover-effect-glow {
|
|
469
|
-
transition:
|
|
470
|
-
background 0.4s ease,
|
|
471
|
-
opacity 0.4s ease;
|
|
472
|
-
pointer-events: none;
|
|
473
|
-
|
|
474
|
-
position: absolute;
|
|
475
|
-
inset: 0;
|
|
476
|
-
border-radius: $border-radius;
|
|
477
|
-
|
|
478
|
-
opacity: 0.1;
|
|
479
|
-
#{$the3dElement}:hover & {
|
|
480
|
-
opacity: 0.5;
|
|
481
|
-
}
|
|
482
|
-
|
|
483
|
-
background-image: radial-gradient(
|
|
484
|
-
circle at var(--limel-3d-hover-effect-glow-position, 50% -20%),
|
|
485
|
-
rgb(var(--color-white), 0.3),
|
|
486
|
-
rgb(var(--color-white), 0)
|
|
487
|
-
);
|
|
488
|
-
|
|
489
|
-
mix-blend-mode: plus-lighter;
|
|
490
|
-
}
|
|
491
|
-
}
|
|
492
|
-
|
|
493
|
-
// These mixins below are designed to apply the necessary visual effects,
|
|
494
|
-
// when the `tiltFollowingTheCursor` utility function from `3d-tilt-hover-effect.ts`
|
|
495
|
-
// is implemented in a component.
|
|
496
|
-
@mixin parent-of-the-3d-element {
|
|
497
|
-
isolation: isolate;
|
|
498
|
-
transform-style: preserve-3d;
|
|
499
|
-
perspective: 1000px;
|
|
500
|
-
}
|
|
501
|
-
|
|
502
|
-
@mixin the-3d-element {
|
|
503
|
-
position: relative;
|
|
504
|
-
|
|
505
|
-
transition-duration: 0.8s;
|
|
506
|
-
transition-property: transform, box-shadow, background-color;
|
|
507
|
-
transition-timing-function: ease-out;
|
|
508
|
-
transform: scale3d(1, 1, 1) rotate3d(0, 0, 0, 0deg);
|
|
509
|
-
|
|
510
|
-
&:hover,
|
|
511
|
-
&:focus,
|
|
512
|
-
&:focus-visible,
|
|
513
|
-
&:focus-within {
|
|
514
|
-
will-change: background-color, box-shadow, transform;
|
|
515
|
-
}
|
|
516
|
-
|
|
517
|
-
&:hover,
|
|
518
|
-
&:focus,
|
|
519
|
-
&:focus-visible,
|
|
520
|
-
&:active {
|
|
521
|
-
transition-duration: 0.2s;
|
|
522
|
-
}
|
|
523
|
-
|
|
524
|
-
&:hover,
|
|
525
|
-
&:focus-visible {
|
|
526
|
-
box-shadow: var(--button-shadow-hovered);
|
|
527
|
-
}
|
|
528
|
-
|
|
529
|
-
&:hover {
|
|
530
|
-
transform: scale3d(1.01, 1.01, 1.01)
|
|
531
|
-
rotate3d(var(--limel-3d-hover-effect-rotate3d));
|
|
532
|
-
}
|
|
533
|
-
&:focus-visible {
|
|
534
|
-
transform: scale3d(1.01, 1.01, 1.01);
|
|
535
|
-
}
|
|
536
|
-
}
|
|
537
|
-
|
|
538
|
-
@mixin the-3d-element--clickable {
|
|
539
|
-
cursor: pointer;
|
|
540
|
-
box-shadow: var(--button-shadow-normal);
|
|
541
|
-
|
|
542
|
-
&:active {
|
|
543
|
-
transform: scale3d(1, 1, 1) rotate3d(0, 0, 0, 0deg);
|
|
544
|
-
box-shadow: var(--button-shadow-pressed);
|
|
545
|
-
}
|
|
546
|
-
|
|
547
|
-
&:focus-visible {
|
|
548
|
-
box-shadow: var(--button-shadow-hovered), var(--shadow-depth-8-focused);
|
|
549
|
-
}
|
|
550
|
-
&:focus-visible:active {
|
|
551
|
-
box-shadow: var(--button-shadow-pressed), var(--shadow-depth-8-focused);
|
|
552
|
-
}
|
|
553
|
-
}
|
package/dist/scss/mixins.scss
CHANGED
|
@@ -456,98 +456,3 @@ $clickable-normal-state-transitions: (
|
|
|
456
456
|
clip-path: inset(50%);
|
|
457
457
|
white-space: nowrap;
|
|
458
458
|
}
|
|
459
|
-
|
|
460
|
-
// This mixin designed to enhance the visual effects,
|
|
461
|
-
// when the `tiltFollowingTheCursor` utility function from `3d-tilt-hover-effect.ts`
|
|
462
|
-
// is implemented in a component.
|
|
463
|
-
// This adds styles to a `<div class"limel-3d-hover-effect-glow" />`, needed to create
|
|
464
|
-
// a glow effect on a 3D element when the parent element is hovered.
|
|
465
|
-
// when the `tiltFollowingTheCursor` utility function from `3d-tilt-hover-effect.ts`
|
|
466
|
-
// Parts of these styles are controlled by the `titleFollowingTheCursor` function.
|
|
467
|
-
@mixin limel-3d-hover-effect-glow($the3dElement, $border-radius) {
|
|
468
|
-
.limel-3d-hover-effect-glow {
|
|
469
|
-
transition:
|
|
470
|
-
background 0.4s ease,
|
|
471
|
-
opacity 0.4s ease;
|
|
472
|
-
pointer-events: none;
|
|
473
|
-
|
|
474
|
-
position: absolute;
|
|
475
|
-
inset: 0;
|
|
476
|
-
border-radius: $border-radius;
|
|
477
|
-
|
|
478
|
-
opacity: 0.1;
|
|
479
|
-
#{$the3dElement}:hover & {
|
|
480
|
-
opacity: 0.5;
|
|
481
|
-
}
|
|
482
|
-
|
|
483
|
-
background-image: radial-gradient(
|
|
484
|
-
circle at var(--limel-3d-hover-effect-glow-position, 50% -20%),
|
|
485
|
-
rgb(var(--color-white), 0.3),
|
|
486
|
-
rgb(var(--color-white), 0)
|
|
487
|
-
);
|
|
488
|
-
|
|
489
|
-
mix-blend-mode: plus-lighter;
|
|
490
|
-
}
|
|
491
|
-
}
|
|
492
|
-
|
|
493
|
-
// These mixins below are designed to apply the necessary visual effects,
|
|
494
|
-
// when the `tiltFollowingTheCursor` utility function from `3d-tilt-hover-effect.ts`
|
|
495
|
-
// is implemented in a component.
|
|
496
|
-
@mixin parent-of-the-3d-element {
|
|
497
|
-
isolation: isolate;
|
|
498
|
-
transform-style: preserve-3d;
|
|
499
|
-
perspective: 1000px;
|
|
500
|
-
}
|
|
501
|
-
|
|
502
|
-
@mixin the-3d-element {
|
|
503
|
-
position: relative;
|
|
504
|
-
|
|
505
|
-
transition-duration: 0.8s;
|
|
506
|
-
transition-property: transform, box-shadow, background-color;
|
|
507
|
-
transition-timing-function: ease-out;
|
|
508
|
-
transform: scale3d(1, 1, 1) rotate3d(0, 0, 0, 0deg);
|
|
509
|
-
|
|
510
|
-
&:hover,
|
|
511
|
-
&:focus,
|
|
512
|
-
&:focus-visible,
|
|
513
|
-
&:focus-within {
|
|
514
|
-
will-change: background-color, box-shadow, transform;
|
|
515
|
-
}
|
|
516
|
-
|
|
517
|
-
&:hover,
|
|
518
|
-
&:focus,
|
|
519
|
-
&:focus-visible,
|
|
520
|
-
&:active {
|
|
521
|
-
transition-duration: 0.2s;
|
|
522
|
-
}
|
|
523
|
-
|
|
524
|
-
&:hover,
|
|
525
|
-
&:focus-visible {
|
|
526
|
-
box-shadow: var(--button-shadow-hovered);
|
|
527
|
-
}
|
|
528
|
-
|
|
529
|
-
&:hover {
|
|
530
|
-
transform: scale3d(1.01, 1.01, 1.01)
|
|
531
|
-
rotate3d(var(--limel-3d-hover-effect-rotate3d));
|
|
532
|
-
}
|
|
533
|
-
&:focus-visible {
|
|
534
|
-
transform: scale3d(1.01, 1.01, 1.01);
|
|
535
|
-
}
|
|
536
|
-
}
|
|
537
|
-
|
|
538
|
-
@mixin the-3d-element--clickable {
|
|
539
|
-
cursor: pointer;
|
|
540
|
-
box-shadow: var(--button-shadow-normal);
|
|
541
|
-
|
|
542
|
-
&:active {
|
|
543
|
-
transform: scale3d(1, 1, 1) rotate3d(0, 0, 0, 0deg);
|
|
544
|
-
box-shadow: var(--button-shadow-pressed);
|
|
545
|
-
}
|
|
546
|
-
|
|
547
|
-
&:focus-visible {
|
|
548
|
-
box-shadow: var(--button-shadow-hovered), var(--shadow-depth-8-focused);
|
|
549
|
-
}
|
|
550
|
-
&:focus-visible:active {
|
|
551
|
-
box-shadow: var(--button-shadow-pressed), var(--shadow-depth-8-focused);
|
|
552
|
-
}
|
|
553
|
-
}
|
|
@@ -14,6 +14,14 @@ import { CustomElementDefinition } from '../../global/shared-types/custom-elemen
|
|
|
14
14
|
* @returns The resulting HTML.
|
|
15
15
|
*/
|
|
16
16
|
export declare function markdownToHTML(text: string, options?: markdownToHTMLOptions): Promise<string>;
|
|
17
|
+
/**
|
|
18
|
+
* Sanitizes a given HTML string by removing dangerous tags and attributes.
|
|
19
|
+
*
|
|
20
|
+
* @param html - The string containing HTML to sanitize.
|
|
21
|
+
* @param whitelist - Optional whitelist of custom components.
|
|
22
|
+
* @returns The sanitized HTML string.
|
|
23
|
+
*/
|
|
24
|
+
export declare function sanitizeHTML(html: string, whitelist?: CustomElementDefinition[]): Promise<string>;
|
|
17
25
|
/**
|
|
18
26
|
* Options for markdownToHTML.
|
|
19
27
|
*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@limetech/lime-elements",
|
|
3
|
-
"version": "37.70.
|
|
3
|
+
"version": "37.70.6",
|
|
4
4
|
"description": "Lime Elements",
|
|
5
5
|
"author": "Lime Technologies",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -96,6 +96,7 @@
|
|
|
96
96
|
"react-dom": "^18.3.1",
|
|
97
97
|
"react-shadow-dom-retarget-events": "^1.1.0",
|
|
98
98
|
"rehype-external-links": "^3.0.0",
|
|
99
|
+
"rehype-parse": "^9.0.1",
|
|
99
100
|
"rehype-raw": "^7.0.0",
|
|
100
101
|
"rehype-sanitize": "^6.0.0",
|
|
101
102
|
"rehype-stringify": "^10.0.1",
|