@semantic-ui/component
Advanced tools
Comparing version 0.0.23 to 0.0.24
@@ -15,8 +15,8 @@ { | ||
"dependencies": { | ||
"@semantic-ui/query": "^0.0.23", | ||
"@semantic-ui/reactivity": "^0.0.23", | ||
"@semantic-ui/templating": "^0.0.23", | ||
"@semantic-ui/utils": "^0.0.23" | ||
"@semantic-ui/query": "^0.0.24", | ||
"@semantic-ui/reactivity": "^0.0.24", | ||
"@semantic-ui/templating": "^0.0.24", | ||
"@semantic-ui/utils": "^0.0.24" | ||
}, | ||
"version": "0.0.23" | ||
"version": "0.0.24" | ||
} |
@@ -15,2 +15,6 @@ import { html } from 'lit'; | ||
static STRING_REGEXP = /^\'(.*)\'$/; | ||
static OUTER_PARENS_REGEXP = /^\((.+)\)$/; | ||
static EXPRESSION_REGEXP = /('[^']*'|[^\s]+)/g; | ||
constructor({ ast, data, subTemplates, helpers }) { | ||
@@ -183,3 +187,3 @@ this.ast = ast || ''; | ||
// if the whole expression is a string we want to return that | ||
const stringRegExp = /^\'(.*)\'$/; | ||
const stringRegExp = LitRenderer.STRING_REGEXP; | ||
const stringMatches = expressionString.match(stringRegExp); | ||
@@ -190,6 +194,14 @@ if (stringMatches && stringMatches.length > 0) { | ||
// converts "foo baz 'wiz bang'" => ["foo", "baz", "'wiz bang'"] | ||
const splitExpressionString = (str) => { | ||
const regex = LitRenderer.EXPRESSION_REGEXP; | ||
const matches = str.match(regex); | ||
return matches || []; | ||
}; | ||
// we can safely remove outer parens | ||
expressionString = expressionString.replace(/^\((.+)\)$/, '$1'); | ||
expressionString = expressionString.replace(LitRenderer.OUTER_PARENS_REGEXP, '$1'); | ||
const expressions = expressionString.split(' ').reverse(); | ||
const expressions = splitExpressionString(expressionString).reverse(); | ||
let funcArguments = []; | ||
@@ -196,0 +208,0 @@ let result; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
49469
1504
+ Added@semantic-ui/query@0.0.24(transitive)
+ Added@semantic-ui/reactivity@0.0.24(transitive)
+ Added@semantic-ui/templating@0.0.24(transitive)
+ Added@semantic-ui/utils@0.0.24(transitive)
- Removed@semantic-ui/query@0.0.23(transitive)
- Removed@semantic-ui/reactivity@0.0.23(transitive)
- Removed@semantic-ui/templating@0.0.23(transitive)
- Removed@semantic-ui/utils@0.0.23(transitive)
Updated@semantic-ui/query@^0.0.24
Updated@semantic-ui/utils@^0.0.24