Skip to content

Commit d96c511

Browse files
authored
[material_ui] Update out-of-date typography documentation (flutter#13372)
Updates out-of-date documentation for typography, which is missing reference to the 2021 theme (the current default). Fixes flutter#195013 ## Pre-Review Checklist **Text exemption:** Documentation changes only. **Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed. [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
1 parent d9db25a commit d96c511

2 files changed

Lines changed: 12 additions & 8 deletions

File tree

‎packages/material_ui/lib/src/typography.dart‎

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,15 +70,16 @@ enum ScriptCategory {
7070
/// font](https://developer.apple.com/design/human-interface-guidelines/typography/)
7171
/// fonts as used by Apple on iOS.
7272
///
73-
/// Two sets of geometry themes are provided: 2014 and 2018. The 2014 themes
74-
/// correspond to the original version of the Material Design spec and are
75-
/// the defaults. The 2018 themes correspond the second iteration of the
76-
/// specification and feature different font sizes, font weights, and
77-
/// letter spacing values.
73+
/// Three sets of geometry themes are provided: 2014, 2018, and 2021. The 2014
74+
/// themes correspond to the original version of the Material Design spec. The
75+
/// 2018 themes correspond to the second iteration of the specification and
76+
/// feature different font sizes, font weights, and letter spacing values. The
77+
/// 2021 themes correspond to the Material Design 3 specification.
7878
///
79-
/// By default, [ThemeData.typography] is `Typography.material2014(platform:
80-
/// platform)` which uses [englishLike2014], [dense2014] and [tall2014]. To use
81-
/// the 2018 text theme geometries, specify a value using the [Typography.material2018]
79+
/// By default, [ThemeData.typography] is `Typography.material2021(platform:
80+
/// platform, colorScheme: colorScheme)` (or `Typography.material2014(platform:
81+
/// platform)` when [ThemeData.useMaterial3] is false). To use the 2018 text
82+
/// theme geometries, specify a value using the [Typography.material2018]
8283
/// constructor:
8384
///
8485
/// ```dart
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
changelog: |
2+
- Updates the `Typography` documentation to describe the 2021 (Material 3) geometry themes and the current `ThemeData.typography` defaults.
3+
version: patch

0 commit comments

Comments
 (0)