bump go modules
This commit is contained in:
committed by
Umputun
parent
8357846818
commit
c70a66a1c5
@@ -7,35 +7,35 @@ require (
|
||||
github.com/go-pkgz/lgr v0.10.4
|
||||
github.com/jessevdk/go-flags v1.5.0
|
||||
github.com/stretchr/testify v1.8.1
|
||||
github.com/umputun/remark42/backend v1.10.1
|
||||
github.com/umputun/remark42/backend v1.11.2
|
||||
)
|
||||
|
||||
require (
|
||||
github.com/Depado/bfchroma/v2 v2.0.0 // indirect
|
||||
github.com/PuerkitoBio/goquery v1.8.0 // indirect
|
||||
github.com/ajg/form v1.5.1 // indirect
|
||||
github.com/alecthomas/chroma/v2 v2.3.0 // indirect
|
||||
github.com/alecthomas/chroma/v2 v2.4.0 // indirect
|
||||
github.com/andybalholm/cascadia v1.3.1 // indirect
|
||||
github.com/aymerick/douceur v0.2.0 // indirect
|
||||
github.com/davecgh/go-spew v1.1.1 // indirect
|
||||
github.com/didip/tollbooth/v7 v7.0.1 // indirect
|
||||
github.com/didip/tollbooth_chi v0.0.0-20220719025231-d662a7f6928f // indirect
|
||||
github.com/dlclark/regexp2 v1.4.0 // indirect
|
||||
github.com/go-chi/chi/v5 v5.0.7 // indirect
|
||||
github.com/go-chi/chi/v5 v5.0.8 // indirect
|
||||
github.com/go-chi/render v1.0.2 // indirect
|
||||
github.com/go-pkgz/expirable-cache v0.1.0 // indirect
|
||||
github.com/go-pkgz/rest v1.16.0 // indirect
|
||||
github.com/go-pkgz/rest v1.17.0 // indirect
|
||||
github.com/gorilla/css v1.0.0 // indirect
|
||||
github.com/hashicorp/errwrap v1.1.0 // indirect
|
||||
github.com/hashicorp/go-multierror v1.1.1 // indirect
|
||||
github.com/microcosm-cc/bluemonday v1.0.20 // indirect
|
||||
github.com/microcosm-cc/bluemonday v1.0.21 // indirect
|
||||
github.com/pmezard/go-difflib v1.0.0 // indirect
|
||||
github.com/rs/xid v1.4.0 // indirect
|
||||
github.com/russross/blackfriday/v2 v2.1.0 // indirect
|
||||
go.etcd.io/bbolt v1.3.6 // indirect
|
||||
golang.org/x/image v0.0.0-20220617043117-41969df76e82 // indirect
|
||||
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b // indirect
|
||||
golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10 // indirect
|
||||
golang.org/x/image v0.3.0 // indirect
|
||||
golang.org/x/net v0.5.0 // indirect
|
||||
golang.org/x/sys v0.4.0 // indirect
|
||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||
)
|
||||
|
||||
|
||||
@@ -4,8 +4,9 @@ github.com/PuerkitoBio/goquery v1.8.0 h1:PJTF7AmFCFKk1N6V6jmKfrNH9tV5pNE6lZMkG0g
|
||||
github.com/PuerkitoBio/goquery v1.8.0/go.mod h1:ypIiRMtY7COPGk+I/YbZLbxsxn9g5ejnI2HSMtkjZvI=
|
||||
github.com/ajg/form v1.5.1 h1:t9c7v8JUKu/XxOGBU0yjNpaMloxGEJhUkqFRq0ibGeU=
|
||||
github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY=
|
||||
github.com/alecthomas/chroma/v2 v2.3.0 h1:83xfxrnjv8eK+Cf8qZDzNo3PPF9IbTWHs7z28GY6D0U=
|
||||
github.com/alecthomas/chroma/v2 v2.3.0/go.mod h1:mZxeWZlxP2Dy+/8cBob2PYd8O2DwNAzave5AY7A2eQw=
|
||||
github.com/alecthomas/assert/v2 v2.2.0 h1:f6L/b7KE2bfA+9O4FL3CM/xJccDEwPVYd5fALBiuwvw=
|
||||
github.com/alecthomas/chroma/v2 v2.4.0 h1:Loe2ZjT5x3q1bcWwemqyqEi8p11/IV/ncFCeLYDpWC4=
|
||||
github.com/alecthomas/chroma/v2 v2.4.0/go.mod h1:6kHzqF5O6FUSJzBXW7fXELjb+e+7OXW4UpoPqMO7IBQ=
|
||||
github.com/alecthomas/repr v0.1.0 h1:ENn2e1+J3k09gyj2shc0dHr/yjaWSHRlrJ4DPMevDqE=
|
||||
github.com/andybalholm/cascadia v1.3.1 h1:nhxRkql1kdYCc8Snf7D5/D3spOX+dBgjA6u8x004T2c=
|
||||
github.com/andybalholm/cascadia v1.3.1/go.mod h1:R4bJ1UQfqADjvDa4P6HZHLh/3OxWWEqc0Sk8XGwHqvA=
|
||||
@@ -21,8 +22,9 @@ github.com/didip/tollbooth_chi v0.0.0-20220719025231-d662a7f6928f h1:jtKwihcLmUC
|
||||
github.com/didip/tollbooth_chi v0.0.0-20220719025231-d662a7f6928f/go.mod h1:q9C80dnsuVRP2dAskjnXRNWdUJqtGgwG9wNrzt0019s=
|
||||
github.com/dlclark/regexp2 v1.4.0 h1:F1rxgk7p4uKjwIQxBs9oAXe5CqrXlCduYEJvrF4u93E=
|
||||
github.com/dlclark/regexp2 v1.4.0/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
|
||||
github.com/go-chi/chi/v5 v5.0.7 h1:rDTPXLDHGATaeHvVlLcR4Qe0zftYethFucbjVQ1PxU8=
|
||||
github.com/go-chi/chi/v5 v5.0.7/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
|
||||
github.com/go-chi/chi/v5 v5.0.8 h1:lD+NLqFcAi1ovnVZpsnObHGW4xb4J8lNmoYVfECH1Y0=
|
||||
github.com/go-chi/chi/v5 v5.0.8/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
|
||||
github.com/go-chi/render v1.0.1/go.mod h1:pq4Rr7HbnsdaeHagklXub+p6Wd16Af5l9koip1OvJns=
|
||||
github.com/go-chi/render v1.0.2 h1:4ER/udB0+fMWB2Jlf15RV3F4A2FDuYi/9f+lFttR/Lg=
|
||||
github.com/go-chi/render v1.0.2/go.mod h1:/gr3hVkmYR0YlEy3LxCuVRFzEu9Ruok+gFqbIofjao0=
|
||||
@@ -33,8 +35,8 @@ github.com/go-pkgz/jrpc v0.3.0/go.mod h1:MFtKs75JESiSqVicsQkgN2iDFFuCd3gVT1/vKiw
|
||||
github.com/go-pkgz/lgr v0.10.4 h1:l7qyFjqEZgwRgaQQSEp6tve4A3OU80VrfzpvtEX8ngw=
|
||||
github.com/go-pkgz/lgr v0.10.4/go.mod h1:CD0s1z6EFpIUplV067gitF77tn25JItzwHNKAPqeCF0=
|
||||
github.com/go-pkgz/rest v1.15.6/go.mod h1:KUWAqbDteYGS/CiXftomQsKjtEOifXsJ36Ka0skYbmk=
|
||||
github.com/go-pkgz/rest v1.16.0 h1:3An51XJXUq1XtICHvfAEp048ZCbUHBEga3g0WEu3zK0=
|
||||
github.com/go-pkgz/rest v1.16.0/go.mod h1:HHlLOt02NJc2sgffXBF6hYVMcRo4Gz3vjg43zTzN7VM=
|
||||
github.com/go-pkgz/rest v1.17.0 h1:LoBI/lDBMuqwWhOOkc6thM9NnwJO+K9nWvCOjZ7BAgE=
|
||||
github.com/go-pkgz/rest v1.17.0/go.mod h1:HHlLOt02NJc2sgffXBF6hYVMcRo4Gz3vjg43zTzN7VM=
|
||||
github.com/gorilla/css v1.0.0 h1:BQqNyPTi50JCFMTw/b67hByjMVXZRwGha6wxVGkeihY=
|
||||
github.com/gorilla/css v1.0.0/go.mod h1:Dn721qIggHpt4+EFCcTLTU/vk5ySda2ReITrtgBl60c=
|
||||
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
||||
@@ -42,6 +44,7 @@ github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY
|
||||
github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
|
||||
github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo=
|
||||
github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM=
|
||||
github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM=
|
||||
github.com/jessevdk/go-flags v1.5.0 h1:1jKYvbxEjfUl0fmqTCOfonvskHHXMjBySTLW4y9LFvc=
|
||||
github.com/jessevdk/go-flags v1.5.0/go.mod h1:Fw0T6WPc1dYxT4mKEZRfG5kJhaTDP9pj1c2EWnYs/m4=
|
||||
github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI=
|
||||
@@ -49,8 +52,8 @@ github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORN
|
||||
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/microcosm-cc/bluemonday v1.0.20 h1:flpzsq4KU3QIYAYGV/szUat7H+GPOXR0B2JU5A1Wp8Y=
|
||||
github.com/microcosm-cc/bluemonday v1.0.20/go.mod h1:yfBmMi8mxvaZut3Yytv+jTXRY8mxyjJ0/kQBTElld50=
|
||||
github.com/microcosm-cc/bluemonday v1.0.21 h1:dNH3e4PSyE4vNX+KlRGHT5KrSvjeUkoNPwEORjffHJg=
|
||||
github.com/microcosm-cc/bluemonday v1.0.21/go.mod h1:ytNkv4RrDrLJ2pqlsSI46O6IVXmZOBBD4SaJyDwwTkM=
|
||||
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
@@ -67,23 +70,43 @@ github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/
|
||||
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
|
||||
github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKsk=
|
||||
github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
|
||||
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
|
||||
go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU=
|
||||
go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4=
|
||||
golang.org/x/image v0.0.0-20220617043117-41969df76e82 h1:KpZB5pUSBvrHltNEdK/tw0xlPeD13M6M6aGP32gKqiw=
|
||||
golang.org/x/image v0.0.0-20220617043117-41969df76e82/go.mod h1:doUCurBvlfPMKfmIpRIywoHmhN3VyhnoFDbvIEWF4hY=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
|
||||
golang.org/x/image v0.3.0 h1:HTDXbdK9bjfSWkPzDJIw89W8CAtfFGduujWs33NLLsg=
|
||||
golang.org/x/image v0.3.0/go.mod h1:fXd9211C/0VTlYuAcOhW8dY/RtEJqODXOWBDpmYBf+A=
|
||||
golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4=
|
||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
|
||||
golang.org/x/net v0.0.0-20210916014120-12bc252f5db8/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b h1:ZmngSVLe/wycRns9MKikG9OWIEjGcGAkacif7oYQaUY=
|
||||
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk=
|
||||
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
golang.org/x/net v0.5.0 h1:GyT4nK/YDHSqa1c4753ouYCDajOYKTja9Xb/OHtgvSw=
|
||||
golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws=
|
||||
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10 h1:WIoqL4EROvwiPdUtaip4VcDdpZ4kha7wBWZrbVKCIZg=
|
||||
golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.4.0 h1:Zr2JFtRQNX3BCZ8YtxRE9hNJYC8J6I1MVbMg6owUp18=
|
||||
golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
|
||||
golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
|
||||
@@ -263,7 +263,7 @@ func TestComment_sanitizeText(t *testing.T) {
|
||||
},
|
||||
{
|
||||
"<a href=javascript:alert(document.domain)//>xxx</a>",
|
||||
"<a/>xxx</a>",
|
||||
"xxx</a>",
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
+15
-15
@@ -5,36 +5,36 @@ go 1.17
|
||||
require (
|
||||
github.com/Depado/bfchroma/v2 v2.0.0
|
||||
github.com/PuerkitoBio/goquery v1.8.0
|
||||
github.com/alecthomas/chroma/v2 v2.3.0
|
||||
github.com/alecthomas/chroma/v2 v2.4.0
|
||||
github.com/didip/tollbooth/v7 v7.0.1
|
||||
github.com/didip/tollbooth_chi v0.0.0-20220719025231-d662a7f6928f
|
||||
github.com/go-chi/chi/v5 v5.0.7
|
||||
github.com/go-chi/chi/v5 v5.0.8
|
||||
github.com/go-chi/cors v1.2.1
|
||||
github.com/go-chi/render v1.0.2
|
||||
github.com/go-pkgz/auth v1.20.1-0.20230103203948-168bd5a101b7
|
||||
github.com/go-pkgz/auth v1.20.1-0.20230115185815-90b4b947ab05
|
||||
github.com/go-pkgz/jrpc v0.3.0
|
||||
github.com/go-pkgz/lcw v1.0.3-0.20221226231215-a66ea7c4aff7
|
||||
github.com/go-pkgz/lgr v0.10.4
|
||||
github.com/go-pkgz/notify v0.2.0
|
||||
github.com/go-pkgz/repeater v1.1.3
|
||||
github.com/go-pkgz/rest v1.16.0
|
||||
github.com/go-pkgz/rest v1.17.0
|
||||
github.com/go-pkgz/syncs v1.2.0
|
||||
github.com/golang-jwt/jwt v3.2.2+incompatible
|
||||
github.com/google/uuid v1.3.0
|
||||
github.com/gorilla/feeds v1.1.1
|
||||
github.com/hashicorp/go-multierror v1.1.1
|
||||
github.com/jessevdk/go-flags v1.5.0
|
||||
github.com/kyokomi/emoji/v2 v2.2.10
|
||||
github.com/microcosm-cc/bluemonday v1.0.20
|
||||
github.com/kyokomi/emoji/v2 v2.2.11
|
||||
github.com/microcosm-cc/bluemonday v1.0.21
|
||||
github.com/rs/xid v1.4.0
|
||||
github.com/russross/blackfriday/v2 v2.1.0
|
||||
github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e
|
||||
github.com/stretchr/testify v1.8.1
|
||||
go.etcd.io/bbolt v1.3.6
|
||||
go.uber.org/goleak v1.2.0
|
||||
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d
|
||||
golang.org/x/image v0.0.0-20220617043117-41969df76e82
|
||||
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b
|
||||
golang.org/x/crypto v0.5.0
|
||||
golang.org/x/image v0.3.0
|
||||
golang.org/x/net v0.5.0
|
||||
)
|
||||
|
||||
require (
|
||||
@@ -44,7 +44,7 @@ require (
|
||||
github.com/aymerick/douceur v0.2.0 // indirect
|
||||
github.com/cespare/xxhash/v2 v2.1.2 // indirect
|
||||
github.com/davecgh/go-spew v1.1.1 // indirect
|
||||
github.com/dghubble/oauth1 v0.7.1 // indirect
|
||||
github.com/dghubble/oauth1 v0.7.2 // indirect
|
||||
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
|
||||
github.com/dlclark/regexp2 v1.4.0 // indirect
|
||||
github.com/go-oauth2/oauth2/v4 v4.5.1 // indirect
|
||||
@@ -67,11 +67,11 @@ require (
|
||||
github.com/xdg-go/scram v1.1.1 // indirect
|
||||
github.com/xdg-go/stringprep v1.0.3 // indirect
|
||||
github.com/youmark/pkcs8 v0.0.0-20201027041543-1326539a0a0a // indirect
|
||||
go.mongodb.org/mongo-driver v1.10.2 // indirect
|
||||
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5 // indirect
|
||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
|
||||
golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10 // indirect
|
||||
golang.org/x/text v0.3.7 // indirect
|
||||
go.mongodb.org/mongo-driver v1.11.1 // indirect
|
||||
golang.org/x/oauth2 v0.4.0 // indirect
|
||||
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 // indirect
|
||||
golang.org/x/sys v0.4.0 // indirect
|
||||
golang.org/x/text v0.6.0 // indirect
|
||||
google.golang.org/appengine v1.6.7 // indirect
|
||||
google.golang.org/protobuf v1.28.0 // indirect
|
||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||
|
||||
@@ -64,6 +64,8 @@ github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY
|
||||
github.com/alecthomas/chroma/v2 v2.2.0/go.mod h1:vf4zrexSH54oEjJ7EdB65tGNHmH3pGZmVkgTP5RHvAs=
|
||||
github.com/alecthomas/chroma/v2 v2.3.0 h1:83xfxrnjv8eK+Cf8qZDzNo3PPF9IbTWHs7z28GY6D0U=
|
||||
github.com/alecthomas/chroma/v2 v2.3.0/go.mod h1:mZxeWZlxP2Dy+/8cBob2PYd8O2DwNAzave5AY7A2eQw=
|
||||
github.com/alecthomas/chroma/v2 v2.4.0 h1:Loe2ZjT5x3q1bcWwemqyqEi8p11/IV/ncFCeLYDpWC4=
|
||||
github.com/alecthomas/chroma/v2 v2.4.0/go.mod h1:6kHzqF5O6FUSJzBXW7fXELjb+e+7OXW4UpoPqMO7IBQ=
|
||||
github.com/alecthomas/repr v0.0.0-20220113201626-b1b626ac65ae/go.mod h1:2kn6fqh/zIyPLmm3ugklbEi5hg5wS435eygvNfaDQL8=
|
||||
github.com/alecthomas/repr v0.1.0 h1:ENn2e1+J3k09gyj2shc0dHr/yjaWSHRlrJ4DPMevDqE=
|
||||
github.com/alecthomas/repr v0.1.0/go.mod h1:2kn6fqh/zIyPLmm3ugklbEi5hg5wS435eygvNfaDQL8=
|
||||
@@ -101,6 +103,8 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/dghubble/oauth1 v0.7.1 h1:JjbOVSVVkms9A4h/sTQy5Jb2nFuAAVb2qVYgenJPyrE=
|
||||
github.com/dghubble/oauth1 v0.7.1/go.mod h1:0eEzON0UY/OLACQrmnjgJjmvCGXzjBCsZqL1kWDXtF0=
|
||||
github.com/dghubble/oauth1 v0.7.2 h1:pwcinOZy8z6XkNxvPmUDY52M7RDPxt0Xw1zgZ6Cl5JA=
|
||||
github.com/dghubble/oauth1 v0.7.2/go.mod h1:9erQdIhqhOHG/7K9s/tgh9Ks/AfoyrO5mW/43Lu2+kE=
|
||||
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/rVNCu3HqELle0jiPLLBs70cWOduZpkS1E78=
|
||||
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc=
|
||||
github.com/didip/tollbooth/v7 v7.0.0/go.mod h1:VZhDSGl5bDSPj4wPsih3PFa4Uh9Ghv8hgacaTm5PRT4=
|
||||
@@ -130,6 +134,8 @@ github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv
|
||||
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
|
||||
github.com/go-chi/chi/v5 v5.0.7 h1:rDTPXLDHGATaeHvVlLcR4Qe0zftYethFucbjVQ1PxU8=
|
||||
github.com/go-chi/chi/v5 v5.0.7/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
|
||||
github.com/go-chi/chi/v5 v5.0.8 h1:lD+NLqFcAi1ovnVZpsnObHGW4xb4J8lNmoYVfECH1Y0=
|
||||
github.com/go-chi/chi/v5 v5.0.8/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
|
||||
github.com/go-chi/cors v1.2.1 h1:xEC8UT3Rlp2QuWNEr4Fs/c2EAGVKBwy/1vHx3bppil4=
|
||||
github.com/go-chi/cors v1.2.1/go.mod h1:sSbTewc+6wYHBBCW7ytsFSn836hqM7JxpglAy2Vzc58=
|
||||
github.com/go-chi/render v1.0.1/go.mod h1:pq4Rr7HbnsdaeHagklXub+p6Wd16Af5l9koip1OvJns=
|
||||
@@ -144,6 +150,8 @@ github.com/go-pkgz/auth v1.20.1-0.20221226231300-65f433fba0f1 h1:MJA4rZAwjd+KpaR
|
||||
github.com/go-pkgz/auth v1.20.1-0.20221226231300-65f433fba0f1/go.mod h1:fG1CP4+LDPnebYeO1BAZg/euTQQ8cnGn+5ZrXvJfckA=
|
||||
github.com/go-pkgz/auth v1.20.1-0.20230103203948-168bd5a101b7 h1:ktKI3Y3UytkBLL1cOEzJmAi3nNKeaRGOzDj51Kgqp6M=
|
||||
github.com/go-pkgz/auth v1.20.1-0.20230103203948-168bd5a101b7/go.mod h1:fG1CP4+LDPnebYeO1BAZg/euTQQ8cnGn+5ZrXvJfckA=
|
||||
github.com/go-pkgz/auth v1.20.1-0.20230115185815-90b4b947ab05 h1:AVT3lrGI0V9zHpeM0SK/ybFP8VmA6ZLvxtcJeSzH1X0=
|
||||
github.com/go-pkgz/auth v1.20.1-0.20230115185815-90b4b947ab05/go.mod h1:ERRbvtLARasBHop3BOY7Cm6iAqu6bfJ3qDGcmg+zqAA=
|
||||
github.com/go-pkgz/email v0.3.1-0.20221002173339-19d25a20d99c/go.mod h1:TpnmSLkQW3FyICit2hn7WIhCUDrhCX6btzz5wS3wHRI=
|
||||
github.com/go-pkgz/email v0.4.1 h1:2vtP2gibsSzqhz6eD5DklSp11m657XEVf17fuXaxMvk=
|
||||
github.com/go-pkgz/email v0.4.1/go.mod h1:BdxglsQnymzhfdbnncEE72a6DrucZHy6I+42LK2jLEc=
|
||||
@@ -162,6 +170,8 @@ github.com/go-pkgz/repeater v1.1.3/go.mod h1:hVTavuO5x3Gxnu8zW7d6sQBfAneKV8X2FjU
|
||||
github.com/go-pkgz/rest v1.15.6/go.mod h1:KUWAqbDteYGS/CiXftomQsKjtEOifXsJ36Ka0skYbmk=
|
||||
github.com/go-pkgz/rest v1.16.0 h1:3An51XJXUq1XtICHvfAEp048ZCbUHBEga3g0WEu3zK0=
|
||||
github.com/go-pkgz/rest v1.16.0/go.mod h1:HHlLOt02NJc2sgffXBF6hYVMcRo4Gz3vjg43zTzN7VM=
|
||||
github.com/go-pkgz/rest v1.17.0 h1:LoBI/lDBMuqwWhOOkc6thM9NnwJO+K9nWvCOjZ7BAgE=
|
||||
github.com/go-pkgz/rest v1.17.0/go.mod h1:HHlLOt02NJc2sgffXBF6hYVMcRo4Gz3vjg43zTzN7VM=
|
||||
github.com/go-pkgz/syncs v1.2.0 h1:aiizQFILlMZ4KtRNaYLcDffRbUQZH9fclsgr5KybWyY=
|
||||
github.com/go-pkgz/syncs v1.2.0/go.mod h1:fjThZdM2FkC/oSeiqBTOZOtHpbrCh4HuHbipB5qZJJM=
|
||||
github.com/go-redis/redis/v8 v8.11.5 h1:AcZZR7igkdvfVmQTPnu9WE37LRrO/YrBH5zWyjDC0oI=
|
||||
@@ -297,10 +307,14 @@ github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/kyokomi/emoji/v2 v2.2.10 h1:1z5eMVcxFifsmEoNpdeq4UahbcicgQ4FEHuzrCVwmiI=
|
||||
github.com/kyokomi/emoji/v2 v2.2.10/go.mod h1:JUcn42DTdsXJo1SWanHh4HKDEyPaR5CqkmoirZZP9qE=
|
||||
github.com/kyokomi/emoji/v2 v2.2.11 h1:Pf/ZWVTbnAVkHOLJLWjPxM/FmgyPe+d85cv/OLP5Yus=
|
||||
github.com/kyokomi/emoji/v2 v2.2.11/go.mod h1:JUcn42DTdsXJo1SWanHh4HKDEyPaR5CqkmoirZZP9qE=
|
||||
github.com/mattn/go-colorable v0.1.7/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
|
||||
github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
|
||||
github.com/microcosm-cc/bluemonday v1.0.20 h1:flpzsq4KU3QIYAYGV/szUat7H+GPOXR0B2JU5A1Wp8Y=
|
||||
github.com/microcosm-cc/bluemonday v1.0.20/go.mod h1:yfBmMi8mxvaZut3Yytv+jTXRY8mxyjJ0/kQBTElld50=
|
||||
github.com/microcosm-cc/bluemonday v1.0.21 h1:dNH3e4PSyE4vNX+KlRGHT5KrSvjeUkoNPwEORjffHJg=
|
||||
github.com/microcosm-cc/bluemonday v1.0.21/go.mod h1:ytNkv4RrDrLJ2pqlsSI46O6IVXmZOBBD4SaJyDwwTkM=
|
||||
github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe h1:iruDEfMl2E6fbMZ9s0scYfZQ84/6SPL6zC8ACM2oIL0=
|
||||
github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc=
|
||||
github.com/moul/http2curl v1.0.0 h1:dRMWoAtb+ePxMlLkrCbAqh4TlPHXvoGUSQ323/9Zahs=
|
||||
@@ -407,12 +421,15 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de
|
||||
github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
|
||||
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
|
||||
github.com/yuin/gopher-lua v0.0.0-20220504180219-658193537a64 h1:5mLPGnFdSsevFRFc9q3yYbBkB6tsm4aCwwQV/j1JQAQ=
|
||||
github.com/yuin/gopher-lua v0.0.0-20220504180219-658193537a64/go.mod h1:GBR0iDaNXjAgGg9zfCvksxSRnQx76gclCIb7kdAd1Pw=
|
||||
go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU=
|
||||
go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4=
|
||||
go.mongodb.org/mongo-driver v1.10.2 h1:4Wk3cnqOrQCn0P92L3/mmurMxzdvWWs5J9jinAVKD+k=
|
||||
go.mongodb.org/mongo-driver v1.10.2/go.mod h1:z4XpeoU6w+9Vht+jAFyLgVrD+jGSQQe0+CBWFHNiHt8=
|
||||
go.mongodb.org/mongo-driver v1.11.1 h1:QP0znIRTuL0jf1oBQoAoM0C6ZJfBK4kx0Uumtv1A7w8=
|
||||
go.mongodb.org/mongo-driver v1.11.1/go.mod h1:s7p5vEtfbeR1gYi6pnj3c3/urpbLv2T5Sfd6Rp2HBB8=
|
||||
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
||||
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
|
||||
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
|
||||
@@ -429,9 +446,12 @@ golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8U
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
|
||||
golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
|
||||
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d h1:sK3txAijHtOK88l68nt020reeT1ZdKLIYetKl95FzVY=
|
||||
golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
|
||||
golang.org/x/crypto v0.5.0 h1:U/0M97KRkSFvyD/3FSmdP5W5swImpNgle/EHFhOsQPE=
|
||||
golang.org/x/crypto v0.5.0/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU=
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
|
||||
@@ -447,6 +467,8 @@ golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+o
|
||||
golang.org/x/image v0.0.0-20220413100746-70e8d0d3baa9/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM=
|
||||
golang.org/x/image v0.0.0-20220617043117-41969df76e82 h1:KpZB5pUSBvrHltNEdK/tw0xlPeD13M6M6aGP32gKqiw=
|
||||
golang.org/x/image v0.0.0-20220617043117-41969df76e82/go.mod h1:doUCurBvlfPMKfmIpRIywoHmhN3VyhnoFDbvIEWF4hY=
|
||||
golang.org/x/image v0.3.0 h1:HTDXbdK9bjfSWkPzDJIw89W8CAtfFGduujWs33NLLsg=
|
||||
golang.org/x/image v0.3.0/go.mod h1:fXd9211C/0VTlYuAcOhW8dY/RtEJqODXOWBDpmYBf+A=
|
||||
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
|
||||
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
@@ -471,6 +493,7 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
|
||||
golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
@@ -515,8 +538,11 @@ golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su
|
||||
golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
|
||||
golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
|
||||
golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
|
||||
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b h1:ZmngSVLe/wycRns9MKikG9OWIEjGcGAkacif7oYQaUY=
|
||||
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk=
|
||||
golang.org/x/net v0.5.0 h1:GyT4nK/YDHSqa1c4753ouYCDajOYKTja9Xb/OHtgvSw=
|
||||
golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws=
|
||||
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
|
||||
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
@@ -537,6 +563,8 @@ golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j
|
||||
golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc=
|
||||
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5 h1:OSnWWcOd/CtWQC2cYSBgbTSJv3ciqd8r54ySIW2y3RE=
|
||||
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc=
|
||||
golang.org/x/oauth2 v0.4.0 h1:NF0gk8LVPg1Ml7SSbGyySuoxdsXitj7TvgvuRxIMc/M=
|
||||
golang.org/x/oauth2 v0.4.0/go.mod h1:RznEsdpjGAINPTOF0UH/t+xJ75L18YO3Ho6Pyn+uRec=
|
||||
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
@@ -549,6 +577,8 @@ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJ
|
||||
golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ=
|
||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 h1:uVc8UZUe6tr40fFVnUP5Oj+veunVezqYl9z7DYw9xzw=
|
||||
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190204203706-41f3e6584952/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
@@ -612,8 +642,12 @@ golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBc
|
||||
golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10 h1:WIoqL4EROvwiPdUtaip4VcDdpZ4kha7wBWZrbVKCIZg=
|
||||
golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.4.0 h1:Zr2JFtRQNX3BCZ8YtxRE9hNJYC8J6I1MVbMg6owUp18=
|
||||
golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
|
||||
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
@@ -626,6 +660,8 @@ golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
|
||||
golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=
|
||||
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
|
||||
golang.org/x/text v0.6.0 h1:3XmdazWV+ubf7QgHSTWeykHOci5oeekaGJBLkrkaw4k=
|
||||
golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
|
||||
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
@@ -683,6 +719,8 @@ golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.5 h1:ouewzE6p+/VEB31YYnTbEJdi8pFqKp4P4n85vwo3DHA=
|
||||
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.12 h1:VveCTK38A2rkS8ZqFY25HIDFscX5X9OoEhJd3quQmXU=
|
||||
golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
root = true
|
||||
|
||||
[*]
|
||||
indent_style = tab
|
||||
end_of_line = lf
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
|
||||
[*.xml]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
insert_final_newline = false
|
||||
+11
@@ -37,6 +37,17 @@ linters:
|
||||
- wrapcheck
|
||||
- stylecheck
|
||||
- thelper
|
||||
- nonamedreturns
|
||||
- revive
|
||||
- dupword
|
||||
- exhaustruct
|
||||
- varnamelen
|
||||
- forcetypeassert
|
||||
- ireturn
|
||||
- maintidx
|
||||
- govet
|
||||
- nosnakecase
|
||||
- testableexamples
|
||||
|
||||
linters-settings:
|
||||
govet:
|
||||
|
||||
+22
-18
@@ -37,26 +37,26 @@ translators for Pygments lexers and styles.
|
||||
Prefix | Language
|
||||
:----: | --------
|
||||
A | ABAP, ABNF, ActionScript, ActionScript 3, Ada, Angular2, ANTLR, ApacheConf, APL, AppleScript, Arduino, Awk
|
||||
B | Ballerina, Base Makefile, Bash, Batchfile, BibTeX, Bicep, BlitzBasic, BNF, Brainfuck
|
||||
B | Ballerina, Bash, Batchfile, BibTeX, Bicep, BlitzBasic, BNF, Brainfuck, BQN
|
||||
C | C, C#, C++, Caddyfile, Caddyfile Directives, Cap'n Proto, Cassandra CQL, Ceylon, CFEngine3, cfstatement, ChaiScript, Chapel, Cheetah, Clojure, CMake, COBOL, CoffeeScript, Common Lisp, Coq, Crystal, CSS, Cython
|
||||
D | D, Dart, Diff, Django/Jinja, Docker, DTD, Dylan
|
||||
E | EBNF, Elixir, Elm, EmacsLisp, Erlang
|
||||
F | Factor, Fish, Forth, Fortran, FSharp
|
||||
G | GAS, GDScript, Genshi, Genshi HTML, Genshi Text, Gherkin, GLSL, Gnuplot, Go, Go HTML Template, Go Text Template, GraphQL, Groff, Groovy
|
||||
H | Handlebars, Haskell, Haxe, HCL, Hexdump, HLB, HTML, HTTP, Hy
|
||||
H | Handlebars, Haskell, Haxe, HCL, Hexdump, HLB, HLSL, HTML, HTTP, Hy
|
||||
I | Idris, Igor, INI, Io
|
||||
J | J, Java, JavaScript, JSON, Julia, Jungle
|
||||
K | Kotlin
|
||||
L | Lighttpd configuration file, LLVM, Lua
|
||||
M | Mako, markdown, Mason, Mathematica, Matlab, MiniZinc, MLIR, Modula-2, MonkeyC, MorrowindScript, Myghty, MySQL
|
||||
M | Makefile, Mako, markdown, Mason, Mathematica, Matlab, MiniZinc, MLIR, Modula-2, MonkeyC, MorrowindScript, Myghty, MySQL
|
||||
N | NASM, Newspeak, Nginx configuration file, Nim, Nix
|
||||
O | Objective-C, OCaml, Octave, OnesEnterprise, OpenEdge ABL, OpenSCAD, Org Mode
|
||||
P | PacmanConf, Perl, PHP, PHTML, Pig, PkgConfig, PL/pgSQL, plaintext, Pony, PostgreSQL SQL dialect, PostScript, POVRay, PowerShell, Prolog, PromQL, Properties, Protocol Buffer, Puppet, Python 2, Python
|
||||
P | PacmanConf, Perl, PHP, PHTML, Pig, PkgConfig, PL/pgSQL, plaintext, Pony, PostgreSQL SQL dialect, PostScript, POVRay, PowerShell, Prolog, PromQL, Properties, Protocol Buffer, PSL, Puppet, Python 2, Python
|
||||
Q | QBasic
|
||||
R | R, Racket, Ragel, Raku, react, ReasonML, reg, reStructuredText, Rexx, Ruby, Rust
|
||||
S | SAS, Sass, Scala, Scheme, Scilab, SCSS, Smalltalk, Smarty, Snobol, Solidity, SPARQL, SQL, SquidConf, Standard ML, Stylus, Svelte, Swift, SYSTEMD, systemverilog
|
||||
S | SAS, Sass, Scala, Scheme, Scilab, SCSS, Sed, Smalltalk, Smarty, Snobol, Solidity, SPARQL, SQL, SquidConf, Standard ML, stas, Stylus, Svelte, Swift, SYSTEMD, systemverilog
|
||||
T | TableGen, TASM, Tcl, Tcsh, Termcap, Terminfo, Terraform, TeX, Thrift, TOML, TradingView, Transact-SQL, Turing, Turtle, Twig, TypeScript, TypoScript, TypoScriptCssData, TypoScriptHtmlData
|
||||
V | VB.net, verilog, VHDL, VimL, vue
|
||||
V | VB.net, verilog, VHDL, VHS, VimL, vue
|
||||
W | WDTE
|
||||
X | XML, Xorg
|
||||
Y | YAML, YANG
|
||||
@@ -185,7 +185,7 @@ following constructor options:
|
||||
- `ClassPrefix(prefix)` - prefix each generated CSS class.
|
||||
- `TabWidth(width)` - Set the rendered tab width, in characters.
|
||||
- `WithLineNumbers()` - Render line numbers (style with `LineNumbers`).
|
||||
- `LinkableLineNumbers()` - Make the line numbers linkable and be a link to themselves.
|
||||
- `WithLinkableLineNumbers()` - Make the line numbers linkable and be a link to themselves.
|
||||
- `HighlightLines(ranges)` - Highlight lines in these ranges (style with `LineHighlight`).
|
||||
- `LineNumbersInTable()` - Use a table for formatting line numbers and code, rather than spans.
|
||||
|
||||
@@ -207,14 +207,13 @@ for details on implementing lexers. Most concepts apply directly to Chroma,
|
||||
but see existing lexer implementations for real examples.
|
||||
|
||||
In many cases lexers can be automatically converted directly from Pygments by
|
||||
using the included Python 3 script `pygments2chroma.py`. I use something like
|
||||
using the included Python 3 script `pygments2chroma_xml.py`. I use something like
|
||||
the following:
|
||||
|
||||
```sh
|
||||
python3 _tools/pygments2chroma.py \
|
||||
python3 _tools/pygments2chroma_xml.py \
|
||||
pygments.lexers.jvm.KotlinLexer \
|
||||
> lexers/k/kotlin.go \
|
||||
&& gofmt -s -w lexers/k/kotlin.go
|
||||
> lexers/embedded/kotlin.xml
|
||||
```
|
||||
|
||||
See notes in [pygments-lexers.txt](https://github.com/alecthomas/chroma/blob/master/pygments-lexers.txt)
|
||||
@@ -231,17 +230,22 @@ formatter outputs raw tokens. The latter is useful for debugging lexers.
|
||||
<a id="markdown-styles" name="styles"></a>
|
||||
### Styles
|
||||
|
||||
Chroma styles use the [same syntax](http://pygments.org/docs/styles/) as Pygments.
|
||||
Chroma styles are defined in XML. The style entries use the
|
||||
[same syntax](http://pygments.org/docs/styles/) as Pygments.
|
||||
|
||||
All Pygments styles have been converted to Chroma using the `_tools/style.py` script.
|
||||
All Pygments styles have been converted to Chroma using the `_tools/style.py`
|
||||
script.
|
||||
|
||||
When you work with one of [Chroma's styles](https://github.com/alecthomas/chroma/tree/master/styles), know that the `chroma.Background` token type provides the default style for tokens. It does so by defining a foreground color and background color.
|
||||
When you work with one of [Chroma's styles](https://github.com/alecthomas/chroma/tree/master/styles),
|
||||
know that the `Background` token type provides the default style for tokens. It does so
|
||||
by defining a foreground color and background color.
|
||||
|
||||
For example, this gives each token name not defined in the style a default color of `#f8f8f8` and uses `#000000` for the highlighted code block's background:
|
||||
For example, this gives each token name not defined in the style a default color
|
||||
of `#f8f8f8` and uses `#000000` for the highlighted code block's background:
|
||||
|
||||
~~~go
|
||||
chroma.Background: "#f8f8f2 bg:#000000",
|
||||
~~~
|
||||
```xml
|
||||
<entry type="Background" style="#f8f8f2 bg:#000000"/>
|
||||
```
|
||||
|
||||
Also, token types in a style file are hierarchical. For instance, when `CommentSpecial` is not defined, Chroma uses the token style from `Comment`. So when several comment tokens use the same color, you'll only need to define `Comment` and override the one that has a different color.
|
||||
|
||||
|
||||
+26
-29
@@ -81,42 +81,39 @@ func ByGroupNames(emitters map[string]Emitter) Emitter {
|
||||
}
|
||||
|
||||
// UsingByGroup emits tokens for the matched groups in the regex using a
|
||||
// "sublexer". Used when lexing code blocks where the name of a sublexer is
|
||||
// sublexer. Used when lexing code blocks where the name of a sublexer is
|
||||
// contained within the block, for example on a Markdown text block or SQL
|
||||
// language block.
|
||||
//
|
||||
// The sublexer will be retrieved using sublexerGetFunc (typically
|
||||
// internal.Get), using the captured value from the matched sublexerNameGroup.
|
||||
//
|
||||
// If sublexerGetFunc returns a non-nil lexer for the captured sublexerNameGroup,
|
||||
// then tokens for the matched codeGroup will be emitted using the retrieved
|
||||
// lexer. Otherwise, if the sublexer is nil, then tokens will be emitted from
|
||||
// the passed emitter.
|
||||
// An attempt to load the sublexer will be made using the captured value from
|
||||
// the text of the matched sublexerNameGroup. If a sublexer matching the
|
||||
// sublexerNameGroup is available, then tokens for the matched codeGroup will
|
||||
// be emitted using the sublexer. Otherwise, if no sublexer is available, then
|
||||
// tokens will be emitted from the passed emitter.
|
||||
//
|
||||
// Example:
|
||||
//
|
||||
// var Markdown = internal.Register(MustNewLexer(
|
||||
// &Config{
|
||||
// Name: "markdown",
|
||||
// Aliases: []string{"md", "mkd"},
|
||||
// Filenames: []string{"*.md", "*.mkd", "*.markdown"},
|
||||
// MimeTypes: []string{"text/x-markdown"},
|
||||
// },
|
||||
// Rules{
|
||||
// "root": {
|
||||
// {"^(```)(\\w+)(\\n)([\\w\\W]*?)(^```$)",
|
||||
// UsingByGroup(
|
||||
// internal.Get,
|
||||
// 2, 4,
|
||||
// String, String, String, Text, String,
|
||||
// ),
|
||||
// nil,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// ))
|
||||
// var Markdown = internal.Register(MustNewLexer(
|
||||
// &Config{
|
||||
// Name: "markdown",
|
||||
// Aliases: []string{"md", "mkd"},
|
||||
// Filenames: []string{"*.md", "*.mkd", "*.markdown"},
|
||||
// MimeTypes: []string{"text/x-markdown"},
|
||||
// },
|
||||
// Rules{
|
||||
// "root": {
|
||||
// {"^(```)(\\w+)(\\n)([\\w\\W]*?)(^```$)",
|
||||
// UsingByGroup(
|
||||
// 2, 4,
|
||||
// String, String, String, Text, String,
|
||||
// ),
|
||||
// nil,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
// ))
|
||||
//
|
||||
// See the lexers/m/markdown.go for the complete example.
|
||||
// See the lexers/markdown.go for the complete example.
|
||||
//
|
||||
// Note: panic's if the number of emitters does not equal the number of matched
|
||||
// groups in the regex.
|
||||
|
||||
+7
-6
@@ -100,9 +100,9 @@ func LineNumbersInTable(b bool) Option {
|
||||
}
|
||||
}
|
||||
|
||||
// LinkableLineNumbers decorates the line numbers HTML elements with an "id"
|
||||
// WithLinkableLineNumbers decorates the line numbers HTML elements with an "id"
|
||||
// attribute so they can be linked.
|
||||
func LinkableLineNumbers(b bool, prefix string) Option {
|
||||
func WithLinkableLineNumbers(b bool, prefix string) Option {
|
||||
return func(f *Formatter) {
|
||||
f.linkableLineNumbers = b
|
||||
f.lineNumbersIDPrefix = prefix
|
||||
@@ -262,7 +262,7 @@ func (f *Formatter) writeHTML(w io.Writer, style *chroma.Style, tokens []chroma.
|
||||
fmt.Fprintf(w, "<span%s>", f.styleAttr(css, chroma.LineHighlight))
|
||||
}
|
||||
|
||||
fmt.Fprintf(w, "<span%s%s>%s\n</span>", f.styleAttr(css, chroma.LineNumbersTable), f.lineIDAttribute(line), f.lineTitleWithLinkIfNeeded(lineDigits, line))
|
||||
fmt.Fprintf(w, "<span%s%s>%s\n</span>", f.styleAttr(css, chroma.LineNumbersTable), f.lineIDAttribute(line), f.lineTitleWithLinkIfNeeded(css, lineDigits, line))
|
||||
|
||||
if highlight {
|
||||
fmt.Fprintf(w, "</span>")
|
||||
@@ -302,7 +302,7 @@ func (f *Formatter) writeHTML(w io.Writer, style *chroma.Style, tokens []chroma.
|
||||
|
||||
// Line number
|
||||
if f.lineNumbers && !wrapInTable {
|
||||
fmt.Fprintf(w, "<span%s%s>%s</span>", f.styleAttr(css, chroma.LineNumbers), f.lineIDAttribute(line), f.lineTitleWithLinkIfNeeded(lineDigits, line))
|
||||
fmt.Fprintf(w, "<span%s%s>%s</span>", f.styleAttr(css, chroma.LineNumbers), f.lineIDAttribute(line), f.lineTitleWithLinkIfNeeded(css, lineDigits, line))
|
||||
}
|
||||
|
||||
fmt.Fprintf(w, `<span%s>`, f.styleAttr(css, chroma.CodeLine))
|
||||
@@ -345,12 +345,12 @@ func (f *Formatter) lineIDAttribute(line int) string {
|
||||
return fmt.Sprintf(" id=\"%s\"", f.lineID(line))
|
||||
}
|
||||
|
||||
func (f *Formatter) lineTitleWithLinkIfNeeded(lineDigits, line int) string {
|
||||
func (f *Formatter) lineTitleWithLinkIfNeeded(css map[chroma.TokenType]string, lineDigits, line int) string {
|
||||
title := fmt.Sprintf("%*d", lineDigits, line)
|
||||
if !f.linkableLineNumbers {
|
||||
return title
|
||||
}
|
||||
return fmt.Sprintf("<a style=\"outline: none; text-decoration:none; color:inherit\" href=\"#%s\">%s</a>", f.lineID(line), title)
|
||||
return fmt.Sprintf("<a%s href=\"#%s\">%s</a>", f.styleAttr(css, chroma.LineLink), f.lineID(line), title)
|
||||
}
|
||||
|
||||
func (f *Formatter) lineID(line int) string {
|
||||
@@ -520,6 +520,7 @@ func (f *Formatter) styleToCSS(style *chroma.Style) map[chroma.TokenType]string
|
||||
classes[chroma.LineNumbersTable] = lineNumbersStyle + classes[chroma.LineNumbersTable]
|
||||
classes[chroma.LineTable] = "border-spacing: 0; padding: 0; margin: 0; border: 0;" + classes[chroma.LineTable]
|
||||
classes[chroma.LineTableTD] = "vertical-align: top; padding: 0; margin: 0; border: 0;" + classes[chroma.LineTableTD]
|
||||
classes[chroma.LineLink] = "outline: none; text-decoration: none; color: inherit" + classes[chroma.LineLink]
|
||||
return classes
|
||||
}
|
||||
|
||||
|
||||
+11
-5
@@ -1,4 +1,8 @@
|
||||
# Lexer tests
|
||||
# Chroma lexers
|
||||
|
||||
All lexers in Chroma should now be defined in XML unless they require custom code.
|
||||
|
||||
## Lexer tests
|
||||
|
||||
The tests in this directory feed a known input `testdata/<name>.actual` into the parser for `<name>` and check
|
||||
that its output matches `<name>.exported`.
|
||||
@@ -6,14 +10,15 @@ that its output matches `<name>.exported`.
|
||||
It is also possible to perform several tests on a same parser `<name>`, by placing know inputs `*.actual` into a
|
||||
directory `testdata/<name>/`.
|
||||
|
||||
## Running the tests
|
||||
### Running the tests
|
||||
|
||||
Run the tests as normal:
|
||||
```go
|
||||
go test ./lexers
|
||||
```
|
||||
|
||||
## Update existing tests
|
||||
### Update existing tests
|
||||
|
||||
When you add a new test data file (`*.actual`), you need to regenerate all tests. That's how Chroma creates the `*.expected` test file based on the corresponding lexer.
|
||||
|
||||
To regenerate all tests, type in your terminal:
|
||||
@@ -26,7 +31,8 @@ This first sets the `RECORD` environment variable to `true`. Then it runs `go te
|
||||
|
||||
(That environment variable tells Chroma it needs to output test data. After running `go test ./lexers` you can remove or reset that variable.)
|
||||
|
||||
### Windows users
|
||||
#### Windows users
|
||||
|
||||
Windows users will find that the `RECORD=true go test ./lexers` command fails in both the standard command prompt terminal and in PowerShell.
|
||||
|
||||
Instead we have to perform both steps separately:
|
||||
@@ -35,6 +41,6 @@ Instead we have to perform both steps separately:
|
||||
+ In the regular command prompt window, the `set` command sets an environment variable for the current session: `set RECORD=true`. See [this page](https://superuser.com/questions/212150/how-to-set-env-variable-in-windows-cmd-line) for more.
|
||||
+ In PowerShell, you can use the `$env:RECORD = 'true'` command for that. See [this article](https://mcpmag.com/articles/2019/03/28/environment-variables-in-powershell.aspx) for more.
|
||||
+ You can also make a persistent environment variable by hand in the Windows computer settings. See [this article](https://www.computerhope.com/issues/ch000549.htm) for how.
|
||||
- When the environment variable is set, run `go tests ./lexers`.
|
||||
- When the environment variable is set, run `go test ./lexers`.
|
||||
|
||||
Chroma will now regenerate the test files and print its results to the console window.
|
||||
|
||||
+83
@@ -0,0 +1,83 @@
|
||||
<lexer>
|
||||
<config>
|
||||
<name>BQN</name>
|
||||
<alias>bqn</alias>
|
||||
<filename>*.bqn</filename>
|
||||
</config>
|
||||
<rules>
|
||||
<state name="root">
|
||||
<rule pattern="\s+">
|
||||
<token type="TextWhitespace"/>
|
||||
</rule>
|
||||
<rule pattern="\A#!.+$">
|
||||
<token type="CommentPreproc"/>
|
||||
</rule>
|
||||
<rule pattern="#.*$">
|
||||
<token type="CommentSingle"/>
|
||||
</rule>
|
||||
<rule pattern=""(?:[^"]|"")*"">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="[{}]">
|
||||
<token type="KeywordPseudo"/>
|
||||
</rule>
|
||||
<rule pattern="[⟨⟩\[\]‿]">
|
||||
<token type="KeywordPseudo"/>
|
||||
</rule>
|
||||
<rule pattern="[()]">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="[:;?]">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="[⋄,]">
|
||||
<token type="KeywordPseudo"/>
|
||||
</rule>
|
||||
<rule pattern="[←⇐↩→]">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
<rule pattern="'.'">
|
||||
<token type="LiteralStringChar"/>
|
||||
</rule>
|
||||
<rule pattern="[˙˜˘¨⌜⁼´˝`]">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="[∘○⊸⟜⌾⊘◶⎉⚇⍟⎊]">
|
||||
<token type="OperatorWord"/>
|
||||
</rule>
|
||||
<rule pattern="[𝔽𝔾𝕎𝕏𝕊+\-×÷⋆√⌊⌈|¬∧∨<>≠=≤≥≡≢⊣⊢⥊∾≍⋈↑↓↕«»⌽⍉/⍋⍒⊏⊑⊐⊒∊⍷⊔!⍕⍎]">
|
||||
<token type="NameFunction"/>
|
||||
</rule>
|
||||
<rule pattern="[𝕗𝕘𝕨𝕩𝕤]">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
<rule pattern="·">
|
||||
<token type="NameConstant"/>
|
||||
</rule>
|
||||
<rule pattern="@">
|
||||
<token type="LiteralStringChar"/>
|
||||
</rule>
|
||||
<rule pattern="\d+(?:\.\d+)?[eE]¯?\d+">
|
||||
<token type="LiteralNumber"/>
|
||||
</rule>
|
||||
<rule pattern="[¯∞π]?(?:\d*\.?\b\d+(?:e[+¯]?\d+|E[+¯]?\d+)?|¯|∞|π)(?:j¯?(?:(?:\d+(?:\.\d+)?|\.\d+)(?:e[+¯]?\d+|E[+¯]?\d+)?|¯|∞|π))?">
|
||||
<token type="LiteralNumber"/>
|
||||
</rule>
|
||||
<rule pattern="(•?[a-z][A-Z_a-z0-9π∞¯]*|𝕣)">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
<rule pattern="•?[A-Z][A-Z_a-z0-9π∞¯]*">
|
||||
<token type="NameFunction"/>
|
||||
</rule>
|
||||
<rule pattern="(•?_[A-Za-z][A-Z_a-z0-9π∞¯]*|_𝕣)">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="(•?_[A-Za-z][A-Z_a-z0-9π∞¯]*_|_𝕣_)">
|
||||
<token type="OperatorWord"/>
|
||||
</rule>
|
||||
<rule pattern="\.">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+5
-2
@@ -196,7 +196,7 @@
|
||||
<rule pattern="(restricted|volatile|continue|register|default|typedef|struct|extern|switch|sizeof|static|return|union|while|const|break|goto|enum|else|case|auto|for|asm|if|do)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="(bool|int|long|float|short|double|char((8|16|32)_t)?|unsigned|signed|void|u?int(_fast|_least|)(8|16|32|64)_t)\b">
|
||||
<rule pattern="(bool|int|long|float|short|double|char((8|16|32)_t)?|unsigned|signed|void|u?int(_fast|_least|)(8|16|32|64)_t)\b|\b[a-z]\w*_t\b">
|
||||
<token type="KeywordType"/>
|
||||
</rule>
|
||||
<rule pattern="(typename|__inline|restrict|_inline|thread|inline|naked)\b">
|
||||
@@ -218,6 +218,9 @@
|
||||
<token type="Punctuation"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="\b[A-Za-z_]\w*(?=\s*\()">
|
||||
<token type="NameFunction"/>
|
||||
</rule>
|
||||
<rule pattern="[a-zA-Z_]\w*">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
@@ -250,4 +253,4 @@
|
||||
</rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
</lexer>
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
+14
-6
@@ -15,15 +15,23 @@
|
||||
<rules>
|
||||
<state name="core">
|
||||
<rule pattern="\b(DO)(\s+)(CONCURRENT)\b">
|
||||
<token type="Keyword"/>
|
||||
<bygroups>
|
||||
<token type="Keyword"/>
|
||||
<token type="TextWhitespace"/>
|
||||
<token type="Keyword"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="\b(GO)(\s*)(TO)\b">
|
||||
<bygroups>
|
||||
<token type="Keyword"/>
|
||||
<token type="TextWhitespace"/>
|
||||
<token type="Keyword"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="\b(ABSTRACT|ACCEPT|ALL|ALLSTOP|ALLOCATABLE|ALLOCATE|ARRAY|ASSIGN|ASSOCIATE|ASYNCHRONOUS|BACKSPACE|BIND|BLOCK|BLOCKDATA|BYTE|CALL|CASE|CLASS|CLOSE|CODIMENSION|COMMON|CONTIGUOUS|CONTAINS|CONTINUE|CRITICAL|CYCLE|DATA|DEALLOCATE|DECODE|DEFERRED|DIMENSION|DO|ELEMENTAL|ELSE|ENCODE|END|ENDASSOCIATE|ENDBLOCK|ENDDO|ENDENUM|ENDFORALL|ENDFUNCTION|ENDIF|ENDINTERFACE|ENDMODULE|ENDPROGRAM|ENDSELECT|ENDSUBMODULE|ENDSUBROUTINE|ENDTYPE|ENDWHERE|ENTRY|ENUM|ENUMERATOR|EQUIVALENCE|ERROR STOP|EXIT|EXTENDS|EXTERNAL|EXTRINSIC|FILE|FINAL|FORALL|FORMAT|FUNCTION|GENERIC|IF|IMAGES|IMPLICIT|IMPORT|IMPURE|INCLUDE|INQUIRE|INTENT|INTERFACE|INTRINSIC|IS|LOCK|MEMORY|MODULE|NAMELIST|NULLIFY|NONE|NON_INTRINSIC|NON_OVERRIDABLE|NOPASS|ONLY|OPEN|OPTIONAL|OPTIONS|PARAMETER|PASS|PAUSE|POINTER|PRINT|PRIVATE|PROGRAM|PROCEDURE|PROTECTED|PUBLIC|PURE|READ|RECURSIVE|RESULT|RETURN|REWIND|SAVE|SELECT|SEQUENCE|STOP|SUBMODULE|SUBROUTINE|SYNC|SYNCALL|SYNCIMAGES|SYNCMEMORY|TARGET|THEN|TYPE|UNLOCK|USE|VALUE|VOLATILE|WHERE|WRITE|WHILE)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="\b(ABSTRACT|ACCEPT|ALL|ALLSTOP|ALLOCATABLE|ALLOCATE|ARRAY|ASSIGN|ASSOCIATE|ASYNCHRONOUS|BACKSPACE|BIND|BLOCK|BLOCKDATA|BYTE|CALL|CASE|CLASS|CLOSE|CODIMENSION|COMMON|CONTIGUOUS|CONTAINS|CONTINUE|CRITICAL|CYCLE|DATA|DEALLOCATE|DECODE|DEFERRED|DIMENSION|DO|ELEMENTAL|ELSE|ENCODE|END|ENDASSOCIATE|ENDBLOCK|ENDDO|ENDENUM|ENDFORALL|ENDFUNCTION|ENDIF|ENDINTERFACE|ENDMODULE|ENDPROGRAM|ENDSELECT|ENDSUBMODULE|ENDSUBROUTINE|ENDTYPE|ENDWHERE|ENTRY|ENUM|ENUMERATOR|EQUIVALENCE|ERROR STOP|EXIT|EXTENDS|EXTERNAL|EXTRINSIC|FILE|FINAL|FORALL|FORMAT|FUNCTION|GENERIC|IF|IMAGES|IMPLICIT|IMPORT|IMPURE|INCLUDE|INQUIRE|INTENT|INTERFACE|INTRINSIC|IS|LOCK|MEMORY|MODULE|NAMELIST|NULLIFY|NONE|NON_INTRINSIC|NON_OVERRIDABLE|NOPASS|ONLY|OPEN|OPTIONAL|OPTIONS|PARAMETER|PASS|PAUSE|POINTER|PRINT|PRIVATE|PROGRAM|PROCEDURE|PROTECTED|PUBLIC|PURE|READ|RECURSIVE|RESULT|RETURN|REWIND|SAVE|SELECT|SEQUENCE|STOP|SUBMODULE|SUBROUTINE|SYNC|SYNCALL|SYNCIMAGES|SYNCMEMORY|TARGET|THEN|TYPE|UNLOCK|USE|VALUE|VOLATILE|WHERE|WRITE|WHILE)\s*\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="\b(CHARACTER|COMPLEX|DOUBLE PRECISION|DOUBLE COMPLEX|INTEGER|LOGICAL|REAL|C_INT|C_SHORT|C_LONG|C_LONG_LONG|C_SIGNED_CHAR|C_SIZE_T|C_INT8_T|C_INT16_T|C_INT32_T|C_INT64_T|C_INT_LEAST8_T|C_INT_LEAST16_T|C_INT_LEAST32_T|C_INT_LEAST64_T|C_INT_FAST8_T|C_INT_FAST16_T|C_INT_FAST32_T|C_INT_FAST64_T|C_INTMAX_T|C_INTPTR_T|C_FLOAT|C_DOUBLE|C_LONG_DOUBLE|C_FLOAT_COMPLEX|C_DOUBLE_COMPLEX|C_LONG_DOUBLE_COMPLEX|C_BOOL|C_CHAR|C_PTR|C_FUNPTR)\s*\b">
|
||||
<rule pattern="\b(CHARACTER|COMPLEX|DOUBLE PRECISION|DOUBLE COMPLEX|INTEGER|LOGICAL|REAL|C_INT|C_SHORT|C_LONG|C_LONG_LONG|C_SIGNED_CHAR|C_SIZE_T|C_INT8_T|C_INT16_T|C_INT32_T|C_INT64_T|C_INT_LEAST8_T|C_INT_LEAST16_T|C_INT_LEAST32_T|C_INT_LEAST64_T|C_INT_FAST8_T|C_INT_FAST16_T|C_INT_FAST32_T|C_INT_FAST64_T|C_INTMAX_T|C_INTPTR_T|C_FLOAT|C_DOUBLE|C_LONG_DOUBLE|C_FLOAT_COMPLEX|C_DOUBLE_COMPLEX|C_LONG_DOUBLE_COMPLEX|C_BOOL|C_CHAR|C_PTR|C_FUNPTR)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="(\*\*|\*|\+|-|\/|<|>|<=|>=|==|\/=|=)">
|
||||
@@ -35,7 +43,7 @@
|
||||
<rule pattern="[()\[\],:&%;.]">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="\b(Abort|Abs|Access|AChar|ACos|ACosH|AdjustL|AdjustR|AImag|AInt|Alarm|All|Allocated|ALog|AMax|AMin|AMod|And|ANInt|Any|ASin|ASinH|Associated|ATan|ATanH|Atomic_Define|Atomic_Ref|BesJ|BesJN|Bessel_J0|Bessel_J1|Bessel_JN|Bessel_Y0|Bessel_Y1|Bessel_YN|BesY|BesYN|BGE|BGT|BLE|BLT|Bit_Size|BTest|CAbs|CCos|Ceiling|CExp|Char|ChDir|ChMod|CLog|Cmplx|Command_Argument_Count|Complex|Conjg|Cos|CosH|Count|CPU_Time|CShift|CSin|CSqRt|CTime|C_Loc|C_Associated|C_Null_Ptr|C_Null_Funptr|C_F_Pointer|C_F_ProcPointer|C_Null_Char|C_Alert|C_Backspace|C_Form_Feed|C_FunLoc|C_Sizeof|C_New_Line|C_Carriage_Return|C_Horizontal_Tab|C_Vertical_Tab|DAbs|DACos|DASin|DATan|Date_and_Time|DbesJ|DbesJN|DbesY|DbesYN|Dble|DCos|DCosH|DDiM|DErF|DErFC|DExp|Digits|DiM|DInt|DLog|DMax|DMin|DMod|DNInt|Dot_Product|DProd|DSign|DSinH|DShiftL|DShiftR|DSin|DSqRt|DTanH|DTan|DTime|EOShift|Epsilon|ErF|ErFC|ErFC_Scaled|ETime|Execute_Command_Line|Exit|Exp|Exponent|Extends_Type_Of|FDate|FGet|FGetC|FindLoc|Float|Floor|Flush|FNum|FPutC|FPut|Fraction|FSeek|FStat|FTell|Gamma|GError|GetArg|Get_Command|Get_Command_Argument|Get_Environment_Variable|GetCWD|GetEnv|GetGId|GetLog|GetPId|GetUId|GMTime|HostNm|Huge|Hypot|IAbs|IAChar|IAll|IAnd|IAny|IArgC|IBClr|IBits|IBSet|IChar|IDate|IDiM|IDInt|IDNInt|IEOr|IErrNo|IFix|Imag|ImagPart|Image_Index|Index|Int|IOr|IParity|IRand|IsaTty|IShft|IShftC|ISign|Iso_C_Binding|Is_Contiguous|Is_Iostat_End|Is_Iostat_Eor|ITime|Kill|Kind|LBound|LCoBound|Len|Len_Trim|LGe|LGt|Link|LLe|LLt|LnBlnk|Loc|Log|Log_Gamma|Logical|Long|LShift|LStat|LTime|MaskL|MaskR|MatMul|Max|MaxExponent|MaxLoc|MaxVal|MClock|Merge|Merge_Bits|Move_Alloc|Min|MinExponent|MinLoc|MinVal|Mod|Modulo|MvBits|Nearest|New_Line|NInt|Norm2|Not|Null|Num_Images|Or|Pack|Parity|PError|Precision|Present|Product|Radix|Rand|Random_Number|Random_Seed|Range|Real|RealPart|Rename|Repeat|Reshape|RRSpacing|RShift|Same_Type_As|Scale|Scan|Second|Selected_Char_Kind|Selected_Int_Kind|Selected_Real_Kind|Set_Exponent|Shape|ShiftA|ShiftL|ShiftR|Short|Sign|Signal|SinH|Sin|Sleep|Sngl|Spacing|Spread|SqRt|SRand|Stat|Storage_Size|Sum|SymLnk|System|System_Clock|Tan|TanH|Time|This_Image|Tiny|TrailZ|Transfer|Transpose|Trim|TtyNam|UBound|UCoBound|UMask|Unlink|Unpack|Verify|XOr|ZAbs|ZCos|ZExp|ZLog|ZSin|ZSqRt)\s*\b">
|
||||
<rule pattern="\b(Abort|Abs|Access|AChar|ACos|ACosH|AdjustL|AdjustR|AImag|AInt|Alarm|All|Allocated|ALog|AMax|AMin|AMod|And|ANInt|Any|ASin|ASinH|Associated|ATan|ATanH|Atomic_Define|Atomic_Ref|BesJ|BesJN|Bessel_J0|Bessel_J1|Bessel_JN|Bessel_Y0|Bessel_Y1|Bessel_YN|BesY|BesYN|BGE|BGT|BLE|BLT|Bit_Size|BTest|CAbs|CCos|Ceiling|CExp|Char|ChDir|ChMod|CLog|Cmplx|Command_Argument_Count|Complex|Conjg|Cos|CosH|Count|CPU_Time|CShift|CSin|CSqRt|CTime|C_Loc|C_Associated|C_Null_Ptr|C_Null_Funptr|C_F_Pointer|C_F_ProcPointer|C_Null_Char|C_Alert|C_Backspace|C_Form_Feed|C_FunLoc|C_Sizeof|C_New_Line|C_Carriage_Return|C_Horizontal_Tab|C_Vertical_Tab|DAbs|DACos|DASin|DATan|Date_and_Time|DbesJ|DbesJN|DbesY|DbesYN|Dble|DCos|DCosH|DDiM|DErF|DErFC|DExp|Digits|DiM|DInt|DLog|DMax|DMin|DMod|DNInt|Dot_Product|DProd|DSign|DSinH|DShiftL|DShiftR|DSin|DSqRt|DTanH|DTan|DTime|EOShift|Epsilon|ErF|ErFC|ErFC_Scaled|ETime|Execute_Command_Line|Exit|Exp|Exponent|Extends_Type_Of|FDate|FGet|FGetC|FindLoc|Float|Floor|Flush|FNum|FPutC|FPut|Fraction|FSeek|FStat|FTell|Gamma|GError|GetArg|Get_Command|Get_Command_Argument|Get_Environment_Variable|GetCWD|GetEnv|GetGId|GetLog|GetPId|GetUId|GMTime|HostNm|Huge|Hypot|IAbs|IAChar|IAll|IAnd|IAny|IArgC|IBClr|IBits|IBSet|IChar|IDate|IDiM|IDInt|IDNInt|IEOr|IErrNo|IFix|Imag|ImagPart|Image_Index|Index|Int|IOr|IParity|IRand|IsaTty|IShft|IShftC|ISign|Iso_C_Binding|Is_Contiguous|Is_Iostat_End|Is_Iostat_Eor|ITime|Kill|Kind|LBound|LCoBound|Len|Len_Trim|LGe|LGt|Link|LLe|LLt|LnBlnk|Loc|Log|Log_Gamma|Logical|Long|LShift|LStat|LTime|MaskL|MaskR|MatMul|Max|MaxExponent|MaxLoc|MaxVal|MClock|Merge|Merge_Bits|Move_Alloc|Min|MinExponent|MinLoc|MinVal|Mod|Modulo|MvBits|Nearest|New_Line|NInt|Norm2|Not|Null|Num_Images|Or|Pack|Parity|PError|Precision|Present|Product|Radix|Rand|Random_Number|Random_Seed|Range|Real|RealPart|Rename|Repeat|Reshape|RRSpacing|RShift|Same_Type_As|Scale|Scan|Second|Selected_Char_Kind|Selected_Int_Kind|Selected_Real_Kind|Set_Exponent|Shape|ShiftA|ShiftL|ShiftR|Short|Sign|Signal|SinH|Sin|Sleep|Sngl|Spacing|Spread|SqRt|SRand|Stat|Storage_Size|Sum|SymLnk|System|System_Clock|Tan|TanH|Time|This_Image|Tiny|TrailZ|Transfer|Transpose|Trim|TtyNam|UBound|UCoBound|UMask|Unlink|Unpack|Verify|XOr|ZAbs|ZCos|ZExp|ZLog|ZSin|ZSqRt)\b">
|
||||
<token type="NameBuiltin"/>
|
||||
</rule>
|
||||
<rule pattern="\.(true|false)\.">
|
||||
|
||||
+1
-1
@@ -133,7 +133,7 @@
|
||||
<token type="LiteralString"/>
|
||||
<push state="string"/>
|
||||
</rule>
|
||||
<rule pattern="\b(open|module)(\s+)([\w.]+)">
|
||||
<rule pattern="\b(open type|open|module)(\s+)([\w.]+)">
|
||||
<bygroups>
|
||||
<token type="Keyword"/>
|
||||
<token type="Text"/>
|
||||
|
||||
+107
@@ -0,0 +1,107 @@
|
||||
<lexer>
|
||||
<config>
|
||||
<name>HLSL</name>
|
||||
<alias>hlsl</alias>
|
||||
<filename>*.hlsl</filename>
|
||||
<filename>*.hlsli</filename>
|
||||
<mime_type>text/x-hlsl</mime_type>
|
||||
</config>
|
||||
<rules>
|
||||
<state name="root">
|
||||
<rule pattern="^#.*$">
|
||||
<token type="CommentPreproc"/>
|
||||
</rule>
|
||||
<rule pattern="//.*$">
|
||||
<token type="CommentSingle"/>
|
||||
</rule>
|
||||
<rule pattern="/(\\\n)?[*](.|\n)*?[*](\\\n)?/">
|
||||
<token type="CommentMultiline"/>
|
||||
</rule>
|
||||
<rule pattern="\+|-|~|!=?|\*|/|%|<<|>>|<=?|>=?|==?|&&?|\^|\|\|?">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="[?:]">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="\bdefined\b">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="[;{}(),.\[\]]">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="[+-]?\d*\.\d+([eE][-+]?\d+)?f?">
|
||||
<token type="LiteralNumberFloat"/>
|
||||
</rule>
|
||||
<rule pattern="[+-]?\d+\.\d*([eE][-+]?\d+)?f?">
|
||||
<token type="LiteralNumberFloat"/>
|
||||
</rule>
|
||||
<rule pattern="0[xX][0-9a-fA-F]*">
|
||||
<token type="LiteralNumberHex"/>
|
||||
</rule>
|
||||
<rule pattern="0[0-7]*">
|
||||
<token type="LiteralNumberOct"/>
|
||||
</rule>
|
||||
<rule pattern="[1-9][0-9]*">
|
||||
<token type="LiteralNumberInteger"/>
|
||||
</rule>
|
||||
<rule pattern=""">
|
||||
<token type="LiteralString"/>
|
||||
<push state="string"/>
|
||||
</rule>
|
||||
<rule pattern="\b(asm|asm_fragment|break|case|cbuffer|centroid|class|column_major|compile|compile_fragment|const|continue|default|discard|do|else|export|extern|for|fxgroup|globallycoherent|groupshared|if|in|inline|inout|interface|line|lineadj|linear|namespace|nointerpolation|noperspective|NULL|out|packoffset|pass|pixelfragment|point|precise|return|register|row_major|sample|sampler|shared|stateblock|stateblock_state|static|struct|switch|tbuffer|technique|technique10|technique11|texture|typedef|triangle|triangleadj|uniform|vertexfragment|volatile|while)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="\b(true|false)\b">
|
||||
<token type="KeywordConstant"/>
|
||||
</rule>
|
||||
<rule pattern="\b(auto|catch|char|const_cast|delete|dynamic_cast|enum|explicit|friend|goto|long|mutable|new|operator|private|protected|public|reinterpret_cast|short|signed|sizeof|static_cast|template|this|throw|try|typename|union|unsigned|using|virtual)\b">
|
||||
<token type="KeywordReserved"/>
|
||||
</rule>
|
||||
<rule pattern="\b(dword|matrix|snorm|string|unorm|unsigned|void|vector|BlendState|Buffer|ByteAddressBuffer|ComputeShader|DepthStencilState|DepthStencilView|DomainShader|GeometryShader|HullShader|InputPatch|LineStream|OutputPatch|PixelShader|PointStream|RasterizerState|RenderTargetView|RasterizerOrderedBuffer|RasterizerOrderedByteAddressBuffer|RasterizerOrderedStructuredBuffer|RasterizerOrderedTexture1D|RasterizerOrderedTexture1DArray|RasterizerOrderedTexture2D|RasterizerOrderedTexture2DArray|RasterizerOrderedTexture3D|RWBuffer|RWByteAddressBuffer|RWStructuredBuffer|RWTexture1D|RWTexture1DArray|RWTexture2D|RWTexture2DArray|RWTexture3D|SamplerState|SamplerComparisonState|StructuredBuffer|Texture1D|Texture1DArray|Texture2D|Texture2DArray|Texture2DMS|Texture2DMSArray|Texture3D|TextureCube|TextureCubeArray|TriangleStream|VertexShader)\b">
|
||||
<token type="KeywordType"/>
|
||||
</rule>
|
||||
<rule pattern="\b(bool|double|float|int|half|min16float|min10float|min16int|min12int|min16uint|uint)([1-4](x[1-4])?)?\b">
|
||||
<token type="KeywordType"/>
|
||||
</rule>
|
||||
<rule pattern="\b(abort|abs|acos|all|AllMemoryBarrier|AllMemoryBarrierWithGroupSync|any|AppendStructuredBuffer|asdouble|asfloat|asin|asint|asuint|asuint|atan|atan2|ceil|CheckAccessFullyMapped|clamp|clip|CompileShader|ConsumeStructuredBuffer|cos|cosh|countbits|cross|D3DCOLORtoUBYTE4|ddx|ddx_coarse|ddx_fine|ddy|ddy_coarse|ddy_fine|degrees|determinant|DeviceMemoryBarrier|DeviceMemoryBarrierWithGroupSync|distance|dot|dst|errorf|EvaluateAttributeAtCentroid|EvaluateAttributeAtSample|EvaluateAttributeSnapped|exp|exp2|f16tof32|f32tof16|faceforward|firstbithigh|firstbitlow|floor|fma|fmod|frac|frexp|fwidth|GetRenderTargetSampleCount|GetRenderTargetSamplePosition|GlobalOrderedCountIncrement|GroupMemoryBarrier|GroupMemoryBarrierWithGroupSync|InterlockedAdd|InterlockedAnd|InterlockedCompareExchange|InterlockedCompareStore|InterlockedExchange|InterlockedMax|InterlockedMin|InterlockedOr|InterlockedXor|isfinite|isinf|isnan|ldexp|length|lerp|lit|log|log10|log2|mad|max|min|modf|msad4|mul|noise|normalize|pow|printf|Process2DQuadTessFactorsAvg|Process2DQuadTessFactorsMax|Process2DQuadTessFactorsMin|ProcessIsolineTessFactors|ProcessQuadTessFactorsAvg|ProcessQuadTessFactorsMax|ProcessQuadTessFactorsMin|ProcessTriTessFactorsAvg|ProcessTriTessFactorsMax|ProcessTriTessFactorsMin|QuadReadLaneAt|QuadSwapX|QuadSwapY|radians|rcp|reflect|refract|reversebits|round|rsqrt|saturate|sign|sin|sincos|sinh|smoothstep|sqrt|step|tan|tanh|tex1D|tex1D|tex1Dbias|tex1Dgrad|tex1Dlod|tex1Dproj|tex2D|tex2D|tex2Dbias|tex2Dgrad|tex2Dlod|tex2Dproj|tex3D|tex3D|tex3Dbias|tex3Dgrad|tex3Dlod|tex3Dproj|texCUBE|texCUBE|texCUBEbias|texCUBEgrad|texCUBElod|texCUBEproj|transpose|trunc|WaveAllBitAnd|WaveAllMax|WaveAllMin|WaveAllBitOr|WaveAllBitXor|WaveAllEqual|WaveAllProduct|WaveAllSum|WaveAllTrue|WaveAnyTrue|WaveBallot|WaveGetLaneCount|WaveGetLaneIndex|WaveGetOrderedIndex|WaveIsHelperLane|WaveOnce|WavePrefixProduct|WavePrefixSum|WaveReadFirstLane|WaveReadLaneAt)\b">
|
||||
<token type="NameBuiltin"/>
|
||||
</rule>
|
||||
<rule pattern="\b(SV_ClipDistance|SV_ClipDistance0|SV_ClipDistance1|SV_Culldistance|SV_CullDistance0|SV_CullDistance1|SV_Coverage|SV_Depth|SV_DepthGreaterEqual|SV_DepthLessEqual|SV_DispatchThreadID|SV_DomainLocation|SV_GroupID|SV_GroupIndex|SV_GroupThreadID|SV_GSInstanceID|SV_InnerCoverage|SV_InsideTessFactor|SV_InstanceID|SV_IsFrontFace|SV_OutputControlPointID|SV_Position|SV_PrimitiveID|SV_RenderTargetArrayIndex|SV_SampleIndex|SV_StencilRef|SV_TessFactor|SV_VertexID|SV_ViewportArrayIndex)\b">
|
||||
<token type="NameDecorator"/>
|
||||
</rule>
|
||||
<rule pattern="\bSV_Target[0-7]?\b">
|
||||
<token type="NameDecorator"/>
|
||||
</rule>
|
||||
<rule pattern="\b(allow_uav_condition|branch|call|domain|earlydepthstencil|fastopt|flatten|forcecase|instance|loop|maxtessfactor|numthreads|outputcontrolpoints|outputtopology|partitioning|patchconstantfunc|unroll)\b">
|
||||
<token type="NameDecorator"/>
|
||||
</rule>
|
||||
<rule pattern="[a-zA-Z_]\w*">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
<rule pattern="\\$">
|
||||
<token type="CommentPreproc"/>
|
||||
</rule>
|
||||
<rule pattern="\s+">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="string">
|
||||
<rule pattern=""">
|
||||
<token type="LiteralString"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
<rule pattern="\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|u[a-fA-F0-9]{4}|U[a-fA-F0-9]{8}|[0-7]{1,3})">
|
||||
<token type="LiteralStringEscape"/>
|
||||
</rule>
|
||||
<rule pattern="[^\\"\n]+">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="\\\n">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="\\">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+4
@@ -7,8 +7,12 @@
|
||||
<filename>*.ini</filename>
|
||||
<filename>*.cfg</filename>
|
||||
<filename>*.inf</filename>
|
||||
<filename>*.service</filename>
|
||||
<filename>*.socket</filename>
|
||||
<filename>.gitconfig</filename>
|
||||
<filename>.editorconfig</filename>
|
||||
<filename>pylintrc</filename>
|
||||
<filename>.pylintrc</filename>
|
||||
<mime_type>text/x-ini</mime_type>
|
||||
<mime_type>text/inf</mime_type>
|
||||
</config>
|
||||
|
||||
+3
@@ -180,6 +180,9 @@
|
||||
<rule pattern="@(?:[_\p{L}][\p{L}\p{N}]*|`@?[_\p{L}][\p{L}\p{N}]+`)">
|
||||
<token type="NameDecorator"/>
|
||||
</rule>
|
||||
<rule pattern="(?:\p{Lu}[_\p{L}]*)(?=\.)">
|
||||
<token type="NameClass"/>
|
||||
</rule>
|
||||
<rule pattern="(?:[_\p{L}][\p{L}\p{N}]*|`@?[_\p{L}][\p{L}\p{N}]+`)">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
|
||||
+87
-7
@@ -6,6 +6,7 @@
|
||||
<alias>ps1</alias>
|
||||
<alias>psm1</alias>
|
||||
<alias>psd1</alias>
|
||||
<alias>pwsh</alias>
|
||||
<filename>*.ps1</filename>
|
||||
<filename>*.psm1</filename>
|
||||
<filename>*.psd1</filename>
|
||||
@@ -22,6 +23,15 @@
|
||||
<rule pattern="\s+">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
<rule pattern="(\s*)(#)(requires)(\s+)">
|
||||
<bygroups>
|
||||
<token type="TextWhitespace"/>
|
||||
<token type="Comment"/>
|
||||
<token type="Keyword"/>
|
||||
<token type="TextWhitespace"/>
|
||||
</bygroups>
|
||||
<push state="requires"/>
|
||||
</rule>
|
||||
<rule pattern="^(\s*#[#\s]*)(\.(?:component|description|example|externalhelp|forwardhelpcategory|forwardhelptargetname|functionality|inputs|link|notes|outputs|parameter|remotehelprunspace|role|synopsis))([^\n]*$)">
|
||||
<bygroups>
|
||||
<token type="Comment"/>
|
||||
@@ -46,6 +56,9 @@
|
||||
<rule pattern="@'\n.*?\n'@">
|
||||
<token type="LiteralStringHeredoc"/>
|
||||
</rule>
|
||||
<rule pattern="@(?=\(|{)|\$(?=\()">
|
||||
<token type="NameVariableMagic"/>
|
||||
</rule>
|
||||
<rule pattern="`[\'"$@-]">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
@@ -56,13 +69,42 @@
|
||||
<rule pattern="'([^']|'')*'">
|
||||
<token type="LiteralStringSingle"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)(function|filter|workflow)(\s*)(global:|script:|private:|env:)?(\w\S*\b)">
|
||||
<bygroups>
|
||||
<token type="KeywordDeclaration"/>
|
||||
<token type="TextWhitespace"/>
|
||||
<token type="NameVariableMagic"/>
|
||||
<token type="NameBuiltin"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)(class|configuration)(\s+)(\w\S*)(\s*)(:*)">
|
||||
<bygroups>
|
||||
<token type="KeywordDeclaration"/>
|
||||
<token type="TextWhitespace"/>
|
||||
<token type="NameBuiltin"/>
|
||||
<token type="NameBuiltin"/>
|
||||
<token type="NameBuiltin"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="\$false|\$null|\$true(?=\b)">
|
||||
<token type="NameVariableMagic"/>
|
||||
</rule>
|
||||
<rule pattern="(\$|@@|@)((global|script|private|env):)?\w+">
|
||||
<token type="NameVariable"/>
|
||||
</rule>
|
||||
<rule pattern="(parameter|validatenotnullorempty|validatescript|validaterange|validateset|validaterange|validatepattern|validatelength|validatecount|validatenotnullorempty|validatescript|cmdletbinding|alias)\b">
|
||||
<token type="NameBuiltin"/>
|
||||
</rule>
|
||||
<rule pattern="[a-z]\w*-[a-z]\w*\b">
|
||||
<token type="NameBuiltin"/>
|
||||
</rule>
|
||||
<rule pattern="(while|validateset|validaterange|validatepattern|validatelength|validatecount|until|trap|switch|return|ref|process|param|parameter|in|if|global:|function|foreach|for|finally|filter|end|elseif|else|dynamicparam|do|default|continue|cmdletbinding|break|begin|alias|\?|%|#script|#private|#local|#global|mandatory|parametersetname|position|valuefrompipeline|valuefrompipelinebypropertyname|valuefromremainingarguments|helpmessage|try|catch|throw)\b">
|
||||
<rule pattern="(mandatory|parametersetname|position|helpmessage|valuefrompipeline|valuefrompipelinebypropertyname|valuefromremainingarguments|dontshow)\b">
|
||||
<token type="NameAttribute"/>
|
||||
</rule>
|
||||
<rule pattern="(confirmimpact|defaultparametersetname|helpuri|supportspaging|supportsshouldprocess|positionalbinding)\b">
|
||||
<token type="NameAttribute"/>
|
||||
</rule>
|
||||
<rule pattern="(while|until|trap|switch|return|ref|process|param|parameter|in|if|global:|foreach|for|finally|filter|end|elseif|else|dynamicparam|do|default|continue|break|begin|\?|%|#script|#private|#local|#global|try|catch|throw)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="-(and|as|band|bnot|bor|bxor|casesensitive|ccontains|ceq|cge|cgt|cle|clike|clt|cmatch|cne|cnotcontains|cnotlike|cnotmatch|contains|creplace|eq|exact|f|file|ge|gt|icontains|ieq|ige|igt|ile|ilike|ilt|imatch|ine|inotcontains|inotlike|inotmatch|ireplace|is|isnot|le|like|lt|match|ne|not|notcontains|notlike|notmatch|or|regex|replace|wildcard)\b">
|
||||
@@ -71,19 +113,47 @@
|
||||
<rule pattern="(ac|asnp|cat|cd|cfs|chdir|clc|clear|clhy|cli|clp|cls|clv|cnsn|compare|copy|cp|cpi|cpp|curl|cvpa|dbp|del|diff|dir|dnsn|ebp|echo|epal|epcsv|epsn|erase|etsn|exsn|fc|fhx|fl|foreach|ft|fw|gal|gbp|gc|gci|gcm|gcs|gdr|ghy|gi|gjb|gl|gm|gmo|gp|gps|gpv|group|gsn|gsnp|gsv|gu|gv|gwmi|h|history|icm|iex|ihy|ii|ipal|ipcsv|ipmo|ipsn|irm|ise|iwmi|iwr|kill|lp|ls|man|md|measure|mi|mount|move|mp|mv|nal|ndr|ni|nmo|npssc|nsn|nv|ogv|oh|popd|ps|pushd|pwd|r|rbp|rcjb|rcsn|rd|rdr|ren|ri|rjb|rm|rmdir|rmo|rni|rnp|rp|rsn|rsnp|rujb|rv|rvpa|rwmi|sajb|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spjb|spps|spsv|start|sujb|sv|swmi|tee|trcm|type|wget|where|wjb|write)\s">
|
||||
<token type="NameBuiltin"/>
|
||||
</rule>
|
||||
<rule pattern="\[[a-z_\[][\w. `,\[\]]*\]">
|
||||
<token type="NameConstant"/>
|
||||
<rule pattern="(\[)([a-z_\[][\w. `,\[\]]*)(\])">
|
||||
<bygroups>
|
||||
<token type="Punctuation"/>
|
||||
<token type="NameConstant"/>
|
||||
<token type="Punctuation"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="-[a-z_]\w*">
|
||||
<rule pattern="(?<!\[)(?<=\S[^\*|\n]\.)\w+(?=\s+|\(|\{|\.)">
|
||||
<token type="NameProperty"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\w)([-+]?(?:[0-9]+)?\.?[0-9]+(?:(?:e|E)[0-9]+)?(?:F|f|D|d|M|m)?)((?i:[kmgtp]b)?)\b">
|
||||
<bygroups>
|
||||
<token type="LiteralNumberFloat"/>
|
||||
<token type="Punctuation"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="-[a-z_]\w*:*">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
<rule pattern="\w+">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
<rule pattern="[.,;@{}\[\]$()=+*/\\&%!~?^`|<>-]|::">
|
||||
<rule pattern="[.,;@{}\[\]$()=+*/\\&%!~?^\x60|<>-]|::">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="requires">
|
||||
<rule pattern="\s*\n|\s*$">
|
||||
<token type="TextWhitespace"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
<rule pattern="-(?i:modules|pssnapin|runasadministrator|ahellid|version|assembly|psedition)">
|
||||
<token type="KeywordDeclaration"/>
|
||||
</rule>
|
||||
<rule pattern="-\S*\b">
|
||||
<token type="Comment"/>
|
||||
</rule>
|
||||
<rule pattern="\s+(\S+)">
|
||||
<token type="NameAttribute"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="child">
|
||||
<rule pattern="\)">
|
||||
<token type="Punctuation"/>
|
||||
@@ -101,8 +171,12 @@
|
||||
<token type="CommentMultiline"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
<rule pattern="\.(component|description|example|externalhelp|forwardhelpcategory|forwardhelptargetname|functionality|inputs|link|notes|outputs|parameter|remotehelprunspace|role|synopsis)">
|
||||
<token type="LiteralStringDoc"/>
|
||||
<rule pattern="(\s*\.)(component|description|example|externalhelp|forwardhelpcategory|forwardhelptargetname|functionality|inputs|link|notes|outputs|parameter|remotehelprunspace|role|synopsis)(\s*$)">
|
||||
<bygroups>
|
||||
<token type="CommentMultiline"/>
|
||||
<token type="LiteralStringDoc"/>
|
||||
<token type="CommentMultiline"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="[#&.]">
|
||||
<token type="CommentMultiline"/>
|
||||
@@ -119,6 +193,9 @@
|
||||
<token type="Punctuation"/>
|
||||
<push state="child"/>
|
||||
</rule>
|
||||
<rule pattern="((\$)((global|script|private|env):)?\w+)|((\$){((global|script|private|env):)?\w+})">
|
||||
<token type="NameVariable"/>
|
||||
</rule>
|
||||
<rule pattern="""">
|
||||
<token type="LiteralStringDouble"/>
|
||||
</rule>
|
||||
@@ -139,6 +216,9 @@
|
||||
<token type="Punctuation"/>
|
||||
<push state="child"/>
|
||||
</rule>
|
||||
<rule pattern="((\$)((global|script|private|env):)?\w+)|((\$){((global|script|private|env):)?\w+})">
|
||||
<token type="NameVariable"/>
|
||||
</rule>
|
||||
<rule pattern="[^@\n]+"]">
|
||||
<token type="LiteralStringHeredoc"/>
|
||||
</rule>
|
||||
|
||||
+126
@@ -0,0 +1,126 @@
|
||||
<lexer>
|
||||
<config>
|
||||
<name>PSL</name>
|
||||
<alias>psl</alias>
|
||||
<filename>*.psl</filename>
|
||||
<filename>*.BATCH</filename>
|
||||
<filename>*.TRIG</filename>
|
||||
<filename>*.PROC</filename>
|
||||
<mime_type>text/x-psl</mime_type>
|
||||
</config>
|
||||
<rules>
|
||||
<!-- NameFunction|TypeName -->
|
||||
<state name="root">
|
||||
<rule pattern="//.*$">
|
||||
<token type="CommentSingle"/>
|
||||
</rule>
|
||||
<rule pattern="/(\\\n)?[*](.|\n)*?[*](\\\n)?/">
|
||||
<token type="CommentMultiline"/>
|
||||
</rule>
|
||||
<rule pattern="\+|-|\*|/|%|'?<|'?>|'?=|\band\b|\bor\b|_|:">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="[{}(),\[\]]">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="[+-]?\d*\.\d+">
|
||||
<token type="LiteralNumber"/>
|
||||
</rule>
|
||||
<rule pattern=""">
|
||||
<token type="LiteralString"/>
|
||||
<push state="string"/>
|
||||
</rule>
|
||||
<rule pattern="\.">
|
||||
<token type="Operator"/>
|
||||
<push state="method"/>
|
||||
</rule>
|
||||
<rule pattern="\$\$">
|
||||
<token type="NameFunction"/>
|
||||
<push state="method"/>
|
||||
</rule>
|
||||
<rule pattern="\bdo\b">
|
||||
<token type="KeywordReserved"/>
|
||||
<push state="callmethod"/>
|
||||
</rule>
|
||||
<rule pattern="\b(do|set|if|for|while|quit|catch|return|while)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="\b(true|false)\b">
|
||||
<token type="KeywordConstant"/>
|
||||
</rule>
|
||||
<rule pattern="\btype\b">
|
||||
<token type="KeywordDeclaration"/>
|
||||
<push state="typename"/>
|
||||
</rule>
|
||||
<rule pattern="\b(public|req|private|void)\b">
|
||||
<token type="KeywordDeclaration"/>
|
||||
</rule>
|
||||
<rule pattern="\b(Boolean|String|Number|Date)\b">
|
||||
<token type="KeywordType"/>
|
||||
</rule>
|
||||
<rule pattern="\^?[a-zA-Z][a-zA-Z0-9]*">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
<rule pattern="\s+">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="string">
|
||||
<rule pattern=""">
|
||||
<token type="LiteralString"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
<rule pattern="\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|u[a-fA-F0-9]{4}|U[a-fA-F0-9]{8}|[0-7]{1,3})">
|
||||
<token type="LiteralStringEscape"/>
|
||||
</rule>
|
||||
<rule pattern="[^\\"\n]+">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="\\\n">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="\\">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="method">
|
||||
<rule pattern="\(">
|
||||
<token type="Punctuation"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
<rule pattern="\^[a-zA-Z][a-zA-Z0-9]*">
|
||||
<token type="NameClass"/>
|
||||
</rule>
|
||||
<rule pattern="[a-zA-Z][a-zA-Z0-9]*">
|
||||
<token type="NameFunction"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="callmethod">
|
||||
<rule pattern="\(|{">
|
||||
<token type="Punctuation"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
<rule pattern="\^[a-zA-Z][a-zA-Z0-9]*">
|
||||
<token type="NameClass"/>
|
||||
</rule>
|
||||
<rule pattern="[a-zA-Z][a-zA-Z0-9]*">
|
||||
<token type="NameFunction"/>
|
||||
</rule>
|
||||
<rule pattern="\s+">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="typename">
|
||||
<rule pattern="\s+">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
<rule pattern="\b(public|req|private|void)\b">
|
||||
<token type="KeywordDeclaration"/>
|
||||
</rule>
|
||||
<rule pattern="[a-zA-Z][a-zA-Z0-9]*">
|
||||
<token type="NameClass"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+1
-1
@@ -379,7 +379,7 @@
|
||||
</rule>
|
||||
</state>
|
||||
<state name="name">
|
||||
<rule pattern="@[_\p{L}][_\p{L}\p{N}]*">
|
||||
<rule pattern="@[_\p{L}][_\p{L}\p{N}]*(\s*\.\s*[_\p{L}][_\p{L}\p{N}]*)*">
|
||||
<token type="NameDecorator"/>
|
||||
</rule>
|
||||
<rule pattern="@">
|
||||
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
<lexer>
|
||||
<config>
|
||||
<name>Sed</name>
|
||||
<alias>sed</alias>
|
||||
<alias>gsed</alias>
|
||||
<alias>ssed</alias>
|
||||
<filename>*.sed</filename>
|
||||
<filename>*.[gs]sed</filename>
|
||||
<mime_type>text/x-sed</mime_type>
|
||||
</config>
|
||||
<rules>
|
||||
<state name="root">
|
||||
<rule pattern="\s+"><token type="TextWhitespace"/></rule>
|
||||
<rule pattern="#.*$"><token type="CommentSingle"/></rule>
|
||||
<rule pattern="[0-9]+"><token type="LiteralNumberInteger"/></rule>
|
||||
<rule pattern="\$"><token type="Operator"/></rule>
|
||||
<rule pattern="[{};,!]"><token type="Punctuation"/></rule>
|
||||
<rule pattern="[dDFgGhHlnNpPqQxz=]"><token type="Keyword"/></rule>
|
||||
<rule pattern="([berRtTvwW:])([^;\n]*)"><bygroups><token type="Keyword"/><token type="LiteralStringSingle"/></bygroups></rule>
|
||||
<rule pattern="([aci])((?:.*?\\\n)*(?:.*?[^\\]$))"><bygroups><token type="Keyword"/><token type="LiteralStringDouble"/></bygroups></rule>
|
||||
<rule pattern="([qQ])([0-9]*)"><bygroups><token type="Keyword"/><token type="LiteralNumberInteger"/></bygroups></rule>
|
||||
<rule pattern="(/)((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)(/)"><bygroups><token type="Punctuation"/><token type="LiteralStringRegex"/><token type="Punctuation"/></bygroups></rule>
|
||||
<rule pattern="(\\(.))((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)(\2)"><bygroups><token type="Punctuation"/>None<token type="LiteralStringRegex"/><token type="Punctuation"/></bygroups></rule>
|
||||
<rule pattern="(y)(.)((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)(\2)((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)(\2)"><bygroups><token type="Keyword"/><token type="Punctuation"/><token type="LiteralStringSingle"/><token type="Punctuation"/><token type="LiteralStringSingle"/><token type="Punctuation"/></bygroups></rule>
|
||||
<rule pattern="(s)(.)((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)(\2)((?:(?:\\[^\n]|[^\\])*?\\\n)*?(?:\\.|[^\\])*?)(\2)((?:[gpeIiMm]|[0-9])*)"><bygroups><token type="Keyword"/><token type="Punctuation"/><token type="LiteralStringRegex"/><token type="Punctuation"/><token type="LiteralStringSingle"/><token type="Punctuation"/><token type="Keyword"/></bygroups></rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+85
@@ -0,0 +1,85 @@
|
||||
<lexer>
|
||||
<config>
|
||||
<name>stas</name>
|
||||
<filename>*.stas</filename>
|
||||
</config>
|
||||
<rules>
|
||||
<state name="string-double-quoted">
|
||||
<rule pattern="\\.">
|
||||
<token type="LiteralStringEscape"/>
|
||||
</rule>
|
||||
<rule pattern="[^\\"]+">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern=""">
|
||||
<token type="LiteralString"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="string-single-quoted">
|
||||
<rule pattern="\\.">
|
||||
<token type="LiteralStringEscape"/>
|
||||
</rule>
|
||||
<rule pattern="[^\\']+">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="'">
|
||||
<token type="LiteralString"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="string-char-literal">
|
||||
<rule pattern="\\.">
|
||||
<token type="LiteralStringEscape"/>
|
||||
</rule>
|
||||
<rule pattern="[^\\`]+">
|
||||
<token type="LiteralString"/>
|
||||
</rule>
|
||||
<rule pattern="`">
|
||||
<token type="LiteralStringChar"/>
|
||||
<pop depth="1"/>
|
||||
</rule>
|
||||
</state>
|
||||
<state name="root">
|
||||
<rule pattern="(\n|\s)+">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)(fn|argc|argv|swap|dup|over|over2|rot|rot4|drop|w8|w16|w32|w64|r8|r16|r32|r64|syscall0|syscall1|syscall2|syscall3|syscall4|syscall5|syscall6|_breakpoint|assert|const|auto|reserve|pop|include|addr|if|else|elif|while|break|continue|ret)(?!\S)">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)(\+|\-|\*|\/|\%|\%\%|\+\+|\-\-|>>|<<)(?!\S)">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)(\=|\!\=|>|<|>\=|<\=|>s|<s|>\=s|<\=s)(?!\S)">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)(\&|\||\^|\~|\!|-\>)(?!\S)">
|
||||
<token type="Operator"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)\-?(\d+)(?!\S)">
|
||||
<token type="LiteralNumber"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S);.*(\S|\n)">
|
||||
<token type="Comment"/>
|
||||
</rule>
|
||||
<rule pattern="'">
|
||||
<token type="LiteralString"/>
|
||||
<push state="string-single-quoted"/>
|
||||
</rule>
|
||||
<rule pattern=""">
|
||||
<token type="LiteralString"/>
|
||||
<push state="string-double-quoted"/>
|
||||
</rule>
|
||||
<rule pattern="`">
|
||||
<token type="LiteralStringChar"/>
|
||||
<push state="string-char-literal"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)[{}](?!\S)">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="(?<!\S)[^\s]+(?!\S)">
|
||||
<token type="Name"/>
|
||||
</rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+2
@@ -6,6 +6,8 @@
|
||||
<alias>typescript</alias>
|
||||
<filename>*.ts</filename>
|
||||
<filename>*.tsx</filename>
|
||||
<filename>*.mts</filename>
|
||||
<filename>*.cts</filename>
|
||||
<mime_type>text/x-typescript</mime_type>
|
||||
<dot_all>true</dot_all>
|
||||
<ensure_nl>true</ensure_nl>
|
||||
|
||||
+72
@@ -0,0 +1,72 @@
|
||||
|
||||
<lexer>
|
||||
<config>
|
||||
<name>Vala</name>
|
||||
<alias>vala</alias>
|
||||
<alias>vapi</alias>
|
||||
<filename>*.vala</filename>
|
||||
<filename>*.vapi</filename>
|
||||
<mime_type>text/x-vala</mime_type>
|
||||
</config>
|
||||
<rules>
|
||||
<state name="whitespace">
|
||||
<rule pattern="^\s*#if\s+0"><token type="CommentPreproc"/><push state="if0"/></rule>
|
||||
<rule pattern="\n"><token type="TextWhitespace"/></rule>
|
||||
<rule pattern="\s+"><token type="TextWhitespace"/></rule>
|
||||
<rule pattern="\\\n"><token type="Text"/></rule>
|
||||
<rule pattern="//(\n|(.|\n)*?[^\\]\n)"><token type="CommentSingle"/></rule>
|
||||
<rule pattern="/(\\\n)?[*](.|\n)*?[*](\\\n)?/"><token type="CommentMultiline"/></rule>
|
||||
</state>
|
||||
<state name="statements">
|
||||
<rule pattern="[L@]?""><token type="LiteralString"/><push state="string"/></rule>
|
||||
<rule pattern="L?'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'"><token type="LiteralStringChar"/></rule>
|
||||
<rule pattern="(?s)""".*?""""><token type="LiteralString"/></rule>
|
||||
<rule pattern="(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?"><token type="LiteralNumberFloat"/></rule>
|
||||
<rule pattern="(\d+\.\d*|\.\d+|\d+[fF])[fF]?"><token type="LiteralNumberFloat"/></rule>
|
||||
<rule pattern="0x[0-9a-fA-F]+[Ll]?"><token type="LiteralNumberHex"/></rule>
|
||||
<rule pattern="0[0-7]+[Ll]?"><token type="LiteralNumberOct"/></rule>
|
||||
<rule pattern="\d+[Ll]?"><token type="LiteralNumberInteger"/></rule>
|
||||
<rule pattern="[~!%^&*+=|?:<>/-]"><token type="Operator"/></rule>
|
||||
<rule pattern="(\[)(Compact|Immutable|(?:Boolean|Simple)Type)(\])"><bygroups><token type="Punctuation"/><token type="NameDecorator"/><token type="Punctuation"/></bygroups></rule>
|
||||
<rule pattern="(\[)(CCode|(?:Integer|Floating)Type)"><bygroups><token type="Punctuation"/><token type="NameDecorator"/></bygroups></rule>
|
||||
<rule pattern="[()\[\],.]"><token type="Punctuation"/></rule>
|
||||
<rule pattern="(as|base|break|case|catch|construct|continue|default|delete|do|else|enum|finally|for|foreach|get|if|in|is|lock|new|out|params|return|set|sizeof|switch|this|throw|try|typeof|while|yield)\b"><token type="Keyword"/></rule>
|
||||
<rule pattern="(abstract|const|delegate|dynamic|ensures|extern|inline|internal|override|owned|private|protected|public|ref|requires|signal|static|throws|unowned|var|virtual|volatile|weak|yields)\b"><token type="KeywordDeclaration"/></rule>
|
||||
<rule pattern="(namespace|using)(\s+)"><bygroups><token type="KeywordNamespace"/><token type="TextWhitespace"/></bygroups><push state="namespace"/></rule>
|
||||
<rule pattern="(class|errordomain|interface|struct)(\s+)"><bygroups><token type="KeywordDeclaration"/><token type="TextWhitespace"/></bygroups><push state="class"/></rule>
|
||||
<rule pattern="(\.)([a-zA-Z_]\w*)"><bygroups><token type="Operator"/><token type="NameAttribute"/></bygroups></rule>
|
||||
<rule pattern="(void|bool|char|double|float|int|int8|int16|int32|int64|long|short|size_t|ssize_t|string|time_t|uchar|uint|uint8|uint16|uint32|uint64|ulong|unichar|ushort)\b"><token type="KeywordType"/></rule>
|
||||
<rule pattern="(true|false|null)\b"><token type="NameBuiltin"/></rule>
|
||||
<rule pattern="[a-zA-Z_]\w*"><token type="Name"/></rule>
|
||||
</state>
|
||||
<state name="root">
|
||||
<rule><include state="whitespace"/></rule>
|
||||
<rule><push state="statement"/></rule>
|
||||
</state>
|
||||
<state name="statement">
|
||||
<rule><include state="whitespace"/></rule>
|
||||
<rule><include state="statements"/></rule>
|
||||
<rule pattern="[{}]"><token type="Punctuation"/></rule>
|
||||
<rule pattern=";"><token type="Punctuation"/><pop depth="1"/></rule>
|
||||
</state>
|
||||
<state name="string">
|
||||
<rule pattern="""><token type="LiteralString"/><pop depth="1"/></rule>
|
||||
<rule pattern="\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})"><token type="LiteralStringEscape"/></rule>
|
||||
<rule pattern="[^\\"\n]+"><token type="LiteralString"/></rule>
|
||||
<rule pattern="\\\n"><token type="LiteralString"/></rule>
|
||||
<rule pattern="\\"><token type="LiteralString"/></rule>
|
||||
</state>
|
||||
<state name="if0">
|
||||
<rule pattern="^\s*#if.*?(?<!\\)\n"><token type="CommentPreproc"/><push/></rule>
|
||||
<rule pattern="^\s*#el(?:se|if).*\n"><token type="CommentPreproc"/><pop depth="1"/></rule>
|
||||
<rule pattern="^\s*#endif.*?(?<!\\)\n"><token type="CommentPreproc"/><pop depth="1"/></rule>
|
||||
<rule pattern=".*?\n"><token type="Comment"/></rule>
|
||||
</state>
|
||||
<state name="class">
|
||||
<rule pattern="[a-zA-Z_]\w*"><token type="NameClass"/><pop depth="1"/></rule>
|
||||
</state>
|
||||
<state name="namespace">
|
||||
<rule pattern="[a-zA-Z_][\w.]*"><token type="NameNamespace"/><pop depth="1"/></rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+48
@@ -0,0 +1,48 @@
|
||||
<lexer>
|
||||
<config>
|
||||
<name>VHS</name>
|
||||
<alias>vhs</alias>
|
||||
<alias>tape</alias>
|
||||
<alias>cassette</alias>
|
||||
<filename>*.tape</filename>
|
||||
</config>
|
||||
<rules>
|
||||
<state name="root">
|
||||
<rule pattern="(Output)(\s+)(.*)(\s+)">
|
||||
<bygroups>
|
||||
<token type="Keyword"/>
|
||||
<token type="TextWhitespace"/>
|
||||
<token type="LiteralString"/>
|
||||
<token type="TextWhitespace"/>
|
||||
</bygroups>
|
||||
</rule>
|
||||
<rule pattern="\b(Set|Type|Left|Right|Up|Down|Backspace|Enter|Tab|Space|Ctrl|Sleep|Hide|Show|Escape)\b">
|
||||
<token type="Keyword"/>
|
||||
</rule>
|
||||
<rule pattern="\b(FontFamily|FontSize|Framerate|Height|Width|Theme|Padding|TypingSpeed|PlaybackSpeed|LineHeight|Framerate|LetterSpacing)\b">
|
||||
<token type="NameBuiltin"/>
|
||||
</rule>
|
||||
<rule pattern="#.*(\S|$)">
|
||||
<token type="Comment"/>
|
||||
</rule>
|
||||
<rule pattern="(?s)".*"">
|
||||
<token type="LiteralStringDouble"/>
|
||||
</rule>
|
||||
<rule pattern="(?s)'.*'">
|
||||
<token type="LiteralStringSingle"/>
|
||||
</rule>
|
||||
<rule pattern="(@|\+)">
|
||||
<token type="Punctuation"/>
|
||||
</rule>
|
||||
<rule pattern="\d+">
|
||||
<token type="LiteralNumber"/>
|
||||
</rule>
|
||||
<rule pattern="\s+">
|
||||
<token type="TextWhitespace"/>
|
||||
</rule>
|
||||
<rule pattern="(ms|s)">
|
||||
<token type="Text"/>
|
||||
</rule>
|
||||
</state>
|
||||
</rules>
|
||||
</lexer>
|
||||
+1
-1
@@ -7,7 +7,7 @@ import (
|
||||
// Makefile lexer.
|
||||
var Makefile = Register(MustNewLexer(
|
||||
&Config{
|
||||
Name: "Base Makefile",
|
||||
Name: "Makefile",
|
||||
Aliases: []string{"make", "makefile", "mf", "bsdmake"},
|
||||
Filenames: []string{"*.mak", "*.mk", "Makefile", "makefile", "Makefile.*", "GNUmakefile", "BSDmakefile"},
|
||||
MimeTypes: []string{"text/x-makefile"},
|
||||
|
||||
+2
-2
File diff suppressed because one or more lines are too long
+4
-4
@@ -60,10 +60,10 @@ type TypeMapping []struct {
|
||||
//
|
||||
// eg. Map "defvaralias" tokens of type NameVariable to NameFunction:
|
||||
//
|
||||
// mapping := TypeMapping{
|
||||
// {NameVariable, NameFunction, []string{"defvaralias"},
|
||||
// }
|
||||
// lexer = TypeRemappingLexer(lexer, mapping)
|
||||
// mapping := TypeMapping{
|
||||
// {NameVariable, NameFunction, []string{"defvaralias"},
|
||||
// }
|
||||
// lexer = TypeRemappingLexer(lexer, mapping)
|
||||
func TypeRemappingLexer(lexer Lexer, mapping TypeMapping) Lexer {
|
||||
// Lookup table for fast remapping.
|
||||
lut := map[TokenType]map[string]TokenType{}
|
||||
|
||||
+28
-29
@@ -15,42 +15,42 @@ import (
|
||||
|
||||
// Serialisation of Chroma rules to XML. The format is:
|
||||
//
|
||||
// <rules>
|
||||
// <state name="$STATE">
|
||||
// <rule [pattern="$PATTERN"]>
|
||||
// [<$EMITTER ...>]
|
||||
// [<$MUTATOR ...>]
|
||||
// </rule>
|
||||
// </state>
|
||||
// </rules>
|
||||
// <rules>
|
||||
// <state name="$STATE">
|
||||
// <rule [pattern="$PATTERN"]>
|
||||
// [<$EMITTER ...>]
|
||||
// [<$MUTATOR ...>]
|
||||
// </rule>
|
||||
// </state>
|
||||
// </rules>
|
||||
//
|
||||
// eg. Include("String") would become:
|
||||
//
|
||||
// <rule>
|
||||
// <include state="String" />
|
||||
// </rule>
|
||||
// <rule>
|
||||
// <include state="String" />
|
||||
// </rule>
|
||||
//
|
||||
// [null, null, {"kind": "include", "state": "String"}]
|
||||
// [null, null, {"kind": "include", "state": "String"}]
|
||||
//
|
||||
// eg. Rule{`\d+`, Text, nil} would become:
|
||||
//
|
||||
// <rule pattern="\\d+">
|
||||
// <token type="Text"/>
|
||||
// </rule>
|
||||
// <rule pattern="\\d+">
|
||||
// <token type="Text"/>
|
||||
// </rule>
|
||||
//
|
||||
// eg. Rule{`"`, String, Push("String")}
|
||||
//
|
||||
// <rule pattern="\"">
|
||||
// <token type="String" />
|
||||
// <push state="String" />
|
||||
// </rule>
|
||||
// <rule pattern="\"">
|
||||
// <token type="String" />
|
||||
// <push state="String" />
|
||||
// </rule>
|
||||
//
|
||||
// eg. Rule{`(\w+)(\n)`, ByGroups(Keyword, Whitespace), nil},
|
||||
//
|
||||
// <rule pattern="(\\w+)(\\n)">
|
||||
// <bygroups token="Keyword" token="Whitespace" />
|
||||
// <push state="String" />
|
||||
// </rule>
|
||||
// <rule pattern="(\\w+)(\\n)">
|
||||
// <bygroups token="Keyword" token="Whitespace" />
|
||||
// <push state="String" />
|
||||
// </rule>
|
||||
var (
|
||||
// ErrNotSerialisable is returned if a lexer contains Rules that cannot be serialised.
|
||||
ErrNotSerialisable = fmt.Errorf("not serialisable")
|
||||
@@ -372,13 +372,12 @@ func (t *TokenType) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
|
||||
if err := d.DecodeElement(&el, &start); err != nil {
|
||||
return err
|
||||
}
|
||||
for tt, text := range _TokenType_map {
|
||||
if text == el.Type {
|
||||
*t = tt
|
||||
return nil
|
||||
}
|
||||
tt, err := TokenTypeString(el.Type)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return fmt.Errorf("unknown TokenType %q", el.Type)
|
||||
*t = tt
|
||||
return nil
|
||||
}
|
||||
|
||||
func (t TokenType) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
|
||||
|
||||
+115
@@ -1,7 +1,10 @@
|
||||
package chroma
|
||||
|
||||
import (
|
||||
"encoding/xml"
|
||||
"fmt"
|
||||
"io"
|
||||
"sort"
|
||||
"strings"
|
||||
)
|
||||
|
||||
@@ -49,6 +52,10 @@ type StyleEntry struct {
|
||||
NoInherit bool
|
||||
}
|
||||
|
||||
func (s StyleEntry) MarshalText() ([]byte, error) {
|
||||
return []byte(s.String()), nil
|
||||
}
|
||||
|
||||
func (s StyleEntry) String() string {
|
||||
out := []string{}
|
||||
if s.Bold != Pass {
|
||||
@@ -216,6 +223,22 @@ func (s *StyleBuilder) Build() (*Style, error) {
|
||||
// StyleEntries mapping TokenType to colour definition.
|
||||
type StyleEntries map[TokenType]string
|
||||
|
||||
// NewXMLStyle parses an XML style definition.
|
||||
func NewXMLStyle(r io.Reader) (*Style, error) {
|
||||
dec := xml.NewDecoder(r)
|
||||
style := &Style{}
|
||||
return style, dec.Decode(style)
|
||||
}
|
||||
|
||||
// MustNewXMLStyle is like NewXMLStyle but panics on error.
|
||||
func MustNewXMLStyle(r io.Reader) *Style {
|
||||
style, err := NewXMLStyle(r)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
return style
|
||||
}
|
||||
|
||||
// NewStyle creates a new style definition.
|
||||
func NewStyle(name string, entries StyleEntries) (*Style, error) {
|
||||
return NewStyleBuilder(name).AddAll(entries).Build()
|
||||
@@ -239,6 +262,89 @@ type Style struct {
|
||||
parent *Style
|
||||
}
|
||||
|
||||
func (s *Style) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
|
||||
if s.parent != nil {
|
||||
return fmt.Errorf("cannot marshal style with parent")
|
||||
}
|
||||
start.Name = xml.Name{Local: "style"}
|
||||
start.Attr = []xml.Attr{{Name: xml.Name{Local: "name"}, Value: s.Name}}
|
||||
if err := e.EncodeToken(start); err != nil {
|
||||
return err
|
||||
}
|
||||
sorted := make([]TokenType, 0, len(s.entries))
|
||||
for ttype := range s.entries {
|
||||
sorted = append(sorted, ttype)
|
||||
}
|
||||
sort.Slice(sorted, func(i, j int) bool { return sorted[i] < sorted[j] })
|
||||
for _, ttype := range sorted {
|
||||
entry := s.entries[ttype]
|
||||
el := xml.StartElement{Name: xml.Name{Local: "entry"}}
|
||||
el.Attr = []xml.Attr{
|
||||
{Name: xml.Name{Local: "type"}, Value: ttype.String()},
|
||||
{Name: xml.Name{Local: "style"}, Value: entry.String()},
|
||||
}
|
||||
if err := e.EncodeToken(el); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := e.EncodeToken(xml.EndElement{Name: el.Name}); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return e.EncodeToken(xml.EndElement{Name: start.Name})
|
||||
}
|
||||
|
||||
func (s *Style) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
|
||||
for _, attr := range start.Attr {
|
||||
if attr.Name.Local == "name" {
|
||||
s.Name = attr.Value
|
||||
} else {
|
||||
return fmt.Errorf("unexpected attribute %s", attr.Name.Local)
|
||||
}
|
||||
}
|
||||
if s.Name == "" {
|
||||
return fmt.Errorf("missing style name attribute")
|
||||
}
|
||||
s.entries = map[TokenType]StyleEntry{}
|
||||
for {
|
||||
tok, err := d.Token()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
switch el := tok.(type) {
|
||||
case xml.StartElement:
|
||||
if el.Name.Local != "entry" {
|
||||
return fmt.Errorf("unexpected element %s", el.Name.Local)
|
||||
}
|
||||
var ttype TokenType
|
||||
var entry StyleEntry
|
||||
for _, attr := range el.Attr {
|
||||
switch attr.Name.Local {
|
||||
case "type":
|
||||
ttype, err = TokenTypeString(attr.Value)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
case "style":
|
||||
entry, err = ParseStyleEntry(attr.Value)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
default:
|
||||
return fmt.Errorf("unexpected attribute %s", attr.Name.Local)
|
||||
}
|
||||
}
|
||||
s.entries[ttype] = entry
|
||||
|
||||
case xml.EndElement:
|
||||
if el.Name.Local == start.Name.Local {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Types that are styled.
|
||||
func (s *Style) Types() []TokenType {
|
||||
dedupe := map[TokenType]bool{}
|
||||
@@ -319,6 +425,15 @@ func (s *Style) synthesisable(ttype TokenType) bool {
|
||||
return ttype == LineHighlight || ttype == LineNumbers || ttype == LineNumbersTable
|
||||
}
|
||||
|
||||
// MustParseStyleEntry parses a Pygments style entry or panics.
|
||||
func MustParseStyleEntry(entry string) StyleEntry {
|
||||
out, err := ParseStyleEntry(entry)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
return out
|
||||
}
|
||||
|
||||
// ParseStyleEntry parses a Pygments style entry.
|
||||
func ParseStyleEntry(entry string) (StyleEntry, error) { // nolint: gocyclo
|
||||
out := StyleEntry{}
|
||||
|
||||
-18
@@ -1,18 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Abap style.
|
||||
var Abap = Register(chroma.MustNewStyle("abap", chroma.StyleEntries{
|
||||
chroma.Comment: "italic #888",
|
||||
chroma.CommentSpecial: "#888",
|
||||
chroma.Keyword: "#00f",
|
||||
chroma.OperatorWord: "#00f",
|
||||
chroma.Name: "#000",
|
||||
chroma.LiteralNumber: "#3af",
|
||||
chroma.LiteralString: "#5a2",
|
||||
chroma.Error: "#F00",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
<style name="abap">
|
||||
<entry type="Error" style="#ff0000"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="#0000ff"/>
|
||||
<entry type="Name" style="#000000"/>
|
||||
<entry type="LiteralString" style="#55aa22"/>
|
||||
<entry type="LiteralNumber" style="#33aaff"/>
|
||||
<entry type="OperatorWord" style="#0000ff"/>
|
||||
<entry type="Comment" style="italic #888888"/>
|
||||
<entry type="CommentSpecial" style="#888888"/>
|
||||
</style>
|
||||
-25
@@ -1,25 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Algol style.
|
||||
var Algol = Register(chroma.MustNewStyle("algol", chroma.StyleEntries{
|
||||
chroma.Comment: "italic #888",
|
||||
chroma.CommentPreproc: "bold noitalic #888",
|
||||
chroma.CommentSpecial: "bold noitalic #888",
|
||||
chroma.Keyword: "underline bold",
|
||||
chroma.KeywordDeclaration: "italic",
|
||||
chroma.NameBuiltin: "bold italic",
|
||||
chroma.NameBuiltinPseudo: "bold italic",
|
||||
chroma.NameNamespace: "bold italic #666",
|
||||
chroma.NameClass: "bold italic #666",
|
||||
chroma.NameFunction: "bold italic #666",
|
||||
chroma.NameVariable: "bold italic #666",
|
||||
chroma.NameConstant: "bold italic #666",
|
||||
chroma.OperatorWord: "bold",
|
||||
chroma.LiteralString: "italic #666",
|
||||
chroma.Error: "border:#FF0000",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
<style name="algol">
|
||||
<entry type="Error" style="border:#ff0000"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold underline"/>
|
||||
<entry type="KeywordDeclaration" style="italic"/>
|
||||
<entry type="NameBuiltin" style="bold italic"/>
|
||||
<entry type="NameBuiltinPseudo" style="bold italic"/>
|
||||
<entry type="NameClass" style="bold italic #666666"/>
|
||||
<entry type="NameConstant" style="bold italic #666666"/>
|
||||
<entry type="NameFunction" style="bold italic #666666"/>
|
||||
<entry type="NameNamespace" style="bold italic #666666"/>
|
||||
<entry type="NameVariable" style="bold italic #666666"/>
|
||||
<entry type="LiteralString" style="italic #666666"/>
|
||||
<entry type="OperatorWord" style="bold"/>
|
||||
<entry type="Comment" style="italic #888888"/>
|
||||
<entry type="CommentSpecial" style="bold noitalic #888888"/>
|
||||
<entry type="CommentPreproc" style="bold noitalic #888888"/>
|
||||
</style>
|
||||
-25
@@ -1,25 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// AlgolNu style.
|
||||
var AlgolNu = Register(chroma.MustNewStyle("algol_nu", chroma.StyleEntries{
|
||||
chroma.Comment: "italic #888",
|
||||
chroma.CommentPreproc: "bold noitalic #888",
|
||||
chroma.CommentSpecial: "bold noitalic #888",
|
||||
chroma.Keyword: "bold",
|
||||
chroma.KeywordDeclaration: "italic",
|
||||
chroma.NameBuiltin: "bold italic",
|
||||
chroma.NameBuiltinPseudo: "bold italic",
|
||||
chroma.NameNamespace: "bold italic #666",
|
||||
chroma.NameClass: "bold italic #666",
|
||||
chroma.NameFunction: "bold italic #666",
|
||||
chroma.NameVariable: "bold italic #666",
|
||||
chroma.NameConstant: "bold italic #666",
|
||||
chroma.OperatorWord: "bold",
|
||||
chroma.LiteralString: "italic #666",
|
||||
chroma.Error: "border:#FF0000",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
<style name="algol_nu">
|
||||
<entry type="Error" style="border:#ff0000"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold"/>
|
||||
<entry type="KeywordDeclaration" style="italic"/>
|
||||
<entry type="NameBuiltin" style="bold italic"/>
|
||||
<entry type="NameBuiltinPseudo" style="bold italic"/>
|
||||
<entry type="NameClass" style="bold italic #666666"/>
|
||||
<entry type="NameConstant" style="bold italic #666666"/>
|
||||
<entry type="NameFunction" style="bold italic #666666"/>
|
||||
<entry type="NameNamespace" style="bold italic #666666"/>
|
||||
<entry type="NameVariable" style="bold italic #666666"/>
|
||||
<entry type="LiteralString" style="italic #666666"/>
|
||||
<entry type="OperatorWord" style="bold"/>
|
||||
<entry type="Comment" style="italic #888888"/>
|
||||
<entry type="CommentSpecial" style="bold noitalic #888888"/>
|
||||
<entry type="CommentPreproc" style="bold noitalic #888888"/>
|
||||
</style>
|
||||
+30
-2
@@ -1,16 +1,44 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"embed"
|
||||
"io/fs"
|
||||
"sort"
|
||||
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
//go:embed *.xml
|
||||
var embedded embed.FS
|
||||
|
||||
// Registry of Styles.
|
||||
var Registry = map[string]*chroma.Style{}
|
||||
var Registry = func() map[string]*chroma.Style {
|
||||
registry := map[string]*chroma.Style{}
|
||||
// Register all embedded styles.
|
||||
files, err := fs.ReadDir(embedded, ".")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
for _, file := range files {
|
||||
if file.IsDir() {
|
||||
continue
|
||||
}
|
||||
r, err := embedded.Open(file.Name())
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
style, err := chroma.NewXMLStyle(r)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
registry[style.Name] = style
|
||||
_ = r.Close()
|
||||
}
|
||||
return registry
|
||||
}()
|
||||
|
||||
// Fallback style. Reassign to change the default fallback style.
|
||||
var Fallback = SwapOff
|
||||
var Fallback = Registry["swapoff"]
|
||||
|
||||
// Register a chroma.Style.
|
||||
func Register(style *chroma.Style) *chroma.Style {
|
||||
|
||||
-25
@@ -1,25 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Arduino style.
|
||||
var Arduino = Register(chroma.MustNewStyle("arduino", chroma.StyleEntries{
|
||||
chroma.Error: "#a61717",
|
||||
chroma.Comment: "#95a5a6",
|
||||
chroma.CommentPreproc: "#728E00",
|
||||
chroma.Keyword: "#728E00",
|
||||
chroma.KeywordConstant: "#00979D",
|
||||
chroma.KeywordPseudo: "#00979D",
|
||||
chroma.KeywordReserved: "#00979D",
|
||||
chroma.KeywordType: "#00979D",
|
||||
chroma.Operator: "#728E00",
|
||||
chroma.Name: "#434f54",
|
||||
chroma.NameBuiltin: "#728E00",
|
||||
chroma.NameFunction: "#D35400",
|
||||
chroma.NameOther: "#728E00",
|
||||
chroma.LiteralNumber: "#8A7B52",
|
||||
chroma.LiteralString: "#7F8C8D",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
<style name="arduino">
|
||||
<entry type="Error" style="#a61717"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="#728e00"/>
|
||||
<entry type="KeywordConstant" style="#00979d"/>
|
||||
<entry type="KeywordPseudo" style="#00979d"/>
|
||||
<entry type="KeywordReserved" style="#00979d"/>
|
||||
<entry type="KeywordType" style="#00979d"/>
|
||||
<entry type="Name" style="#434f54"/>
|
||||
<entry type="NameBuiltin" style="#728e00"/>
|
||||
<entry type="NameFunction" style="#d35400"/>
|
||||
<entry type="NameOther" style="#728e00"/>
|
||||
<entry type="LiteralString" style="#7f8c8d"/>
|
||||
<entry type="LiteralNumber" style="#8a7b52"/>
|
||||
<entry type="Operator" style="#728e00"/>
|
||||
<entry type="Comment" style="#95a5a6"/>
|
||||
<entry type="CommentPreproc" style="#728e00"/>
|
||||
</style>
|
||||
-43
@@ -1,43 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Autumn style.
|
||||
var Autumn = Register(chroma.MustNewStyle("autumn", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "italic #aaaaaa",
|
||||
chroma.CommentPreproc: "noitalic #4c8317",
|
||||
chroma.CommentSpecial: "italic #0000aa",
|
||||
chroma.Keyword: "#0000aa",
|
||||
chroma.KeywordType: "#00aaaa",
|
||||
chroma.OperatorWord: "#0000aa",
|
||||
chroma.NameBuiltin: "#00aaaa",
|
||||
chroma.NameFunction: "#00aa00",
|
||||
chroma.NameClass: "underline #00aa00",
|
||||
chroma.NameNamespace: "underline #00aaaa",
|
||||
chroma.NameVariable: "#aa0000",
|
||||
chroma.NameConstant: "#aa0000",
|
||||
chroma.NameEntity: "bold #800",
|
||||
chroma.NameAttribute: "#1e90ff",
|
||||
chroma.NameTag: "bold #1e90ff",
|
||||
chroma.NameDecorator: "#888888",
|
||||
chroma.LiteralString: "#aa5500",
|
||||
chroma.LiteralStringSymbol: "#0000aa",
|
||||
chroma.LiteralStringRegex: "#009999",
|
||||
chroma.LiteralNumber: "#009999",
|
||||
chroma.GenericHeading: "bold #000080",
|
||||
chroma.GenericSubheading: "bold #800080",
|
||||
chroma.GenericDeleted: "#aa0000",
|
||||
chroma.GenericInserted: "#00aa00",
|
||||
chroma.GenericError: "#aa0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "#555555",
|
||||
chroma.GenericOutput: "#888888",
|
||||
chroma.GenericTraceback: "#aa0000",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "#F00 bg:#FAA",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
<style name="autumn">
|
||||
<entry type="Error" style="#ff0000 bg:#ffaaaa"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="#0000aa"/>
|
||||
<entry type="KeywordType" style="#00aaaa"/>
|
||||
<entry type="NameAttribute" style="#1e90ff"/>
|
||||
<entry type="NameBuiltin" style="#00aaaa"/>
|
||||
<entry type="NameClass" style="underline #00aa00"/>
|
||||
<entry type="NameConstant" style="#aa0000"/>
|
||||
<entry type="NameDecorator" style="#888888"/>
|
||||
<entry type="NameEntity" style="bold #880000"/>
|
||||
<entry type="NameFunction" style="#00aa00"/>
|
||||
<entry type="NameNamespace" style="underline #00aaaa"/>
|
||||
<entry type="NameTag" style="bold #1e90ff"/>
|
||||
<entry type="NameVariable" style="#aa0000"/>
|
||||
<entry type="LiteralString" style="#aa5500"/>
|
||||
<entry type="LiteralStringRegex" style="#009999"/>
|
||||
<entry type="LiteralStringSymbol" style="#0000aa"/>
|
||||
<entry type="LiteralNumber" style="#009999"/>
|
||||
<entry type="OperatorWord" style="#0000aa"/>
|
||||
<entry type="Comment" style="italic #aaaaaa"/>
|
||||
<entry type="CommentSpecial" style="italic #0000aa"/>
|
||||
<entry type="CommentPreproc" style="noitalic #4c8317"/>
|
||||
<entry type="GenericDeleted" style="#aa0000"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#aa0000"/>
|
||||
<entry type="GenericHeading" style="bold #000080"/>
|
||||
<entry type="GenericInserted" style="#00aa00"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="#555555"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #800080"/>
|
||||
<entry type="GenericTraceback" style="#aa0000"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
-81
@@ -1,81 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Average style.
|
||||
var Average = Register(chroma.MustNewStyle("average", chroma.StyleEntries{
|
||||
chroma.Comment: "#757575",
|
||||
chroma.CommentHashbang: "#757575",
|
||||
chroma.CommentMultiline: "#757575",
|
||||
chroma.CommentPreproc: "#757575",
|
||||
chroma.CommentSingle: "#757575",
|
||||
chroma.CommentSpecial: "#757575",
|
||||
chroma.Generic: "#757575",
|
||||
chroma.GenericDeleted: "#ec0000",
|
||||
chroma.GenericEmph: "#757575 underline",
|
||||
chroma.GenericError: "#ec0000",
|
||||
chroma.GenericHeading: "#757575 bold",
|
||||
chroma.GenericInserted: "#757575 bold",
|
||||
chroma.GenericOutput: "#757575",
|
||||
chroma.GenericPrompt: "#757575",
|
||||
chroma.GenericStrong: "#757575 italic",
|
||||
chroma.GenericSubheading: "#757575 bold",
|
||||
chroma.GenericTraceback: "#757575",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "#ec0000",
|
||||
chroma.Keyword: "#ec0000",
|
||||
chroma.KeywordConstant: "#ec0000",
|
||||
chroma.KeywordDeclaration: "#ec0000",
|
||||
chroma.KeywordNamespace: "#ec0000",
|
||||
chroma.KeywordPseudo: "#ec0000",
|
||||
chroma.KeywordReserved: "#ec0000",
|
||||
chroma.KeywordType: "#5f5fff",
|
||||
chroma.Literal: "#757575",
|
||||
chroma.LiteralDate: "#757575",
|
||||
chroma.Name: "#757575",
|
||||
chroma.NameAttribute: "#5f5fff",
|
||||
chroma.NameBuiltin: "#ec0000",
|
||||
chroma.NameBuiltinPseudo: "#757575",
|
||||
chroma.NameClass: "#5f5fff",
|
||||
chroma.NameConstant: "#008900",
|
||||
chroma.NameDecorator: "#008900",
|
||||
chroma.NameEntity: "#757575",
|
||||
chroma.NameException: "#757575",
|
||||
chroma.NameFunction: "#5f5fff",
|
||||
chroma.NameLabel: "#ec0000",
|
||||
chroma.NameNamespace: "#757575",
|
||||
chroma.NameOther: "#757575",
|
||||
chroma.NameTag: "#ec0000",
|
||||
chroma.NameVariable: "#ec0000",
|
||||
chroma.NameVariableClass: "#ec0000",
|
||||
chroma.NameVariableGlobal: "#ec0000",
|
||||
chroma.NameVariableInstance: "#ec0000",
|
||||
chroma.LiteralNumber: "#008900",
|
||||
chroma.LiteralNumberBin: "#008900",
|
||||
chroma.LiteralNumberFloat: "#008900",
|
||||
chroma.LiteralNumberHex: "#008900",
|
||||
chroma.LiteralNumberInteger: "#008900",
|
||||
chroma.LiteralNumberIntegerLong: "#008900",
|
||||
chroma.LiteralNumberOct: "#008900",
|
||||
chroma.Operator: "#ec0000",
|
||||
chroma.OperatorWord: "#ec0000",
|
||||
chroma.Other: "#757575",
|
||||
chroma.Punctuation: "#757575",
|
||||
chroma.LiteralString: "#008900",
|
||||
chroma.LiteralStringBacktick: "#008900",
|
||||
chroma.LiteralStringChar: "#008900",
|
||||
chroma.LiteralStringDoc: "#008900",
|
||||
chroma.LiteralStringDouble: "#008900",
|
||||
chroma.LiteralStringEscape: "#008900",
|
||||
chroma.LiteralStringHeredoc: "#008900",
|
||||
chroma.LiteralStringInterpol: "#008900",
|
||||
chroma.LiteralStringOther: "#008900",
|
||||
chroma.LiteralStringRegex: "#008900",
|
||||
chroma.LiteralStringSingle: "#008900",
|
||||
chroma.LiteralStringSymbol: "#008900",
|
||||
chroma.Text: "#757575",
|
||||
chroma.TextWhitespace: "#757575",
|
||||
chroma.Background: " bg:#000000",
|
||||
}))
|
||||
+74
@@ -0,0 +1,74 @@
|
||||
<style name="average">
|
||||
<entry type="Other" style="#757575"/>
|
||||
<entry type="Error" style="#ec0000"/>
|
||||
<entry type="Background" style="bg:#000000"/>
|
||||
<entry type="Keyword" style="#ec0000"/>
|
||||
<entry type="KeywordConstant" style="#ec0000"/>
|
||||
<entry type="KeywordDeclaration" style="#ec0000"/>
|
||||
<entry type="KeywordNamespace" style="#ec0000"/>
|
||||
<entry type="KeywordPseudo" style="#ec0000"/>
|
||||
<entry type="KeywordReserved" style="#ec0000"/>
|
||||
<entry type="KeywordType" style="#5f5fff"/>
|
||||
<entry type="Name" style="#757575"/>
|
||||
<entry type="NameAttribute" style="#5f5fff"/>
|
||||
<entry type="NameBuiltin" style="#ec0000"/>
|
||||
<entry type="NameBuiltinPseudo" style="#757575"/>
|
||||
<entry type="NameClass" style="#5f5fff"/>
|
||||
<entry type="NameConstant" style="#008900"/>
|
||||
<entry type="NameDecorator" style="#008900"/>
|
||||
<entry type="NameEntity" style="#757575"/>
|
||||
<entry type="NameException" style="#757575"/>
|
||||
<entry type="NameFunction" style="#5f5fff"/>
|
||||
<entry type="NameLabel" style="#ec0000"/>
|
||||
<entry type="NameNamespace" style="#757575"/>
|
||||
<entry type="NameOther" style="#757575"/>
|
||||
<entry type="NameTag" style="#ec0000"/>
|
||||
<entry type="NameVariable" style="#ec0000"/>
|
||||
<entry type="NameVariableClass" style="#ec0000"/>
|
||||
<entry type="NameVariableGlobal" style="#ec0000"/>
|
||||
<entry type="NameVariableInstance" style="#ec0000"/>
|
||||
<entry type="Literal" style="#757575"/>
|
||||
<entry type="LiteralDate" style="#757575"/>
|
||||
<entry type="LiteralString" style="#008900"/>
|
||||
<entry type="LiteralStringBacktick" style="#008900"/>
|
||||
<entry type="LiteralStringChar" style="#008900"/>
|
||||
<entry type="LiteralStringDoc" style="#008900"/>
|
||||
<entry type="LiteralStringDouble" style="#008900"/>
|
||||
<entry type="LiteralStringEscape" style="#008900"/>
|
||||
<entry type="LiteralStringHeredoc" style="#008900"/>
|
||||
<entry type="LiteralStringInterpol" style="#008900"/>
|
||||
<entry type="LiteralStringOther" style="#008900"/>
|
||||
<entry type="LiteralStringRegex" style="#008900"/>
|
||||
<entry type="LiteralStringSingle" style="#008900"/>
|
||||
<entry type="LiteralStringSymbol" style="#008900"/>
|
||||
<entry type="LiteralNumber" style="#008900"/>
|
||||
<entry type="LiteralNumberBin" style="#008900"/>
|
||||
<entry type="LiteralNumberFloat" style="#008900"/>
|
||||
<entry type="LiteralNumberHex" style="#008900"/>
|
||||
<entry type="LiteralNumberInteger" style="#008900"/>
|
||||
<entry type="LiteralNumberIntegerLong" style="#008900"/>
|
||||
<entry type="LiteralNumberOct" style="#008900"/>
|
||||
<entry type="Operator" style="#ec0000"/>
|
||||
<entry type="OperatorWord" style="#ec0000"/>
|
||||
<entry type="Punctuation" style="#757575"/>
|
||||
<entry type="Comment" style="#757575"/>
|
||||
<entry type="CommentHashbang" style="#757575"/>
|
||||
<entry type="CommentMultiline" style="#757575"/>
|
||||
<entry type="CommentSingle" style="#757575"/>
|
||||
<entry type="CommentSpecial" style="#757575"/>
|
||||
<entry type="CommentPreproc" style="#757575"/>
|
||||
<entry type="Generic" style="#757575"/>
|
||||
<entry type="GenericDeleted" style="#ec0000"/>
|
||||
<entry type="GenericEmph" style="underline #757575"/>
|
||||
<entry type="GenericError" style="#ec0000"/>
|
||||
<entry type="GenericHeading" style="bold #757575"/>
|
||||
<entry type="GenericInserted" style="bold #757575"/>
|
||||
<entry type="GenericOutput" style="#757575"/>
|
||||
<entry type="GenericPrompt" style="#757575"/>
|
||||
<entry type="GenericStrong" style="italic #757575"/>
|
||||
<entry type="GenericSubheading" style="bold #757575"/>
|
||||
<entry type="GenericTraceback" style="#757575"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="Text" style="#757575"/>
|
||||
<entry type="TextWhitespace" style="#757575"/>
|
||||
</style>
|
||||
-81
@@ -1,81 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Base16Snazzy style
|
||||
var Base16Snazzy = Register(chroma.MustNewStyle("base16-snazzy", chroma.StyleEntries{
|
||||
chroma.Comment: "#78787e",
|
||||
chroma.CommentHashbang: "#78787e",
|
||||
chroma.CommentMultiline: "#78787e",
|
||||
chroma.CommentPreproc: "#78787e",
|
||||
chroma.CommentSingle: "#78787e",
|
||||
chroma.CommentSpecial: "#78787e",
|
||||
chroma.Generic: "#e2e4e5",
|
||||
chroma.GenericDeleted: "#ff5c57",
|
||||
chroma.GenericEmph: "#e2e4e5 underline",
|
||||
chroma.GenericError: "#ff5c57",
|
||||
chroma.GenericHeading: "#e2e4e5 bold",
|
||||
chroma.GenericInserted: "#e2e4e5 bold",
|
||||
chroma.GenericOutput: "#43454f",
|
||||
chroma.GenericPrompt: "#e2e4e5",
|
||||
chroma.GenericStrong: "#e2e4e5 italic",
|
||||
chroma.GenericSubheading: "#e2e4e5 bold",
|
||||
chroma.GenericTraceback: "#e2e4e5",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "#ff5c57",
|
||||
chroma.Keyword: "#ff6ac1",
|
||||
chroma.KeywordConstant: "#ff6ac1",
|
||||
chroma.KeywordDeclaration: "#ff5c57",
|
||||
chroma.KeywordNamespace: "#ff6ac1",
|
||||
chroma.KeywordPseudo: "#ff6ac1",
|
||||
chroma.KeywordReserved: "#ff6ac1",
|
||||
chroma.KeywordType: "#9aedfe",
|
||||
chroma.Literal: "#e2e4e5",
|
||||
chroma.LiteralDate: "#e2e4e5",
|
||||
chroma.Name: "#e2e4e5",
|
||||
chroma.NameAttribute: "#57c7ff",
|
||||
chroma.NameBuiltin: "#ff5c57",
|
||||
chroma.NameBuiltinPseudo: "#e2e4e5",
|
||||
chroma.NameClass: "#f3f99d",
|
||||
chroma.NameConstant: "#ff9f43",
|
||||
chroma.NameDecorator: "#ff9f43",
|
||||
chroma.NameEntity: "#e2e4e5",
|
||||
chroma.NameException: "#e2e4e5",
|
||||
chroma.NameFunction: "#57c7ff",
|
||||
chroma.NameLabel: "#ff5c57",
|
||||
chroma.NameNamespace: "#e2e4e5",
|
||||
chroma.NameOther: "#e2e4e5",
|
||||
chroma.NameTag: "#ff6ac1",
|
||||
chroma.NameVariable: "#ff5c57",
|
||||
chroma.NameVariableClass: "#ff5c57",
|
||||
chroma.NameVariableGlobal: "#ff5c57",
|
||||
chroma.NameVariableInstance: "#ff5c57",
|
||||
chroma.LiteralNumber: "#ff9f43",
|
||||
chroma.LiteralNumberBin: "#ff9f43",
|
||||
chroma.LiteralNumberFloat: "#ff9f43",
|
||||
chroma.LiteralNumberHex: "#ff9f43",
|
||||
chroma.LiteralNumberInteger: "#ff9f43",
|
||||
chroma.LiteralNumberIntegerLong: "#ff9f43",
|
||||
chroma.LiteralNumberOct: "#ff9f43",
|
||||
chroma.Operator: "#ff6ac1",
|
||||
chroma.OperatorWord: "#ff6ac1",
|
||||
chroma.Other: "#e2e4e5",
|
||||
chroma.Punctuation: "#e2e4e5",
|
||||
chroma.LiteralString: "#5af78e",
|
||||
chroma.LiteralStringBacktick: "#5af78e",
|
||||
chroma.LiteralStringChar: "#5af78e",
|
||||
chroma.LiteralStringDoc: "#5af78e",
|
||||
chroma.LiteralStringDouble: "#5af78e",
|
||||
chroma.LiteralStringEscape: "#5af78e",
|
||||
chroma.LiteralStringHeredoc: "#5af78e",
|
||||
chroma.LiteralStringInterpol: "#5af78e",
|
||||
chroma.LiteralStringOther: "#5af78e",
|
||||
chroma.LiteralStringRegex: "#5af78e",
|
||||
chroma.LiteralStringSingle: "#5af78e",
|
||||
chroma.LiteralStringSymbol: "#5af78e",
|
||||
chroma.Text: "#e2e4e5",
|
||||
chroma.TextWhitespace: "#e2e4e5",
|
||||
chroma.Background: " bg:#282a36",
|
||||
}))
|
||||
+74
@@ -0,0 +1,74 @@
|
||||
<style name="base16-snazzy">
|
||||
<entry type="Other" style="#e2e4e5"/>
|
||||
<entry type="Error" style="#ff5c57"/>
|
||||
<entry type="Background" style="bg:#282a36"/>
|
||||
<entry type="Keyword" style="#ff6ac1"/>
|
||||
<entry type="KeywordConstant" style="#ff6ac1"/>
|
||||
<entry type="KeywordDeclaration" style="#ff5c57"/>
|
||||
<entry type="KeywordNamespace" style="#ff6ac1"/>
|
||||
<entry type="KeywordPseudo" style="#ff6ac1"/>
|
||||
<entry type="KeywordReserved" style="#ff6ac1"/>
|
||||
<entry type="KeywordType" style="#9aedfe"/>
|
||||
<entry type="Name" style="#e2e4e5"/>
|
||||
<entry type="NameAttribute" style="#57c7ff"/>
|
||||
<entry type="NameBuiltin" style="#ff5c57"/>
|
||||
<entry type="NameBuiltinPseudo" style="#e2e4e5"/>
|
||||
<entry type="NameClass" style="#f3f99d"/>
|
||||
<entry type="NameConstant" style="#ff9f43"/>
|
||||
<entry type="NameDecorator" style="#ff9f43"/>
|
||||
<entry type="NameEntity" style="#e2e4e5"/>
|
||||
<entry type="NameException" style="#e2e4e5"/>
|
||||
<entry type="NameFunction" style="#57c7ff"/>
|
||||
<entry type="NameLabel" style="#ff5c57"/>
|
||||
<entry type="NameNamespace" style="#e2e4e5"/>
|
||||
<entry type="NameOther" style="#e2e4e5"/>
|
||||
<entry type="NameTag" style="#ff6ac1"/>
|
||||
<entry type="NameVariable" style="#ff5c57"/>
|
||||
<entry type="NameVariableClass" style="#ff5c57"/>
|
||||
<entry type="NameVariableGlobal" style="#ff5c57"/>
|
||||
<entry type="NameVariableInstance" style="#ff5c57"/>
|
||||
<entry type="Literal" style="#e2e4e5"/>
|
||||
<entry type="LiteralDate" style="#e2e4e5"/>
|
||||
<entry type="LiteralString" style="#5af78e"/>
|
||||
<entry type="LiteralStringBacktick" style="#5af78e"/>
|
||||
<entry type="LiteralStringChar" style="#5af78e"/>
|
||||
<entry type="LiteralStringDoc" style="#5af78e"/>
|
||||
<entry type="LiteralStringDouble" style="#5af78e"/>
|
||||
<entry type="LiteralStringEscape" style="#5af78e"/>
|
||||
<entry type="LiteralStringHeredoc" style="#5af78e"/>
|
||||
<entry type="LiteralStringInterpol" style="#5af78e"/>
|
||||
<entry type="LiteralStringOther" style="#5af78e"/>
|
||||
<entry type="LiteralStringRegex" style="#5af78e"/>
|
||||
<entry type="LiteralStringSingle" style="#5af78e"/>
|
||||
<entry type="LiteralStringSymbol" style="#5af78e"/>
|
||||
<entry type="LiteralNumber" style="#ff9f43"/>
|
||||
<entry type="LiteralNumberBin" style="#ff9f43"/>
|
||||
<entry type="LiteralNumberFloat" style="#ff9f43"/>
|
||||
<entry type="LiteralNumberHex" style="#ff9f43"/>
|
||||
<entry type="LiteralNumberInteger" style="#ff9f43"/>
|
||||
<entry type="LiteralNumberIntegerLong" style="#ff9f43"/>
|
||||
<entry type="LiteralNumberOct" style="#ff9f43"/>
|
||||
<entry type="Operator" style="#ff6ac1"/>
|
||||
<entry type="OperatorWord" style="#ff6ac1"/>
|
||||
<entry type="Punctuation" style="#e2e4e5"/>
|
||||
<entry type="Comment" style="#78787e"/>
|
||||
<entry type="CommentHashbang" style="#78787e"/>
|
||||
<entry type="CommentMultiline" style="#78787e"/>
|
||||
<entry type="CommentSingle" style="#78787e"/>
|
||||
<entry type="CommentSpecial" style="#78787e"/>
|
||||
<entry type="CommentPreproc" style="#78787e"/>
|
||||
<entry type="Generic" style="#e2e4e5"/>
|
||||
<entry type="GenericDeleted" style="#ff5c57"/>
|
||||
<entry type="GenericEmph" style="underline #e2e4e5"/>
|
||||
<entry type="GenericError" style="#ff5c57"/>
|
||||
<entry type="GenericHeading" style="bold #e2e4e5"/>
|
||||
<entry type="GenericInserted" style="bold #e2e4e5"/>
|
||||
<entry type="GenericOutput" style="#43454f"/>
|
||||
<entry type="GenericPrompt" style="#e2e4e5"/>
|
||||
<entry type="GenericStrong" style="italic #e2e4e5"/>
|
||||
<entry type="GenericSubheading" style="bold #e2e4e5"/>
|
||||
<entry type="GenericTraceback" style="#e2e4e5"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="Text" style="#e2e4e5"/>
|
||||
<entry type="TextWhitespace" style="#e2e4e5"/>
|
||||
</style>
|
||||
-33
@@ -1,33 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Borland style.
|
||||
var Borland = Register(chroma.MustNewStyle("borland", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "italic #008800",
|
||||
chroma.CommentPreproc: "noitalic #008080",
|
||||
chroma.CommentSpecial: "noitalic bold",
|
||||
chroma.LiteralString: "#0000FF",
|
||||
chroma.LiteralStringChar: "#800080",
|
||||
chroma.LiteralNumber: "#0000FF",
|
||||
chroma.Keyword: "bold #000080",
|
||||
chroma.OperatorWord: "bold",
|
||||
chroma.NameTag: "bold #000080",
|
||||
chroma.NameAttribute: "#FF0000",
|
||||
chroma.GenericHeading: "#999999",
|
||||
chroma.GenericSubheading: "#aaaaaa",
|
||||
chroma.GenericDeleted: "bg:#ffdddd #000000",
|
||||
chroma.GenericInserted: "bg:#ddffdd #000000",
|
||||
chroma.GenericError: "#aa0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "#555555",
|
||||
chroma.GenericOutput: "#888888",
|
||||
chroma.GenericTraceback: "#aa0000",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "bg:#e3d2d2 #a61717",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
<style name="borland">
|
||||
<entry type="Error" style="#a61717 bg:#e3d2d2"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold #000080"/>
|
||||
<entry type="NameAttribute" style="#ff0000"/>
|
||||
<entry type="NameTag" style="bold #000080"/>
|
||||
<entry type="LiteralString" style="#0000ff"/>
|
||||
<entry type="LiteralStringChar" style="#800080"/>
|
||||
<entry type="LiteralNumber" style="#0000ff"/>
|
||||
<entry type="OperatorWord" style="bold"/>
|
||||
<entry type="Comment" style="italic #008800"/>
|
||||
<entry type="CommentSpecial" style="bold noitalic"/>
|
||||
<entry type="CommentPreproc" style="noitalic #008080"/>
|
||||
<entry type="GenericDeleted" style="#000000 bg:#ffdddd"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#aa0000"/>
|
||||
<entry type="GenericHeading" style="#999999"/>
|
||||
<entry type="GenericInserted" style="#000000 bg:#ddffdd"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="#555555"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#aaaaaa"/>
|
||||
<entry type="GenericTraceback" style="#aa0000"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
-30
@@ -1,30 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// BlackWhite style.
|
||||
var BlackWhite = Register(chroma.MustNewStyle("bw", chroma.StyleEntries{
|
||||
chroma.Comment: "italic",
|
||||
chroma.CommentPreproc: "noitalic",
|
||||
chroma.Keyword: "bold",
|
||||
chroma.KeywordPseudo: "nobold",
|
||||
chroma.KeywordType: "nobold",
|
||||
chroma.OperatorWord: "bold",
|
||||
chroma.NameClass: "bold",
|
||||
chroma.NameNamespace: "bold",
|
||||
chroma.NameException: "bold",
|
||||
chroma.NameEntity: "bold",
|
||||
chroma.NameTag: "bold",
|
||||
chroma.LiteralString: "italic",
|
||||
chroma.LiteralStringInterpol: "bold",
|
||||
chroma.LiteralStringEscape: "bold",
|
||||
chroma.GenericHeading: "bold",
|
||||
chroma.GenericSubheading: "bold",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold",
|
||||
chroma.Error: "border:#FF0000",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
<style name="bw">
|
||||
<entry type="Error" style="border:#ff0000"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold"/>
|
||||
<entry type="KeywordPseudo" style="nobold"/>
|
||||
<entry type="KeywordType" style="nobold"/>
|
||||
<entry type="NameClass" style="bold"/>
|
||||
<entry type="NameEntity" style="bold"/>
|
||||
<entry type="NameException" style="bold"/>
|
||||
<entry type="NameNamespace" style="bold"/>
|
||||
<entry type="NameTag" style="bold"/>
|
||||
<entry type="LiteralString" style="italic"/>
|
||||
<entry type="LiteralStringEscape" style="bold"/>
|
||||
<entry type="LiteralStringInterpol" style="bold"/>
|
||||
<entry type="OperatorWord" style="bold"/>
|
||||
<entry type="Comment" style="italic"/>
|
||||
<entry type="CommentPreproc" style="noitalic"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericHeading" style="bold"/>
|
||||
<entry type="GenericPrompt" style="bold"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold"/>
|
||||
</style>
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
<style name="catppuccin-frappe">
|
||||
<entry type="Error" style="#e78284"/>
|
||||
<entry type="Background" style="#ef9f76 bg:#303446"/>
|
||||
<entry type="Keyword" style="#ca9ee6"/>
|
||||
<entry type="KeywordConstant" style="italic #ca9ee6"/>
|
||||
<entry type="KeywordPseudo" style="bold #ca9ee6"/>
|
||||
<entry type="KeywordType" style="#e5c890"/>
|
||||
<entry type="Name" style="#babbf1"/>
|
||||
<entry type="NameAttribute" style="#e5c890"/>
|
||||
<entry type="NameBuiltin" style="italic #c6d0f5"/>
|
||||
<entry type="NameClass" style="#e5c890"/>
|
||||
<entry type="NameConstant" style="#e5c890"/>
|
||||
<entry type="NameDecorator" style="#f4b8e4"/>
|
||||
<entry type="NameEntity" style="#f4b8e4"/>
|
||||
<entry type="NameException" style="#ea999c"/>
|
||||
<entry type="NameFunction" style="#99d1db"/>
|
||||
<entry type="NameLabel" style="#e5c890"/>
|
||||
<entry type="NameNamespace" style="#e5c890"/>
|
||||
<entry type="NameOther" style="#ef9f76"/>
|
||||
<entry type="NameTag" style="#ca9ee6"/>
|
||||
<entry type="NameVariable" style="#ef9f76"/>
|
||||
<entry type="LiteralString" style="#a6d189"/>
|
||||
<entry type="LiteralStringDoc" style="#a6d189"/>
|
||||
<entry type="LiteralStringEscape" style="#8caaee"/>
|
||||
<entry type="LiteralStringInterpol" style="#a6d189"/>
|
||||
<entry type="LiteralStringOther" style="#a6d189"/>
|
||||
<entry type="LiteralStringRegex" style="#8caaee"/>
|
||||
<entry type="LiteralStringSymbol" style="#a6d189"/>
|
||||
<entry type="LiteralNumber" style="#ef9f76"/>
|
||||
<entry type="Operator" style="#99d1db"/>
|
||||
<entry type="OperatorWord" style="bold #99d1db"/>
|
||||
<entry type="Punctuation" style="#c6d0f5"/>
|
||||
<entry type="Comment" style="italic #626880"/>
|
||||
<entry type="CommentPreproc" style="#8caaee"/>
|
||||
<entry type="GenericDeleted" style="#ea999c"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ea999c"/>
|
||||
<entry type="GenericHeading" style="bold #99d1db"/>
|
||||
<entry type="GenericInserted" style="#a6d189"/>
|
||||
<entry type="GenericOutput" style="#ef9f76"/>
|
||||
<entry type="GenericPrompt" style="bold #737994"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #99d1db"/>
|
||||
<entry type="GenericTraceback" style="#ea999c"/>
|
||||
<entry type="TextWhitespace" style="#414559"/>
|
||||
</style>
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
<style name="catppuccin-latte">
|
||||
<entry type="Error" style="#d20f39"/>
|
||||
<entry type="Background" style="#fe640b bg:#eff1f5"/>
|
||||
<entry type="Keyword" style="#8839ef"/>
|
||||
<entry type="KeywordConstant" style="italic #8839ef"/>
|
||||
<entry type="KeywordPseudo" style="bold #8839ef"/>
|
||||
<entry type="KeywordType" style="#df8e1d"/>
|
||||
<entry type="Name" style="#7287fd"/>
|
||||
<entry type="NameAttribute" style="#df8e1d"/>
|
||||
<entry type="NameBuiltin" style="italic #fe640b"/>
|
||||
<entry type="NameClass" style="#df8e1d"/>
|
||||
<entry type="NameConstant" style="#df8e1d"/>
|
||||
<entry type="NameDecorator" style="#ea76cb"/>
|
||||
<entry type="NameEntity" style="#ea76cb"/>
|
||||
<entry type="NameException" style="#e64553"/>
|
||||
<entry type="NameFunction" style="#04a5e5"/>
|
||||
<entry type="NameLabel" style="#df8e1d"/>
|
||||
<entry type="NameNamespace" style="#df8e1d"/>
|
||||
<entry type="NameOther" style="#fe640b"/>
|
||||
<entry type="NameTag" style="#8839ef"/>
|
||||
<entry type="NameVariable" style="#fe640b"/>
|
||||
<entry type="LiteralString" style="#40a02b"/>
|
||||
<entry type="LiteralStringDoc" style="#40a02b"/>
|
||||
<entry type="LiteralStringEscape" style="#1e66f5"/>
|
||||
<entry type="LiteralStringInterpol" style="#40a02b"/>
|
||||
<entry type="LiteralStringOther" style="#40a02b"/>
|
||||
<entry type="LiteralStringRegex" style="#1e66f5"/>
|
||||
<entry type="LiteralStringSymbol" style="#40a02b"/>
|
||||
<entry type="LiteralNumber" style="#fe640b"/>
|
||||
<entry type="Operator" style="#04a5e5"/>
|
||||
<entry type="OperatorWord" style="bold #04a5e5"/>
|
||||
<entry type="Punctuation" style="#4c4f69"/>
|
||||
<entry type="Comment" style="italic #acb0be"/>
|
||||
<entry type="CommentPreproc" style="#1e66f5"/>
|
||||
<entry type="GenericDeleted" style="#e64553"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#e64553"/>
|
||||
<entry type="GenericHeading" style="bold #04a5e5"/>
|
||||
<entry type="GenericInserted" style="#40a02b"/>
|
||||
<entry type="GenericOutput" style="#fe640b"/>
|
||||
<entry type="GenericPrompt" style="bold #9ca0b0"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #04a5e5"/>
|
||||
<entry type="GenericTraceback" style="#e64553"/>
|
||||
<entry type="TextWhitespace" style="#ccd0da"/>
|
||||
</style>
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
<style name="catppuccin-macchiato">
|
||||
<entry type="Error" style="#ed8796"/>
|
||||
<entry type="Background" style="#f5a97f bg:#24273a"/>
|
||||
<entry type="Keyword" style="#c6a0f6"/>
|
||||
<entry type="KeywordConstant" style="italic #c6a0f6"/>
|
||||
<entry type="KeywordPseudo" style="bold #c6a0f6"/>
|
||||
<entry type="KeywordType" style="#eed49f"/>
|
||||
<entry type="Name" style="#b7bdf8"/>
|
||||
<entry type="NameAttribute" style="#eed49f"/>
|
||||
<entry type="NameBuiltin" style="italic #f5a97f"/>
|
||||
<entry type="NameClass" style="#eed49f"/>
|
||||
<entry type="NameConstant" style="#eed49f"/>
|
||||
<entry type="NameDecorator" style="#f5bde6"/>
|
||||
<entry type="NameEntity" style="#f5bde6"/>
|
||||
<entry type="NameException" style="#ee99a0"/>
|
||||
<entry type="NameFunction" style="#91d7e3"/>
|
||||
<entry type="NameLabel" style="#eed49f"/>
|
||||
<entry type="NameNamespace" style="#eed49f"/>
|
||||
<entry type="NameOther" style="#f5a97f"/>
|
||||
<entry type="NameTag" style="#c6a0f6"/>
|
||||
<entry type="NameVariable" style="#f5a97f"/>
|
||||
<entry type="LiteralString" style="#a6da95"/>
|
||||
<entry type="LiteralStringDoc" style="#a6da95"/>
|
||||
<entry type="LiteralStringEscape" style="#8aadf4"/>
|
||||
<entry type="LiteralStringInterpol" style="#a6da95"/>
|
||||
<entry type="LiteralStringOther" style="#a6da95"/>
|
||||
<entry type="LiteralStringRegex" style="#8aadf4"/>
|
||||
<entry type="LiteralStringSymbol" style="#a6da95"/>
|
||||
<entry type="LiteralNumber" style="#f5a97f"/>
|
||||
<entry type="Operator" style="#91d7e3"/>
|
||||
<entry type="OperatorWord" style="bold #91d7e3"/>
|
||||
<entry type="Punctuation" style="#cad3f5"/>
|
||||
<entry type="Comment" style="italic #5b6078"/>
|
||||
<entry type="CommentPreproc" style="#8aadf4"/>
|
||||
<entry type="GenericDeleted" style="#ee99a0"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ee99a0"/>
|
||||
<entry type="GenericHeading" style="bold #91d7e3"/>
|
||||
<entry type="GenericInserted" style="#a6da95"/>
|
||||
<entry type="GenericOutput" style="#f5a97f"/>
|
||||
<entry type="GenericPrompt" style="bold #6e738d"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #91d7e3"/>
|
||||
<entry type="GenericTraceback" style="#ee99a0"/>
|
||||
<entry type="TextWhitespace" style="#363a4f"/>
|
||||
</style>
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
<style name="catppuccin-mocha">
|
||||
<entry type="Error" style="#f38ba8"/>
|
||||
<entry type="Background" style="#fab387 bg:#1e1e2e"/>
|
||||
<entry type="Keyword" style="#cba6f7"/>
|
||||
<entry type="KeywordConstant" style="italic #cba6f7"/>
|
||||
<entry type="KeywordPseudo" style="bold #cba6f7"/>
|
||||
<entry type="KeywordType" style="#f9e2af"/>
|
||||
<entry type="Name" style="#b4befe"/>
|
||||
<entry type="NameAttribute" style="#f9e2af"/>
|
||||
<entry type="NameBuiltin" style="italic #fab387"/>
|
||||
<entry type="NameClass" style="#f9e2af"/>
|
||||
<entry type="NameConstant" style="#f9e2af"/>
|
||||
<entry type="NameDecorator" style="#f5c2e7"/>
|
||||
<entry type="NameEntity" style="#f5c2e7"/>
|
||||
<entry type="NameException" style="#eba0ac"/>
|
||||
<entry type="NameFunction" style="#89dceb"/>
|
||||
<entry type="NameLabel" style="#f9e2af"/>
|
||||
<entry type="NameNamespace" style="#f9e2af"/>
|
||||
<entry type="NameOther" style="#fab387"/>
|
||||
<entry type="NameTag" style="#cba6f7"/>
|
||||
<entry type="NameVariable" style="#fab387"/>
|
||||
<entry type="LiteralString" style="#a6e3a1"/>
|
||||
<entry type="LiteralStringDoc" style="#a6e3a1"/>
|
||||
<entry type="LiteralStringEscape" style="#89b4fa"/>
|
||||
<entry type="LiteralStringInterpol" style="#a6e3a1"/>
|
||||
<entry type="LiteralStringOther" style="#a6e3a1"/>
|
||||
<entry type="LiteralStringRegex" style="#89b4fa"/>
|
||||
<entry type="LiteralStringSymbol" style="#a6e3a1"/>
|
||||
<entry type="LiteralNumber" style="#fab387"/>
|
||||
<entry type="Operator" style="#89dceb"/>
|
||||
<entry type="OperatorWord" style="bold #89dceb"/>
|
||||
<entry type="Punctuation" style="#cdd6f4"/>
|
||||
<entry type="Comment" style="italic #585b70"/>
|
||||
<entry type="CommentPreproc" style="#89b4fa"/>
|
||||
<entry type="GenericDeleted" style="#eba0ac"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#eba0ac"/>
|
||||
<entry type="GenericHeading" style="bold #89dceb"/>
|
||||
<entry type="GenericInserted" style="#a6e3a1"/>
|
||||
<entry type="GenericOutput" style="#fab387"/>
|
||||
<entry type="GenericPrompt" style="bold #6c7086"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #89dceb"/>
|
||||
<entry type="GenericTraceback" style="#eba0ac"/>
|
||||
<entry type="TextWhitespace" style="#313244"/>
|
||||
</style>
|
||||
-59
@@ -1,59 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Colorful style.
|
||||
var Colorful = Register(chroma.MustNewStyle("colorful", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "#888",
|
||||
chroma.CommentPreproc: "#579",
|
||||
chroma.CommentSpecial: "bold #cc0000",
|
||||
chroma.Keyword: "bold #080",
|
||||
chroma.KeywordPseudo: "#038",
|
||||
chroma.KeywordType: "#339",
|
||||
chroma.Operator: "#333",
|
||||
chroma.OperatorWord: "bold #000",
|
||||
chroma.NameBuiltin: "#007020",
|
||||
chroma.NameFunction: "bold #06B",
|
||||
chroma.NameClass: "bold #B06",
|
||||
chroma.NameNamespace: "bold #0e84b5",
|
||||
chroma.NameException: "bold #F00",
|
||||
chroma.NameVariable: "#963",
|
||||
chroma.NameVariableInstance: "#33B",
|
||||
chroma.NameVariableClass: "#369",
|
||||
chroma.NameVariableGlobal: "bold #d70",
|
||||
chroma.NameConstant: "bold #036",
|
||||
chroma.NameLabel: "bold #970",
|
||||
chroma.NameEntity: "bold #800",
|
||||
chroma.NameAttribute: "#00C",
|
||||
chroma.NameTag: "#070",
|
||||
chroma.NameDecorator: "bold #555",
|
||||
chroma.LiteralString: "bg:#fff0f0",
|
||||
chroma.LiteralStringChar: "#04D bg:",
|
||||
chroma.LiteralStringDoc: "#D42 bg:",
|
||||
chroma.LiteralStringInterpol: "bg:#eee",
|
||||
chroma.LiteralStringEscape: "bold #666",
|
||||
chroma.LiteralStringRegex: "bg:#fff0ff #000",
|
||||
chroma.LiteralStringSymbol: "#A60 bg:",
|
||||
chroma.LiteralStringOther: "#D20",
|
||||
chroma.LiteralNumber: "bold #60E",
|
||||
chroma.LiteralNumberInteger: "bold #00D",
|
||||
chroma.LiteralNumberFloat: "bold #60E",
|
||||
chroma.LiteralNumberHex: "bold #058",
|
||||
chroma.LiteralNumberOct: "bold #40E",
|
||||
chroma.GenericHeading: "bold #000080",
|
||||
chroma.GenericSubheading: "bold #800080",
|
||||
chroma.GenericDeleted: "#A00000",
|
||||
chroma.GenericInserted: "#00A000",
|
||||
chroma.GenericError: "#FF0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold #c65d09",
|
||||
chroma.GenericOutput: "#888",
|
||||
chroma.GenericTraceback: "#04D",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "#F00 bg:#FAA",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+52
@@ -0,0 +1,52 @@
|
||||
<style name="colorful">
|
||||
<entry type="Error" style="#ff0000 bg:#ffaaaa"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold #008800"/>
|
||||
<entry type="KeywordPseudo" style="#003388"/>
|
||||
<entry type="KeywordType" style="#333399"/>
|
||||
<entry type="NameAttribute" style="#0000cc"/>
|
||||
<entry type="NameBuiltin" style="#007020"/>
|
||||
<entry type="NameClass" style="bold #bb0066"/>
|
||||
<entry type="NameConstant" style="bold #003366"/>
|
||||
<entry type="NameDecorator" style="bold #555555"/>
|
||||
<entry type="NameEntity" style="bold #880000"/>
|
||||
<entry type="NameException" style="bold #ff0000"/>
|
||||
<entry type="NameFunction" style="bold #0066bb"/>
|
||||
<entry type="NameLabel" style="bold #997700"/>
|
||||
<entry type="NameNamespace" style="bold #0e84b5"/>
|
||||
<entry type="NameTag" style="#007700"/>
|
||||
<entry type="NameVariable" style="#996633"/>
|
||||
<entry type="NameVariableClass" style="#336699"/>
|
||||
<entry type="NameVariableGlobal" style="bold #dd7700"/>
|
||||
<entry type="NameVariableInstance" style="#3333bb"/>
|
||||
<entry type="LiteralString" style="bg:#fff0f0"/>
|
||||
<entry type="LiteralStringChar" style="#0044dd"/>
|
||||
<entry type="LiteralStringDoc" style="#dd4422"/>
|
||||
<entry type="LiteralStringEscape" style="bold #666666"/>
|
||||
<entry type="LiteralStringInterpol" style="bg:#eeeeee"/>
|
||||
<entry type="LiteralStringOther" style="#dd2200"/>
|
||||
<entry type="LiteralStringRegex" style="#000000 bg:#fff0ff"/>
|
||||
<entry type="LiteralStringSymbol" style="#aa6600"/>
|
||||
<entry type="LiteralNumber" style="bold #6600ee"/>
|
||||
<entry type="LiteralNumberFloat" style="bold #6600ee"/>
|
||||
<entry type="LiteralNumberHex" style="bold #005588"/>
|
||||
<entry type="LiteralNumberInteger" style="bold #0000dd"/>
|
||||
<entry type="LiteralNumberOct" style="bold #4400ee"/>
|
||||
<entry type="Operator" style="#333333"/>
|
||||
<entry type="OperatorWord" style="bold #000000"/>
|
||||
<entry type="Comment" style="#888888"/>
|
||||
<entry type="CommentSpecial" style="bold #cc0000"/>
|
||||
<entry type="CommentPreproc" style="#557799"/>
|
||||
<entry type="GenericDeleted" style="#a00000"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ff0000"/>
|
||||
<entry type="GenericHeading" style="bold #000080"/>
|
||||
<entry type="GenericInserted" style="#00a000"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="bold #c65d09"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #800080"/>
|
||||
<entry type="GenericTraceback" style="#0044dd"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
+66
@@ -0,0 +1,66 @@
|
||||
package styles
|
||||
|
||||
// Present for backwards compatibility.
|
||||
//
|
||||
// Deprecated: use styles.Get(name) instead.
|
||||
var (
|
||||
Abap = Registry["abap"]
|
||||
Algol = Registry["algol"]
|
||||
AlgolNu = Registry["algol_nu"]
|
||||
Arduino = Registry["arduino"]
|
||||
Autumn = Registry["autumn"]
|
||||
Average = Registry["average"]
|
||||
Base16Snazzy = Registry["base16-snazzy"]
|
||||
Borland = Registry["borland"]
|
||||
BlackWhite = Registry["bw"]
|
||||
CatppuccinFrappe = Registry["catppuccin-frappe"]
|
||||
CatppuccinLatte = Registry["catppuccin-latte"]
|
||||
CatppuccinMacchiato = Registry["catppuccin-macchiato"]
|
||||
CatppuccinMocha = Registry["catppuccin-mocha"]
|
||||
Colorful = Registry["colorful"]
|
||||
DoomOne = Registry["doom-one"]
|
||||
DoomOne2 = Registry["doom-one2"]
|
||||
Dracula = Registry["dracula"]
|
||||
Emacs = Registry["emacs"]
|
||||
Friendly = Registry["friendly"]
|
||||
Fruity = Registry["fruity"]
|
||||
GitHubDark = Registry["github-dark"]
|
||||
GitHub = Registry["github"]
|
||||
GruvboxLight = Registry["gruvbox-light"]
|
||||
Gruvbox = Registry["gruvbox"]
|
||||
HrDark = Registry["hrdark"]
|
||||
HrHighContrast = Registry["hr_high_contrast"]
|
||||
Igor = Registry["igor"]
|
||||
Lovelace = Registry["lovelace"]
|
||||
Manni = Registry["manni"]
|
||||
ModusOperandi = Registry["modus-operandi"]
|
||||
ModusVivendi = Registry["modus-vivendi"]
|
||||
Monokai = Registry["monokai"]
|
||||
MonokaiLight = Registry["monokailight"]
|
||||
Murphy = Registry["murphy"]
|
||||
Native = Registry["native"]
|
||||
Nord = Registry["nord"]
|
||||
OnesEnterprise = Registry["onesenterprise"]
|
||||
ParaisoDark = Registry["paraiso-dark"]
|
||||
ParaisoLight = Registry["paraiso-light"]
|
||||
Pastie = Registry["pastie"]
|
||||
Perldoc = Registry["perldoc"]
|
||||
Pygments = Registry["pygments"]
|
||||
RainbowDash = Registry["rainbow_dash"]
|
||||
RosePineDawn = Registry["rose-pine-dawn"]
|
||||
RosePineMoon = Registry["rose-pine-moon"]
|
||||
RosePine = Registry["rose-pine"]
|
||||
Rrt = Registry["rrt"]
|
||||
SolarizedDark = Registry["solarized-dark"]
|
||||
SolarizedDark256 = Registry["solarized-dark256"]
|
||||
SolarizedLight = Registry["solarized-light"]
|
||||
SwapOff = Registry["swapoff"]
|
||||
Tango = Registry["tango"]
|
||||
Trac = Registry["trac"]
|
||||
Vim = Registry["vim"]
|
||||
VisualStudio = Registry["vs"]
|
||||
Vulcan = Registry["vulcan"]
|
||||
WitchHazel = Registry["witchhazel"]
|
||||
XcodeDark = Registry["xcode-dark"]
|
||||
Xcode = Registry["xcode"]
|
||||
)
|
||||
-58
@@ -1,58 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Doom One style. Inspired by Atom One and Doom Emacs's Atom One theme
|
||||
var DoomOne = Register(chroma.MustNewStyle("doom-one", chroma.StyleEntries{
|
||||
chroma.Text: "#b0c4de",
|
||||
chroma.Error: "#b0c4de",
|
||||
chroma.Comment: "italic #8a93a5",
|
||||
chroma.CommentHashbang: "bold",
|
||||
chroma.Keyword: "#c678dd",
|
||||
chroma.KeywordType: "#ef8383",
|
||||
chroma.KeywordConstant: "bold #b756ff",
|
||||
chroma.Operator: "#c7bf54",
|
||||
chroma.OperatorWord: "bold #b756ff",
|
||||
chroma.Punctuation: "#b0c4de",
|
||||
chroma.Name: "#c1abea",
|
||||
chroma.NameAttribute: "#b3d23c",
|
||||
chroma.NameBuiltin: "#ef8383",
|
||||
chroma.NameClass: "#76a9f9",
|
||||
chroma.NameConstant: "bold #b756ff",
|
||||
chroma.NameDecorator: "#e5c07b",
|
||||
chroma.NameEntity: "#bda26f",
|
||||
chroma.NameException: "bold #fd7474",
|
||||
chroma.NameFunction: "#00b1f7",
|
||||
chroma.NameProperty: "#cebc3a",
|
||||
chroma.NameLabel: "#f5a40d",
|
||||
chroma.NameNamespace: "#76a9f9",
|
||||
chroma.NameTag: "#e06c75",
|
||||
chroma.NameVariable: "#DCAEEA",
|
||||
chroma.NameVariableGlobal: "bold #DCAEEA",
|
||||
chroma.NameVariableInstance: "#e06c75",
|
||||
chroma.Literal: "#98c379",
|
||||
chroma.Number: "#d19a66",
|
||||
chroma.String: "#98c379",
|
||||
chroma.StringDoc: "#7e97c3",
|
||||
chroma.StringDouble: "#63c381",
|
||||
chroma.StringEscape: "bold #d26464",
|
||||
chroma.StringHeredoc: "#98c379",
|
||||
chroma.StringInterpol: "#98c379",
|
||||
chroma.StringOther: "#70b33f",
|
||||
chroma.StringRegex: "#56b6c2",
|
||||
chroma.StringSingle: "#98c379",
|
||||
chroma.StringSymbol: "#56b6c2",
|
||||
chroma.Generic: "#b0c4de",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericHeading: "bold #a2cbff",
|
||||
chroma.GenericInserted: "#a6e22e",
|
||||
chroma.GenericOutput: "#a6e22e",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.GenericPrompt: "#a6e22e",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericSubheading: "#a2cbff",
|
||||
chroma.GenericTraceback: "#a2cbff",
|
||||
chroma.Background: "#b0c4de bg:#282c34",
|
||||
}))
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
<style name="doom-one">
|
||||
<entry type="Error" style="#b0c4de"/>
|
||||
<entry type="Background" style="#b0c4de bg:#282c34"/>
|
||||
<entry type="Keyword" style="#c678dd"/>
|
||||
<entry type="KeywordConstant" style="bold #b756ff"/>
|
||||
<entry type="KeywordType" style="#ef8383"/>
|
||||
<entry type="Name" style="#c1abea"/>
|
||||
<entry type="NameAttribute" style="#b3d23c"/>
|
||||
<entry type="NameBuiltin" style="#ef8383"/>
|
||||
<entry type="NameClass" style="#76a9f9"/>
|
||||
<entry type="NameConstant" style="bold #b756ff"/>
|
||||
<entry type="NameDecorator" style="#e5c07b"/>
|
||||
<entry type="NameEntity" style="#bda26f"/>
|
||||
<entry type="NameException" style="bold #fd7474"/>
|
||||
<entry type="NameFunction" style="#00b1f7"/>
|
||||
<entry type="NameLabel" style="#f5a40d"/>
|
||||
<entry type="NameNamespace" style="#76a9f9"/>
|
||||
<entry type="NameProperty" style="#cebc3a"/>
|
||||
<entry type="NameTag" style="#e06c75"/>
|
||||
<entry type="NameVariable" style="#dcaeea"/>
|
||||
<entry type="NameVariableGlobal" style="bold #dcaeea"/>
|
||||
<entry type="NameVariableInstance" style="#e06c75"/>
|
||||
<entry type="Literal" style="#98c379"/>
|
||||
<entry type="LiteralString" style="#98c379"/>
|
||||
<entry type="LiteralStringDoc" style="#7e97c3"/>
|
||||
<entry type="LiteralStringDouble" style="#63c381"/>
|
||||
<entry type="LiteralStringEscape" style="bold #d26464"/>
|
||||
<entry type="LiteralStringHeredoc" style="#98c379"/>
|
||||
<entry type="LiteralStringInterpol" style="#98c379"/>
|
||||
<entry type="LiteralStringOther" style="#70b33f"/>
|
||||
<entry type="LiteralStringRegex" style="#56b6c2"/>
|
||||
<entry type="LiteralStringSingle" style="#98c379"/>
|
||||
<entry type="LiteralStringSymbol" style="#56b6c2"/>
|
||||
<entry type="LiteralNumber" style="#d19a66"/>
|
||||
<entry type="Operator" style="#c7bf54"/>
|
||||
<entry type="OperatorWord" style="bold #b756ff"/>
|
||||
<entry type="Punctuation" style="#b0c4de"/>
|
||||
<entry type="Comment" style="italic #8a93a5"/>
|
||||
<entry type="CommentHashbang" style="bold"/>
|
||||
<entry type="Generic" style="#b0c4de"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericHeading" style="bold #a2cbff"/>
|
||||
<entry type="GenericInserted" style="#a6e22e"/>
|
||||
<entry type="GenericOutput" style="#a6e22e"/>
|
||||
<entry type="GenericPrompt" style="#a6e22e"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#a2cbff"/>
|
||||
<entry type="GenericTraceback" style="#a2cbff"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="Text" style="#b0c4de"/>
|
||||
</style>
|
||||
-71
@@ -1,71 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Doom One 2 style. Inspired by Atom One and Doom Emacs's Atom One theme
|
||||
var DoomOne2 = Register(chroma.MustNewStyle("doom-one2", chroma.StyleEntries{
|
||||
chroma.Text: "#b0c4de",
|
||||
chroma.Error: "#b0c4de",
|
||||
chroma.Comment: "italic #8a93a5",
|
||||
chroma.CommentHashbang: "bold",
|
||||
chroma.Keyword: "#76a9f9",
|
||||
chroma.KeywordConstant: "#e5c07b",
|
||||
chroma.KeywordType: "#e5c07b",
|
||||
chroma.Operator: "#54b1c7",
|
||||
chroma.OperatorWord: "bold #b756ff",
|
||||
chroma.Punctuation: "#abb2bf",
|
||||
chroma.Name: "#aa89ea",
|
||||
chroma.NameAttribute: "#cebc3a",
|
||||
chroma.NameBuiltin: "#e5c07b",
|
||||
chroma.NameClass: "#ca72ff",
|
||||
chroma.NameConstant: "bold",
|
||||
chroma.NameDecorator: "#e5c07b",
|
||||
chroma.NameEntity: "#bda26f",
|
||||
chroma.NameException: "bold #fd7474",
|
||||
chroma.NameFunction: "#00b1f7",
|
||||
chroma.NameProperty: "#cebc3a",
|
||||
chroma.NameLabel: "#f5a40d",
|
||||
chroma.NameNamespace: "#ca72ff",
|
||||
chroma.NameTag: "#76a9f9",
|
||||
chroma.NameVariable: "#DCAEEA",
|
||||
chroma.NameVariableClass: "#DCAEEA",
|
||||
chroma.NameVariableGlobal: "bold #DCAEEA",
|
||||
chroma.NameVariableInstance: "#e06c75",
|
||||
chroma.NameVariableMagic: "#DCAEEA",
|
||||
chroma.Literal: "#98c379",
|
||||
chroma.LiteralDate: "#98c379",
|
||||
chroma.Number: "#d19a66",
|
||||
chroma.NumberBin: "#d19a66",
|
||||
chroma.NumberFloat: "#d19a66",
|
||||
chroma.NumberHex: "#d19a66",
|
||||
chroma.NumberInteger: "#d19a66",
|
||||
chroma.NumberIntegerLong: "#d19a66",
|
||||
chroma.NumberOct: "#d19a66",
|
||||
chroma.String: "#98c379",
|
||||
chroma.StringAffix: "#98c379",
|
||||
chroma.StringBacktick: "#98c379",
|
||||
chroma.StringDelimiter: "#98c379",
|
||||
chroma.StringDoc: "#7e97c3",
|
||||
chroma.StringDouble: "#63c381",
|
||||
chroma.StringEscape: "bold #d26464",
|
||||
chroma.StringHeredoc: "#98c379",
|
||||
chroma.StringInterpol: "#98c379",
|
||||
chroma.StringOther: "#70b33f",
|
||||
chroma.StringRegex: "#56b6c2",
|
||||
chroma.StringSingle: "#98c379",
|
||||
chroma.StringSymbol: "#56b6c2",
|
||||
chroma.Generic: "#b0c4de",
|
||||
chroma.GenericDeleted: "#b0c4de",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericHeading: "bold #a2cbff",
|
||||
chroma.GenericInserted: "#a6e22e",
|
||||
chroma.GenericOutput: "#a6e22e",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.GenericPrompt: "#a6e22e",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericSubheading: "#a2cbff",
|
||||
chroma.GenericTraceback: "#a2cbff",
|
||||
chroma.Background: "#b0c4de bg:#282c34",
|
||||
}))
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
<style name="doom-one2">
|
||||
<entry type="Error" style="#b0c4de"/>
|
||||
<entry type="Background" style="#b0c4de bg:#282c34"/>
|
||||
<entry type="Keyword" style="#76a9f9"/>
|
||||
<entry type="KeywordConstant" style="#e5c07b"/>
|
||||
<entry type="KeywordType" style="#e5c07b"/>
|
||||
<entry type="Name" style="#aa89ea"/>
|
||||
<entry type="NameAttribute" style="#cebc3a"/>
|
||||
<entry type="NameBuiltin" style="#e5c07b"/>
|
||||
<entry type="NameClass" style="#ca72ff"/>
|
||||
<entry type="NameConstant" style="bold"/>
|
||||
<entry type="NameDecorator" style="#e5c07b"/>
|
||||
<entry type="NameEntity" style="#bda26f"/>
|
||||
<entry type="NameException" style="bold #fd7474"/>
|
||||
<entry type="NameFunction" style="#00b1f7"/>
|
||||
<entry type="NameLabel" style="#f5a40d"/>
|
||||
<entry type="NameNamespace" style="#ca72ff"/>
|
||||
<entry type="NameProperty" style="#cebc3a"/>
|
||||
<entry type="NameTag" style="#76a9f9"/>
|
||||
<entry type="NameVariable" style="#dcaeea"/>
|
||||
<entry type="NameVariableClass" style="#dcaeea"/>
|
||||
<entry type="NameVariableGlobal" style="bold #dcaeea"/>
|
||||
<entry type="NameVariableInstance" style="#e06c75"/>
|
||||
<entry type="NameVariableMagic" style="#dcaeea"/>
|
||||
<entry type="Literal" style="#98c379"/>
|
||||
<entry type="LiteralDate" style="#98c379"/>
|
||||
<entry type="LiteralString" style="#98c379"/>
|
||||
<entry type="LiteralStringAffix" style="#98c379"/>
|
||||
<entry type="LiteralStringBacktick" style="#98c379"/>
|
||||
<entry type="LiteralStringDelimiter" style="#98c379"/>
|
||||
<entry type="LiteralStringDoc" style="#7e97c3"/>
|
||||
<entry type="LiteralStringDouble" style="#63c381"/>
|
||||
<entry type="LiteralStringEscape" style="bold #d26464"/>
|
||||
<entry type="LiteralStringHeredoc" style="#98c379"/>
|
||||
<entry type="LiteralStringInterpol" style="#98c379"/>
|
||||
<entry type="LiteralStringOther" style="#70b33f"/>
|
||||
<entry type="LiteralStringRegex" style="#56b6c2"/>
|
||||
<entry type="LiteralStringSingle" style="#98c379"/>
|
||||
<entry type="LiteralStringSymbol" style="#56b6c2"/>
|
||||
<entry type="LiteralNumber" style="#d19a66"/>
|
||||
<entry type="LiteralNumberBin" style="#d19a66"/>
|
||||
<entry type="LiteralNumberFloat" style="#d19a66"/>
|
||||
<entry type="LiteralNumberHex" style="#d19a66"/>
|
||||
<entry type="LiteralNumberInteger" style="#d19a66"/>
|
||||
<entry type="LiteralNumberIntegerLong" style="#d19a66"/>
|
||||
<entry type="LiteralNumberOct" style="#d19a66"/>
|
||||
<entry type="Operator" style="#54b1c7"/>
|
||||
<entry type="OperatorWord" style="bold #b756ff"/>
|
||||
<entry type="Punctuation" style="#abb2bf"/>
|
||||
<entry type="Comment" style="italic #8a93a5"/>
|
||||
<entry type="CommentHashbang" style="bold"/>
|
||||
<entry type="Generic" style="#b0c4de"/>
|
||||
<entry type="GenericDeleted" style="#b0c4de"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericHeading" style="bold #a2cbff"/>
|
||||
<entry type="GenericInserted" style="#a6e22e"/>
|
||||
<entry type="GenericOutput" style="#a6e22e"/>
|
||||
<entry type="GenericPrompt" style="#a6e22e"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#a2cbff"/>
|
||||
<entry type="GenericTraceback" style="#a2cbff"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="Text" style="#b0c4de"/>
|
||||
</style>
|
||||
-81
@@ -1,81 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Dracula Style
|
||||
var Dracula = Register(chroma.MustNewStyle("dracula", chroma.StyleEntries{
|
||||
chroma.Comment: "#6272a4",
|
||||
chroma.CommentHashbang: "#6272a4",
|
||||
chroma.CommentMultiline: "#6272a4",
|
||||
chroma.CommentPreproc: "#ff79c6",
|
||||
chroma.CommentSingle: "#6272a4",
|
||||
chroma.CommentSpecial: "#6272a4",
|
||||
chroma.Generic: "#f8f8f2",
|
||||
chroma.GenericDeleted: "#ff5555",
|
||||
chroma.GenericEmph: "#f8f8f2 underline",
|
||||
chroma.GenericError: "#f8f8f2",
|
||||
chroma.GenericHeading: "#f8f8f2 bold",
|
||||
chroma.GenericInserted: "#50fa7b bold",
|
||||
chroma.GenericOutput: "#44475a",
|
||||
chroma.GenericPrompt: "#f8f8f2",
|
||||
chroma.GenericStrong: "#f8f8f2",
|
||||
chroma.GenericSubheading: "#f8f8f2 bold",
|
||||
chroma.GenericTraceback: "#f8f8f2",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "#f8f8f2",
|
||||
chroma.Keyword: "#ff79c6",
|
||||
chroma.KeywordConstant: "#ff79c6",
|
||||
chroma.KeywordDeclaration: "#8be9fd italic",
|
||||
chroma.KeywordNamespace: "#ff79c6",
|
||||
chroma.KeywordPseudo: "#ff79c6",
|
||||
chroma.KeywordReserved: "#ff79c6",
|
||||
chroma.KeywordType: "#8be9fd",
|
||||
chroma.Literal: "#f8f8f2",
|
||||
chroma.LiteralDate: "#f8f8f2",
|
||||
chroma.Name: "#f8f8f2",
|
||||
chroma.NameAttribute: "#50fa7b",
|
||||
chroma.NameBuiltin: "#8be9fd italic",
|
||||
chroma.NameBuiltinPseudo: "#f8f8f2",
|
||||
chroma.NameClass: "#50fa7b",
|
||||
chroma.NameConstant: "#f8f8f2",
|
||||
chroma.NameDecorator: "#f8f8f2",
|
||||
chroma.NameEntity: "#f8f8f2",
|
||||
chroma.NameException: "#f8f8f2",
|
||||
chroma.NameFunction: "#50fa7b",
|
||||
chroma.NameLabel: "#8be9fd italic",
|
||||
chroma.NameNamespace: "#f8f8f2",
|
||||
chroma.NameOther: "#f8f8f2",
|
||||
chroma.NameTag: "#ff79c6",
|
||||
chroma.NameVariable: "#8be9fd italic",
|
||||
chroma.NameVariableClass: "#8be9fd italic",
|
||||
chroma.NameVariableGlobal: "#8be9fd italic",
|
||||
chroma.NameVariableInstance: "#8be9fd italic",
|
||||
chroma.LiteralNumber: "#bd93f9",
|
||||
chroma.LiteralNumberBin: "#bd93f9",
|
||||
chroma.LiteralNumberFloat: "#bd93f9",
|
||||
chroma.LiteralNumberHex: "#bd93f9",
|
||||
chroma.LiteralNumberInteger: "#bd93f9",
|
||||
chroma.LiteralNumberIntegerLong: "#bd93f9",
|
||||
chroma.LiteralNumberOct: "#bd93f9",
|
||||
chroma.Operator: "#ff79c6",
|
||||
chroma.OperatorWord: "#ff79c6",
|
||||
chroma.Other: "#f8f8f2",
|
||||
chroma.Punctuation: "#f8f8f2",
|
||||
chroma.LiteralString: "#f1fa8c",
|
||||
chroma.LiteralStringBacktick: "#f1fa8c",
|
||||
chroma.LiteralStringChar: "#f1fa8c",
|
||||
chroma.LiteralStringDoc: "#f1fa8c",
|
||||
chroma.LiteralStringDouble: "#f1fa8c",
|
||||
chroma.LiteralStringEscape: "#f1fa8c",
|
||||
chroma.LiteralStringHeredoc: "#f1fa8c",
|
||||
chroma.LiteralStringInterpol: "#f1fa8c",
|
||||
chroma.LiteralStringOther: "#f1fa8c",
|
||||
chroma.LiteralStringRegex: "#f1fa8c",
|
||||
chroma.LiteralStringSingle: "#f1fa8c",
|
||||
chroma.LiteralStringSymbol: "#f1fa8c",
|
||||
chroma.Text: "#f8f8f2",
|
||||
chroma.TextWhitespace: "#f8f8f2",
|
||||
chroma.Background: " bg:#282a36",
|
||||
}))
|
||||
+74
@@ -0,0 +1,74 @@
|
||||
<style name="dracula">
|
||||
<entry type="Other" style="#f8f8f2"/>
|
||||
<entry type="Error" style="#f8f8f2"/>
|
||||
<entry type="Background" style="bg:#282a36"/>
|
||||
<entry type="Keyword" style="#ff79c6"/>
|
||||
<entry type="KeywordConstant" style="#ff79c6"/>
|
||||
<entry type="KeywordDeclaration" style="italic #8be9fd"/>
|
||||
<entry type="KeywordNamespace" style="#ff79c6"/>
|
||||
<entry type="KeywordPseudo" style="#ff79c6"/>
|
||||
<entry type="KeywordReserved" style="#ff79c6"/>
|
||||
<entry type="KeywordType" style="#8be9fd"/>
|
||||
<entry type="Name" style="#f8f8f2"/>
|
||||
<entry type="NameAttribute" style="#50fa7b"/>
|
||||
<entry type="NameBuiltin" style="italic #8be9fd"/>
|
||||
<entry type="NameBuiltinPseudo" style="#f8f8f2"/>
|
||||
<entry type="NameClass" style="#50fa7b"/>
|
||||
<entry type="NameConstant" style="#f8f8f2"/>
|
||||
<entry type="NameDecorator" style="#f8f8f2"/>
|
||||
<entry type="NameEntity" style="#f8f8f2"/>
|
||||
<entry type="NameException" style="#f8f8f2"/>
|
||||
<entry type="NameFunction" style="#50fa7b"/>
|
||||
<entry type="NameLabel" style="italic #8be9fd"/>
|
||||
<entry type="NameNamespace" style="#f8f8f2"/>
|
||||
<entry type="NameOther" style="#f8f8f2"/>
|
||||
<entry type="NameTag" style="#ff79c6"/>
|
||||
<entry type="NameVariable" style="italic #8be9fd"/>
|
||||
<entry type="NameVariableClass" style="italic #8be9fd"/>
|
||||
<entry type="NameVariableGlobal" style="italic #8be9fd"/>
|
||||
<entry type="NameVariableInstance" style="italic #8be9fd"/>
|
||||
<entry type="Literal" style="#f8f8f2"/>
|
||||
<entry type="LiteralDate" style="#f8f8f2"/>
|
||||
<entry type="LiteralString" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringBacktick" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringChar" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringDoc" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringDouble" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringEscape" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringHeredoc" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringInterpol" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringOther" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringRegex" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringSingle" style="#f1fa8c"/>
|
||||
<entry type="LiteralStringSymbol" style="#f1fa8c"/>
|
||||
<entry type="LiteralNumber" style="#bd93f9"/>
|
||||
<entry type="LiteralNumberBin" style="#bd93f9"/>
|
||||
<entry type="LiteralNumberFloat" style="#bd93f9"/>
|
||||
<entry type="LiteralNumberHex" style="#bd93f9"/>
|
||||
<entry type="LiteralNumberInteger" style="#bd93f9"/>
|
||||
<entry type="LiteralNumberIntegerLong" style="#bd93f9"/>
|
||||
<entry type="LiteralNumberOct" style="#bd93f9"/>
|
||||
<entry type="Operator" style="#ff79c6"/>
|
||||
<entry type="OperatorWord" style="#ff79c6"/>
|
||||
<entry type="Punctuation" style="#f8f8f2"/>
|
||||
<entry type="Comment" style="#6272a4"/>
|
||||
<entry type="CommentHashbang" style="#6272a4"/>
|
||||
<entry type="CommentMultiline" style="#6272a4"/>
|
||||
<entry type="CommentSingle" style="#6272a4"/>
|
||||
<entry type="CommentSpecial" style="#6272a4"/>
|
||||
<entry type="CommentPreproc" style="#ff79c6"/>
|
||||
<entry type="Generic" style="#f8f8f2"/>
|
||||
<entry type="GenericDeleted" style="#ff5555"/>
|
||||
<entry type="GenericEmph" style="underline #f8f8f2"/>
|
||||
<entry type="GenericError" style="#f8f8f2"/>
|
||||
<entry type="GenericHeading" style="bold #f8f8f2"/>
|
||||
<entry type="GenericInserted" style="bold #50fa7b"/>
|
||||
<entry type="GenericOutput" style="#44475a"/>
|
||||
<entry type="GenericPrompt" style="#f8f8f2"/>
|
||||
<entry type="GenericStrong" style="#f8f8f2"/>
|
||||
<entry type="GenericSubheading" style="bold #f8f8f2"/>
|
||||
<entry type="GenericTraceback" style="#f8f8f2"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="Text" style="#f8f8f2"/>
|
||||
<entry type="TextWhitespace" style="#f8f8f2"/>
|
||||
</style>
|
||||
-51
@@ -1,51 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Emacs style.
|
||||
var Emacs = Register(chroma.MustNewStyle("emacs", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "italic #008800",
|
||||
chroma.CommentPreproc: "noitalic",
|
||||
chroma.CommentSpecial: "noitalic bold",
|
||||
chroma.Keyword: "bold #AA22FF",
|
||||
chroma.KeywordPseudo: "nobold",
|
||||
chroma.KeywordType: "bold #00BB00",
|
||||
chroma.Operator: "#666666",
|
||||
chroma.OperatorWord: "bold #AA22FF",
|
||||
chroma.NameBuiltin: "#AA22FF",
|
||||
chroma.NameFunction: "#00A000",
|
||||
chroma.NameClass: "#0000FF",
|
||||
chroma.NameNamespace: "bold #0000FF",
|
||||
chroma.NameException: "bold #D2413A",
|
||||
chroma.NameVariable: "#B8860B",
|
||||
chroma.NameConstant: "#880000",
|
||||
chroma.NameLabel: "#A0A000",
|
||||
chroma.NameEntity: "bold #999999",
|
||||
chroma.NameAttribute: "#BB4444",
|
||||
chroma.NameTag: "bold #008000",
|
||||
chroma.NameDecorator: "#AA22FF",
|
||||
chroma.LiteralString: "#BB4444",
|
||||
chroma.LiteralStringDoc: "italic",
|
||||
chroma.LiteralStringInterpol: "bold #BB6688",
|
||||
chroma.LiteralStringEscape: "bold #BB6622",
|
||||
chroma.LiteralStringRegex: "#BB6688",
|
||||
chroma.LiteralStringSymbol: "#B8860B",
|
||||
chroma.LiteralStringOther: "#008000",
|
||||
chroma.LiteralNumber: "#666666",
|
||||
chroma.GenericHeading: "bold #000080",
|
||||
chroma.GenericSubheading: "bold #800080",
|
||||
chroma.GenericDeleted: "#A00000",
|
||||
chroma.GenericInserted: "#00A000",
|
||||
chroma.GenericError: "#FF0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold #000080",
|
||||
chroma.GenericOutput: "#888",
|
||||
chroma.GenericTraceback: "#04D",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "border:#FF0000",
|
||||
chroma.Background: " bg:#f8f8f8",
|
||||
}))
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
<style name="emacs">
|
||||
<entry type="Error" style="border:#ff0000"/>
|
||||
<entry type="Background" style="bg:#f8f8f8"/>
|
||||
<entry type="Keyword" style="bold #aa22ff"/>
|
||||
<entry type="KeywordPseudo" style="nobold"/>
|
||||
<entry type="KeywordType" style="bold #00bb00"/>
|
||||
<entry type="NameAttribute" style="#bb4444"/>
|
||||
<entry type="NameBuiltin" style="#aa22ff"/>
|
||||
<entry type="NameClass" style="#0000ff"/>
|
||||
<entry type="NameConstant" style="#880000"/>
|
||||
<entry type="NameDecorator" style="#aa22ff"/>
|
||||
<entry type="NameEntity" style="bold #999999"/>
|
||||
<entry type="NameException" style="bold #d2413a"/>
|
||||
<entry type="NameFunction" style="#00a000"/>
|
||||
<entry type="NameLabel" style="#a0a000"/>
|
||||
<entry type="NameNamespace" style="bold #0000ff"/>
|
||||
<entry type="NameTag" style="bold #008000"/>
|
||||
<entry type="NameVariable" style="#b8860b"/>
|
||||
<entry type="LiteralString" style="#bb4444"/>
|
||||
<entry type="LiteralStringDoc" style="italic"/>
|
||||
<entry type="LiteralStringEscape" style="bold #bb6622"/>
|
||||
<entry type="LiteralStringInterpol" style="bold #bb6688"/>
|
||||
<entry type="LiteralStringOther" style="#008000"/>
|
||||
<entry type="LiteralStringRegex" style="#bb6688"/>
|
||||
<entry type="LiteralStringSymbol" style="#b8860b"/>
|
||||
<entry type="LiteralNumber" style="#666666"/>
|
||||
<entry type="Operator" style="#666666"/>
|
||||
<entry type="OperatorWord" style="bold #aa22ff"/>
|
||||
<entry type="Comment" style="italic #008800"/>
|
||||
<entry type="CommentSpecial" style="bold noitalic"/>
|
||||
<entry type="CommentPreproc" style="noitalic"/>
|
||||
<entry type="GenericDeleted" style="#a00000"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ff0000"/>
|
||||
<entry type="GenericHeading" style="bold #000080"/>
|
||||
<entry type="GenericInserted" style="#00a000"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="bold #000080"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #800080"/>
|
||||
<entry type="GenericTraceback" style="#0044dd"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
-51
@@ -1,51 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Friendly style.
|
||||
var Friendly = Register(chroma.MustNewStyle("friendly", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "italic #60a0b0",
|
||||
chroma.CommentPreproc: "noitalic #007020",
|
||||
chroma.CommentSpecial: "noitalic bg:#fff0f0",
|
||||
chroma.Keyword: "bold #007020",
|
||||
chroma.KeywordPseudo: "nobold",
|
||||
chroma.KeywordType: "nobold #902000",
|
||||
chroma.Operator: "#666666",
|
||||
chroma.OperatorWord: "bold #007020",
|
||||
chroma.NameBuiltin: "#007020",
|
||||
chroma.NameFunction: "#06287e",
|
||||
chroma.NameClass: "bold #0e84b5",
|
||||
chroma.NameNamespace: "bold #0e84b5",
|
||||
chroma.NameException: "#007020",
|
||||
chroma.NameVariable: "#bb60d5",
|
||||
chroma.NameConstant: "#60add5",
|
||||
chroma.NameLabel: "bold #002070",
|
||||
chroma.NameEntity: "bold #d55537",
|
||||
chroma.NameAttribute: "#4070a0",
|
||||
chroma.NameTag: "bold #062873",
|
||||
chroma.NameDecorator: "bold #555555",
|
||||
chroma.LiteralString: "#4070a0",
|
||||
chroma.LiteralStringDoc: "italic",
|
||||
chroma.LiteralStringInterpol: "#70a0d0",
|
||||
chroma.LiteralStringEscape: "bold #4070a0",
|
||||
chroma.LiteralStringRegex: "#235388",
|
||||
chroma.LiteralStringSymbol: "#517918",
|
||||
chroma.LiteralStringOther: "#c65d09",
|
||||
chroma.LiteralNumber: "#40a070",
|
||||
chroma.GenericHeading: "bold #000080",
|
||||
chroma.GenericSubheading: "bold #800080",
|
||||
chroma.GenericDeleted: "#A00000",
|
||||
chroma.GenericInserted: "#00A000",
|
||||
chroma.GenericError: "#FF0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold #c65d09",
|
||||
chroma.GenericOutput: "#888",
|
||||
chroma.GenericTraceback: "#04D",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "border:#FF0000",
|
||||
chroma.Background: " bg:#f0f0f0",
|
||||
}))
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
<style name="friendly">
|
||||
<entry type="Error" style="border:#ff0000"/>
|
||||
<entry type="Background" style="bg:#f0f0f0"/>
|
||||
<entry type="Keyword" style="bold #007020"/>
|
||||
<entry type="KeywordPseudo" style="nobold"/>
|
||||
<entry type="KeywordType" style="nobold #902000"/>
|
||||
<entry type="NameAttribute" style="#4070a0"/>
|
||||
<entry type="NameBuiltin" style="#007020"/>
|
||||
<entry type="NameClass" style="bold #0e84b5"/>
|
||||
<entry type="NameConstant" style="#60add5"/>
|
||||
<entry type="NameDecorator" style="bold #555555"/>
|
||||
<entry type="NameEntity" style="bold #d55537"/>
|
||||
<entry type="NameException" style="#007020"/>
|
||||
<entry type="NameFunction" style="#06287e"/>
|
||||
<entry type="NameLabel" style="bold #002070"/>
|
||||
<entry type="NameNamespace" style="bold #0e84b5"/>
|
||||
<entry type="NameTag" style="bold #062873"/>
|
||||
<entry type="NameVariable" style="#bb60d5"/>
|
||||
<entry type="LiteralString" style="#4070a0"/>
|
||||
<entry type="LiteralStringDoc" style="italic"/>
|
||||
<entry type="LiteralStringEscape" style="bold #4070a0"/>
|
||||
<entry type="LiteralStringInterpol" style="#70a0d0"/>
|
||||
<entry type="LiteralStringOther" style="#c65d09"/>
|
||||
<entry type="LiteralStringRegex" style="#235388"/>
|
||||
<entry type="LiteralStringSymbol" style="#517918"/>
|
||||
<entry type="LiteralNumber" style="#40a070"/>
|
||||
<entry type="Operator" style="#666666"/>
|
||||
<entry type="OperatorWord" style="bold #007020"/>
|
||||
<entry type="Comment" style="italic #60a0b0"/>
|
||||
<entry type="CommentSpecial" style="noitalic bg:#fff0f0"/>
|
||||
<entry type="CommentPreproc" style="noitalic #007020"/>
|
||||
<entry type="GenericDeleted" style="#a00000"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ff0000"/>
|
||||
<entry type="GenericHeading" style="bold #000080"/>
|
||||
<entry type="GenericInserted" style="#00a000"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="bold #c65d09"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #800080"/>
|
||||
<entry type="GenericTraceback" style="#0044dd"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
-26
@@ -1,26 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Fruity style.
|
||||
var Fruity = Register(chroma.MustNewStyle("fruity", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#888888",
|
||||
chroma.Background: "#ffffff bg:#111111",
|
||||
chroma.GenericOutput: "#444444 bg:#222222",
|
||||
chroma.Keyword: "#fb660a bold",
|
||||
chroma.KeywordPseudo: "nobold",
|
||||
chroma.LiteralNumber: "#0086f7 bold",
|
||||
chroma.NameTag: "#fb660a bold",
|
||||
chroma.NameVariable: "#fb660a",
|
||||
chroma.Comment: "#008800 bg:#0f140f italic",
|
||||
chroma.NameAttribute: "#ff0086 bold",
|
||||
chroma.LiteralString: "#0086d2",
|
||||
chroma.NameFunction: "#ff0086 bold",
|
||||
chroma.GenericHeading: "#ffffff bold",
|
||||
chroma.KeywordType: "#cdcaa9 bold",
|
||||
chroma.GenericSubheading: "#ffffff bold",
|
||||
chroma.NameConstant: "#0086d2",
|
||||
chroma.CommentPreproc: "#ff0007 bold",
|
||||
}))
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
<style name="fruity">
|
||||
<entry type="Background" style="#ffffff bg:#111111"/>
|
||||
<entry type="Keyword" style="bold #fb660a"/>
|
||||
<entry type="KeywordPseudo" style="nobold"/>
|
||||
<entry type="KeywordType" style="bold #cdcaa9"/>
|
||||
<entry type="NameAttribute" style="bold #ff0086"/>
|
||||
<entry type="NameConstant" style="#0086d2"/>
|
||||
<entry type="NameFunction" style="bold #ff0086"/>
|
||||
<entry type="NameTag" style="bold #fb660a"/>
|
||||
<entry type="NameVariable" style="#fb660a"/>
|
||||
<entry type="LiteralString" style="#0086d2"/>
|
||||
<entry type="LiteralNumber" style="bold #0086f7"/>
|
||||
<entry type="Comment" style="italic #008800 bg:#0f140f"/>
|
||||
<entry type="CommentPreproc" style="bold #ff0007"/>
|
||||
<entry type="GenericHeading" style="bold #ffffff"/>
|
||||
<entry type="GenericOutput" style="#444444 bg:#222222"/>
|
||||
<entry type="GenericSubheading" style="bold #ffffff"/>
|
||||
<entry type="TextWhitespace" style="#888888"/>
|
||||
</style>
|
||||
-86
@@ -1,86 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
var (
|
||||
// colors used from https://github.com/primer/primitives
|
||||
ghRed2 = "#ffa198"
|
||||
ghRed3 = "#ff7b72"
|
||||
ghRed9 = "#490202"
|
||||
ghOrange2 = "#ffa657"
|
||||
ghOrange3 = "#f0883e"
|
||||
ghGreen1 = "#7ee787"
|
||||
ghGreen2 = "#56d364"
|
||||
ghGreen7 = "#0f5323"
|
||||
ghBlue1 = "#a5d6ff"
|
||||
ghBlue2 = "#79c0ff"
|
||||
ghPurple2 = "#d2a8ff"
|
||||
ghGray3 = "#8b949e"
|
||||
ghGray4 = "#6e7681"
|
||||
ghFgSubtle = "#6e7681"
|
||||
ghFgDefault = "#c9d1d9"
|
||||
ghBgDefault = "#0d1117"
|
||||
ghDangerFg = "#f85149"
|
||||
)
|
||||
|
||||
// GitHub Dark style.
|
||||
var GitHubDark = Register(chroma.MustNewStyle("github-dark", chroma.StyleEntries{
|
||||
// Default Token Style
|
||||
chroma.Background: fmt.Sprintf("bg:%s %s", ghBgDefault, ghFgDefault),
|
||||
|
||||
chroma.LineNumbers: ghGray4,
|
||||
// has transparency in VS Code theme as `colors.codemirror.activelineBg`
|
||||
chroma.LineHighlight: ghGray4,
|
||||
|
||||
chroma.Error: ghDangerFg,
|
||||
|
||||
chroma.Keyword: ghRed3,
|
||||
chroma.KeywordConstant: ghBlue2,
|
||||
chroma.KeywordPseudo: ghBlue2,
|
||||
|
||||
chroma.Name: ghFgDefault,
|
||||
chroma.NameClass: "bold " + ghOrange3,
|
||||
chroma.NameConstant: "bold " + ghBlue2,
|
||||
chroma.NameDecorator: "bold " + ghPurple2,
|
||||
chroma.NameEntity: ghOrange2,
|
||||
chroma.NameException: "bold " + ghOrange3,
|
||||
chroma.NameFunction: "bold " + ghPurple2,
|
||||
chroma.NameLabel: "bold " + ghBlue2,
|
||||
chroma.NameNamespace: ghRed3,
|
||||
chroma.NameProperty: ghBlue2,
|
||||
chroma.NameTag: ghGreen1,
|
||||
chroma.NameVariable: ghBlue2,
|
||||
|
||||
chroma.Literal: ghBlue1,
|
||||
chroma.LiteralDate: ghBlue2,
|
||||
chroma.LiteralStringAffix: ghBlue2,
|
||||
chroma.LiteralStringDelimiter: ghBlue2,
|
||||
chroma.LiteralStringEscape: ghBlue2,
|
||||
chroma.LiteralStringHeredoc: ghBlue2,
|
||||
chroma.LiteralStringRegex: ghBlue2,
|
||||
|
||||
chroma.Operator: "bold " + ghRed3,
|
||||
|
||||
chroma.Comment: "italic " + ghGray3,
|
||||
chroma.CommentPreproc: "bold " + ghGray3,
|
||||
chroma.CommentSpecial: "bold italic " + ghGray3,
|
||||
|
||||
chroma.Generic: ghFgDefault,
|
||||
chroma.GenericDeleted: fmt.Sprintf("bg:%s %s", ghRed9, ghRed2),
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericError: ghRed2,
|
||||
chroma.GenericHeading: "bold " + ghBlue2,
|
||||
chroma.GenericInserted: fmt.Sprintf("bg:%s %s", ghGreen7, ghGreen2),
|
||||
chroma.GenericOutput: ghGray3,
|
||||
chroma.GenericPrompt: ghGray3,
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericSubheading: ghBlue2,
|
||||
chroma.GenericTraceback: ghRed3,
|
||||
chroma.GenericUnderline: "underline",
|
||||
|
||||
chroma.TextWhitespace: ghFgSubtle,
|
||||
}))
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
<style name="github-dark">
|
||||
<entry type="Error" style="#f85149"/>
|
||||
<entry type="LineHighlight" style="#6e7681"/>
|
||||
<entry type="LineNumbers" style="#6e7681"/>
|
||||
<entry type="Background" style="#c9d1d9 bg:#0d1117"/>
|
||||
<entry type="Keyword" style="#ff7b72"/>
|
||||
<entry type="KeywordConstant" style="#79c0ff"/>
|
||||
<entry type="KeywordPseudo" style="#79c0ff"/>
|
||||
<entry type="Name" style="#c9d1d9"/>
|
||||
<entry type="NameClass" style="bold #f0883e"/>
|
||||
<entry type="NameConstant" style="bold #79c0ff"/>
|
||||
<entry type="NameDecorator" style="bold #d2a8ff"/>
|
||||
<entry type="NameEntity" style="#ffa657"/>
|
||||
<entry type="NameException" style="bold #f0883e"/>
|
||||
<entry type="NameFunction" style="bold #d2a8ff"/>
|
||||
<entry type="NameLabel" style="bold #79c0ff"/>
|
||||
<entry type="NameNamespace" style="#ff7b72"/>
|
||||
<entry type="NameProperty" style="#79c0ff"/>
|
||||
<entry type="NameTag" style="#7ee787"/>
|
||||
<entry type="NameVariable" style="#79c0ff"/>
|
||||
<entry type="Literal" style="#a5d6ff"/>
|
||||
<entry type="LiteralDate" style="#79c0ff"/>
|
||||
<entry type="LiteralStringAffix" style="#79c0ff"/>
|
||||
<entry type="LiteralStringDelimiter" style="#79c0ff"/>
|
||||
<entry type="LiteralStringEscape" style="#79c0ff"/>
|
||||
<entry type="LiteralStringHeredoc" style="#79c0ff"/>
|
||||
<entry type="LiteralStringRegex" style="#79c0ff"/>
|
||||
<entry type="Operator" style="bold #ff7b72"/>
|
||||
<entry type="Comment" style="italic #8b949e"/>
|
||||
<entry type="CommentSpecial" style="bold italic #8b949e"/>
|
||||
<entry type="CommentPreproc" style="bold #8b949e"/>
|
||||
<entry type="Generic" style="#c9d1d9"/>
|
||||
<entry type="GenericDeleted" style="#ffa198 bg:#490202"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ffa198"/>
|
||||
<entry type="GenericHeading" style="bold #79c0ff"/>
|
||||
<entry type="GenericInserted" style="#56d364 bg:#0f5323"/>
|
||||
<entry type="GenericOutput" style="#8b949e"/>
|
||||
<entry type="GenericPrompt" style="#8b949e"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#79c0ff"/>
|
||||
<entry type="GenericTraceback" style="#ff7b72"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#6e7681"/>
|
||||
</style>
|
||||
-51
@@ -1,51 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// GitHub style.
|
||||
var GitHub = Register(chroma.MustNewStyle("github", chroma.StyleEntries{
|
||||
chroma.CommentMultiline: "italic #999988",
|
||||
chroma.CommentPreproc: "bold #999999",
|
||||
chroma.CommentSingle: "italic #999988",
|
||||
chroma.CommentSpecial: "bold italic #999999",
|
||||
chroma.Comment: "italic #999988",
|
||||
chroma.Error: "bg:#e3d2d2 #a61717",
|
||||
chroma.GenericDeleted: "bg:#ffdddd #000000",
|
||||
chroma.GenericEmph: "italic #000000",
|
||||
chroma.GenericError: "#aa0000",
|
||||
chroma.GenericHeading: "#999999",
|
||||
chroma.GenericInserted: "bg:#ddffdd #000000",
|
||||
chroma.GenericOutput: "#888888",
|
||||
chroma.GenericPrompt: "#555555",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericSubheading: "#aaaaaa",
|
||||
chroma.GenericTraceback: "#aa0000",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.KeywordType: "bold #445588",
|
||||
chroma.Keyword: "bold #000000",
|
||||
chroma.LiteralNumber: "#009999",
|
||||
chroma.LiteralStringRegex: "#009926",
|
||||
chroma.LiteralStringSymbol: "#990073",
|
||||
chroma.LiteralString: "#d14",
|
||||
chroma.NameAttribute: "#008080",
|
||||
chroma.NameBuiltinPseudo: "#999999",
|
||||
chroma.NameBuiltin: "#0086B3",
|
||||
chroma.NameClass: "bold #445588",
|
||||
chroma.NameConstant: "#008080",
|
||||
chroma.NameDecorator: "bold #3c5d5d",
|
||||
chroma.NameEntity: "#800080",
|
||||
chroma.NameException: "bold #990000",
|
||||
chroma.NameFunction: "bold #990000",
|
||||
chroma.NameLabel: "bold #990000",
|
||||
chroma.NameNamespace: "#555555",
|
||||
chroma.NameTag: "#000080",
|
||||
chroma.NameVariableClass: "#008080",
|
||||
chroma.NameVariableGlobal: "#008080",
|
||||
chroma.NameVariableInstance: "#008080",
|
||||
chroma.NameVariable: "#008080",
|
||||
chroma.Operator: "bold #000000",
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
<style name="github">
|
||||
<entry type="Error" style="#a61717 bg:#e3d2d2"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold #000000"/>
|
||||
<entry type="KeywordType" style="bold #445588"/>
|
||||
<entry type="NameAttribute" style="#008080"/>
|
||||
<entry type="NameBuiltin" style="#0086b3"/>
|
||||
<entry type="NameBuiltinPseudo" style="#999999"/>
|
||||
<entry type="NameClass" style="bold #445588"/>
|
||||
<entry type="NameConstant" style="#008080"/>
|
||||
<entry type="NameDecorator" style="bold #3c5d5d"/>
|
||||
<entry type="NameEntity" style="#800080"/>
|
||||
<entry type="NameException" style="bold #990000"/>
|
||||
<entry type="NameFunction" style="bold #990000"/>
|
||||
<entry type="NameLabel" style="bold #990000"/>
|
||||
<entry type="NameNamespace" style="#555555"/>
|
||||
<entry type="NameTag" style="#000080"/>
|
||||
<entry type="NameVariable" style="#008080"/>
|
||||
<entry type="NameVariableClass" style="#008080"/>
|
||||
<entry type="NameVariableGlobal" style="#008080"/>
|
||||
<entry type="NameVariableInstance" style="#008080"/>
|
||||
<entry type="LiteralString" style="#dd1144"/>
|
||||
<entry type="LiteralStringRegex" style="#009926"/>
|
||||
<entry type="LiteralStringSymbol" style="#990073"/>
|
||||
<entry type="LiteralNumber" style="#009999"/>
|
||||
<entry type="Operator" style="bold #000000"/>
|
||||
<entry type="Comment" style="italic #999988"/>
|
||||
<entry type="CommentMultiline" style="italic #999988"/>
|
||||
<entry type="CommentSingle" style="italic #999988"/>
|
||||
<entry type="CommentSpecial" style="bold italic #999999"/>
|
||||
<entry type="CommentPreproc" style="bold #999999"/>
|
||||
<entry type="GenericDeleted" style="#000000 bg:#ffdddd"/>
|
||||
<entry type="GenericEmph" style="italic #000000"/>
|
||||
<entry type="GenericError" style="#aa0000"/>
|
||||
<entry type="GenericHeading" style="#999999"/>
|
||||
<entry type="GenericInserted" style="#000000 bg:#ddffdd"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="#555555"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#aaaaaa"/>
|
||||
<entry type="GenericTraceback" style="#aa0000"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
-40
@@ -1,40 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Gruvbox light style.
|
||||
var GruvboxLight = Register(chroma.MustNewStyle("gruvbox-light", chroma.StyleEntries{
|
||||
chroma.CommentPreproc: "noinherit #427B58",
|
||||
chroma.Comment: "#928374 italic",
|
||||
chroma.GenericDeleted: "noinherit #282828 bg:#9D0006",
|
||||
chroma.GenericEmph: "#076678 underline",
|
||||
chroma.GenericError: "bg:#9D0006 bold",
|
||||
chroma.GenericHeading: "#79740E bold",
|
||||
chroma.GenericInserted: "noinherit #282828 bg:#79740E",
|
||||
chroma.GenericOutput: "noinherit #504945",
|
||||
chroma.GenericPrompt: "#3C3836",
|
||||
chroma.GenericStrong: "#3C3836",
|
||||
chroma.GenericSubheading: "#79740E bold",
|
||||
chroma.GenericTraceback: "bg:#3C3836 bold",
|
||||
chroma.Generic: "#3C3836",
|
||||
chroma.KeywordType: "noinherit #B57614",
|
||||
chroma.Keyword: "noinherit #AF3A03",
|
||||
chroma.NameAttribute: "#79740E bold",
|
||||
chroma.NameBuiltin: "#B57614",
|
||||
chroma.NameConstant: "noinherit #d3869b",
|
||||
chroma.NameEntity: "noinherit #B57614",
|
||||
chroma.NameException: "noinherit #fb4934",
|
||||
chroma.NameFunction: "#B57614",
|
||||
chroma.NameLabel: "noinherit #9D0006",
|
||||
chroma.NameTag: "noinherit #9D0006",
|
||||
chroma.NameVariable: "noinherit #3C3836",
|
||||
chroma.Name: "#3C3836",
|
||||
chroma.LiteralNumberFloat: "noinherit #8F3F71",
|
||||
chroma.LiteralNumber: "noinherit #8F3F71",
|
||||
chroma.Operator: "#AF3A03",
|
||||
chroma.LiteralStringSymbol: "#076678",
|
||||
chroma.LiteralString: "noinherit #79740E",
|
||||
chroma.Background: "noinherit #3C3836 bg:#FBF1C7 bg:#FBF1C7",
|
||||
}))
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
<style name="gruvbox-light">
|
||||
<entry type="Background" style="noinherit #3c3836 bg:#fbf1c7"/>
|
||||
<entry type="Keyword" style="noinherit #af3a03"/>
|
||||
<entry type="KeywordType" style="noinherit #b57614"/>
|
||||
<entry type="Name" style="#3c3836"/>
|
||||
<entry type="NameAttribute" style="bold #79740e"/>
|
||||
<entry type="NameBuiltin" style="#b57614"/>
|
||||
<entry type="NameConstant" style="noinherit #d3869b"/>
|
||||
<entry type="NameEntity" style="noinherit #b57614"/>
|
||||
<entry type="NameException" style="noinherit #fb4934"/>
|
||||
<entry type="NameFunction" style="#b57614"/>
|
||||
<entry type="NameLabel" style="noinherit #9d0006"/>
|
||||
<entry type="NameTag" style="noinherit #9d0006"/>
|
||||
<entry type="NameVariable" style="noinherit #3c3836"/>
|
||||
<entry type="LiteralString" style="noinherit #79740e"/>
|
||||
<entry type="LiteralStringSymbol" style="#076678"/>
|
||||
<entry type="LiteralNumber" style="noinherit #8f3f71"/>
|
||||
<entry type="LiteralNumberFloat" style="noinherit #8f3f71"/>
|
||||
<entry type="Operator" style="#af3a03"/>
|
||||
<entry type="Comment" style="italic #928374"/>
|
||||
<entry type="CommentPreproc" style="noinherit #427b58"/>
|
||||
<entry type="Generic" style="#3c3836"/>
|
||||
<entry type="GenericDeleted" style="noinherit #282828 bg:#9d0006"/>
|
||||
<entry type="GenericEmph" style="underline #076678"/>
|
||||
<entry type="GenericError" style="bold bg:#9d0006"/>
|
||||
<entry type="GenericHeading" style="bold #79740e"/>
|
||||
<entry type="GenericInserted" style="noinherit #282828 bg:#79740e"/>
|
||||
<entry type="GenericOutput" style="noinherit #504945"/>
|
||||
<entry type="GenericPrompt" style="#3c3836"/>
|
||||
<entry type="GenericStrong" style="#3c3836"/>
|
||||
<entry type="GenericSubheading" style="bold #79740e"/>
|
||||
<entry type="GenericTraceback" style="bold bg:#3c3836"/>
|
||||
</style>
|
||||
-40
@@ -1,40 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Gruvbox style.
|
||||
var Gruvbox = Register(chroma.MustNewStyle("gruvbox", chroma.StyleEntries{
|
||||
chroma.CommentPreproc: "noinherit #8ec07c",
|
||||
chroma.Comment: "#928374 italic",
|
||||
chroma.GenericDeleted: "noinherit #282828 bg:#fb4934",
|
||||
chroma.GenericEmph: "#83a598 underline",
|
||||
chroma.GenericError: "bg:#fb4934 bold",
|
||||
chroma.GenericHeading: "#b8bb26 bold",
|
||||
chroma.GenericInserted: "noinherit #282828 bg:#b8bb26",
|
||||
chroma.GenericOutput: "noinherit #504945",
|
||||
chroma.GenericPrompt: "#ebdbb2",
|
||||
chroma.GenericStrong: "#ebdbb2",
|
||||
chroma.GenericSubheading: "#b8bb26 bold",
|
||||
chroma.GenericTraceback: "bg:#fb4934 bold",
|
||||
chroma.Generic: "#ebdbb2",
|
||||
chroma.KeywordType: "noinherit #fabd2f",
|
||||
chroma.Keyword: "noinherit #fe8019",
|
||||
chroma.NameAttribute: "#b8bb26 bold",
|
||||
chroma.NameBuiltin: "#fabd2f",
|
||||
chroma.NameConstant: "noinherit #d3869b",
|
||||
chroma.NameEntity: "noinherit #fabd2f",
|
||||
chroma.NameException: "noinherit #fb4934",
|
||||
chroma.NameFunction: "#fabd2f",
|
||||
chroma.NameLabel: "noinherit #fb4934",
|
||||
chroma.NameTag: "noinherit #fb4934",
|
||||
chroma.NameVariable: "noinherit #ebdbb2",
|
||||
chroma.Name: "#ebdbb2",
|
||||
chroma.LiteralNumberFloat: "noinherit #d3869b",
|
||||
chroma.LiteralNumber: "noinherit #d3869b",
|
||||
chroma.Operator: "#fe8019",
|
||||
chroma.LiteralStringSymbol: "#83a598",
|
||||
chroma.LiteralString: "noinherit #b8bb26",
|
||||
chroma.Background: "noinherit #ebdbb2 bg:#282828 bg:#282828",
|
||||
}))
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
<style name="gruvbox">
|
||||
<entry type="Background" style="noinherit #ebdbb2 bg:#282828"/>
|
||||
<entry type="Keyword" style="noinherit #fe8019"/>
|
||||
<entry type="KeywordType" style="noinherit #fabd2f"/>
|
||||
<entry type="Name" style="#ebdbb2"/>
|
||||
<entry type="NameAttribute" style="bold #b8bb26"/>
|
||||
<entry type="NameBuiltin" style="#fabd2f"/>
|
||||
<entry type="NameConstant" style="noinherit #d3869b"/>
|
||||
<entry type="NameEntity" style="noinherit #fabd2f"/>
|
||||
<entry type="NameException" style="noinherit #fb4934"/>
|
||||
<entry type="NameFunction" style="#fabd2f"/>
|
||||
<entry type="NameLabel" style="noinherit #fb4934"/>
|
||||
<entry type="NameTag" style="noinherit #fb4934"/>
|
||||
<entry type="NameVariable" style="noinherit #ebdbb2"/>
|
||||
<entry type="LiteralString" style="noinherit #b8bb26"/>
|
||||
<entry type="LiteralStringSymbol" style="#83a598"/>
|
||||
<entry type="LiteralNumber" style="noinherit #d3869b"/>
|
||||
<entry type="LiteralNumberFloat" style="noinherit #d3869b"/>
|
||||
<entry type="Operator" style="#fe8019"/>
|
||||
<entry type="Comment" style="italic #928374"/>
|
||||
<entry type="CommentPreproc" style="noinherit #8ec07c"/>
|
||||
<entry type="Generic" style="#ebdbb2"/>
|
||||
<entry type="GenericDeleted" style="noinherit #282828 bg:#fb4934"/>
|
||||
<entry type="GenericEmph" style="underline #83a598"/>
|
||||
<entry type="GenericError" style="bold bg:#fb4934"/>
|
||||
<entry type="GenericHeading" style="bold #b8bb26"/>
|
||||
<entry type="GenericInserted" style="noinherit #282828 bg:#b8bb26"/>
|
||||
<entry type="GenericOutput" style="noinherit #504945"/>
|
||||
<entry type="GenericPrompt" style="#ebdbb2"/>
|
||||
<entry type="GenericStrong" style="#ebdbb2"/>
|
||||
<entry type="GenericSubheading" style="bold #b8bb26"/>
|
||||
<entry type="GenericTraceback" style="bold bg:#fb4934"/>
|
||||
</style>
|
||||
-17
@@ -1,17 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Theme based on HackerRank Dark Editor theme
|
||||
var HrDark = Register(chroma.MustNewStyle("hrdark", chroma.StyleEntries{
|
||||
chroma.Comment: "italic #828b96",
|
||||
chroma.Keyword: "#ff636f",
|
||||
chroma.OperatorWord: "#ff636f",
|
||||
chroma.Name: "#58a1dd",
|
||||
chroma.Literal: "#a6be9d",
|
||||
chroma.Operator: "#ff636f",
|
||||
chroma.Background: "#1d2432",
|
||||
chroma.Other: "#fff",
|
||||
}))
|
||||
-19
@@ -1,19 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Theme based on HackerRank High Contrast Editor Theme
|
||||
var HrHighContrast = Register(chroma.MustNewStyle("hr_high_contrast", chroma.StyleEntries{
|
||||
chroma.Comment: "#5a8349",
|
||||
chroma.Keyword: "#467faf",
|
||||
chroma.OperatorWord: "#467faf",
|
||||
chroma.Name: "#ffffff",
|
||||
chroma.LiteralString: "#a87662",
|
||||
chroma.LiteralNumber: "#fff",
|
||||
chroma.LiteralStringBoolean: "#467faf",
|
||||
chroma.Operator: "#e4e400",
|
||||
chroma.Background: "#000",
|
||||
chroma.Other: "#d5d500",
|
||||
}))
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
<style name="hr_high_contrast">
|
||||
<entry type="Other" style="#d5d500"/>
|
||||
<entry type="Background" style="#000000"/>
|
||||
<entry type="Keyword" style="#467faf"/>
|
||||
<entry type="Name" style="#ffffff"/>
|
||||
<entry type="LiteralString" style="#a87662"/>
|
||||
<entry type="LiteralStringBoolean" style="#467faf"/>
|
||||
<entry type="LiteralNumber" style="#ffffff"/>
|
||||
<entry type="Operator" style="#e4e400"/>
|
||||
<entry type="OperatorWord" style="#467faf"/>
|
||||
<entry type="Comment" style="#5a8349"/>
|
||||
</style>
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
<style name="hrdark">
|
||||
<entry type="Other" style="#ffffff"/>
|
||||
<entry type="Background" style="#1d2432"/>
|
||||
<entry type="Keyword" style="#ff636f"/>
|
||||
<entry type="Name" style="#58a1dd"/>
|
||||
<entry type="Literal" style="#a6be9d"/>
|
||||
<entry type="Operator" style="#ff636f"/>
|
||||
<entry type="OperatorWord" style="#ff636f"/>
|
||||
<entry type="Comment" style="italic #828b96"/>
|
||||
</style>
|
||||
-16
@@ -1,16 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Igor style.
|
||||
var Igor = Register(chroma.MustNewStyle("igor", chroma.StyleEntries{
|
||||
chroma.Comment: "italic #FF0000",
|
||||
chroma.Keyword: "#0000FF",
|
||||
chroma.NameFunction: "#C34E00",
|
||||
chroma.NameDecorator: "#CC00A3",
|
||||
chroma.NameClass: "#007575",
|
||||
chroma.LiteralString: "#009C00",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
<style name="igor">
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="#0000ff"/>
|
||||
<entry type="NameClass" style="#007575"/>
|
||||
<entry type="NameDecorator" style="#cc00a3"/>
|
||||
<entry type="NameFunction" style="#c34e00"/>
|
||||
<entry type="LiteralString" style="#009c00"/>
|
||||
<entry type="Comment" style="italic #ff0000"/>
|
||||
</style>
|
||||
-60
@@ -1,60 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Lovelace style.
|
||||
var Lovelace = Register(chroma.MustNewStyle("lovelace", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#a89028",
|
||||
chroma.Comment: "italic #888888",
|
||||
chroma.CommentHashbang: "#287088",
|
||||
chroma.CommentMultiline: "#888888",
|
||||
chroma.CommentPreproc: "noitalic #289870",
|
||||
chroma.Keyword: "#2838b0",
|
||||
chroma.KeywordConstant: "italic #444444",
|
||||
chroma.KeywordDeclaration: "italic",
|
||||
chroma.KeywordType: "italic",
|
||||
chroma.Operator: "#666666",
|
||||
chroma.OperatorWord: "#a848a8",
|
||||
chroma.Punctuation: "#888888",
|
||||
chroma.NameAttribute: "#388038",
|
||||
chroma.NameBuiltin: "#388038",
|
||||
chroma.NameBuiltinPseudo: "italic",
|
||||
chroma.NameClass: "#287088",
|
||||
chroma.NameConstant: "#b85820",
|
||||
chroma.NameDecorator: "#287088",
|
||||
chroma.NameEntity: "#709030",
|
||||
chroma.NameException: "#908828",
|
||||
chroma.NameFunction: "#785840",
|
||||
chroma.NameFunctionMagic: "#b85820",
|
||||
chroma.NameLabel: "#289870",
|
||||
chroma.NameNamespace: "#289870",
|
||||
chroma.NameTag: "#2838b0",
|
||||
chroma.NameVariable: "#b04040",
|
||||
chroma.NameVariableGlobal: "#908828",
|
||||
chroma.NameVariableMagic: "#b85820",
|
||||
chroma.LiteralString: "#b83838",
|
||||
chroma.LiteralStringAffix: "#444444",
|
||||
chroma.LiteralStringChar: "#a848a8",
|
||||
chroma.LiteralStringDelimiter: "#b85820",
|
||||
chroma.LiteralStringDoc: "italic #b85820",
|
||||
chroma.LiteralStringEscape: "#709030",
|
||||
chroma.LiteralStringInterpol: "underline",
|
||||
chroma.LiteralStringOther: "#a848a8",
|
||||
chroma.LiteralStringRegex: "#a848a8",
|
||||
chroma.LiteralNumber: "#444444",
|
||||
chroma.GenericDeleted: "#c02828",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericError: "#c02828",
|
||||
chroma.GenericHeading: "#666666",
|
||||
chroma.GenericSubheading: "#444444",
|
||||
chroma.GenericInserted: "#388038",
|
||||
chroma.GenericOutput: "#666666",
|
||||
chroma.GenericPrompt: "#444444",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericTraceback: "#2838b0",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "bg:#a848a8",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+53
@@ -0,0 +1,53 @@
|
||||
<style name="lovelace">
|
||||
<entry type="Error" style="bg:#a848a8"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="#2838b0"/>
|
||||
<entry type="KeywordConstant" style="italic #444444"/>
|
||||
<entry type="KeywordDeclaration" style="italic"/>
|
||||
<entry type="KeywordType" style="italic"/>
|
||||
<entry type="NameAttribute" style="#388038"/>
|
||||
<entry type="NameBuiltin" style="#388038"/>
|
||||
<entry type="NameBuiltinPseudo" style="italic"/>
|
||||
<entry type="NameClass" style="#287088"/>
|
||||
<entry type="NameConstant" style="#b85820"/>
|
||||
<entry type="NameDecorator" style="#287088"/>
|
||||
<entry type="NameEntity" style="#709030"/>
|
||||
<entry type="NameException" style="#908828"/>
|
||||
<entry type="NameFunction" style="#785840"/>
|
||||
<entry type="NameFunctionMagic" style="#b85820"/>
|
||||
<entry type="NameLabel" style="#289870"/>
|
||||
<entry type="NameNamespace" style="#289870"/>
|
||||
<entry type="NameTag" style="#2838b0"/>
|
||||
<entry type="NameVariable" style="#b04040"/>
|
||||
<entry type="NameVariableGlobal" style="#908828"/>
|
||||
<entry type="NameVariableMagic" style="#b85820"/>
|
||||
<entry type="LiteralString" style="#b83838"/>
|
||||
<entry type="LiteralStringAffix" style="#444444"/>
|
||||
<entry type="LiteralStringChar" style="#a848a8"/>
|
||||
<entry type="LiteralStringDelimiter" style="#b85820"/>
|
||||
<entry type="LiteralStringDoc" style="italic #b85820"/>
|
||||
<entry type="LiteralStringEscape" style="#709030"/>
|
||||
<entry type="LiteralStringInterpol" style="underline"/>
|
||||
<entry type="LiteralStringOther" style="#a848a8"/>
|
||||
<entry type="LiteralStringRegex" style="#a848a8"/>
|
||||
<entry type="LiteralNumber" style="#444444"/>
|
||||
<entry type="Operator" style="#666666"/>
|
||||
<entry type="OperatorWord" style="#a848a8"/>
|
||||
<entry type="Punctuation" style="#888888"/>
|
||||
<entry type="Comment" style="italic #888888"/>
|
||||
<entry type="CommentHashbang" style="#287088"/>
|
||||
<entry type="CommentMultiline" style="#888888"/>
|
||||
<entry type="CommentPreproc" style="noitalic #289870"/>
|
||||
<entry type="GenericDeleted" style="#c02828"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#c02828"/>
|
||||
<entry type="GenericHeading" style="#666666"/>
|
||||
<entry type="GenericInserted" style="#388038"/>
|
||||
<entry type="GenericOutput" style="#666666"/>
|
||||
<entry type="GenericPrompt" style="#444444"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#444444"/>
|
||||
<entry type="GenericTraceback" style="#2838b0"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#a89028"/>
|
||||
</style>
|
||||
-51
@@ -1,51 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Manni style.
|
||||
var Manni = Register(chroma.MustNewStyle("manni", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "italic #0099FF",
|
||||
chroma.CommentPreproc: "noitalic #009999",
|
||||
chroma.CommentSpecial: "bold",
|
||||
chroma.Keyword: "bold #006699",
|
||||
chroma.KeywordPseudo: "nobold",
|
||||
chroma.KeywordType: "#007788",
|
||||
chroma.Operator: "#555555",
|
||||
chroma.OperatorWord: "bold #000000",
|
||||
chroma.NameBuiltin: "#336666",
|
||||
chroma.NameFunction: "#CC00FF",
|
||||
chroma.NameClass: "bold #00AA88",
|
||||
chroma.NameNamespace: "bold #00CCFF",
|
||||
chroma.NameException: "bold #CC0000",
|
||||
chroma.NameVariable: "#003333",
|
||||
chroma.NameConstant: "#336600",
|
||||
chroma.NameLabel: "#9999FF",
|
||||
chroma.NameEntity: "bold #999999",
|
||||
chroma.NameAttribute: "#330099",
|
||||
chroma.NameTag: "bold #330099",
|
||||
chroma.NameDecorator: "#9999FF",
|
||||
chroma.LiteralString: "#CC3300",
|
||||
chroma.LiteralStringDoc: "italic",
|
||||
chroma.LiteralStringInterpol: "#AA0000",
|
||||
chroma.LiteralStringEscape: "bold #CC3300",
|
||||
chroma.LiteralStringRegex: "#33AAAA",
|
||||
chroma.LiteralStringSymbol: "#FFCC33",
|
||||
chroma.LiteralStringOther: "#CC3300",
|
||||
chroma.LiteralNumber: "#FF6600",
|
||||
chroma.GenericHeading: "bold #003300",
|
||||
chroma.GenericSubheading: "bold #003300",
|
||||
chroma.GenericDeleted: "border:#CC0000 bg:#FFCCCC",
|
||||
chroma.GenericInserted: "border:#00CC00 bg:#CCFFCC",
|
||||
chroma.GenericError: "#FF0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold #000099",
|
||||
chroma.GenericOutput: "#AAAAAA",
|
||||
chroma.GenericTraceback: "#99CC66",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "bg:#FFAAAA #AA0000",
|
||||
chroma.Background: " bg:#f0f3f3",
|
||||
}))
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
<style name="manni">
|
||||
<entry type="Error" style="#aa0000 bg:#ffaaaa"/>
|
||||
<entry type="Background" style="bg:#f0f3f3"/>
|
||||
<entry type="Keyword" style="bold #006699"/>
|
||||
<entry type="KeywordPseudo" style="nobold"/>
|
||||
<entry type="KeywordType" style="#007788"/>
|
||||
<entry type="NameAttribute" style="#330099"/>
|
||||
<entry type="NameBuiltin" style="#336666"/>
|
||||
<entry type="NameClass" style="bold #00aa88"/>
|
||||
<entry type="NameConstant" style="#336600"/>
|
||||
<entry type="NameDecorator" style="#9999ff"/>
|
||||
<entry type="NameEntity" style="bold #999999"/>
|
||||
<entry type="NameException" style="bold #cc0000"/>
|
||||
<entry type="NameFunction" style="#cc00ff"/>
|
||||
<entry type="NameLabel" style="#9999ff"/>
|
||||
<entry type="NameNamespace" style="bold #00ccff"/>
|
||||
<entry type="NameTag" style="bold #330099"/>
|
||||
<entry type="NameVariable" style="#003333"/>
|
||||
<entry type="LiteralString" style="#cc3300"/>
|
||||
<entry type="LiteralStringDoc" style="italic"/>
|
||||
<entry type="LiteralStringEscape" style="bold #cc3300"/>
|
||||
<entry type="LiteralStringInterpol" style="#aa0000"/>
|
||||
<entry type="LiteralStringOther" style="#cc3300"/>
|
||||
<entry type="LiteralStringRegex" style="#33aaaa"/>
|
||||
<entry type="LiteralStringSymbol" style="#ffcc33"/>
|
||||
<entry type="LiteralNumber" style="#ff6600"/>
|
||||
<entry type="Operator" style="#555555"/>
|
||||
<entry type="OperatorWord" style="bold #000000"/>
|
||||
<entry type="Comment" style="italic #0099ff"/>
|
||||
<entry type="CommentSpecial" style="bold"/>
|
||||
<entry type="CommentPreproc" style="noitalic #009999"/>
|
||||
<entry type="GenericDeleted" style="bg:#ffcccc border:#cc0000"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ff0000"/>
|
||||
<entry type="GenericHeading" style="bold #003300"/>
|
||||
<entry type="GenericInserted" style="bg:#ccffcc border:#00cc00"/>
|
||||
<entry type="GenericOutput" style="#aaaaaa"/>
|
||||
<entry type="GenericPrompt" style="bold #000099"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #003300"/>
|
||||
<entry type="GenericTraceback" style="#99cc66"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
<style name="modus-operandi">
|
||||
<entry type="Background" style="#000000 bg:#ffffff"/>
|
||||
<entry type="Keyword" style="#5317ac"/>
|
||||
<entry type="KeywordConstant" style="#0000c0"/>
|
||||
<entry type="KeywordType" style="#005a5f"/>
|
||||
<entry type="NameBuiltin" style="#8f0075"/>
|
||||
<entry type="NameFunction" style="#721045"/>
|
||||
<entry type="NameVariable" style="#00538b"/>
|
||||
<entry type="Literal" style="#0000c0"/>
|
||||
<entry type="LiteralString" style="#2544bb"/>
|
||||
<entry type="Operator" style="#00538b"/>
|
||||
<entry type="Comment" style="#505050"/>
|
||||
</style>
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
<style name="modus-vivendi">
|
||||
<entry type="Background" style="#ffffff bg:#000000"/>
|
||||
<entry type="Keyword" style="#b6a0ff"/>
|
||||
<entry type="KeywordConstant" style="#00bcff"/>
|
||||
<entry type="KeywordType" style="#6ae4b9"/>
|
||||
<entry type="NameBuiltin" style="#f78fe7"/>
|
||||
<entry type="NameFunction" style="#feacd0"/>
|
||||
<entry type="NameVariable" style="#00d3d0"/>
|
||||
<entry type="Literal" style="#00bcff"/>
|
||||
<entry type="LiteralString" style="#79a8ff"/>
|
||||
<entry type="Operator" style="#00d3d0"/>
|
||||
<entry type="Comment" style="#a8a8a8"/>
|
||||
</style>
|
||||
-36
@@ -1,36 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Monokai style.
|
||||
var Monokai = Register(chroma.MustNewStyle("monokai", chroma.StyleEntries{
|
||||
chroma.Text: "#f8f8f2",
|
||||
chroma.Error: "#960050 bg:#1e0010",
|
||||
chroma.Comment: "#75715e",
|
||||
chroma.Keyword: "#66d9ef",
|
||||
chroma.KeywordNamespace: "#f92672",
|
||||
chroma.Operator: "#f92672",
|
||||
chroma.Punctuation: "#f8f8f2",
|
||||
chroma.Name: "#f8f8f2",
|
||||
chroma.NameAttribute: "#a6e22e",
|
||||
chroma.NameClass: "#a6e22e",
|
||||
chroma.NameConstant: "#66d9ef",
|
||||
chroma.NameDecorator: "#a6e22e",
|
||||
chroma.NameException: "#a6e22e",
|
||||
chroma.NameFunction: "#a6e22e",
|
||||
chroma.NameOther: "#a6e22e",
|
||||
chroma.NameTag: "#f92672",
|
||||
chroma.LiteralNumber: "#ae81ff",
|
||||
chroma.Literal: "#ae81ff",
|
||||
chroma.LiteralDate: "#e6db74",
|
||||
chroma.LiteralString: "#e6db74",
|
||||
chroma.LiteralStringEscape: "#ae81ff",
|
||||
chroma.GenericDeleted: "#f92672",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericInserted: "#a6e22e",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericSubheading: "#75715e",
|
||||
chroma.Background: "bg:#272822",
|
||||
}))
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
<style name="monokai">
|
||||
<entry type="Error" style="#960050 bg:#1e0010"/>
|
||||
<entry type="Background" style="bg:#272822"/>
|
||||
<entry type="Keyword" style="#66d9ef"/>
|
||||
<entry type="KeywordNamespace" style="#f92672"/>
|
||||
<entry type="Name" style="#f8f8f2"/>
|
||||
<entry type="NameAttribute" style="#a6e22e"/>
|
||||
<entry type="NameClass" style="#a6e22e"/>
|
||||
<entry type="NameConstant" style="#66d9ef"/>
|
||||
<entry type="NameDecorator" style="#a6e22e"/>
|
||||
<entry type="NameException" style="#a6e22e"/>
|
||||
<entry type="NameFunction" style="#a6e22e"/>
|
||||
<entry type="NameOther" style="#a6e22e"/>
|
||||
<entry type="NameTag" style="#f92672"/>
|
||||
<entry type="Literal" style="#ae81ff"/>
|
||||
<entry type="LiteralDate" style="#e6db74"/>
|
||||
<entry type="LiteralString" style="#e6db74"/>
|
||||
<entry type="LiteralStringEscape" style="#ae81ff"/>
|
||||
<entry type="LiteralNumber" style="#ae81ff"/>
|
||||
<entry type="Operator" style="#f92672"/>
|
||||
<entry type="Punctuation" style="#f8f8f2"/>
|
||||
<entry type="Comment" style="#75715e"/>
|
||||
<entry type="GenericDeleted" style="#f92672"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericInserted" style="#a6e22e"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="#75715e"/>
|
||||
<entry type="Text" style="#f8f8f2"/>
|
||||
</style>
|
||||
-33
@@ -1,33 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// MonokaiLight style.
|
||||
var MonokaiLight = Register(chroma.MustNewStyle("monokailight", chroma.StyleEntries{
|
||||
chroma.Text: "#272822",
|
||||
chroma.Error: "#960050 bg:#1e0010",
|
||||
chroma.Comment: "#75715e",
|
||||
chroma.Keyword: "#00a8c8",
|
||||
chroma.KeywordNamespace: "#f92672",
|
||||
chroma.Operator: "#f92672",
|
||||
chroma.Punctuation: "#111111",
|
||||
chroma.Name: "#111111",
|
||||
chroma.NameAttribute: "#75af00",
|
||||
chroma.NameClass: "#75af00",
|
||||
chroma.NameConstant: "#00a8c8",
|
||||
chroma.NameDecorator: "#75af00",
|
||||
chroma.NameException: "#75af00",
|
||||
chroma.NameFunction: "#75af00",
|
||||
chroma.NameOther: "#75af00",
|
||||
chroma.NameTag: "#f92672",
|
||||
chroma.LiteralNumber: "#ae81ff",
|
||||
chroma.Literal: "#ae81ff",
|
||||
chroma.LiteralDate: "#d88200",
|
||||
chroma.LiteralString: "#d88200",
|
||||
chroma.LiteralStringEscape: "#8045FF",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.Background: " bg:#fafafa",
|
||||
}))
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
<style name="monokailight">
|
||||
<entry type="Error" style="#960050 bg:#1e0010"/>
|
||||
<entry type="Background" style="bg:#fafafa"/>
|
||||
<entry type="Keyword" style="#00a8c8"/>
|
||||
<entry type="KeywordNamespace" style="#f92672"/>
|
||||
<entry type="Name" style="#111111"/>
|
||||
<entry type="NameAttribute" style="#75af00"/>
|
||||
<entry type="NameClass" style="#75af00"/>
|
||||
<entry type="NameConstant" style="#00a8c8"/>
|
||||
<entry type="NameDecorator" style="#75af00"/>
|
||||
<entry type="NameException" style="#75af00"/>
|
||||
<entry type="NameFunction" style="#75af00"/>
|
||||
<entry type="NameOther" style="#75af00"/>
|
||||
<entry type="NameTag" style="#f92672"/>
|
||||
<entry type="Literal" style="#ae81ff"/>
|
||||
<entry type="LiteralDate" style="#d88200"/>
|
||||
<entry type="LiteralString" style="#d88200"/>
|
||||
<entry type="LiteralStringEscape" style="#8045ff"/>
|
||||
<entry type="LiteralNumber" style="#ae81ff"/>
|
||||
<entry type="Operator" style="#f92672"/>
|
||||
<entry type="Punctuation" style="#111111"/>
|
||||
<entry type="Comment" style="#75715e"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="Text" style="#272822"/>
|
||||
</style>
|
||||
-59
@@ -1,59 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Murphy style.
|
||||
var Murphy = Register(chroma.MustNewStyle("murphy", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: "#bbbbbb",
|
||||
chroma.Comment: "#666 italic",
|
||||
chroma.CommentPreproc: "#579 noitalic",
|
||||
chroma.CommentSpecial: "#c00 bold",
|
||||
chroma.Keyword: "bold #289",
|
||||
chroma.KeywordPseudo: "#08f",
|
||||
chroma.KeywordType: "#66f",
|
||||
chroma.Operator: "#333",
|
||||
chroma.OperatorWord: "bold #000",
|
||||
chroma.NameBuiltin: "#072",
|
||||
chroma.NameFunction: "bold #5ed",
|
||||
chroma.NameClass: "bold #e9e",
|
||||
chroma.NameNamespace: "bold #0e84b5",
|
||||
chroma.NameException: "bold #F00",
|
||||
chroma.NameVariable: "#036",
|
||||
chroma.NameVariableInstance: "#aaf",
|
||||
chroma.NameVariableClass: "#ccf",
|
||||
chroma.NameVariableGlobal: "#f84",
|
||||
chroma.NameConstant: "bold #5ed",
|
||||
chroma.NameLabel: "bold #970",
|
||||
chroma.NameEntity: "#800",
|
||||
chroma.NameAttribute: "#007",
|
||||
chroma.NameTag: "#070",
|
||||
chroma.NameDecorator: "bold #555",
|
||||
chroma.LiteralString: "bg:#e0e0ff",
|
||||
chroma.LiteralStringChar: "#88F bg:",
|
||||
chroma.LiteralStringDoc: "#D42 bg:",
|
||||
chroma.LiteralStringInterpol: "bg:#eee",
|
||||
chroma.LiteralStringEscape: "bold #666",
|
||||
chroma.LiteralStringRegex: "bg:#e0e0ff #000",
|
||||
chroma.LiteralStringSymbol: "#fc8 bg:",
|
||||
chroma.LiteralStringOther: "#f88",
|
||||
chroma.LiteralNumber: "bold #60E",
|
||||
chroma.LiteralNumberInteger: "bold #66f",
|
||||
chroma.LiteralNumberFloat: "bold #60E",
|
||||
chroma.LiteralNumberHex: "bold #058",
|
||||
chroma.LiteralNumberOct: "bold #40E",
|
||||
chroma.GenericHeading: "bold #000080",
|
||||
chroma.GenericSubheading: "bold #800080",
|
||||
chroma.GenericDeleted: "#A00000",
|
||||
chroma.GenericInserted: "#00A000",
|
||||
chroma.GenericError: "#FF0000",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold #c65d09",
|
||||
chroma.GenericOutput: "#888",
|
||||
chroma.GenericTraceback: "#04D",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "#F00 bg:#FAA",
|
||||
chroma.Background: " bg:#ffffff",
|
||||
}))
|
||||
+52
@@ -0,0 +1,52 @@
|
||||
<style name="murphy">
|
||||
<entry type="Error" style="#ff0000 bg:#ffaaaa"/>
|
||||
<entry type="Background" style="bg:#ffffff"/>
|
||||
<entry type="Keyword" style="bold #228899"/>
|
||||
<entry type="KeywordPseudo" style="#0088ff"/>
|
||||
<entry type="KeywordType" style="#6666ff"/>
|
||||
<entry type="NameAttribute" style="#000077"/>
|
||||
<entry type="NameBuiltin" style="#007722"/>
|
||||
<entry type="NameClass" style="bold #ee99ee"/>
|
||||
<entry type="NameConstant" style="bold #55eedd"/>
|
||||
<entry type="NameDecorator" style="bold #555555"/>
|
||||
<entry type="NameEntity" style="#880000"/>
|
||||
<entry type="NameException" style="bold #ff0000"/>
|
||||
<entry type="NameFunction" style="bold #55eedd"/>
|
||||
<entry type="NameLabel" style="bold #997700"/>
|
||||
<entry type="NameNamespace" style="bold #0e84b5"/>
|
||||
<entry type="NameTag" style="#007700"/>
|
||||
<entry type="NameVariable" style="#003366"/>
|
||||
<entry type="NameVariableClass" style="#ccccff"/>
|
||||
<entry type="NameVariableGlobal" style="#ff8844"/>
|
||||
<entry type="NameVariableInstance" style="#aaaaff"/>
|
||||
<entry type="LiteralString" style="bg:#e0e0ff"/>
|
||||
<entry type="LiteralStringChar" style="#8888ff"/>
|
||||
<entry type="LiteralStringDoc" style="#dd4422"/>
|
||||
<entry type="LiteralStringEscape" style="bold #666666"/>
|
||||
<entry type="LiteralStringInterpol" style="bg:#eeeeee"/>
|
||||
<entry type="LiteralStringOther" style="#ff8888"/>
|
||||
<entry type="LiteralStringRegex" style="#000000 bg:#e0e0ff"/>
|
||||
<entry type="LiteralStringSymbol" style="#ffcc88"/>
|
||||
<entry type="LiteralNumber" style="bold #6600ee"/>
|
||||
<entry type="LiteralNumberFloat" style="bold #6600ee"/>
|
||||
<entry type="LiteralNumberHex" style="bold #005588"/>
|
||||
<entry type="LiteralNumberInteger" style="bold #6666ff"/>
|
||||
<entry type="LiteralNumberOct" style="bold #4400ee"/>
|
||||
<entry type="Operator" style="#333333"/>
|
||||
<entry type="OperatorWord" style="bold #000000"/>
|
||||
<entry type="Comment" style="italic #666666"/>
|
||||
<entry type="CommentSpecial" style="bold #cc0000"/>
|
||||
<entry type="CommentPreproc" style="noitalic #557799"/>
|
||||
<entry type="GenericDeleted" style="#a00000"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#ff0000"/>
|
||||
<entry type="GenericHeading" style="bold #000080"/>
|
||||
<entry type="GenericInserted" style="#00a000"/>
|
||||
<entry type="GenericOutput" style="#888888"/>
|
||||
<entry type="GenericPrompt" style="bold #c65d09"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #800080"/>
|
||||
<entry type="GenericTraceback" style="#0044dd"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#bbbbbb"/>
|
||||
</style>
|
||||
-42
@@ -1,42 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
// Native style.
|
||||
var Native = Register(chroma.MustNewStyle("native", chroma.StyleEntries{
|
||||
chroma.Background: "#d0d0d0 bg:#202020",
|
||||
chroma.TextWhitespace: "#666666",
|
||||
chroma.Comment: "italic #999999",
|
||||
chroma.CommentPreproc: "noitalic bold #cd2828",
|
||||
chroma.CommentSpecial: "noitalic bold #e50808 bg:#520000",
|
||||
chroma.Keyword: "bold #6ab825",
|
||||
chroma.KeywordPseudo: "nobold",
|
||||
chroma.OperatorWord: "bold #6ab825",
|
||||
chroma.LiteralString: "#ed9d13",
|
||||
chroma.LiteralStringOther: "#ffa500",
|
||||
chroma.LiteralNumber: "#3677a9",
|
||||
chroma.NameBuiltin: "#24909d",
|
||||
chroma.NameVariable: "#40ffff",
|
||||
chroma.NameConstant: "#40ffff",
|
||||
chroma.NameClass: "underline #447fcf",
|
||||
chroma.NameFunction: "#447fcf",
|
||||
chroma.NameNamespace: "underline #447fcf",
|
||||
chroma.NameException: "#bbbbbb",
|
||||
chroma.NameTag: "bold #6ab825",
|
||||
chroma.NameAttribute: "#bbbbbb",
|
||||
chroma.NameDecorator: "#ffa500",
|
||||
chroma.GenericHeading: "bold #ffffff",
|
||||
chroma.GenericSubheading: "underline #ffffff",
|
||||
chroma.GenericDeleted: "#d22323",
|
||||
chroma.GenericInserted: "#589819",
|
||||
chroma.GenericError: "#d22323",
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "#aaaaaa",
|
||||
chroma.GenericOutput: "#cccccc",
|
||||
chroma.GenericTraceback: "#d22323",
|
||||
chroma.GenericUnderline: "underline",
|
||||
chroma.Error: "bg:#e3d2d2 #a61717",
|
||||
}))
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
<style name="native">
|
||||
<entry type="Error" style="#a61717 bg:#e3d2d2"/>
|
||||
<entry type="Background" style="#d0d0d0 bg:#202020"/>
|
||||
<entry type="Keyword" style="bold #6ab825"/>
|
||||
<entry type="KeywordPseudo" style="nobold"/>
|
||||
<entry type="NameAttribute" style="#bbbbbb"/>
|
||||
<entry type="NameBuiltin" style="#24909d"/>
|
||||
<entry type="NameClass" style="underline #447fcf"/>
|
||||
<entry type="NameConstant" style="#40ffff"/>
|
||||
<entry type="NameDecorator" style="#ffa500"/>
|
||||
<entry type="NameException" style="#bbbbbb"/>
|
||||
<entry type="NameFunction" style="#447fcf"/>
|
||||
<entry type="NameNamespace" style="underline #447fcf"/>
|
||||
<entry type="NameTag" style="bold #6ab825"/>
|
||||
<entry type="NameVariable" style="#40ffff"/>
|
||||
<entry type="LiteralString" style="#ed9d13"/>
|
||||
<entry type="LiteralStringOther" style="#ffa500"/>
|
||||
<entry type="LiteralNumber" style="#3677a9"/>
|
||||
<entry type="OperatorWord" style="bold #6ab825"/>
|
||||
<entry type="Comment" style="italic #999999"/>
|
||||
<entry type="CommentSpecial" style="bold noitalic #e50808 bg:#520000"/>
|
||||
<entry type="CommentPreproc" style="bold noitalic #cd2828"/>
|
||||
<entry type="GenericDeleted" style="#d22323"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#d22323"/>
|
||||
<entry type="GenericHeading" style="bold #ffffff"/>
|
||||
<entry type="GenericInserted" style="#589819"/>
|
||||
<entry type="GenericOutput" style="#cccccc"/>
|
||||
<entry type="GenericPrompt" style="#aaaaaa"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="underline #ffffff"/>
|
||||
<entry type="GenericTraceback" style="#d22323"/>
|
||||
<entry type="GenericUnderline" style="underline"/>
|
||||
<entry type="TextWhitespace" style="#666666"/>
|
||||
</style>
|
||||
-75
@@ -1,75 +0,0 @@
|
||||
package styles
|
||||
|
||||
import (
|
||||
"github.com/alecthomas/chroma/v2"
|
||||
)
|
||||
|
||||
var (
|
||||
// colors and palettes based on https://www.nordtheme.com/docs/colors-and-palettes
|
||||
nord0 = "#2e3440"
|
||||
nord1 = "#3b4252" // nolint
|
||||
nord2 = "#434c5e" // nolint
|
||||
nord3 = "#4c566a"
|
||||
nord3b = "#616e87"
|
||||
|
||||
nord4 = "#d8dee9"
|
||||
nord5 = "#e5e9f0" // nolint
|
||||
nord6 = "#eceff4"
|
||||
|
||||
nord7 = "#8fbcbb"
|
||||
nord8 = "#88c0d0"
|
||||
nord9 = "#81a1c1"
|
||||
nord10 = "#5e81ac"
|
||||
|
||||
nord11 = "#bf616a"
|
||||
nord12 = "#d08770"
|
||||
nord13 = "#ebcb8b"
|
||||
nord14 = "#a3be8c"
|
||||
nord15 = "#b48ead"
|
||||
)
|
||||
|
||||
// Nord, an arctic, north-bluish color palette
|
||||
var Nord = Register(chroma.MustNewStyle("nord", chroma.StyleEntries{
|
||||
chroma.TextWhitespace: nord4,
|
||||
chroma.Comment: "italic " + nord3b,
|
||||
chroma.CommentPreproc: nord10,
|
||||
chroma.Keyword: "bold " + nord9,
|
||||
chroma.KeywordPseudo: "nobold " + nord9,
|
||||
chroma.KeywordType: "nobold " + nord9,
|
||||
chroma.Operator: nord9,
|
||||
chroma.OperatorWord: "bold " + nord9,
|
||||
chroma.Name: nord4,
|
||||
chroma.NameBuiltin: nord9,
|
||||
chroma.NameFunction: nord8,
|
||||
chroma.NameClass: nord7,
|
||||
chroma.NameNamespace: nord7,
|
||||
chroma.NameException: nord11,
|
||||
chroma.NameVariable: nord4,
|
||||
chroma.NameConstant: nord7,
|
||||
chroma.NameLabel: nord7,
|
||||
chroma.NameEntity: nord12,
|
||||
chroma.NameAttribute: nord7,
|
||||
chroma.NameTag: nord9,
|
||||
chroma.NameDecorator: nord12,
|
||||
chroma.Punctuation: nord6,
|
||||
chroma.LiteralString: nord14,
|
||||
chroma.LiteralStringDoc: nord3b,
|
||||
chroma.LiteralStringInterpol: nord14,
|
||||
chroma.LiteralStringEscape: nord13,
|
||||
chroma.LiteralStringRegex: nord13,
|
||||
chroma.LiteralStringSymbol: nord14,
|
||||
chroma.LiteralStringOther: nord14,
|
||||
chroma.LiteralNumber: nord15,
|
||||
chroma.GenericHeading: "bold " + nord8,
|
||||
chroma.GenericSubheading: "bold " + nord8,
|
||||
chroma.GenericDeleted: nord11,
|
||||
chroma.GenericInserted: nord14,
|
||||
chroma.GenericError: nord11,
|
||||
chroma.GenericEmph: "italic",
|
||||
chroma.GenericStrong: "bold",
|
||||
chroma.GenericPrompt: "bold " + nord3,
|
||||
chroma.GenericOutput: nord4,
|
||||
chroma.GenericTraceback: nord11,
|
||||
chroma.Error: nord11,
|
||||
chroma.Background: nord4 + " bg:" + nord0,
|
||||
}))
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
<style name="nord">
|
||||
<entry type="Error" style="#bf616a"/>
|
||||
<entry type="Background" style="#d8dee9 bg:#2e3440"/>
|
||||
<entry type="Keyword" style="bold #81a1c1"/>
|
||||
<entry type="KeywordPseudo" style="nobold #81a1c1"/>
|
||||
<entry type="KeywordType" style="nobold #81a1c1"/>
|
||||
<entry type="Name" style="#d8dee9"/>
|
||||
<entry type="NameAttribute" style="#8fbcbb"/>
|
||||
<entry type="NameBuiltin" style="#81a1c1"/>
|
||||
<entry type="NameClass" style="#8fbcbb"/>
|
||||
<entry type="NameConstant" style="#8fbcbb"/>
|
||||
<entry type="NameDecorator" style="#d08770"/>
|
||||
<entry type="NameEntity" style="#d08770"/>
|
||||
<entry type="NameException" style="#bf616a"/>
|
||||
<entry type="NameFunction" style="#88c0d0"/>
|
||||
<entry type="NameLabel" style="#8fbcbb"/>
|
||||
<entry type="NameNamespace" style="#8fbcbb"/>
|
||||
<entry type="NameTag" style="#81a1c1"/>
|
||||
<entry type="NameVariable" style="#d8dee9"/>
|
||||
<entry type="LiteralString" style="#a3be8c"/>
|
||||
<entry type="LiteralStringDoc" style="#616e87"/>
|
||||
<entry type="LiteralStringEscape" style="#ebcb8b"/>
|
||||
<entry type="LiteralStringInterpol" style="#a3be8c"/>
|
||||
<entry type="LiteralStringOther" style="#a3be8c"/>
|
||||
<entry type="LiteralStringRegex" style="#ebcb8b"/>
|
||||
<entry type="LiteralStringSymbol" style="#a3be8c"/>
|
||||
<entry type="LiteralNumber" style="#b48ead"/>
|
||||
<entry type="Operator" style="#81a1c1"/>
|
||||
<entry type="OperatorWord" style="bold #81a1c1"/>
|
||||
<entry type="Punctuation" style="#eceff4"/>
|
||||
<entry type="Comment" style="italic #616e87"/>
|
||||
<entry type="CommentPreproc" style="#5e81ac"/>
|
||||
<entry type="GenericDeleted" style="#bf616a"/>
|
||||
<entry type="GenericEmph" style="italic"/>
|
||||
<entry type="GenericError" style="#bf616a"/>
|
||||
<entry type="GenericHeading" style="bold #88c0d0"/>
|
||||
<entry type="GenericInserted" style="#a3be8c"/>
|
||||
<entry type="GenericOutput" style="#d8dee9"/>
|
||||
<entry type="GenericPrompt" style="bold #4c566a"/>
|
||||
<entry type="GenericStrong" style="bold"/>
|
||||
<entry type="GenericSubheading" style="bold #88c0d0"/>
|
||||
<entry type="GenericTraceback" style="#bf616a"/>
|
||||
<entry type="TextWhitespace" style="#d8dee9"/>
|
||||
</style>
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user