mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-26 03:01:51 +08:00
Fix for using css attribute selector alone.
This commit is contained in:
@ -24,7 +24,7 @@ export class CssSelector {
|
||||
constructor(expression: string, declarations: cssParser.Declaration[]) {
|
||||
if (expression) {
|
||||
let leftSquareBracketIndex = expression.indexOf(LSBRACKET);
|
||||
if (leftSquareBracketIndex > 0) {
|
||||
if (leftSquareBracketIndex >= 0) {
|
||||
// extracts what is inside square brackets ([target = 'test'] will extract "target = 'test'")
|
||||
let paramsRegex = /\[\s*(.*)\s*\]/;
|
||||
let attrParams = paramsRegex.exec(expression);
|
||||
|
Reference in New Issue
Block a user