Ghost/ghost/admin/lib/koenig-editor/addon/components/koenig-link-input.hbs
Kevin Ansfield d2fb2c8518 Added ability to make image cards links
refs https://github.com/TryGhost/Team/issues/465

- modifies `<KoenigLinkInput>` to add a "direct" mode that is not tied to editor selection
- adds link toolbar icon to image card toolbar
- adds link editing mode to image card that replaces toolbar with link input
- stores url in `href` attribute in card payload
2021-02-16 22:02:04 +00:00

14 lines
501 B
Handlebars

<input
placeholder="Enter url"
value={{this._href}}
class="kg-link-input pa2 pr6 mih-100 ba br3 shadow-2 f8 lh-heading tracked-2 outline-0 b--blue h10 nudge-top--8"
{{on "input" (action (mut this._href) value="target.value")}}
{{on "keydown" (action "inputKeydown")}}
/>
{{#if this._href}}
<button aria-label="Close" class="kg-input-bar-close" type="button" {{on "click" (action "clear")}}>
{{svg-jar "close" class="ih2 stroke-midlightgrey-l2"}}
</button>
{{/if}}