hz-fillgaps is an haztivity resource.
hz-fillgaps uses jquery ui droppable and jquery ui draggable under the hood.
npm i --save @haztivity/hz-fillgaps
- JQuery
- JQuery UI dialog
- @haztivity/core
- Import @haztivity/hz-fillgaps
- Add HzFillgaps to the page
- Add de html
import {PageFactory, Page, PageController, PageRegister} from "@haztivity/core";
import template from "./page.pug";
import {HzFillgapsResource} from "@haztivity/hz-fillgaps";
export let page: PageRegister = PageFactory.createPage(
{
name: "myPage",
resources: [
HzFillgapsResource
],
template: template
}
);
div
.hz-fillgaps(data-hz-resource="HzFillgaps")
| Lorem ipsum dolor sit amet,
span.hz-fillgaps__gap consectetur
| adipiscing elit, sed do eiusmod tempor
span.hz-fillgaps__gap incididunt
| ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis
span.hz-fillgaps__gap ullamco
| laboris nisi ut aliquip ex ea commodo consequat.
or
<div class="hz-fillgaps" data-hz-resource="HzFillgaps">Lorem ipsum dolor sit amet,<span class="hz-fillgaps__gap">consectetur</span>adipiscing elit, sed do eiusmod tempor<span class="hz-fillgaps__gap">incididunt</span>ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis<span class="hz-fillgaps__gap">ullamco</span>laboris nisi ut aliquip ex ea commodo consequat.</div>
--