progress on migrating to heex templates and font-icons

This commit is contained in:
Adam Piontek 2022-08-13 07:32:36 -04:00
parent d43daafdb7
commit 3eff955672
21793 changed files with 2161968 additions and 16895 deletions

12
assets_old/node_modules/posthtml-svg-mode/CHANGELOG.md generated vendored Normal file
View file

@ -0,0 +1,12 @@
# Change Log
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
<a name="1.0.3"></a>
## 1.0.3 (2018-10-29)
### Bug Fixes
* upgrade merge-options due to severity vulnerabilities ([0538c60](https://github.com/JetBrains/svg-mixer/tree/v1/posthtml-svg-mode/commit/0538c60))

18
assets_old/node_modules/posthtml-svg-mode/LICENSE generated vendored Normal file
View file

@ -0,0 +1,18 @@
Copyright 2018 JetBrains s.r.o.
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

1
assets_old/node_modules/posthtml-svg-mode/README.md generated vendored Normal file
View file

@ -0,0 +1 @@
# This module is DEPRECATED. Please use [postsvg](https://www.npmjs.com/package/postsvg) instead.

View file

@ -0,0 +1,11 @@
const createParser = require('posthtml-parser');
/**
* @see https://github.com/fb55/htmlparser2/wiki/Parser-options
*/
module.exports = createParser(({
xmlMode: true,
lowerCaseTags: false,
decodeEntities: false,
lowerCaseAttributeNames: false
}));

View file

@ -0,0 +1,70 @@
const PostHTML = require('posthtml');
const parser = require('./parser');
const renderer = require('./renderer');
/**
* @typedef {Object} PostHTMLTree
* @see https://github.com/posthtml/posthtml/blob/master/docs/tree.md#json
*/
class PostHTMLProcessingResult {
constructor(tree) {
this.tree = tree;
}
get html() {
return this.toString();
}
toString() {
return renderer(this.tree, this.tree.options);
}
render() {
return this.toString();
}
}
class Processor {
/**
* @param {Array<Function>} [plugins]
*/
constructor(plugins) {
const posthtml = this.posthtml = PostHTML(plugins);
this.version = posthtml.version;
this.name = posthtml.name;
this.plugins = posthtml.plugins;
}
/**
* @param {...Function} plugins
* @return {Processor}
*/
use(...plugins) {
this.posthtml.use.apply(this, ...plugins);
return this;
}
/**
* @param {string|PostHTMLTree} ast
* @param {Object} options {@see https://github.com/posthtml/posthtml-render#options}
* @return {Promise<PostHTMLProcessingResult>}
*/
process(ast, options = null) {
const opts = Object.assign({ parser }, options);
return this.posthtml.process(ast, opts).then(({ tree }) => new PostHTMLProcessingResult(tree));
}
}
Processor.parser = parser;
Processor.render = renderer;
/**
* @param {Array<Function>} [plugins]
* @return {Processor}
*/
module.exports = plugins => new Processor(plugins);
module.exports.parser = parser;
module.exports.renderer = renderer;
module.exports.Processor = Processor;
module.exports.Result = PostHTMLProcessingResult;

View file

@ -0,0 +1,49 @@
const merge = require('merge-options');
const renderer = require('posthtml-render');
const api = require('posthtml/lib/api');
const defaultOptions = {
closingSingleTag: 'slash',
singleTags: [
'circle',
'path',
'ellipse',
'line',
'path',
'polygon',
'polyline',
'rect',
'use',
'animateTransform',
'stop'
]
};
/**
* @param {PostHTMLTree} tree
* @param {Object|null} [options] {@see https://github.com/posthtml/posthtml-render#options}
*/
module.exports = function xmlRenderer(tree, options) {
const opts = merge(defaultOptions, options || {});
/**
* Workaround for https://github.com/fb55/htmlparser2/issues/187
* Also see https://github.com/fb55/htmlparser2/pull/129
*/
opts.singleTags = opts.singleTags.filter((tag) => {
let hasContent = false;
api.match.call(tree, { tag }, (node) => {
if (typeof node.content !== 'undefined' && !hasContent) {
hasContent = true;
}
return node;
});
return !hasContent;
});
return renderer(tree, opts);
};
module.exports.defaultOptions = defaultOptions;

23
assets_old/node_modules/posthtml-svg-mode/package.json generated vendored Normal file
View file

@ -0,0 +1,23 @@
{
"name": "posthtml-svg-mode",
"version": "1.0.3",
"description": "",
"license": "MIT",
"author": "JetBrains",
"repository": "https://github.com/JetBrains/svg-mixer/tree/v1/posthtml-svg-mode",
"main": "lib/processor.js",
"files": [
"lib/",
"README.md"
],
"dependencies": {
"merge-options": "1.0.1",
"posthtml": "^0.9.2",
"posthtml-parser": "^0.2.1",
"posthtml-render": "^1.0.6"
},
"scripts": {
"lint": "eslint lib test",
"test": "nyc --reporter=lcov mocha -r ../../test/mocha-setup.js"
}
}