Skip to content

Commit

Permalink
Release 4.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jvanbruegge committed Oct 25, 2017
1 parent 469b273 commit e0525e5
Show file tree
Hide file tree
Showing 8 changed files with 387 additions and 31 deletions.
2 changes: 1 addition & 1 deletion docs/assets/js/search.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 26 additions & 0 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,32 @@ <h1 id="cyclejs-modal">cyclejs-modal</h1>
<p>An easy way to open custom modals in a cyclejs app</p>
<h2 id="use-it">Use it</h2>
<p><code>npm install --save cyclejs-modal</code></p>
<h2 id="caveats">Caveats</h2>
<p><code>modalify</code> assumes that your DOM Driver is using the <code>DOM</code> property for sink and source.</p>
<h2 id="example">Example</h2>
<p>You can find the examples in the <a href="https://github.com/cyclejs-community/cyclejs-modal/tree/master/examples">examples/</a> folder</p>
<pre><code class="lang-js"><span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">main</span>(<span class="hljs-params">{ DOM }</span>) </span>{
<span class="hljs-keyword">return</span> {
<span class="hljs-attr">DOM</span>: xs.of(button(<span class="hljs-string">'.button'</span>, [<span class="hljs-string">'open modal'</span>])),
<span class="hljs-attr">modal</span>: DOM.select(<span class="hljs-string">'.button'</span>).events(<span class="hljs-string">'click'</span>)
.mapTo({
<span class="hljs-attr">type</span>: <span class="hljs-string">'open'</span>,
<span class="hljs-attr">component</span>: isolate(modal, <span class="hljs-string">'myscope'</span>)
} <span class="hljs-keyword">as</span> ModalAction)
};
}

<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">modal</span>(<span class="hljs-params">{ DOM }</span>) </span>{
<span class="hljs-keyword">return</span> {
<span class="hljs-attr">DOM</span>: xs.of(div(<span class="hljs-string">'.div'</span>, [
span(<span class="hljs-string">'.span'</span>, [<span class="hljs-string">'This is a modal. Yeah? :)'</span>]),
button(<span class="hljs-string">'.button'</span>, [<span class="hljs-string">'close'</span>])
])),
<span class="hljs-attr">modal</span>: DOM.select(<span class="hljs-string">'.button'</span>).events(<span class="hljs-string">'click'</span>)
.mapTo({ <span class="hljs-attr">type</span>: <span class="hljs-string">'close'</span> } <span class="hljs-keyword">as</span> ModalAction)
};
}
</code></pre>
<h2 id="try-it">Try it</h2>
<p>Clone it, run <code>npm i &amp;&amp; npm run examples</code></p>
</div>
Expand Down
7 changes: 5 additions & 2 deletions docs/interfaces/_modalify_.close.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ <h3><span class="tsd-flag ts-flagOptional">Optional</span> count</h3>
<div class="tsd-signature tsd-kind-icon">count<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/b29f89e/src/modalify.ts#L18">modalify.ts:18</a></li>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/469b273/src/modalify.ts#L18">modalify.ts:18</a></li>
</ul>
</aside>
</section>
Expand All @@ -109,7 +109,7 @@ <h3>type</h3>
<div class="tsd-signature tsd-kind-icon">type<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"close"</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/b29f89e/src/modalify.ts#L17">modalify.ts:17</a></li>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/469b273/src/modalify.ts#L17">modalify.ts:17</a></li>
</ul>
</aside>
</section>
Expand Down Expand Up @@ -149,6 +149,9 @@ <h3>type</h3>
<li class=" tsd-kind-interface tsd-parent-kind-external-module">
<a href="_modalify_.open.html" class="tsd-kind-icon">Open</a>
</li>
<li class=" tsd-kind-interface tsd-parent-kind-external-module">
<a href="_modalify_.options.html" class="tsd-kind-icon">Options</a>
</li>
<li class=" tsd-kind-type-alias tsd-parent-kind-external-module">
<a href="../modules/_modalify_.html#component" class="tsd-kind-icon">Component</a>
</li>
Expand Down
7 changes: 5 additions & 2 deletions docs/interfaces/_modalify_.message.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ <h3>payload</h3>
<div class="tsd-signature tsd-kind-icon">payload<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/b29f89e/src/modalify.ts#L22">modalify.ts:22</a></li>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/469b273/src/modalify.ts#L22">modalify.ts:22</a></li>
</ul>
</aside>
</section>
Expand All @@ -109,7 +109,7 @@ <h3>type</h3>
<div class="tsd-signature tsd-kind-icon">type<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"message"</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/b29f89e/src/modalify.ts#L21">modalify.ts:21</a></li>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/469b273/src/modalify.ts#L21">modalify.ts:21</a></li>
</ul>
</aside>
</section>
Expand Down Expand Up @@ -149,6 +149,9 @@ <h3>type</h3>
<li class=" tsd-kind-interface tsd-parent-kind-external-module">
<a href="_modalify_.open.html" class="tsd-kind-icon">Open</a>
</li>
<li class=" tsd-kind-interface tsd-parent-kind-external-module">
<a href="_modalify_.options.html" class="tsd-kind-icon">Options</a>
</li>
<li class=" tsd-kind-type-alias tsd-parent-kind-external-module">
<a href="../modules/_modalify_.html#component" class="tsd-kind-icon">Component</a>
</li>
Expand Down
7 changes: 5 additions & 2 deletions docs/interfaces/_modalify_.open.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ <h3>component</h3>
<div class="tsd-signature tsd-kind-icon">component<span class="tsd-signature-symbol">:</span> <a href="../modules/_modalify_.html#component" class="tsd-signature-type">Component</a></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/b29f89e/src/modalify.ts#L13">modalify.ts:13</a></li>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/469b273/src/modalify.ts#L13">modalify.ts:13</a></li>
</ul>
</aside>
</section>
Expand All @@ -109,7 +109,7 @@ <h3>type</h3>
<div class="tsd-signature tsd-kind-icon">type<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"open"</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/b29f89e/src/modalify.ts#L12">modalify.ts:12</a></li>
<li>Defined in <a href="https://github.com/cyclejs-community/cyclejs-modal/blob/469b273/src/modalify.ts#L12">modalify.ts:12</a></li>
</ul>
</aside>
</section>
Expand Down Expand Up @@ -149,6 +149,9 @@ <h3>type</h3>
</li>
</ul>
<ul class="after-current">
<li class=" tsd-kind-interface tsd-parent-kind-external-module">
<a href="_modalify_.options.html" class="tsd-kind-icon">Options</a>
</li>
<li class=" tsd-kind-type-alias tsd-parent-kind-external-module">
<a href="../modules/_modalify_.html#component" class="tsd-kind-icon">Component</a>
</li>
Expand Down
Loading

0 comments on commit e0525e5

Please sign in to comment.