verstak 0.22.506 → 0.22.507

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.
@@ -1,8 +1,8 @@
1
1
  import { VBlock, Place, BlockArgs } from "../core/api";
2
2
  import { HtmlDriver } from "./HtmlDriver";
3
3
  export declare function Block<M = unknown, R = void>(name: string, args: BlockArgs<HTMLElement, M, R>): VBlock<HTMLElement, M, R>;
4
- export declare function PlainText(content: string, wrapping?: boolean): VBlock<HTMLElement, void, void>;
5
- export declare function HtmlText(content: string, wrapping?: boolean): VBlock<HTMLElement, void, void>;
4
+ export declare function PlainText(content: string, name?: string, args?: Partial<BlockArgs<HTMLElement, void, void>>): VBlock<HTMLElement, void, void>;
5
+ export declare function HtmlText(content: string, name?: string, args?: Partial<BlockArgs<HTMLElement, void, void>>): VBlock<HTMLElement, void, void>;
6
6
  export declare function Grid<M = unknown, R = void>(name: string, args: BlockArgs<HTMLElement, M, R>): VBlock<HTMLElement, M, R>;
7
7
  export declare function Line<T = void>(claim: (x: void) => T): VBlock<HTMLElement>;
8
8
  export declare function lineFeed(args?: BlockArgs<HTMLElement, void, void>, noCoalescing?: boolean): VBlock<HTMLElement>;
@@ -3,11 +3,11 @@ import { HtmlDriver } from "./HtmlDriver";
3
3
  export function Block(name, args) {
4
4
  return VBlock.claim(name, args, VerstakTags.block);
5
5
  }
6
- export function PlainText(content, wrapping) {
7
- return VBlock.claim("", { wrapping, render(e) { e.innerText = content; } }, VerstakTags.text);
6
+ export function PlainText(content, name, args) {
7
+ return VBlock.claim(name !== null && name !== void 0 ? name : "", Object.assign(Object.assign({}, args), { render(e) { e.innerText = content; } }), VerstakTags.text);
8
8
  }
9
- export function HtmlText(content, wrapping) {
10
- return VBlock.claim("", { wrapping, render(e) { e.innerHTML = content; } }, VerstakTags.text);
9
+ export function HtmlText(content, name, args) {
10
+ return VBlock.claim(name !== null && name !== void 0 ? name : "", Object.assign(Object.assign({}, args), { render(e) { e.innerHTML = content; } }), VerstakTags.text);
11
11
  }
12
12
  export function Grid(name, args) {
13
13
  return VBlock.claim(name, args, VerstakTags.grid);
@@ -100,7 +100,7 @@ export class VerstakDriver extends HtmlDriver {
100
100
  const wrapping = (_s = place === null || place === void 0 ? void 0 : place.wrapping) !== null && _s !== void 0 ? _s : false;
101
101
  if (wrapping !== ((_t = ex === null || ex === void 0 ? void 0 : ex.wrapping) !== null && _t !== void 0 ? _t : false)) {
102
102
  if (wrapping)
103
- native.setAttribute("wrapping", "");
103
+ native.setAttribute("wrapping", "true");
104
104
  else
105
105
  native.removeAttribute("wrapping");
106
106
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "verstak",
3
- "version": "0.22.506",
3
+ "version": "0.22.507",
4
4
  "description": "Verstak - Front-End Library",
5
5
  "publisher": "Nezaboodka Software",
6
6
  "license": "Apache-2.0",