Commit Graph

5 Commits

Author SHA1 Message Date
Pierre-Louis
66cda5917d
Improve defaults generation with logging, stats, and token validation (#128244)
## Description

This improves defaults generation with logging, stats, and token validation. 

This PR includes these changes:
* introduce `TokenLogger`, with a verbose mode
  * prints versions and tokens usage to the console
  * outputs `generated/used_tokens.csv`, a list of all used tokens, for use by Google
* find token files in `data` automatically
* hide tokens `Map`
  * tokens can be obtained using existing resolvers (e.g. `color`, `shape`), or directly through `getToken`.
  * tokens can be checked for existence with `tokenAvailable`
* remove version from template, since the tokens are aggregated and multiple versions are possible (as is the case currently), it does not make sense to attribute a single version
* improve documentation

## Related Issues
 - Fixes https://github.com/flutter/flutter/issues/122602

## Tests
 - Added tests for `TokenLogger`
 - Regenerated tokens, no-op except version removal

## Future work
A future PR should replace or remove the following invalid tokens usages

<img width="578" alt="image" src="https://github.com/flutter/flutter/assets/6655696/b6f9e5a7-523f-4f72-94f9-1b0bf4cc9f00">
2023-06-09 11:28:18 +00:00
Taha Tesser
d24a28b806
Cleanup M3 token templates for theme lookups (#122601)
Cleanup M3 token templates for theme lookups
2023-03-14 17:01:13 +00:00
Eilidh Southren
d696b05165
Bottom appbar/sheet shadow property (#121406)
* add shadowColor property

* add to bottom app bar

* add test

* update m2/m3 diffs

* reorder debug test

* finalize

* remove crswap

* update doc comments

* add m2 shadow back

* add const

* update docs

* update docs

* comment replies

* make param non-null

* indentation fix

* doc fix
2023-03-06 11:41:59 +00:00
Darren Austin
96d7f9cb13
Updated tokens to v0_143. (#115890) 2022-11-27 22:08:48 -08:00
Darren Austin
6a66aa282f
Add Material 3 support for BottomAppBar (reland #106525) (#114439)
* Revert "Revert "Add Material 3 support for BottomAppBar" (#114421)"

This reverts commit 210a2aa371.

* Regenerated the defaults from tokens and fixed tests.

* Fixed the tests.

* Updated the shape token template to optimize the a common case.
2022-11-02 10:54:19 +00:00