{"id":15056329,"url":"https://github.com/bel-framework/bel-css","last_synced_at":"2026-04-01T21:51:16.349Z","repository":{"id":233898636,"uuid":"786960437","full_name":"bel-framework/bel-css","owner":"bel-framework","description":"CSS utilities for Erlang","archived":false,"fork":false,"pushed_at":"2024-04-17T05:35:44.000Z","size":78,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-27T13:41:57.362Z","etag":null,"topics":["css","css-parser","css3","erlang","erlang-library","parser"],"latest_commit_sha":null,"homepage":"","language":"Erlang","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bel-framework.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null},"funding":{"github":["williamthome"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":["https://www.buymeacoffee.com/williamthome"]}},"created_at":"2024-04-15T16:16:33.000Z","updated_at":"2025-08-26T21:11:27.000Z","dependencies_parsed_at":"2024-04-17T16:37:58.405Z","dependency_job_id":"010b3de6-e406-4a20-8653-09b1a6791de6","html_url":"https://github.com/bel-framework/bel-css","commit_stats":null,"previous_names":["bel-framework/bel-css"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/bel-framework/bel-css","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bel-framework%2Fbel-css","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bel-framework%2Fbel-css/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bel-framework%2Fbel-css/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bel-framework%2Fbel-css/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bel-framework","download_url":"https://codeload.github.com/bel-framework/bel-css/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bel-framework%2Fbel-css/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31046794,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-27T09:35:52.079Z","status":"ssl_error","status_checked_at":"2026-03-27T09:35:20.916Z","response_time":164,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["css","css-parser","css3","erlang","erlang-library","parser"],"created_at":"2024-09-24T21:49:57.598Z","updated_at":"2026-04-01T21:51:16.316Z","avatar_url":"https://github.com/bel-framework.png","language":"Erlang","funding_links":["https://github.com/sponsors/williamthome","https://www.buymeacoffee.com/williamthome"],"categories":[],"sub_categories":[],"readme":"# bel-framework/bel_css\n\nCSS utilities for Erlang.\n\n## Scanner and Parser\n\n### Example\n\n```erlang\n1\u003e Selectors = \"#foo \u003e .bar + div.k1.k2 [id='baz']:hello(2):not(:where(div))::before, #bar + .baz.fizz div.buzz\".\n\"#foo \u003e .bar + div.k1.k2 [id='baz']:hello(2):not(:where(div))::before, #bar + .baz.fizz div.buzz\".\n\n2\u003e {ok, Tokens, _} = bel_css:scan_css3(Selectors).\n{ok,[{hash,{1,1},\u003c\u003c\"foo\"\u003e\u003e},\n     {greater,{1,5}},\n     {space,{1,7}},\n     {'.',{1,8}},\n     {ident,{1,9},\u003c\u003c\"bar\"\u003e\u003e},\n     {plus,{1,12}},\n     {space,{1,14}},\n     {ident,{1,15},\u003c\u003c\"div\"\u003e\u003e},\n     {'.',{1,18}},\n     {ident,{1,19},\u003c\u003c\"k1\"\u003e\u003e},\n     {'.',{1,21}},\n     {ident,{1,22},\u003c\u003c\"k2\"\u003e\u003e},\n     {space,{1,24}},\n     {'[',{1,25}},\n     {ident,{1,26},\u003c\u003c\"id\"\u003e\u003e},\n     {'=',{1,28}},\n     {string,{1,29},\u003c\u003c\"baz\"\u003e\u003e},\n     {']',{1,34}},\n     {':',{1,35}},\n     {function,{1,36},\u003c\u003c\"hello\"\u003e\u003e},\n     {number,{1,42},\u003c\u003c\"2\"\u003e\u003e},\n     {')',{1,43}},\n     {'not',{1,44}},\n     {':',{1,49}},\n     {function,{1,50},\u003c\u003c\"where\"\u003e\u003e},\n     {ident,{1,56},\u003c\u003c\"div\"\u003e\u003e},\n     {')',{1,59}},\n     {')',{1,60}},\n     {':',{1,61}},\n     {':',{1,62}},\n     {ident,{1,63},\u003c\u003c\"before\"\u003e\u003e},\n     {comma,{1,69}},\n     {space,{1,70}},\n     {hash,{1,71},\u003c\u003c\"bar\"\u003e\u003e},\n     {plus,{1,75}},\n     {space,{1,77}},\n     {'.',{1,78}},\n     {ident,{1,79},\u003c\u003c\"baz\"\u003e\u003e},\n     {'.',{1,82}},\n     {ident,{1,83},\u003c\u003c\"fizz\"\u003e\u003e},\n     {space,{1,87}},\n     {ident,{1,88},\u003c\u003c\"div\"\u003e\u003e},\n     {'.',{1,91}},\n     {ident,{1,92},\u003c\u003c\"buzz\"\u003e\u003e}],\n    1}\n\n3\u003e bel_css:parse_css3(Tokens).\n{ok,[{greater,\n         {[{id,\u003c\u003c\"foo\"\u003e\u003e}],\n          {plus,\n              {[{class,\u003c\u003c\"bar\"\u003e\u003e}],\n               {space,\n                   {[{type,{undefined,\u003c\u003c\"div\"\u003e\u003e}},\n                     {class,\u003c\u003c\"k1\"\u003e\u003e},\n                     {class,\u003c\u003c\"k2\"\u003e\u003e}],\n                    [{attrib,{undefined,\u003c\u003c\"id\"\u003e\u003e,{'=',{string,\u003c\u003c\"baz\"\u003e\u003e}}}},\n                     {pseudo_class,{function,{\u003c\u003c\"hello\"\u003e\u003e,[{number,\u003c\u003c\"2\"\u003e\u003e}]}}},\n                     {negation,\n                         {pseudo_class,\n                             {function,{\u003c\u003c\"where\"\u003e\u003e,[{ident,\u003c\u003c\"div\"\u003e\u003e}]}}}},\n                     {pseudo_element,{ident,\u003c\u003c\"before\"\u003e\u003e}}]}}}}}},\n     {plus,\n         {[{id,\u003c\u003c\"bar\"\u003e\u003e}],\n          {space,\n              {[{class,\u003c\u003c\"baz\"\u003e\u003e},{class,\u003c\u003c\"fizz\"\u003e\u003e}],\n               [{type,{undefined,\u003c\u003c\"div\"\u003e\u003e}},{class,\u003c\u003c\"buzz\"\u003e\u003e}]}}}}]}\n```\n\n## Build\n\n```shell\n$ rebar3 compile\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbel-framework%2Fbel-css","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbel-framework%2Fbel-css","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbel-framework%2Fbel-css/lists"}