- Styles(light-code): Default line wrapping of
<light-code>
is now"hard"
- Bug Fix(light-preview): Fixed a bug in Safari with vertical resizing.
- Feature(light-preview): Added the
after-actions
,above-expanded-code
, andafter-expanded-code
slots and parts. [#24] - Bug Fix(light-preview): now properly listens to changes to
unescapeBehavior
/unescape-behavior
[#24] - Bug Fix(light-editor): Properly insert new lines. [#25]
- BREAKING_CHANGE: All components are now scoped under
exports/components/<component-name>/<component-name>.js
- Bug Fix(light-code):
wrap="none"
properly renamed towrap="hard"
#22 - Bug Fix(light-code): Fixes wrapping in light-editor, and adjusts the
wrap
values to align with<light-pen>
#22 - Bug Fix(light-code) Line highlights now work properly when using
wrap="hard"
#22 - Bug Fix(light-code): Added cursor syncing due to line numbers obstructing view of text #22
-
Bug Fix(light-code): Fixed a bug that caused LineNumberPlugin to run before the Prism
afterTokenize
hooks. -
Styles(light-code):
<light-code>
refactored to use CSS variables for easier initial styling. -
Dependencies: Upgraded Lit and
form-associated-helpers
-
Feature: Add
src
attribute for loading remote content into<light-editor>
-
Feature: Added
highlighter
property to<light-code>
,<light-preview>
, and<light-editor>
for customizing the Prism instance. -
Bug Fix:
required
is not a proper boolean on<light-editor>
-
Styles(light-code):
<light-code>
(and<light-preview>
/<light-editor>
) got updates to their default theme and now have a number of syntax tokens to use for easy themeing. -
Docs: Added documentation on how to extend the Prism instance.
- Bug Fix:
<light-editor>
now properly scrolls. #15
- Bug Fix: gutter now behaves appropriately when scrolling on
wrap="hard"
#14
- Bug Fix: No longer wipe away state when resizing a
<light-preview>
#13
- Bug Fix: Fixed
gutter
in<light-code>
not extending the entire height of the element. - Bug Fix: Make
<iframe>
max-width: 100%; so it doesn't overflow preview container.
- Styles:
overflow: auto;
moved to[part~="base"]
in<light-preview>
- Bug Fix:
disable-highlight
anddisable-line-numbers
now works as expected in<light-preview>
- Bug Fix:
<light-preview>
fixesunescapeBehavior
attribute tounescape-behavior
- Bug Fix:
<light-code>
now properly supportswrap="hard"
.
- Bug Fix: Properly add
sandbox-settings
for<light-preview>
and<light-pen>
Bug Fix: <light-preview>
now correctly passes the wrap
property down to <light-code>
- BREAKING_CHANGE: The default entrypoint now registers all elements.
- BREAKING_CHANGE:
previewCode
has changed topreviewHtml
property andpreview-html
attribute for<light-preview>
. - Feature: Added
lineNumberStart
for counting indexes starting at a specific number. - Feature:
code
andpreview-code
attributes are now supported on<light-preview>
- Feature: Added
<light-code>
for displaying code. - Feature: Added line numbers to all code displays.
- Bug Fix:
<script>
tags now properly execute inside of<light-preview>
and have the scope of their shadow dom bound. - Improvement:
<light-editor>
,<light-code>
, and<light-preview>
all use<light-code>
internally now. - Improvement: Use declarative shadow DOM and fallback to polyfill in
<light-preview>
- Update form associated package
- Added form association to
<light-editor>
- Added
wrap="soft | hard"
to<light-preview>
and<light-editor>
- Added
preserve-whitespace
to the<light-pen>
to pass down to<light-editor>
<light-preview>
now properly creates a second level shadow dom so the preview's shadow dom styles don't leak.
- Switch to a
Prism
fork to play nicely with ESM and allow testing.
- Added
initialValue
to the<light-editor>
to allow for resetting the form input. - Fixed a bug where we would have Prism running automatically.
- Fixed a bug where
<light-pen>
was no resetting to initial values.
- BREAKING_CHANGE: Renamed
inline-preview
topreview-mode
for<light-preview>
with options of"iframe"
or"shadow-dom"
- BREAKING_CHANGE: Changed underlying highlighting library from Highlight.JS to PrismJS
- BREAKING_CHANGE:
<light-editor>
and<light-preview>
No longer attempt to escape / unescape characters in editors and previews. - BREAKING_CHANGE:
<light-preview>
has renamedhighlightLanguage
property tolanguage
.highlight-language
attribute has been renamed tolanguage
. - Added
<light-disclosure>
- Added
<light-editor>
<light-pen>
now uses<light-editor>
under the hood. A number of parts have been moved around for the editor.
- Don't use
src
orsrcdoc
, return to usingiframe.contentWindow.writeln(content)
due to fixing some CORS bugs.
- A number of fixes including allowing
<template>
elements to be slotted into<light-pen>
and<light-preview>
- fix: issues with
>
and<
- fix: allow any HTML Element for templating