File tree Expand file tree Collapse file tree 4 files changed +87
-2
lines changed Expand file tree Collapse file tree 4 files changed +87
-2
lines changed Original file line number Diff line number Diff line change @@ -123,7 +123,7 @@ class Func extends Container {
123
123
124
124
// fixes #92
125
125
// eslint-disable-next-line no-useless-escape
126
- if ( ! reFunctions . test ( node . name ) && ! / ^ [ a - z A - Z \- ] + $ / . test ( node . name ) ) {
126
+ if ( ! reFunctions . test ( node . name ) && ! / ^ [ a - z A - Z \- \. ] + $ / . test ( node . name ) ) {
127
127
const nameTokens = getTokens ( node . name ) ;
128
128
tokens . unshift ( ...nameTokens , brackets ) ;
129
129
parser . back ( tokens ) ;
Original file line number Diff line number Diff line change @@ -47,7 +47,8 @@ module.exports = {
47
47
'1em/var(--line-height)' ,
48
48
'local(foo),local(bar)' ,
49
49
'bat-man(#000)' ,
50
- 'conic-gradient()'
50
+ 'conic-gradient()' ,
51
+ 'color.red(#6b717f)'
51
52
] ,
52
53
53
54
throws : [ 'url( /gfx/img/bg.jpg ' ]
Original file line number Diff line number Diff line change @@ -1871,6 +1871,90 @@ Generated by [AVA](https://avajs.dev).
1871
1871
},
1872
1872
]
1873
1873
1874
+ ## color.red(#6b717f)
1875
+
1876
+ > Snapshot 1
1877
+
1878
+ 'color.red(#6b717f)'
1879
+
1880
+ > Snapshot 2
1881
+
1882
+ 'color.red(#6b717f)'
1883
+
1884
+ > Snapshot 3
1885
+
1886
+ [
1887
+ Func {
1888
+ isColor: false,
1889
+ isVar: false,
1890
+ name: 'color.red',
1891
+ nodes: [
1892
+ Word {
1893
+ isColor: true,
1894
+ isHex: true,
1895
+ isUrl: false,
1896
+ isVariable: false,
1897
+ parent: [Circular],
1898
+ raws: {
1899
+ after: '',
1900
+ before: '',
1901
+ },
1902
+ source: {
1903
+ end: {
1904
+ column: 1,
1905
+ line: 1,
1906
+ offset: 0,
1907
+ },
1908
+ input: Input {
1909
+ css: '#6b717f',
1910
+ hasBOM: false,
1911
+ id: '<input css 1>',
1912
+ [Symbol(fromOffset cache)]: [
1913
+ 0,
1914
+ ],
1915
+ },
1916
+ start: {
1917
+ column: 1,
1918
+ line: 1,
1919
+ offset: 0,
1920
+ },
1921
+ },
1922
+ type: 'word',
1923
+ value: '#6b717f',
1924
+ [Symbol(isClean)]: false,
1925
+ },
1926
+ ],
1927
+ params: '(#6b717f)',
1928
+ raws: {
1929
+ after: '',
1930
+ before: '',
1931
+ semicolon: false,
1932
+ },
1933
+ source: {
1934
+ end: {
1935
+ column: 10,
1936
+ line: 1,
1937
+ offset: 9,
1938
+ },
1939
+ input: Input {
1940
+ css: 'color.red(#6b717f)',
1941
+ hasBOM: false,
1942
+ id: '<input css 1>',
1943
+ [Symbol(fromOffset cache)]: [
1944
+ 0,
1945
+ ],
1946
+ },
1947
+ start: {
1948
+ column: 1,
1949
+ line: 1,
1950
+ offset: 0,
1951
+ },
1952
+ },
1953
+ type: 'func',
1954
+ [Symbol(isClean)]: false,
1955
+ },
1956
+ ]
1957
+
1874
1958
## conic-gradient()
1875
1959
1876
1960
> Snapshot 1
You can’t perform that action at this time.
0 commit comments