diff --git a/packages/katana_theme/example/README.md b/packages/katana_theme/example/README.md index 13195e252..37b4b53cf 100644 --- a/packages/katana_theme/example/README.md +++ b/packages/katana_theme/example/README.md @@ -1,4 +1,4 @@ -# katana_listenables_example +# katana_theme_example A new Flutter project. diff --git a/packages/katana_theme/example/assets/Localization.csv b/packages/katana_theme/example/assets/Localization.csv new file mode 100644 index 000000000..393b75186 --- /dev/null +++ b/packages/katana_theme/example/assets/Localization.csv @@ -0,0 +1,235 @@ +Localization,1.0.0, +ID,ja:Japanese,en:English +#Apps,, +AppTitle,アプリタイトル,AppTitle +#General,, +Yes,はい,Yes +No,いいえ,No +OK,OK,Okay +Open,開く,Open +Close,閉じる,Close +Forward,進む,Forward +Back,戻る,Back +Next,次,Next +Prev,前,Prev +Complete,完了,Complete +Success,成功,Success +Error,エラー,Error +Warning,警告,Warning +Notice,注意,Notice +Confirmation,確認,Confirmation +Refresh,更新,Refresh +Resend,再送信,Resend +Retry,リトライ,Retry +Quit,終了,Quit +Property,プロパティ,Property +All day,終日,All day +Others,その他,Others +Setting,設定,Setting +Config,設定,Config +Post,投稿,Post +Submit,決定,Submit +Save,保存,Save +Add,追加,Add +New,新規,New +Remove,削除,Remove +Delete,削除,Delete +Invite,招待,Invite +User,ユーザー,User +Content,コンテンツ,Content +Member,メンバー,Member +Account,アカウント,Account +Editing,編集,Editing +Deletion,削除,Deletion +%s list,%sリスト,%s list +Under maintenance,メンテナンス中,Under maintenance +%s is completed.,%sが完了しました。,%s is completed. +%s is not completed.,%sに失敗しました。,%s is not completed. +You can't undo it after deleting it. May I delete it?,削除した後、元に戻すことはできません。削除してもよろしいでしょうか?,You can't undo it after deleting it. May I delete it? +The app is currently under maintenance. Detailed information on maintenance will be announced on the official website.,現在アプリはメンテナンス中です。メンテナンスの詳しい情報は公式サイトでお知らせいたします。,The app is currently under maintenance. Detailed information on maintenance will be announced on the official website. +Please update,アップデートしてください,Please update +App update required. Get the latest version from the store.,アプリのアップデートが必要です。ストアから最新版を入手してください。,App update required. Get the latest version from the store. +Search Users,ユーザーを検索,Search Users +Terms,利用規約,Terms of use +Privacy Policy,プライバシーポリシー,Privacy policy +A new entry,新規追加,A new entry +Editing %s,%sの編集,Editing %s +#Language,, +Japanese,日本語,Japanese +English,英語,English +Chinese,中国語,Chinese +ChineseTraditional,中国語(繁体),Chinese (Traditional) +ChineseSimplified,中国語(簡体),Chinese (Simplified) +French,フランス語,French +Spanish,スペイン語,Spanish +Korean,韓国語,Korean +Indonesian,インドネシア語,Indonesian +Thai,タイ語,Thai +Arabic,アラビア語,Arabic +Russian,ロシア語,Russian +German,ドイツ語,German +Italian,イタリア語,Italian +Portuguese,ポルトガル語,Portuguese +#WeekDay,, +WeekDay1,月曜日,Monday +WeekDay2,火曜日,Tuesday +WeekDay3,水曜日,Wednesday +WeekDay4,木曜日,Thursday +WeekDay5,金曜日,Friday +WeekDay6,土曜日,Saturday +WeekDay7,日曜日,Sunday +Week1,月,Mon +Week2,火,Tue +Week3,水,Wed +Week4,木,Thu +Week5,金,Fri +Week6,土,Sat +Week7,日,Sun +Yesterday,昨日,Yesterday +Today,今日,Today +Tomorrow,明日,Tomorrow +#AppConfig,, +Used for upload material by taking pictures and video communication.,カメラ撮影による素材のアップロード及びビデオコミュニケーションに利用します。,Used for upload material by taking pictures and video communication. +Used for upload material by recording and video and audio communications.,録音による素材のアップロード及びビデオ・オーディオコミュニケーションに利用します。,Used for upload material by recording and video and audio communications. +Used for map services.,マップサービスのために利用します。,Used for map services. +Used for upload material.,素材のアップロードのために利用します。,Used for upload material. +Used for processing materials.,素材の加工のために利用します。,Used for processing materials. +Used for data sharing.,データ共有のために利用します。,Used for data sharing. +Used to read/write schedule data.,スケジュールデータの読取/書込のために利用します。,Used to read/write schedule data. +Used for schedule reminders.,スケジュールのリマインダのために利用します。,Used for schedule reminders. +Used for data transmission and audio playback.,データ送信及びオーディオの再生のために利用します。,Used for data transmission and audio playback. +Used for playing music.,音楽の再生のために利用します。,Used for playing music. +Used for voice input.,音声入力のために利用します。,Used for voice input. +Used for access analysis for the purpose of UI/UX improvement.,UI・UX改善を目的としたアクセス解析のために利用します。,Used for access analysis for the purpose of UI/UX improvement. +#Auth,, +This notification channel is used for important notifications.,この通知チャンネルは重要な通知に利用されます。,This notification channel is used for important notifications. +#Auth,, +Login,ログイン,Login +Logout,ログアウト,Logout +Registration,ユーザー登録,Registration +%s registration,%sの登録,Registration of %s +Change Email,メールアドレス変更,Change Email +Change Password,パスワード変更,Change Password +Account deletion,アカウント削除,Account deletion +Google SignIn,Googleアカウント,Google Account +Twitter SignIn,Twitterアカウント,Twitter Account +Facebook SignIn,Facebookアカウント,Facebook Account +Apple SignIn,Appleアカウント,Apple Account +Email & Password SignIn,メール&パスワード,Email & Password +Anonymous SingIn,ログインしない,Do not log-in +Reauthentication,再認証,Reauthentication +Email,メールアドレス,Email +Password,パスワード,Password +ConfirmationPassword,パスワード(確認用),Password (Confirmation) +Click here if you forget your password,パスワードを忘れた場合はこちら,Click here if you forget your password +Please enter your login information again,再度ログイン情報を入力してください,Please enter your login information again +Please enter the information you want to change,変更したい情報を入力してください,Please enter the information you want to change +Edit Profile,プロフィール編集,Edit Profile +Password reset,パスワードリセット,Password reset +Verifying email address,メールアドレス確認中,Verifying email address +Send mail,メール送信,Send mail +Please authenticate your email,メールを認証してください,Please authenticate your email +Agree to the %s,%sに同意する,Agree to the %s +Please agree to the %s,%sに同意してください,Please agree to the %s +Currently sending a verification email to your registered email address. Please open the link in the email to complete the email verification process.,登録されたメールアドレスに現在認証メールを送信しております。メールに記載されたリンクを開いてメール認証を完了してください。,Currently sending a verification email to your registered email address. Please open the link in the email to complete the email verification process. +"To send an authentication email again, press the ''Resend'' button. If the screen does not change after authentication, press the ''Refresh'' button. If you want to log in with another account, press the ''Logout'' button.",再度認証メールを送る場合は「再送信」ボタンを、認証後画面が切り替わらない場合は「更新」ボタンを、別のアカウントでログインしたい場合は「ログアウト」ボタンを押してください。,"To send an authentication email again, press the ''Resend'' button. If the screen does not change after authentication, press the ''Refresh'' button. If you want to log in with another account, press the ''Logout'' button." +Confirmation email has been sent to your registered email address. Your registration will be completed once we have received your email address.,登録したメールアドレス宛に確認のメールを送信しました。メールアドレスの確認が取れた後登録完了となります。,Confirmation email has been sent to your registered email address. Your registration will be completed once we have received your email address. +Resent the confirmation email.,確認用のメールを再送信しました。,Resent the confirmation email. +Registration has been completed.,登録が完了しました。,Registration has been completed. +"The account is deleted. After deleting the account, it cannot be restored. Are you sure?",アカウントを削除します。アカウントを削除後元に戻すことはできません。よろしいですか?,"The account is deleted. After deleting the account, it cannot be restored. Are you sure?" +Account deletion is complete.,アカウントの削除が完了しました。,Account deletion is complete. +You're logging out. Are you sure?,ログアウトします。よろしいですか?,You're logging out. Are you sure? +Logout is complete.,ログアウトが完了しました。,Logout is complete. +Passwords do not match.,パスワードが一致しません。,Passwords do not match. +Could not register. It may already be registered. Please check your email address and password again.,登録できませんでした。すでに登録されている可能性があります。メールアドレスとパスワードを再度確認してください。,Could not register. It may already be registered. Please check your email address and password again. +Could not login. Please check your email address and password.,ログインできませんでした。メールアドレスとパスワードを確認してください。,Could not login. Please check your email address and password. +Email to reset your password will be sent to the email address you specified. Please reset your password from the link in the email you received.,指定したメールアドレスにパスワードリセット用のメールを送信します。届いたメールのリンクからパスワードをリセットしてください。,Email to reset your password will be sent to the email address you specified. Please reset your password from the link in the email you received. +The specified email address did not exist. Please check your email address.,指定したメールアドレスが存在しませんでした。メールアドレスをご確認ください。,The specified email address did not exist. Please check your email address. +Password reset email has been sent to the specified email address. Please login again after resetting the password.,指定したメールアドレスにパスワードリセット用のメールを送信しました。パスワードリセット後再度ログインしてください。,Password reset email has been sent to the specified email address. Please login again after resetting the password. +#Users,, +%s san,%sさん,%s +Follow,フォローする,Follow +Unfollow,フォロー解除,Unfollow +Followers,フォロワー,Followers +Report,通報する,Report +Block,ブロックする,Block +#Actions,, +You will block this %s. Are you sure?,この%sをブロックします。よろしいですか?,You will block this %s. Are you sure? +You will unblock this %s. Are you sure?,この%sをブロックから外します。よろしいですか?,You will unblock this %s. Are you sure? +You will report this %s. Are you sure?,この%sを通報します。よろしいですか?,You will report this %s. Are you sure? +You will delete this %s. Are you sure?,この%sを削除します。よろしいですか?,You will delete this %s. Are you sure? +You will remove this %s from the list. Are you sure?,この%sをリストから削除します。よろしいですか?,You will remove this %s from the list. Are you sure? +You have reported this %s.,この%sを通報しました。,You have reported this %s. +You have blocked this %s.,この%sをブロックしました。,You have blocked this %s. +You have unblocked this %s.,この%sをブロックから外しました。,You have unblocked this %s. +You have deleted this %s.,この%sを削除しました。,You have deleted this %s. +You have removed this %s from the list.,この%sをリストから削除しました。,You have removed this %s from the list. +This %s has already been reported.,この%sはすでに通報されています。,This %s has already been reported. +This %s has already been blocked.,この%sはすでにブロックされています。,This %s has already been blocked. +This %s has already been deleted.,この%sはすでに削除されています。,This %s has already been deleted. +This %s has already been removed.,この%sはすでに削除されています。,This %s has already been removed. +#Assets,, +Media,メディア,Media +Image,画像,Image +Video,ビデオ,Video +Text,テキスト,Text +Audio,オーディオ,Audio +Taken with camera,カメラで撮影,Taken with camera +Read from library,ライブラリーから読み込み,Read from library +%s's Video,%sの動画,%s's Video +%s's Image,%sの画像,%s's Image +#Form,, +Input %s,%sを入力してください,Input %s +Select %s,%sを選択してください,Select %s +No input %s,%sが入力されていません,%s is empty +No select %s,%sが選択されていません,%s is not selected +Please input your %s,%sを入力してください,Please input your %s +Please select your %s,%sを選択してください,Please select your %s +#Attribute,, +Name,名前,Name +Title,タイトル,Title +Text,テキスト,Text +Description,説明,Description +Contents,コンテンツ,Contents +URL,URL,URL +Category,カテゴリー,Category +Tag,タグ,Tag +Post time,投稿日時,Post time +Date,日付,Date +Time,時間,Time +Start date,開始日時,Start date +End date,終了日時,End date +Choices,選択肢,Choices +Required,必須,Required +Optional,任意,Optional +Type,タイプ,Type +Mode,モード,Mode +#Location,, +Location service not available. The platform may not be supported or it may be disabled in the settings. please confirm.,位置情報サービスが使用できません。プラットフォームが対応していないか設定で無効化されている場合があります。ご確認ください。,Location service not available. The platform may not be supported or it may be disabled in the settings. please confirm. +You are not authorized to use the location information service. Check the permission settings.,位置情報サービスの権限がありません。パーミッションの設定を確認してください。,You are not authorized to use the location information service. Check the permission settings. +#Error,, +No data.,データがありません。,No data. +No %s.,%sがありません。,No %s. +Unknown error.,不明なエラーです。,Unknown error. +Invalid error.,不正な処理です。,Invalid error. +Please enter some text,なにか文字を入力してください,Please enter some text +Timed out.,タイムアウトしました。,Timed out. +Unable to connect to the network.,ネットワークに接続できません。,Unable to connect to the network. +Unable to connect to the network. Application is quit.,ネットワークに接続できません。アプリを終了します。,Unable to connect to the network. Application is quit. +You could not log in because the communication environment was bad. Please try again.,通信環境が悪いためログインが完了しませんでした。リトライしてください。,You could not log in because the communication environment was bad. Please try again. +Initialization failed. Application is quit.,初期化に失敗しました。アプリを終了します。,Initialization failed. Application is quit. +The login process could not be performed. Please try again.,ログインが完了しませんでした。リトライしてください。,The login process could not be performed. Please try again. +Please input at least %s characters.,%s文字以上入力してください。,Please input at least %s characters. +The end date and time must be a time after the start date and time.,終了日時は開始日時より後の時間を指定してください。,The end date and time must be a time after the start date and time. +#Module,, +Question,設問,Question +Answer,回答,Answer +Already responding,回答済み,Already responding +Deadline %s,アンケート期限 %s,Deadline %s +Question No.%s,設問 No.%s,Question No.%s +List of %s answers,%sの回答一覧,List of %s answers +%s answers,%sの回答,%s answers +The question is empty. Please set a new question by clicking the 'Add New' button.,設問は空です。新規追加ボタンから新しく設問を設定してください。,The question is empty. Please set a new question by clicking the 'Add New' button. +The question has not been set yet. Please wait for a while until the question is set.,まだ設問が設定されていません。設問が設定されるまでしばらくお待ち下さい。,The question has not been set yet. Please wait for a while until the question is set. +An invitation email will be sent to the email address you entered. You can complete the invitation by clicking the link in the invitation email.,入力したメールアドレスに招待メールが届きます。招待メールに記載されたリンクをクリックしていただくことで招待が完了します。,An invitation email will be sent to the email address you entered. You can complete the invitation by clicking the link in the invitation email. +#Apps,, \ No newline at end of file diff --git a/packages/katana_theme/example/assets/background.jpg b/packages/katana_theme/example/assets/background.jpg new file mode 100644 index 000000000..1be205a82 Binary files /dev/null and b/packages/katana_theme/example/assets/background.jpg differ diff --git a/packages/katana_theme/example/assets/default_icon.png b/packages/katana_theme/example/assets/default_icon.png new file mode 100644 index 000000000..1d100d84d Binary files /dev/null and b/packages/katana_theme/example/assets/default_icon.png differ diff --git a/packages/katana_theme/example/assets/fonts/NotoSerifJP-Regular.otf b/packages/katana_theme/example/assets/fonts/NotoSerifJP-Regular.otf new file mode 100644 index 000000000..541a86b62 Binary files /dev/null and b/packages/katana_theme/example/assets/fonts/NotoSerifJP-Regular.otf differ diff --git a/packages/katana_theme/example/assets/icon.png b/packages/katana_theme/example/assets/icon.png new file mode 100644 index 000000000..8d7a16660 Binary files /dev/null and b/packages/katana_theme/example/assets/icon.png differ diff --git a/packages/katana_theme/example/ios/Flutter/Debug.xcconfig b/packages/katana_theme/example/ios/Flutter/Debug.xcconfig index 592ceee85..ec97fc6f3 100644 --- a/packages/katana_theme/example/ios/Flutter/Debug.xcconfig +++ b/packages/katana_theme/example/ios/Flutter/Debug.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" #include "Generated.xcconfig" diff --git a/packages/katana_theme/example/ios/Flutter/Release.xcconfig b/packages/katana_theme/example/ios/Flutter/Release.xcconfig index 592ceee85..c4855bfe2 100644 --- a/packages/katana_theme/example/ios/Flutter/Release.xcconfig +++ b/packages/katana_theme/example/ios/Flutter/Release.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" #include "Generated.xcconfig" diff --git a/packages/katana_theme/example/ios/Podfile b/packages/katana_theme/example/ios/Podfile new file mode 100644 index 000000000..88359b225 --- /dev/null +++ b/packages/katana_theme/example/ios/Podfile @@ -0,0 +1,41 @@ +# Uncomment this line to define a global platform for your project +# platform :ios, '11.0' + +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. +ENV['COCOAPODS_DISABLE_STATS'] = 'true' + +project 'Runner', { + 'Debug' => :debug, + 'Profile' => :release, + 'Release' => :release, +} + +def flutter_root + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) + unless File.exist?(generated_xcode_build_settings_path) + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" + end + + File.foreach(generated_xcode_build_settings_path) do |line| + matches = line.match(/FLUTTER_ROOT\=(.*)/) + return matches[1].strip if matches + end + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" +end + +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) + +flutter_ios_podfile_setup + +target 'Runner' do + use_frameworks! + use_modular_headers! + + flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) +end + +post_install do |installer| + installer.pods_project.targets.each do |target| + flutter_additional_ios_build_settings(target) + end +end diff --git a/packages/katana_theme/example/ios/Podfile.lock b/packages/katana_theme/example/ios/Podfile.lock new file mode 100644 index 000000000..746f0889e --- /dev/null +++ b/packages/katana_theme/example/ios/Podfile.lock @@ -0,0 +1,22 @@ +PODS: + - Flutter (1.0.0) + - path_provider_ios (0.0.1): + - Flutter + +DEPENDENCIES: + - Flutter (from `Flutter`) + - path_provider_ios (from `.symlinks/plugins/path_provider_ios/ios`) + +EXTERNAL SOURCES: + Flutter: + :path: Flutter + path_provider_ios: + :path: ".symlinks/plugins/path_provider_ios/ios" + +SPEC CHECKSUMS: + Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 + path_provider_ios: 14f3d2fd28c4fdb42f44e0f751d12861c43cee02 + +PODFILE CHECKSUM: ef19549a9bc3046e7bb7d2fab4d021637c0c58a3 + +COCOAPODS: 1.11.3 diff --git a/packages/katana_theme/example/ios/Runner.xcodeproj/project.pbxproj b/packages/katana_theme/example/ios/Runner.xcodeproj/project.pbxproj index 37811ece2..2548c49e2 100644 --- a/packages/katana_theme/example/ios/Runner.xcodeproj/project.pbxproj +++ b/packages/katana_theme/example/ios/Runner.xcodeproj/project.pbxproj @@ -9,6 +9,7 @@ /* Begin PBXBuildFile section */ 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; + 4156FC010F2832F9DCC9F7EB /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9A7710B75AC0BC14927D1C2A /* Pods_Runner.framework */; }; 74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; }; 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; @@ -42,6 +43,10 @@ 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 9A35E8C26B41CE3072D29944 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; }; + 9A7710B75AC0BC14927D1C2A /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + C6B114DBCC57008EEDF12E23 /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; }; + E8F809518DB69E904D8AC26C /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -49,12 +54,21 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 4156FC010F2832F9DCC9F7EB /* Pods_Runner.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ + 127C5F1D46F53DA020BA5EC9 /* Frameworks */ = { + isa = PBXGroup; + children = ( + 9A7710B75AC0BC14927D1C2A /* Pods_Runner.framework */, + ); + name = Frameworks; + sourceTree = ""; + }; 9740EEB11CF90186004384FC /* Flutter */ = { isa = PBXGroup; children = ( @@ -72,6 +86,8 @@ 9740EEB11CF90186004384FC /* Flutter */, 97C146F01CF9000F007C117D /* Runner */, 97C146EF1CF9000F007C117D /* Products */, + B82730F705ABA070FF9A372E /* Pods */, + 127C5F1D46F53DA020BA5EC9 /* Frameworks */, ); sourceTree = ""; }; @@ -98,6 +114,17 @@ path = Runner; sourceTree = ""; }; + B82730F705ABA070FF9A372E /* Pods */ = { + isa = PBXGroup; + children = ( + 9A35E8C26B41CE3072D29944 /* Pods-Runner.debug.xcconfig */, + E8F809518DB69E904D8AC26C /* Pods-Runner.release.xcconfig */, + C6B114DBCC57008EEDF12E23 /* Pods-Runner.profile.xcconfig */, + ); + name = Pods; + path = Pods; + sourceTree = ""; + }; /* End PBXGroup section */ /* Begin PBXNativeTarget section */ @@ -105,12 +132,14 @@ isa = PBXNativeTarget; buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; buildPhases = ( + 5F888FA9A1C71157EEDCB88B /* [CP] Check Pods Manifest.lock */, 9740EEB61CF901F6004384FC /* Run Script */, 97C146EA1CF9000F007C117D /* Sources */, 97C146EB1CF9000F007C117D /* Frameworks */, 97C146EC1CF9000F007C117D /* Resources */, 9705A1C41CF9048500538489 /* Embed Frameworks */, 3B06AD1E1E4923F5004D2608 /* Thin Binary */, + 156B88983ADCA4785D5372EE /* [CP] Embed Pods Frameworks */, ); buildRules = ( ); @@ -169,6 +198,23 @@ /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ + 156B88983ADCA4785D5372EE /* [CP] Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Embed Pods Frameworks"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -183,6 +229,28 @@ shellPath = /bin/sh; shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; }; + 5F888FA9A1C71157EEDCB88B /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; 9740EEB61CF901F6004384FC /* Run Script */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; diff --git a/packages/katana_theme/example/ios/Runner.xcworkspace/contents.xcworkspacedata b/packages/katana_theme/example/ios/Runner.xcworkspace/contents.xcworkspacedata index 1d526a16e..21a3cc14c 100644 --- a/packages/katana_theme/example/ios/Runner.xcworkspace/contents.xcworkspacedata +++ b/packages/katana_theme/example/ios/Runner.xcworkspace/contents.xcworkspacedata @@ -4,4 +4,7 @@ + + diff --git a/packages/katana_theme/example/lib/main.dart b/packages/katana_theme/example/lib/main.dart index 72218b4d1..02d1eb80e 100644 --- a/packages/katana_theme/example/lib/main.dart +++ b/packages/katana_theme/example/lib/main.dart @@ -1,9 +1,18 @@ +import 'package:flutter/services.dart'; +import 'package:flutter_svg/flutter_svg.dart'; import 'package:katana_theme/katana_theme.dart'; import 'package:flutter/material.dart'; part 'main.theme.dart'; +@appTheme +final theme = AppThemeData.light( + primary: Colors.red, + secondary: Colors.orange, + tertiary: Colors.teal, +); + void main() { runApp(const MyApp()); } @@ -13,11 +22,66 @@ class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { - return MaterialApp( - home: const ListenablePage(), - title: "Flutter Demo", - theme: ThemeData( - primarySwatch: Colors.blue, + return AppThemeScope( + theme: theme, + child: MaterialApp( + home: const MyHomePage( + title: "Flutter Demo", + ), + title: "Flutter Demo", + theme: theme.toThemeData( + defaultFontFamily: theme.font.notoSerifJP, + ), + ), + ); + } +} + +@immutable +class MyHomePage extends StatefulWidget { + const MyHomePage({super.key, required this.title}); + + final String title; + + @override + State createState() => _MyHomePageState(); +} + +class _MyHomePageState extends State { + int _counter = 0; + + void _incrementCounter() { + setState(() { + _counter++; + }); + } + + @override + Widget build(BuildContext context) { + return Scaffold( + appBar: AppBar( + title: Text(widget.title), + ), + body: Center( + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Text( + "You have pushed the button this many times:", + style: theme.text.labelMedium, + ), + Text( + "$_counter", + style: theme.text.displayMedium, + ), + ], + ), + ), + floatingActionButton: FloatingActionButton( + backgroundColor: theme.color.tertiary, + onPressed: _incrementCounter, + tooltip: "Increment", + child: Icon(Icons.add, color: theme.color.onTertiary), ), ); } diff --git a/packages/katana_theme/example/lib/main.theme.dart b/packages/katana_theme/example/lib/main.theme.dart new file mode 100644 index 000000000..814e1a854 --- /dev/null +++ b/packages/katana_theme/example/lib/main.theme.dart @@ -0,0 +1,58 @@ +// ignore_for_file: unused_field, unused_element, require_trailing_commas, prefer_const_constructors, unnecessary_overrides, prefer_const_literals_to_create_immutables, unnecessary_null_in_if_null_operators, library_prefixes, directives_ordering, no_leading_underscores_for_local_identifiers, unnecessary_brace_in_string_interps, unnecessary_type_check, library_private_types_in_public_api + +part of 'main.dart'; + +// ************************************************************************** +// ThemeGenerator +// ************************************************************************** + +extension $ThemeAssetsExtensions on AssetThemeData { + _$01208c4b24c6b5e728eca36851bc335174a144dc get icon => + const _$01208c4b24c6b5e728eca36851bc335174a144dc(); + _$f06c88961712f1c49d6696007c8b6c3da5a53947 get localization => + const _$f06c88961712f1c49d6696007c8b6c3da5a53947(); + _$a5ad3eaf62869fd7eb3d770139e27947e8686dd1 get background => + const _$a5ad3eaf62869fd7eb3d770139e27947e8686dd1(); + _$021a869279104ac41a650f69ae9eb60afb135864 get defaultIcon => + const _$021a869279104ac41a650f69ae9eb60afb135864(); +} + +extension $FontAssetsExtensions on FontThemeData { + String get notoSerifJP => "NotoSerifJP"; +} + +extension $FontTextStyleExtensions on TextStyle { + TextStyle withNotoSerifJPFont() => copyWith(fontFamily: "NotoSerifJP"); +} + +class _$01208c4b24c6b5e728eca36851bc335174a144dc { + const _$01208c4b24c6b5e728eca36851bc335174a144dc(); + + final path = "assets/icon.png"; + + ImageProvider get provider => AssetImage(path); +} + +class _$f06c88961712f1c49d6696007c8b6c3da5a53947 { + const _$f06c88961712f1c49d6696007c8b6c3da5a53947(); + + final path = "assets/Localization.csv"; + + TextProvider get provider => AssetTextProvider(path); +} + +class _$a5ad3eaf62869fd7eb3d770139e27947e8686dd1 { + const _$a5ad3eaf62869fd7eb3d770139e27947e8686dd1(); + + final path = "assets/background.jpg"; + + ImageProvider get provider => AssetImage(path); +} + +class _$021a869279104ac41a650f69ae9eb60afb135864 { + const _$021a869279104ac41a650f69ae9eb60afb135864(); + + final path = "assets/default_icon.png"; + + ImageProvider get provider => AssetImage(path); +} diff --git a/packages/katana_theme/example/macos/Flutter/Flutter-Debug.xcconfig b/packages/katana_theme/example/macos/Flutter/Flutter-Debug.xcconfig index c2efd0b60..4b81f9b2d 100644 --- a/packages/katana_theme/example/macos/Flutter/Flutter-Debug.xcconfig +++ b/packages/katana_theme/example/macos/Flutter/Flutter-Debug.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" #include "ephemeral/Flutter-Generated.xcconfig" diff --git a/packages/katana_theme/example/macos/Flutter/Flutter-Release.xcconfig b/packages/katana_theme/example/macos/Flutter/Flutter-Release.xcconfig index c2efd0b60..5caa9d157 100644 --- a/packages/katana_theme/example/macos/Flutter/Flutter-Release.xcconfig +++ b/packages/katana_theme/example/macos/Flutter/Flutter-Release.xcconfig @@ -1 +1,2 @@ +#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" #include "ephemeral/Flutter-Generated.xcconfig" diff --git a/packages/katana_theme/example/macos/Podfile b/packages/katana_theme/example/macos/Podfile new file mode 100644 index 000000000..dade8dfad --- /dev/null +++ b/packages/katana_theme/example/macos/Podfile @@ -0,0 +1,40 @@ +platform :osx, '10.11' + +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. +ENV['COCOAPODS_DISABLE_STATS'] = 'true' + +project 'Runner', { + 'Debug' => :debug, + 'Profile' => :release, + 'Release' => :release, +} + +def flutter_root + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__) + unless File.exist?(generated_xcode_build_settings_path) + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first" + end + + File.foreach(generated_xcode_build_settings_path) do |line| + matches = line.match(/FLUTTER_ROOT\=(.*)/) + return matches[1].strip if matches + end + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\"" +end + +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) + +flutter_macos_podfile_setup + +target 'Runner' do + use_frameworks! + use_modular_headers! + + flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__)) +end + +post_install do |installer| + installer.pods_project.targets.each do |target| + flutter_additional_macos_build_settings(target) + end +end diff --git a/packages/katana_theme/example/macos/Podfile.lock b/packages/katana_theme/example/macos/Podfile.lock new file mode 100644 index 000000000..c21cdc749 --- /dev/null +++ b/packages/katana_theme/example/macos/Podfile.lock @@ -0,0 +1,22 @@ +PODS: + - FlutterMacOS (1.0.0) + - path_provider_macos (0.0.1): + - FlutterMacOS + +DEPENDENCIES: + - FlutterMacOS (from `Flutter/ephemeral`) + - path_provider_macos (from `Flutter/ephemeral/.symlinks/plugins/path_provider_macos/macos`) + +EXTERNAL SOURCES: + FlutterMacOS: + :path: Flutter/ephemeral + path_provider_macos: + :path: Flutter/ephemeral/.symlinks/plugins/path_provider_macos/macos + +SPEC CHECKSUMS: + FlutterMacOS: ae6af50a8ea7d6103d888583d46bd8328a7e9811 + path_provider_macos: 3c0c3b4b0d4a76d2bf989a913c2de869c5641a19 + +PODFILE CHECKSUM: 6eac6b3292e5142cfc23bdeb71848a40ec51c14c + +COCOAPODS: 1.11.3 diff --git a/packages/katana_theme/example/macos/Runner.xcodeproj/project.pbxproj b/packages/katana_theme/example/macos/Runner.xcodeproj/project.pbxproj index 3e49af945..fa9a30b90 100644 --- a/packages/katana_theme/example/macos/Runner.xcodeproj/project.pbxproj +++ b/packages/katana_theme/example/macos/Runner.xcodeproj/project.pbxproj @@ -26,6 +26,7 @@ 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F22044A3C60003C045 /* Assets.xcassets */; }; 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; }; 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; }; + 5458D1F53F4EE6B7A354F92A /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D527DE178CA2DDAB038E0D71 /* Pods_Runner.framework */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -52,9 +53,10 @@ /* End PBXCopyFilesBuildPhase section */ /* Begin PBXFileReference section */ + 1C401C8D9854713B8ADDB2CC /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; }; 333000ED22D3DE5D00554162 /* Warnings.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Warnings.xcconfig; sourceTree = ""; }; 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GeneratedPluginRegistrant.swift; sourceTree = ""; }; - 33CC10ED2044A3C60003C045 /* katana_router_example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "katana_router_example.app"; sourceTree = BUILT_PRODUCTS_DIR; }; + 33CC10ED2044A3C60003C045 /* katana_router_example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = katana_router_example.app; sourceTree = BUILT_PRODUCTS_DIR; }; 33CC10F02044A3C60003C045 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 33CC10F22044A3C60003C045 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assets.xcassets; path = Runner/Assets.xcassets; sourceTree = ""; }; 33CC10F52044A3C60003C045 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/MainMenu.xib; sourceTree = ""; }; @@ -67,7 +69,10 @@ 33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = ""; }; 33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = ""; }; 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = ""; }; + 8486B1DEFC93FE2843A3EBE0 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = ""; }; 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Debug.xcconfig; sourceTree = ""; }; + BF82CA1B2485AFEE8ECAFE5D /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = ""; }; + D527DE178CA2DDAB038E0D71 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -75,6 +80,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 5458D1F53F4EE6B7A354F92A /* Pods_Runner.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -99,6 +105,7 @@ 33CEB47122A05771004F2AC0 /* Flutter */, 33CC10EE2044A3C60003C045 /* Products */, D73912EC22F37F3D000D13A0 /* Frameworks */, + 8CA487614F17BAECFA16E719 /* Pods */, ); sourceTree = ""; }; @@ -145,9 +152,21 @@ path = Runner; sourceTree = ""; }; + 8CA487614F17BAECFA16E719 /* Pods */ = { + isa = PBXGroup; + children = ( + 1C401C8D9854713B8ADDB2CC /* Pods-Runner.debug.xcconfig */, + 8486B1DEFC93FE2843A3EBE0 /* Pods-Runner.release.xcconfig */, + BF82CA1B2485AFEE8ECAFE5D /* Pods-Runner.profile.xcconfig */, + ); + name = Pods; + path = Pods; + sourceTree = ""; + }; D73912EC22F37F3D000D13A0 /* Frameworks */ = { isa = PBXGroup; children = ( + D527DE178CA2DDAB038E0D71 /* Pods_Runner.framework */, ); name = Frameworks; sourceTree = ""; @@ -159,11 +178,13 @@ isa = PBXNativeTarget; buildConfigurationList = 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */; buildPhases = ( + BAF51BF7E01208AB90D256EE /* [CP] Check Pods Manifest.lock */, 33CC10E92044A3C60003C045 /* Sources */, 33CC10EA2044A3C60003C045 /* Frameworks */, 33CC10EB2044A3C60003C045 /* Resources */, 33CC110E2044A8840003C045 /* Bundle Framework */, 3399D490228B24CF009A79C7 /* ShellScript */, + 13372119614E76DC23304FA0 /* [CP] Embed Pods Frameworks */, ); buildRules = ( ); @@ -233,6 +254,23 @@ /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ + 13372119614E76DC23304FA0 /* [CP] Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Embed Pods Frameworks"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; 3399D490228B24CF009A79C7 /* ShellScript */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -270,6 +308,28 @@ shellPath = /bin/sh; shellScript = "\"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh && touch Flutter/ephemeral/tripwire"; }; + BAF51BF7E01208AB90D256EE /* [CP] Check Pods Manifest.lock */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; + outputFileListPaths = ( + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + showEnvVarsInLog = 0; + }; /* End PBXShellScriptBuildPhase section */ /* Begin PBXSourcesBuildPhase section */ diff --git a/packages/katana_theme/example/macos/Runner.xcworkspace/contents.xcworkspacedata b/packages/katana_theme/example/macos/Runner.xcworkspace/contents.xcworkspacedata index 1d526a16e..21a3cc14c 100644 --- a/packages/katana_theme/example/macos/Runner.xcworkspace/contents.xcworkspacedata +++ b/packages/katana_theme/example/macos/Runner.xcworkspace/contents.xcworkspacedata @@ -4,4 +4,7 @@ + + diff --git a/packages/katana_theme/example/pubspec.lock b/packages/katana_theme/example/pubspec.lock index 3f00229e3..1ab9e677e 100644 --- a/packages/katana_theme/example/pubspec.lock +++ b/packages/katana_theme/example/pubspec.lock @@ -7,14 +7,14 @@ packages: name: _fe_analyzer_shared url: "https://pub.dartlang.org" source: hosted - version: "49.0.0" + version: "50.0.0" analyzer: dependency: transitive description: name: analyzer url: "https://pub.dartlang.org" source: hosted - version: "5.1.0" + version: "5.2.0" args: dependency: transitive description: @@ -28,7 +28,7 @@ packages: name: asn1lib url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.4.0" async: dependency: transitive description: @@ -70,7 +70,7 @@ packages: name: build_resolvers url: "https://pub.dartlang.org" source: hosted - version: "2.0.10" + version: "2.1.0" build_runner: dependency: "direct dev" description: @@ -84,7 +84,7 @@ packages: name: build_runner_core url: "https://pub.dartlang.org" source: hosted - version: "7.2.6" + version: "7.2.7" built_collection: dependency: transitive description: @@ -98,7 +98,7 @@ packages: name: built_value url: "https://pub.dartlang.org" source: hosted - version: "8.4.1" + version: "8.4.2" characters: dependency: transitive description: @@ -202,6 +202,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.0.1" + flutter_svg: + dependency: "direct main" + description: + name: flutter_svg + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.6" flutter_test: dependency: "direct dev" description: flutter @@ -220,7 +227,7 @@ packages: name: glob url: "https://pub.dartlang.org" source: hosted - version: "2.1.0" + version: "2.1.1" graphs: dependency: transitive description: @@ -283,28 +290,28 @@ packages: name: katana url: "https://pub.dartlang.org" source: hosted - version: "0.15.6" - katana_listenables: + version: "0.15.10" + katana_theme: dependency: "direct main" description: path: ".." relative: true source: path - version: "1.1.2" - katana_listenables_annotation: - dependency: "direct overridden" + version: "1.1.5" + katana_theme_annotation: + dependency: transitive description: - path: "../../katana_listenables_annotation" - relative: true - source: path - version: "1.1.1" - katana_listenables_builder: + name: katana_theme_annotation + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.5" + katana_theme_builder: dependency: "direct dev" description: - path: "../../katana_listenables_builder" + path: "../../katana_theme_builder" relative: true source: path - version: "1.1.2" + version: "1.1.5" lints: dependency: transitive description: @@ -361,6 +368,27 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.8.2" + path_drawing: + dependency: transitive + description: + name: path_drawing + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.1" + path_parsing: + dependency: transitive + description: + name: path_parsing + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.1" + petitparser: + dependency: transitive + description: + name: petitparser + url: "https://pub.dartlang.org" + source: hosted + version: "5.1.0" pointycastle: dependency: transitive description: @@ -381,7 +409,7 @@ packages: name: pub_semver url: "https://pub.dartlang.org" source: hosted - version: "2.1.2" + version: "2.1.3" pubspec_parse: dependency: transitive description: @@ -409,7 +437,7 @@ packages: name: shelf_web_socket url: "https://pub.dartlang.org" source: hosted - version: "1.0.2" + version: "1.0.3" sky_engine: dependency: transitive description: flutter @@ -456,7 +484,7 @@ packages: name: stream_transform url: "https://pub.dartlang.org" source: hosted - version: "2.0.1" + version: "2.1.0" string_scanner: dependency: transitive description: @@ -498,7 +526,7 @@ packages: name: uuid url: "https://pub.dartlang.org" source: hosted - version: "3.0.6" + version: "3.0.7" vector_math: dependency: transitive description: @@ -520,6 +548,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.2.0" + xml: + dependency: transitive + description: + name: xml + url: "https://pub.dartlang.org" + source: hosted + version: "6.1.0" yaml: dependency: transitive description: @@ -529,4 +564,4 @@ packages: version: "3.1.1" sdks: dart: ">=2.18.1 <3.0.0" - flutter: ">=2.0.0" + flutter: ">=2.11.0-0.1.pre" diff --git a/packages/katana_theme/example/pubspec.yaml b/packages/katana_theme/example/pubspec.yaml index 9c8912573..12cbbf880 100644 --- a/packages/katana_theme/example/pubspec.yaml +++ b/packages/katana_theme/example/pubspec.yaml @@ -73,15 +73,11 @@ flutter: # To add assets to your application, add an assets section, like this: assets: - assets/ - - assets/images/ - - assets/images/2.0x/ - - assets/images/3.0x/ - - assets/images/connection/ - - assets/images/connection/2.0x/ - - assets/images/connection/3.0x/ - - assets/images/orphe_core/ - - assets/images/orphe_core/2.0x/ - - assets/images/orphe_core/3.0x/ + + fonts: + - family: NotoSerifJP + fonts: + - asset: assets/fonts/NotoSerifJP-Regular.otf # An image asset can refer to one or more resolution-specific "variants", see # https://flutter.dev/assets-and-images/#resolution-aware diff --git a/packages/katana_theme/example/test/widget_test.dart b/packages/katana_theme/example/test/widget_test.dart deleted file mode 100644 index 46aa5d319..000000000 --- a/packages/katana_theme/example/test/widget_test.dart +++ /dev/null @@ -1,13 +0,0 @@ -// This is a basic Flutter widget test. -// -// To perform an interaction with a widget in your test, use the WidgetTester -// utility in the flutter_test package. For example, you can send tap and scroll -// gestures. You can also use WidgetTester to find child widgets in the widget -// tree, read text, and verify that the values of widget properties are correct. - -import 'package:flutter/material.dart'; -import 'package:flutter_test/flutter_test.dart'; - -import 'package:katana_theme_example/main.dart'; - -void main() {} diff --git a/packages/katana_theme/lib/katana_theme.dart b/packages/katana_theme/lib/katana_theme.dart index 5d96ac472..ab6781236 100644 --- a/packages/katana_theme/lib/katana_theme.dart +++ b/packages/katana_theme/lib/katana_theme.dart @@ -8,14 +8,18 @@ /// [YouTube]: https://www.youtube.com/c/mathrunetchannel library katana_theme; +import 'dart:async'; + +import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; -import 'package:google_fonts/google_fonts.dart'; +import 'package:flutter/services.dart'; import 'package:katana/katana.dart'; export 'package:katana_theme_annotation/katana_theme_annotation.dart'; -part 'src/app_theme_base.dart'; -part 'src/fonts.dart'; +part 'src/app_theme_data.dart'; part 'src/theme_scope.dart'; part 'src/extensions.dart'; part 'src/gradient_color.dart'; +part 'src/video_provider.dart'; +part 'src/text_provider.dart'; diff --git a/packages/katana_theme/lib/src/app_theme_base.dart b/packages/katana_theme/lib/src/app_theme_base.dart deleted file mode 100644 index b4dbf474a..000000000 --- a/packages/katana_theme/lib/src/app_theme_base.dart +++ /dev/null @@ -1,569 +0,0 @@ -part of katana_theme; - -@immutable -class ColorThemeBase { - const ColorThemeBase({ - this.primary = Colors.blue, - this.secondary = Colors.cyan, - this.tertiary = Colors.lightBlue, - this.primaryContainer = Colors.blueAccent, - this.secondaryContainer = Colors.cyanAccent, - this.tertiaryContainer = Colors.lightBlueAccent, - this.disabled = Colors.grey, - this.weak = Colors.grey, - this.outline = Colors.grey, - this.error = Colors.red, - this.warning = Colors.amber, - this.info = Colors.blue, - this.success = Colors.green, - this.surface = const Color(0xFFFFFFFF), - this.background = const Color(0xFFFFFFFF), - this.onPrimary = const Color(0xFFFFFFFF), - this.onSecondary = const Color(0xFFFFFFFF), - this.onTertiary = const Color(0xFFFFFFFF), - this.onPrimaryContainer = const Color(0xFFFFFFFF), - this.onSecondaryContainer = const Color(0xFFFFFFFF), - this.onTertiaryContainer = const Color(0xFFFFFFFF), - this.onDisabled = const Color(0xFFFFFFFF), - this.onSurface = const Color(0xFFFFFFFF), - this.onBackground = const Color(0xFF212121), - this.onWeak = const Color(0xFFFFFFFF), - this.onError = const Color(0xFFFFFFFF), - this.onInfo = const Color(0xFFFFFFFF), - this.onSuccess = const Color(0xFF212121), - this.onWarning = const Color(0xFFFFFFFF), - this.splashColor = const Color(0xaaFFFFFF), - this.appBarColor, - this.onAppBarColor, - this.scaffoldBackgroundColor, - }); - - final Color primary; - - final Color secondary; - - final Color tertiary; - - final Color primaryContainer; - - final Color secondaryContainer; - - final Color tertiaryContainer; - - final Color disabled; - - final Color weak; - - final Color outline; - - final Color error; - - final Color warning; - - final Color info; - - final Color success; - - final Color surface; - - final Color background; - - final Color onPrimary; - - final Color onSecondary; - - final Color onTertiary; - - final Color onPrimaryContainer; - - final Color onSecondaryContainer; - - final Color onTertiaryContainer; - - final Color onDisabled; - - final Color onSurface; - - final Color onBackground; - - final Color onWeak; - - final Color onError; - - final Color onInfo; - - final Color onSuccess; - - final Color onWarning; - - final Color? appBarColor; - - final Color? onAppBarColor; - - final Color? scaffoldBackgroundColor; - - final Color? splashColor; -} - -@immutable -class TextThemeBase { - const TextThemeBase({ - this.fontFamily, - this.displayLarge = const TextStyle( - fontSize: 57, - fontWeight: FontWeight.w400, - leadingDistribution: TextLeadingDistribution.even, - ), - this.displayMedium = const TextStyle( - fontSize: 45, - fontWeight: FontWeight.w400, - leadingDistribution: TextLeadingDistribution.even, - ), - this.displaySmall = const TextStyle( - fontSize: 36, - fontWeight: FontWeight.w400, - leadingDistribution: TextLeadingDistribution.even, - ), - this.headlineLarge = const TextStyle( - fontSize: 32, - fontWeight: FontWeight.w400, - height: 1.25, - leadingDistribution: TextLeadingDistribution.proportional, - ), - this.headlineMedium = const TextStyle( - fontSize: 28, - fontWeight: FontWeight.w400, - height: 1.29, - leadingDistribution: TextLeadingDistribution.proportional, - ), - this.headlineSmall = const TextStyle( - fontSize: 24, - fontWeight: FontWeight.w400, - height: 1.33, - leadingDistribution: TextLeadingDistribution.proportional, - ), - this.titleLarge = const TextStyle( - fontSize: 22, - fontWeight: FontWeight.w500, - leadingDistribution: TextLeadingDistribution.even, - ), - this.titleMedium = const TextStyle( - fontSize: 16, - fontWeight: FontWeight.w500, - leadingDistribution: TextLeadingDistribution.even, - ), - this.titleSmall = const TextStyle( - fontSize: 14, - fontWeight: FontWeight.w500, - leadingDistribution: TextLeadingDistribution.even, - ), - this.bodyLarge = const TextStyle( - fontSize: 16, - fontWeight: FontWeight.w400, - leadingDistribution: TextLeadingDistribution.even, - ), - this.bodyMedium = const TextStyle( - fontSize: 14, - fontWeight: FontWeight.w400, - leadingDistribution: TextLeadingDistribution.even, - ), - this.bodySmall = const TextStyle( - fontSize: 12, - fontWeight: FontWeight.w400, - leadingDistribution: TextLeadingDistribution.even, - ), - this.labelLarge = const TextStyle( - fontSize: 14, - fontWeight: FontWeight.w500, - leadingDistribution: TextLeadingDistribution.even, - ), - this.labelMedium = const TextStyle( - fontSize: 12, - fontWeight: FontWeight.w500, - leadingDistribution: TextLeadingDistribution.even, - ), - this.labelSmall = const TextStyle( - fontSize: 11, - fontWeight: FontWeight.w500, - leadingDistribution: TextLeadingDistribution.even, - ), - this.fontSizeFactor = 1.0, - this.fontSizeDelta = 0.0, - }); - - final String? fontFamily; - - final TextStyle displayLarge; - - final TextStyle displayMedium; - - final TextStyle displaySmall; - - final TextStyle headlineLarge; - - final TextStyle headlineMedium; - - final TextStyle headlineSmall; - - final TextStyle titleLarge; - - final TextStyle titleMedium; - - final TextStyle titleSmall; - - final TextStyle bodyLarge; - - final TextStyle bodyMedium; - - final TextStyle bodySmall; - - final TextStyle labelLarge; - - final TextStyle labelMedium; - - final TextStyle labelSmall; - - final double fontSizeFactor; - - final double fontSizeDelta; -} - -@immutable -class WidgetThemeBase { - const WidgetThemeBase({ - this.indicator = const CircularProgressIndicator(), - }); - - final Widget indicator; -} - -@immutable -class AssetThemeBase { - const AssetThemeBase(); -} - -@immutable -abstract class AppThemeBase< - TColor extends ColorThemeBase, - TText extends TextThemeBase, - TAsset extends AssetThemeBase, - TWidget extends WidgetThemeBase> { - const AppThemeBase({ - this.brightness = Brightness.light, - this.useMaterial3 = true, - this.platform = TargetPlatform.iOS, - }); - - TColor get color; - TText get text; - TAsset get asset; - TWidget get widget; - - final Brightness brightness; - final bool useMaterial3; - final TargetPlatform platform; - - ThemeData toThemeData() { - switch (brightness) { - case Brightness.dark: - final colorScheme = const ColorScheme.dark().copyWith( - primary: color.primary, - primaryContainer: color.primaryContainer, - secondary: color.secondary, - secondaryContainer: color.secondaryContainer, - tertiary: color.tertiary, - tertiaryContainer: color.tertiaryContainer, - surface: color.surface, - background: color.background, - error: color.error, - errorContainer: color.warning, - onPrimary: color.onPrimary, - onPrimaryContainer: color.onPrimaryContainer, - onSecondary: color.onSecondary, - onSecondaryContainer: color.onSecondaryContainer, - onTertiary: color.onTertiary, - onTertiaryContainer: color.onTertiaryContainer, - onBackground: color.onBackground, - onSurface: color.onSurface, - onError: color.onError, - onErrorContainer: color.onWarning, - brightness: brightness, - outline: color.outline, - ); - final theme = ThemeData.dark(); - final textTheme = _convertTextThemeFromFont( - text.fontFamily, - theme.textTheme, - ).apply( - fontSizeFactor: text.fontSizeFactor, - fontSizeDelta: text.fontSizeDelta, - ); - final appBarForegroundColor = color.appBarColor == Colors.transparent - ? color.onBackground - : color.onAppBarColor; - return ThemeData( - useMaterial3: useMaterial3, - platform: platform, - colorScheme: colorScheme, - splashColor: color.splashColor, - scaffoldBackgroundColor: color.scaffoldBackgroundColor, - textTheme: textTheme.apply( - bodyColor: color.onBackground, - displayColor: color.onBackground, - ), - appBarTheme: theme.appBarTheme.copyWith( - backgroundColor: color.appBarColor, - elevation: color.appBarColor == Colors.transparent ? 0 : null, - foregroundColor: appBarForegroundColor, - toolbarTextStyle: theme.appBarTheme.toolbarTextStyle?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? TextStyle(color: appBarForegroundColor) - : null), - titleTextStyle: theme.appBarTheme.titleTextStyle?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? TextStyle(color: appBarForegroundColor) - : null), - iconTheme: theme.appBarTheme.iconTheme?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? IconThemeData(color: appBarForegroundColor) - : null), - actionsIconTheme: theme.appBarTheme.actionsIconTheme?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? IconThemeData(color: appBarForegroundColor) - : null), - ), - buttonTheme: theme.buttonTheme.copyWith( - textTheme: theme.buttonTheme.textTheme, - buttonColor: color.primary, - disabledColor: color.disabled, - colorScheme: colorScheme, - ), - inputDecorationTheme: theme.inputDecorationTheme.copyWith( - labelStyle: TextStyle(color: color.weak), - helperStyle: TextStyle(color: color.weak), - hintStyle: TextStyle(color: color.weak), - counterStyle: TextStyle(color: color.weak), - errorStyle: TextStyle(color: color.error), - prefixStyle: TextStyle(color: color.onBackground), - suffixStyle: TextStyle(color: color.onBackground), - border: OutlineInputBorder( - borderSide: BorderSide(color: color.weak, width: 2), - ), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.weak, width: 2), - ), - disabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.weak, width: 2), - ), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.primary, width: 2), - ), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.error, width: 2), - ), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.error, width: 2), - ), - ), - indicatorColor: color.secondary, - brightness: brightness, - primaryColor: color.primary, - disabledColor: color.disabled, - dividerColor: color.outline, - errorColor: color.error, - backgroundColor: color.background, - canvasColor: color.background, - ); - default: - final colorScheme = const ColorScheme.light().copyWith( - primary: color.primary, - primaryContainer: color.primaryContainer, - secondary: color.secondary, - secondaryContainer: color.secondaryContainer, - tertiary: color.tertiary, - tertiaryContainer: color.tertiaryContainer, - surface: color.surface, - background: color.background, - error: color.error, - onPrimary: color.onPrimary, - onPrimaryContainer: color.onPrimaryContainer, - onSecondary: color.onSecondary, - onSecondaryContainer: color.onSecondaryContainer, - onTertiary: color.onTertiary, - onTertiaryContainer: color.onTertiaryContainer, - onBackground: color.onBackground, - onSurface: color.onSurface, - onError: color.onError, - brightness: brightness, - outline: color.outline, - ); - final theme = ThemeData.light(); - final textTheme = _convertTextThemeFromFont( - text.fontFamily, - theme.textTheme, - ).apply( - fontSizeFactor: text.fontSizeFactor, - fontSizeDelta: text.fontSizeDelta, - ); - final appBarForegroundColor = color.appBarColor == Colors.transparent - ? color.onBackground - : color.onAppBarColor; - return ThemeData( - useMaterial3: useMaterial3, - platform: platform, - colorScheme: colorScheme, - splashColor: color.splashColor, - scaffoldBackgroundColor: color.scaffoldBackgroundColor, - appBarTheme: theme.appBarTheme.copyWith( - backgroundColor: color.appBarColor, - elevation: color.appBarColor == Colors.transparent ? 0 : null, - foregroundColor: appBarForegroundColor, - toolbarTextStyle: theme.appBarTheme.toolbarTextStyle?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? TextStyle(color: appBarForegroundColor) - : null), - titleTextStyle: theme.appBarTheme.titleTextStyle?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? TextStyle(color: appBarForegroundColor) - : null), - iconTheme: theme.appBarTheme.iconTheme?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? IconThemeData(color: appBarForegroundColor) - : null), - actionsIconTheme: theme.appBarTheme.actionsIconTheme?.copyWith( - color: appBarForegroundColor, - ) ?? - (appBarForegroundColor != null - ? IconThemeData(color: appBarForegroundColor) - : null), - ), - textTheme: textTheme.apply( - bodyColor: color.onBackground, - displayColor: color.onBackground, - ), - buttonTheme: theme.buttonTheme.copyWith( - buttonColor: color.primary, - disabledColor: color.disabled, - colorScheme: colorScheme, - ), - inputDecorationTheme: theme.inputDecorationTheme.copyWith( - labelStyle: TextStyle(color: color.weak), - helperStyle: TextStyle(color: color.weak), - hintStyle: TextStyle(color: color.weak), - counterStyle: TextStyle(color: color.weak), - errorStyle: TextStyle(color: color.error), - prefixStyle: TextStyle(color: color.onBackground), - suffixStyle: TextStyle(color: color.onBackground), - border: OutlineInputBorder( - borderSide: BorderSide(color: color.weak, width: 2), - ), - enabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.weak, width: 2), - ), - disabledBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.weak, width: 2), - ), - focusedBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.primary, width: 2), - ), - errorBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.error, width: 2), - ), - focusedErrorBorder: OutlineInputBorder( - borderSide: BorderSide(color: color.error, width: 2), - ), - ), - indicatorColor: color.secondary, - brightness: brightness, - primaryColor: color.primary, - disabledColor: color.disabled, - dividerColor: color.outline, - errorColor: color.error, - backgroundColor: color.background, - canvasColor: color.background, - ); - } - } - - TextTheme _convertTextThemeFromFont( - String? fontFamily, - TextTheme textTheme, - ) { - textTheme = textTheme.copyWith( - displayLarge: text.displayLarge, - displayMedium: text.displayMedium, - displaySmall: text.displaySmall, - headlineLarge: text.headlineLarge, - headlineMedium: text.headlineMedium, - headlineSmall: text.headlineSmall, - titleLarge: text.titleLarge, - titleMedium: text.titleMedium, - titleSmall: text.titleSmall, - bodyLarge: text.bodyLarge, - bodyMedium: text.bodyMedium, - bodySmall: text.bodySmall, - labelLarge: text.labelLarge, - labelMedium: text.labelMedium, - labelSmall: text.labelSmall, - ); - if (fontFamily.isEmpty) { - return textTheme; - } - final fonts = GoogleFonts.asMap(); - final fontGenerator = fonts[fontFamily]; - if (fontGenerator == null) { - return TextTheme( - displayLarge: textTheme.displayLarge?.copyWith(fontFamily: fontFamily), - displayMedium: - textTheme.displayMedium?.copyWith(fontFamily: fontFamily), - displaySmall: textTheme.displaySmall?.copyWith(fontFamily: fontFamily), - headlineLarge: - textTheme.headlineLarge?.copyWith(fontFamily: fontFamily), - headlineMedium: - textTheme.headlineMedium?.copyWith(fontFamily: fontFamily), - headlineSmall: - textTheme.headlineSmall?.copyWith(fontFamily: fontFamily), - titleLarge: textTheme.titleLarge?.copyWith(fontFamily: fontFamily), - titleMedium: textTheme.titleMedium?.copyWith(fontFamily: fontFamily), - titleSmall: textTheme.titleSmall?.copyWith(fontFamily: fontFamily), - bodyLarge: textTheme.bodyLarge?.copyWith(fontFamily: fontFamily), - bodyMedium: textTheme.bodyMedium?.copyWith(fontFamily: fontFamily), - bodySmall: textTheme.bodySmall?.copyWith(fontFamily: fontFamily), - labelLarge: textTheme.labelLarge?.copyWith(fontFamily: fontFamily), - labelMedium: textTheme.labelMedium?.copyWith(fontFamily: fontFamily), - labelSmall: textTheme.labelSmall?.copyWith(fontFamily: fontFamily), - ); - } - return TextTheme( - displayLarge: fontGenerator(textStyle: textTheme.displayLarge), - displayMedium: fontGenerator(textStyle: textTheme.displayMedium), - displaySmall: fontGenerator(textStyle: textTheme.displaySmall), - headlineLarge: fontGenerator(textStyle: textTheme.headlineLarge), - headlineMedium: fontGenerator(textStyle: textTheme.headlineMedium), - headlineSmall: fontGenerator(textStyle: textTheme.headlineSmall), - titleLarge: fontGenerator(textStyle: textTheme.titleLarge), - titleMedium: fontGenerator(textStyle: textTheme.titleMedium), - titleSmall: fontGenerator(textStyle: textTheme.titleSmall), - bodyLarge: fontGenerator(textStyle: textTheme.bodyLarge), - bodyMedium: fontGenerator(textStyle: textTheme.bodyMedium), - bodySmall: fontGenerator(textStyle: textTheme.bodySmall), - labelLarge: fontGenerator(textStyle: textTheme.labelLarge), - labelMedium: fontGenerator(textStyle: textTheme.labelMedium), - labelSmall: fontGenerator(textStyle: textTheme.labelSmall), - ); - } -} diff --git a/packages/katana_theme/lib/src/app_theme_data.dart b/packages/katana_theme/lib/src/app_theme_data.dart new file mode 100644 index 000000000..b147756d9 --- /dev/null +++ b/packages/katana_theme/lib/src/app_theme_data.dart @@ -0,0 +1,1710 @@ +part of katana_theme; + +/// {@template app_theme_data} +/// Set the theme of the application. +/// +/// [ColorScheme] and [TextTheme] of MaterialDesign3 can be specified. +/// +/// You can use `context.theme` to get this value, or you can pass [ThemeData] converted by [toThemeData] to [MaterialApp] and other widgets in Flutter. +/// +/// [ColorScheme] can be obtained by [color]. [TextTheme] can be obtained by [text]. [widget] allows you to retrieve the theme used for the widget. In [asset], you can get the assets of the application specified in pubspec.yaml. You can get the font of the app specified in pubspec.yaml at [font]. +/// +/// You can also set up your own theme by extending [ColorThemeData], [TextThemeData], [WidgetThemeData], [AssetThemeData], and [FontThemeData] with extensions, respectively. +/// +/// アプリのテーマを設定します。 +/// +/// MaterialDesign3の[ColorScheme]と[TextTheme]を指定することが可能です。 +/// +/// `context.theme`でこの値を取得できる様になっている他、[MaterialApp]等に[toThemeData]で変換した[ThemeData]を渡すことでFlutter内の各種ウィジェットに伝えることができます。 +/// +/// [color]で[ColorScheme]を取得することができます。[text]で[TextTheme]を取得することができます。[widget]でウィジェットで使うテーマを取得することができます。[asset]でpubspec.yamlで指定したアプリのアセットを取得することができます。[font]でpubspec.yamlで指定したアプリのフォントを取得することができます。 +/// +/// またそれぞれ[ColorThemeData]、[TextThemeData]、[WidgetThemeData]、[AssetThemeData]、[FontThemeData]をエクステンションで拡張することにより独自のテーマを設定することも可能です。 +/// +/// See also: +/// +/// - https://m3.material.io/styles/color/the-color-system/color-roles +/// - https://m3.material.io/styles/typography/type-scale-tokens +/// {@endtemplate} +@immutable +class AppThemeData { + /// The light theme defines the initial color. + /// + /// ライトテーマで初期色を定義しています。 + /// + /// {@macro app_theme_data} + AppThemeData({ + Color primary = Colors.blue, + Color secondary = Colors.cyan, + Color tertiary = Colors.lightBlue, + Color primaryContainer = Colors.blueAccent, + Color secondaryContainer = Colors.cyanAccent, + Color tertiaryContainer = Colors.lightBlueAccent, + Color disabled = Colors.grey, + Color weak = Colors.grey, + Color outline = Colors.grey, + Color error = Colors.red, + Color warning = Colors.amber, + Color info = Colors.blue, + Color success = Colors.green, + Color surface = Colors.white, + Color background = Colors.white, + Color onPrimary = Colors.white, + Color onSecondary = Colors.white, + Color onTertiary = Colors.white, + Color onPrimaryContainer = Colors.white, + Color onSecondaryContainer = Colors.white, + Color onTertiaryContainer = Colors.white, + Color onDisabled = Colors.white, + Color onSurface = Colors.white, + Color onBackground = const Color(0xFF212121), + Color onWeak = Colors.white, + Color onError = Colors.white, + Color onInfo = Colors.white, + Color onSuccess = const Color(0xFF212121), + Color onWarning = Colors.white, + Color splashColor = const Color(0xaaFFFFFF), + Color shadow = Colors.black, + Color inverseSurface = const Color(0xFF212121), + Color onInverseSurface = Colors.white, + Color inversePrimary = Colors.white, + Color? appBarColor, + Color? onAppBarColor, + Color? scaffoldBackgroundColor, + TextStyle displayLarge = const TextStyle( + fontSize: 57, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle displayMedium = const TextStyle( + fontSize: 45, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle displaySmall = const TextStyle( + fontSize: 36, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle headlineLarge = const TextStyle( + fontSize: 32, + fontWeight: FontWeight.w400, + height: 1.25, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle headlineMedium = const TextStyle( + fontSize: 28, + fontWeight: FontWeight.w400, + height: 1.29, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle headlineSmall = const TextStyle( + fontSize: 24, + fontWeight: FontWeight.w400, + height: 1.33, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle titleLarge = const TextStyle( + fontSize: 22, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle titleMedium = const TextStyle( + fontSize: 16, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle titleSmall = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodyLarge = const TextStyle( + fontSize: 16, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodyMedium = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodySmall = const TextStyle( + fontSize: 12, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelLarge = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelMedium = const TextStyle( + fontSize: 12, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelSmall = const TextStyle( + fontSize: 11, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + double fontSizeFactor = 1.0, + double fontSizeDelta = 0.0, + String? defaultFontFamily, + this.brightness = Brightness.light, + this.useMaterial3 = true, + this.platform = TargetPlatform.iOS, + }) : color = ColorThemeData._( + primary: primary, + secondary: secondary, + tertiary: tertiary, + primaryContainer: primaryContainer, + secondaryContainer: secondaryContainer, + tertiaryContainer: tertiaryContainer, + disabled: disabled, + weak: weak, + outline: outline, + error: error, + warning: warning, + info: info, + success: success, + surface: surface, + background: background, + onPrimary: onPrimary, + onSecondary: onSecondary, + onTertiary: onTertiary, + onPrimaryContainer: onPrimaryContainer, + onSecondaryContainer: onSecondaryContainer, + onTertiaryContainer: onTertiaryContainer, + onDisabled: onDisabled, + onSurface: onSurface, + onBackground: onBackground, + onWeak: onWeak, + onError: onError, + onInfo: onInfo, + onSuccess: onSuccess, + onWarning: onWarning, + splashColor: splashColor, + shadow: shadow, + inverseSurface: inverseSurface, + onInverseSurface: onInverseSurface, + inversePrimary: inversePrimary, + appBarColor: appBarColor, + onAppBarColor: onAppBarColor, + scaffoldBackgroundColor: scaffoldBackgroundColor, + ), + text = TextThemeData._( + displayLarge: displayLarge, + displayMedium: displayMedium, + displaySmall: displaySmall, + headlineLarge: headlineLarge, + headlineMedium: headlineMedium, + headlineSmall: headlineSmall, + titleLarge: titleLarge, + titleMedium: titleMedium, + titleSmall: titleSmall, + bodyLarge: bodyLarge, + bodyMedium: bodyMedium, + bodySmall: bodySmall, + labelLarge: labelLarge, + labelMedium: labelMedium, + labelSmall: labelSmall, + fontSizeFactor: fontSizeFactor, + fontSizeDelta: fontSizeDelta, + defaultFontFamily: defaultFontFamily, + ); + + /// The light theme defines the initial color. + /// + /// ライトテーマで初期色を定義しています。 + /// + /// {@macro app_theme_data} + AppThemeData.light({ + Color primary = Colors.blue, + Color secondary = Colors.cyan, + Color tertiary = Colors.lightBlue, + Color primaryContainer = Colors.blueAccent, + Color secondaryContainer = Colors.cyanAccent, + Color tertiaryContainer = Colors.lightBlueAccent, + Color disabled = Colors.grey, + Color weak = Colors.grey, + Color outline = Colors.grey, + Color error = Colors.red, + Color warning = Colors.amber, + Color info = Colors.blue, + Color success = Colors.green, + Color surface = Colors.white, + Color background = Colors.white, + Color onPrimary = Colors.white, + Color onSecondary = Colors.white, + Color onTertiary = Colors.white, + Color onPrimaryContainer = Colors.white, + Color onSecondaryContainer = Colors.white, + Color onTertiaryContainer = Colors.white, + Color onDisabled = Colors.white, + Color onSurface = Colors.white, + Color onBackground = const Color(0xFF212121), + Color onWeak = Colors.white, + Color onError = Colors.white, + Color onInfo = Colors.white, + Color onSuccess = const Color(0xFF212121), + Color onWarning = Colors.white, + Color splashColor = const Color(0xaaFFFFFF), + Color shadow = Colors.black, + Color inverseSurface = const Color(0xFF212121), + Color onInverseSurface = Colors.white, + Color inversePrimary = Colors.white, + Color? appBarColor, + Color? onAppBarColor, + Color? scaffoldBackgroundColor, + TextStyle displayLarge = const TextStyle( + fontSize: 57, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle displayMedium = const TextStyle( + fontSize: 45, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle displaySmall = const TextStyle( + fontSize: 36, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle headlineLarge = const TextStyle( + fontSize: 32, + fontWeight: FontWeight.w400, + height: 1.25, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle headlineMedium = const TextStyle( + fontSize: 28, + fontWeight: FontWeight.w400, + height: 1.29, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle headlineSmall = const TextStyle( + fontSize: 24, + fontWeight: FontWeight.w400, + height: 1.33, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle titleLarge = const TextStyle( + fontSize: 22, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle titleMedium = const TextStyle( + fontSize: 16, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle titleSmall = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodyLarge = const TextStyle( + fontSize: 16, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodyMedium = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodySmall = const TextStyle( + fontSize: 12, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelLarge = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelMedium = const TextStyle( + fontSize: 12, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelSmall = const TextStyle( + fontSize: 11, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + double fontSizeFactor = 1.0, + double fontSizeDelta = 0.0, + String? defaultFontFamily, + this.useMaterial3 = true, + this.platform = TargetPlatform.iOS, + }) : brightness = Brightness.light, + color = ColorThemeData._( + primary: primary, + secondary: secondary, + tertiary: tertiary, + primaryContainer: primaryContainer, + secondaryContainer: secondaryContainer, + tertiaryContainer: tertiaryContainer, + disabled: disabled, + weak: weak, + outline: outline, + error: error, + warning: warning, + info: info, + success: success, + surface: surface, + background: background, + onPrimary: onPrimary, + onSecondary: onSecondary, + onTertiary: onTertiary, + onPrimaryContainer: onPrimaryContainer, + onSecondaryContainer: onSecondaryContainer, + onTertiaryContainer: onTertiaryContainer, + onDisabled: onDisabled, + onSurface: onSurface, + onBackground: onBackground, + onWeak: onWeak, + onError: onError, + onInfo: onInfo, + onSuccess: onSuccess, + onWarning: onWarning, + splashColor: splashColor, + shadow: shadow, + inverseSurface: inverseSurface, + onInverseSurface: onInverseSurface, + inversePrimary: inversePrimary, + appBarColor: appBarColor, + onAppBarColor: onAppBarColor, + scaffoldBackgroundColor: scaffoldBackgroundColor, + ), + text = TextThemeData._( + displayLarge: displayLarge, + displayMedium: displayMedium, + displaySmall: displaySmall, + headlineLarge: headlineLarge, + headlineMedium: headlineMedium, + headlineSmall: headlineSmall, + titleLarge: titleLarge, + titleMedium: titleMedium, + titleSmall: titleSmall, + bodyLarge: bodyLarge, + bodyMedium: bodyMedium, + bodySmall: bodySmall, + labelLarge: labelLarge, + labelMedium: labelMedium, + labelSmall: labelSmall, + fontSizeFactor: fontSizeFactor, + fontSizeDelta: fontSizeDelta, + defaultFontFamily: defaultFontFamily, + ); + + /// The dark theme defines the initial color. + /// + /// ダークテーマで初期色を定義しています。 + /// + /// {@macro app_theme_data} + AppThemeData.dark({ + Color primary = Colors.blue, + Color secondary = Colors.cyan, + Color tertiary = Colors.lightBlue, + Color primaryContainer = Colors.blueAccent, + Color secondaryContainer = Colors.cyanAccent, + Color tertiaryContainer = Colors.lightBlueAccent, + Color disabled = Colors.grey, + Color weak = Colors.grey, + Color outline = Colors.grey, + Color error = Colors.red, + Color warning = Colors.amber, + Color info = Colors.blue, + Color success = Colors.green, + Color surface = const Color(0xFF212121), + Color background = const Color(0xFF212121), + Color onPrimary = const Color(0xFF212121), + Color onSecondary = const Color(0xFF212121), + Color onTertiary = const Color(0xFF212121), + Color onPrimaryContainer = const Color(0xFF212121), + Color onSecondaryContainer = const Color(0xFF212121), + Color onTertiaryContainer = const Color(0xFF212121), + Color onDisabled = const Color(0xFF212121), + Color onSurface = const Color(0xFF212121), + Color onBackground = Colors.white, + Color onWeak = const Color(0xFF212121), + Color onError = const Color(0xFF212121), + Color onInfo = const Color(0xFF212121), + Color onSuccess = Colors.white, + Color onWarning = const Color(0xFF212121), + Color splashColor = const Color(0xaaFFFFFF), + Color shadow = Colors.black, + Color inverseSurface = Colors.white, + Color onInverseSurface = const Color(0xFF212121), + Color inversePrimary = const Color(0xFF212121), + Color? appBarColor, + Color? onAppBarColor, + Color? scaffoldBackgroundColor, + TextStyle displayLarge = const TextStyle( + fontSize: 57, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle displayMedium = const TextStyle( + fontSize: 45, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle displaySmall = const TextStyle( + fontSize: 36, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle headlineLarge = const TextStyle( + fontSize: 32, + fontWeight: FontWeight.w400, + height: 1.25, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle headlineMedium = const TextStyle( + fontSize: 28, + fontWeight: FontWeight.w400, + height: 1.29, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle headlineSmall = const TextStyle( + fontSize: 24, + fontWeight: FontWeight.w400, + height: 1.33, + leadingDistribution: TextLeadingDistribution.proportional, + ), + TextStyle titleLarge = const TextStyle( + fontSize: 22, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle titleMedium = const TextStyle( + fontSize: 16, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle titleSmall = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodyLarge = const TextStyle( + fontSize: 16, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodyMedium = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle bodySmall = const TextStyle( + fontSize: 12, + fontWeight: FontWeight.w400, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelLarge = const TextStyle( + fontSize: 14, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelMedium = const TextStyle( + fontSize: 12, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + TextStyle labelSmall = const TextStyle( + fontSize: 11, + fontWeight: FontWeight.w500, + leadingDistribution: TextLeadingDistribution.even, + ), + double fontSizeFactor = 1.0, + double fontSizeDelta = 0.0, + String? defaultFontFamily, + this.useMaterial3 = true, + this.platform = TargetPlatform.iOS, + }) : brightness = Brightness.dark, + color = ColorThemeData._( + primary: primary, + secondary: secondary, + tertiary: tertiary, + primaryContainer: primaryContainer, + secondaryContainer: secondaryContainer, + tertiaryContainer: tertiaryContainer, + disabled: disabled, + weak: weak, + outline: outline, + error: error, + warning: warning, + info: info, + success: success, + surface: surface, + background: background, + onPrimary: onPrimary, + onSecondary: onSecondary, + onTertiary: onTertiary, + onPrimaryContainer: onPrimaryContainer, + onSecondaryContainer: onSecondaryContainer, + onTertiaryContainer: onTertiaryContainer, + onDisabled: onDisabled, + onSurface: onSurface, + onBackground: onBackground, + onWeak: onWeak, + onError: onError, + onInfo: onInfo, + onSuccess: onSuccess, + onWarning: onWarning, + splashColor: splashColor, + shadow: shadow, + inverseSurface: inverseSurface, + onInverseSurface: onInverseSurface, + inversePrimary: inversePrimary, + appBarColor: appBarColor, + onAppBarColor: onAppBarColor, + scaffoldBackgroundColor: scaffoldBackgroundColor, + ), + text = TextThemeData._( + displayLarge: displayLarge, + displayMedium: displayMedium, + displaySmall: displaySmall, + headlineLarge: headlineLarge, + headlineMedium: headlineMedium, + headlineSmall: headlineSmall, + titleLarge: titleLarge, + titleMedium: titleMedium, + titleSmall: titleSmall, + bodyLarge: bodyLarge, + bodyMedium: bodyMedium, + bodySmall: bodySmall, + labelLarge: labelLarge, + labelMedium: labelMedium, + labelSmall: labelSmall, + fontSizeFactor: fontSizeFactor, + fontSizeDelta: fontSizeDelta, + defaultFontFamily: defaultFontFamily, + ); + + /// Retrieve the color scheme. + /// + /// New themes can be defined by extending [ColorThemeData]. + /// + /// カラースキームを取得します。 + /// + /// [ColorThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final ColorThemeData color; + + /// Retrieve the text theme. + /// + /// New themes can be defined by extending [TextThemeData]. + /// + /// テキストテーマを取得します。 + /// + /// [TextThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + // TextThemeData get text => TextThemeData._( + // displayLarge: _displayLarge, + // displayMedium: _displayMedium, + // displaySmall: _displaySmall, + // headlineLarge: _headlineLarge, + // headlineMedium: _headlineMedium, + // headlineSmall: _headlineSmall, + // titleLarge: _titleLarge, + // titleMedium: _titleMedium, + // titleSmall: _titleSmall, + // bodyLarge: _bodyLarge, + // bodyMedium: _bodyMedium, + // bodySmall: _bodySmall, + // labelLarge: _labelLarge, + // labelMedium: _labelMedium, + // labelSmall: _labelSmall, + // fontSizeFactor: _fontSizeFactor, + // fontSizeDelta: _fontSizeDelta, + // defaultFontFamily: _defaultFontFamily, + // ); + final TextThemeData text; + + /// Retrieve font themes. + /// + /// The builder will allow you to retrieve the font families defined in pubspec.yaml. + /// + /// New themes can be defined by extending [FontThemeData]. + /// + /// フォントテーマを取得します。 + /// + /// ビルダーによってpubspec.yaml内に定義されたフォントファミリーを取得することができるようになります。 + /// + /// [FontThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 + FontThemeData get font => const FontThemeData._(); + + /// Obtains a list of asset paths. + /// + /// The builder will allow you to retrieve the assets defined in pubspec.yaml. + /// + /// New themes can be defined by extending [AssetThemeData]. + /// + /// アセットのパス一覧を取得します。 + /// + /// ビルダーによってpubspec.yaml内に定義されたアセットを取得することができるようになります。 + /// + /// [AssetThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 + AssetThemeData get asset => const AssetThemeData._(); + + /// Get the theme of the widget. + /// + /// New themes can be defined by extending [WidgetThemeData]. + /// + /// ウィジェットのテーマを取得します。 + /// + /// [WidgetThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 + WidgetThemeData get widget => const WidgetThemeData._(); + + /// Define [Brightness] for the application. [Brightness.dark] will set it to dark mode and [Brightness.light] will set it to light mode. + /// + /// アプリの[Brightness]を定義します。[Brightness.dark]でダークモードに、[Brightness.light]でライトモードになります。 + final Brightness brightness; + + /// If this is set to `true`, the app will be designed with Material3 design. + /// + /// これを`true`にした場合、Material3のデザインでアプリがデザインされます。 + /// + /// See also: + /// + /// - https://m3.material.io/ + final bool useMaterial3; + + /// Specify the target platform for the design. + /// + /// The design will be tailored to this platform. + /// + /// デザインのターゲットプラットフォームを指定します。 + /// + /// このプラットフォームに合わせたデザインになります。 + final TargetPlatform platform; + + /// Get [AppThemeData] placed on the widget tree. + /// + /// ウィジェットツリー上に配置されている[AppThemeData]を取得します。 + static AppThemeData of(BuildContext context) { + final scope = context + .getElementForInheritedWidgetOfExactType() + ?.widget as AppThemeScope?; + assert(scope != null, "AppThemeData is not found."); + return scope!.theme; + } + + /// Convert to [ThemeData] in Flutter. + /// + /// Passing this to [MaterialApp] and others will change the Flutter widget to a design suitable for [AppThemeData]. + /// + /// [defaultFontFamily] allows you to specify the default font for the app. + /// + /// Flutterの[ThemeData]に変換します。 + /// + /// これを[MaterialApp]などに渡すとFlutterのウィジェットが[AppThemeData]に適したデザインに変更されます。 + /// + /// [defaultFontFamily]を指定するとアプリのデフォルトのフォントを指定することができます。 + ThemeData toThemeData({ + String? defaultFontFamily, + }) { + final color = this.color; + final text = this.text; + defaultFontFamily ??= text.defaultFontFamily; + + switch (brightness) { + case Brightness.dark: + final colorScheme = const ColorScheme.dark().copyWith( + primary: color.primary, + primaryContainer: color.primaryContainer, + secondary: color.secondary, + secondaryContainer: color.secondaryContainer, + tertiary: color.tertiary, + tertiaryContainer: color.tertiaryContainer, + surface: color.surface, + background: color.background, + error: color.error, + errorContainer: color.warning, + onPrimary: color.onPrimary, + onPrimaryContainer: color.onPrimaryContainer, + onSecondary: color.onSecondary, + onSecondaryContainer: color.onSecondaryContainer, + onTertiary: color.onTertiary, + onTertiaryContainer: color.onTertiaryContainer, + onBackground: color.onBackground, + onSurface: color.onSurface, + onError: color.onError, + onErrorContainer: color.onWarning, + brightness: brightness, + outline: color.outline, + inversePrimary: color.inversePrimary, + inverseSurface: color.inverseSurface, + onInverseSurface: color.onInverseSurface, + ); + final theme = ThemeData.dark(); + final textTheme = theme.textTheme.copyWith( + displayLarge: + text.displayLarge.copyWith(fontFamily: text.defaultFontFamily), + displayMedium: + text.displayMedium.copyWith(fontFamily: text.defaultFontFamily), + displaySmall: + text.displaySmall.copyWith(fontFamily: text.defaultFontFamily), + headlineLarge: + text.headlineLarge.copyWith(fontFamily: text.defaultFontFamily), + headlineMedium: + text.headlineMedium.copyWith(fontFamily: text.defaultFontFamily), + headlineSmall: + text.headlineSmall.copyWith(fontFamily: text.defaultFontFamily), + titleLarge: + text.titleLarge.copyWith(fontFamily: text.defaultFontFamily), + titleMedium: + text.titleMedium.copyWith(fontFamily: text.defaultFontFamily), + titleSmall: + text.titleSmall.copyWith(fontFamily: text.defaultFontFamily), + bodyLarge: + text.bodyLarge.copyWith(fontFamily: text.defaultFontFamily), + bodyMedium: + text.bodyMedium.copyWith(fontFamily: text.defaultFontFamily), + bodySmall: + text.bodySmall.copyWith(fontFamily: text.defaultFontFamily), + labelLarge: + text.labelLarge.copyWith(fontFamily: text.defaultFontFamily), + labelMedium: + text.labelMedium.copyWith(fontFamily: text.defaultFontFamily), + labelSmall: + text.labelSmall.copyWith(fontFamily: text.defaultFontFamily), + ); + final appBarForegroundColor = color.appBarColor == Colors.transparent + ? color.onBackground + : (color.onAppBarColor ?? color.onPrimary); + return ThemeData( + fontFamily: defaultFontFamily, + useMaterial3: useMaterial3, + platform: platform, + colorScheme: colorScheme, + splashColor: color.splashColor, + scaffoldBackgroundColor: color.scaffoldBackgroundColor, + textTheme: textTheme.apply( + fontFamily: text.defaultFontFamily, + bodyColor: color.onBackground, + displayColor: color.onBackground, + fontSizeFactor: text.fontSizeFactor, + fontSizeDelta: text.fontSizeDelta, + ), + appBarTheme: theme.appBarTheme.copyWith( + backgroundColor: color.appBarColor ?? color.primary, + elevation: color.appBarColor == Colors.transparent ? 0 : null, + foregroundColor: appBarForegroundColor, + toolbarTextStyle: theme.appBarTheme.toolbarTextStyle?.copyWith( + color: appBarForegroundColor, + ) ?? + TextStyle(color: appBarForegroundColor), + titleTextStyle: theme.appBarTheme.titleTextStyle?.copyWith( + color: appBarForegroundColor, + ) ?? + TextStyle(color: appBarForegroundColor), + iconTheme: theme.appBarTheme.iconTheme?.copyWith( + color: appBarForegroundColor, + ) ?? + IconThemeData(color: appBarForegroundColor), + actionsIconTheme: theme.appBarTheme.actionsIconTheme?.copyWith( + color: appBarForegroundColor, + ) ?? + IconThemeData(color: appBarForegroundColor), + ), + buttonTheme: theme.buttonTheme.copyWith( + textTheme: theme.buttonTheme.textTheme, + buttonColor: color.primary, + disabledColor: color.disabled, + colorScheme: colorScheme, + ), + inputDecorationTheme: theme.inputDecorationTheme.copyWith( + labelStyle: TextStyle(color: color.weak), + helperStyle: TextStyle(color: color.weak), + hintStyle: TextStyle(color: color.weak), + counterStyle: TextStyle(color: color.weak), + errorStyle: TextStyle(color: color.error), + prefixStyle: TextStyle(color: color.onBackground), + suffixStyle: TextStyle(color: color.onBackground), + border: OutlineInputBorder( + borderSide: BorderSide(color: color.weak, width: 2), + ), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.weak, width: 2), + ), + disabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.weak, width: 2), + ), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.primary, width: 2), + ), + errorBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.error, width: 2), + ), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.error, width: 2), + ), + ), + indicatorColor: color.secondary, + brightness: brightness, + primaryColor: color.primary, + disabledColor: color.disabled, + dividerColor: color.outline, + errorColor: color.error, + backgroundColor: color.background, + canvasColor: color.background, + ); + default: + final colorScheme = const ColorScheme.light().copyWith( + primary: color.primary, + primaryContainer: color.primaryContainer, + secondary: color.secondary, + secondaryContainer: color.secondaryContainer, + tertiary: color.tertiary, + tertiaryContainer: color.tertiaryContainer, + surface: color.surface, + background: color.background, + error: color.error, + onPrimary: color.onPrimary, + onPrimaryContainer: color.onPrimaryContainer, + onSecondary: color.onSecondary, + onSecondaryContainer: color.onSecondaryContainer, + onTertiary: color.onTertiary, + onTertiaryContainer: color.onTertiaryContainer, + onBackground: color.onBackground, + onSurface: color.onSurface, + onError: color.onError, + brightness: brightness, + outline: color.outline, + inversePrimary: color.inversePrimary, + inverseSurface: color.inverseSurface, + onInverseSurface: color.onInverseSurface, + ); + final theme = ThemeData.light(); + final textTheme = theme.textTheme.copyWith( + displayLarge: + text.displayLarge.copyWith(fontFamily: text.defaultFontFamily), + displayMedium: + text.displayMedium.copyWith(fontFamily: text.defaultFontFamily), + displaySmall: + text.displaySmall.copyWith(fontFamily: text.defaultFontFamily), + headlineLarge: + text.headlineLarge.copyWith(fontFamily: text.defaultFontFamily), + headlineMedium: + text.headlineMedium.copyWith(fontFamily: text.defaultFontFamily), + headlineSmall: + text.headlineSmall.copyWith(fontFamily: text.defaultFontFamily), + titleLarge: + text.titleLarge.copyWith(fontFamily: text.defaultFontFamily), + titleMedium: + text.titleMedium.copyWith(fontFamily: text.defaultFontFamily), + titleSmall: + text.titleSmall.copyWith(fontFamily: text.defaultFontFamily), + bodyLarge: + text.bodyLarge.copyWith(fontFamily: text.defaultFontFamily), + bodyMedium: + text.bodyMedium.copyWith(fontFamily: text.defaultFontFamily), + bodySmall: + text.bodySmall.copyWith(fontFamily: text.defaultFontFamily), + labelLarge: + text.labelLarge.copyWith(fontFamily: text.defaultFontFamily), + labelMedium: + text.labelMedium.copyWith(fontFamily: text.defaultFontFamily), + labelSmall: + text.labelSmall.copyWith(fontFamily: text.defaultFontFamily), + ); + final appBarForegroundColor = color.appBarColor == Colors.transparent + ? color.onBackground + : (color.onAppBarColor ?? color.onPrimary); + return ThemeData( + fontFamily: defaultFontFamily, + useMaterial3: useMaterial3, + platform: platform, + colorScheme: colorScheme, + splashColor: color.splashColor, + scaffoldBackgroundColor: color.scaffoldBackgroundColor, + appBarTheme: theme.appBarTheme.copyWith( + backgroundColor: color.appBarColor ?? color.primary, + elevation: color.appBarColor == Colors.transparent ? 0 : null, + foregroundColor: appBarForegroundColor, + toolbarTextStyle: theme.appBarTheme.toolbarTextStyle?.copyWith( + color: appBarForegroundColor, + ) ?? + TextStyle(color: appBarForegroundColor), + titleTextStyle: theme.appBarTheme.titleTextStyle?.copyWith( + color: appBarForegroundColor, + ) ?? + TextStyle(color: appBarForegroundColor), + iconTheme: theme.appBarTheme.iconTheme?.copyWith( + color: appBarForegroundColor, + ) ?? + IconThemeData(color: appBarForegroundColor), + actionsIconTheme: theme.appBarTheme.actionsIconTheme?.copyWith( + color: appBarForegroundColor, + ) ?? + IconThemeData(color: appBarForegroundColor), + ), + textTheme: textTheme.apply( + fontFamily: text.defaultFontFamily, + bodyColor: color.onBackground, + displayColor: color.onBackground, + fontSizeFactor: text.fontSizeFactor, + fontSizeDelta: text.fontSizeDelta, + ), + buttonTheme: theme.buttonTheme.copyWith( + buttonColor: color.primary, + disabledColor: color.disabled, + colorScheme: colorScheme, + ), + inputDecorationTheme: theme.inputDecorationTheme.copyWith( + labelStyle: TextStyle(color: color.weak), + helperStyle: TextStyle(color: color.weak), + hintStyle: TextStyle(color: color.weak), + counterStyle: TextStyle(color: color.weak), + errorStyle: TextStyle(color: color.error), + prefixStyle: TextStyle(color: color.onBackground), + suffixStyle: TextStyle(color: color.onBackground), + border: OutlineInputBorder( + borderSide: BorderSide(color: color.weak, width: 2), + ), + enabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.weak, width: 2), + ), + disabledBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.weak, width: 2), + ), + focusedBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.primary, width: 2), + ), + errorBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.error, width: 2), + ), + focusedErrorBorder: OutlineInputBorder( + borderSide: BorderSide(color: color.error, width: 2), + ), + ), + indicatorColor: color.secondary, + brightness: brightness, + primaryColor: color.primary, + disabledColor: color.disabled, + dividerColor: color.outline, + errorColor: color.error, + backgroundColor: color.background, + canvasColor: color.background, + ); + } + } +} + +/// Define a color scheme. +/// +/// New themes can be defined by extending [ColorThemeData]. +/// +/// カラースキームを定義します。 +/// +/// [ColorThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 +/// +/// See also: +/// +/// - https://m3.material.io/styles/color/the-color-system/color-roles +@immutable +class ColorThemeData { + const ColorThemeData._({ + required this.primary, + required this.secondary, + required this.tertiary, + required this.primaryContainer, + required this.secondaryContainer, + required this.tertiaryContainer, + required this.disabled, + required this.weak, + required this.outline, + required this.error, + required this.warning, + required this.info, + required this.success, + required this.surface, + required this.background, + required this.onPrimary, + required this.onSecondary, + required this.onTertiary, + required this.onPrimaryContainer, + required this.onSecondaryContainer, + required this.onTertiaryContainer, + required this.onDisabled, + required this.onSurface, + required this.onBackground, + required this.onWeak, + required this.onError, + required this.onInfo, + required this.onSuccess, + required this.onWarning, + required this.splashColor, + required this.shadow, + required this.inverseSurface, + required this.onInverseSurface, + required this.inversePrimary, + this.appBarColor, + this.onAppBarColor, + this.scaffoldBackgroundColor, + }); + + /// Primary key color. + /// + /// プライマリーのキーカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color primary; + + /// Secondary key color. + /// + /// セカンダリーのキーカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color secondary; + + /// Tertiary key color. + /// + /// サーシャリーのキーカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color tertiary; + + /// Primary container color. + /// + /// プライマリーのコンテナカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color primaryContainer; + + /// Secondary container color. + /// + /// セカンダリーのコンテナカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color secondaryContainer; + + /// Searshally container color. + /// + /// サーシャリーのコンテナカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color tertiaryContainer; + + /// Color when inactive. + /// + /// 非アクティブ時のカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color disabled; + + /// Color for light text color. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// 薄い文字色用のカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color weak; + + /// Colors for Borderline and Divider. + /// + /// ボーダーラインやDivider用のカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color outline; + + /// Color for error. + /// + /// エラー用のカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color error; + + /// Colors for Warning. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// ワーニング用のカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color warning; + + /// Colors for information display. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// 情報表示用のカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color info; + + /// Color for successful processing. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// 処理成功時用のカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color success; + + /// Background color for dialogs, cards, etc. + /// + /// ダイアログやカードなどの背景色。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color surface; + + /// Background color. + /// + /// 背景色。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color background; + + /// Color of text and icons on [primary]. + /// + /// [primary]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onPrimary; + + /// Color of text and icons on [secondary]. + /// + /// [secondary]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onSecondary; + + /// Color of text and icons on [tertiary]. + /// + /// [tertiary]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onTertiary; + + /// Color of text and icons on [primaryContainer]. + /// + /// [primaryContainer]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onPrimaryContainer; + + /// Color of text and icons on [secondaryContainer]. + /// + /// [secondaryContainer]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onSecondaryContainer; + + /// Color of text and icons on [tertiaryContainer]. + /// + /// [tertiaryContainer]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onTertiaryContainer; + + /// Color of text and icons on [disabled]. + /// + /// [disabled]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onDisabled; + + /// Color of text and icons on [surface]. + /// + /// [surface]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onSurface; + + /// color of text and icons on [background]. Usually the text color. + /// + /// [background]上のテキストやアイコンのカラー。通常文字色。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onBackground; + + /// Color of text and icons on [weak]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [weak]上のテキストやアイコンのカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color onWeak; + + /// Color of text and icons on [error]. + /// + /// [error]上のテキストやアイコンのカラー。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/color/the-color-system/color-roles + final Color onError; + + /// Color of text and icons on [info]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [info]上のテキストやアイコンのカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color onInfo; + + /// Color of text and icons on [success]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [success]上のテキストやアイコンのカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color onSuccess; + + /// Color of text and icons on [warning]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [warning]上のテキストやアイコンのカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color onWarning; + + /// Background color of [AppBar]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [AppBar]の背景色。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color? appBarColor; + + /// Color of text and icons in [AppBar]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [AppBar]のテキストやアイコンのカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color? onAppBarColor; + + /// Background color of [Scaffold]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [Scaffold]の背景色。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color? scaffoldBackgroundColor; + + /// Color for the effect when the button is tapped. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// ボタンをタップしたときのエフェクト用のカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color? splashColor; + + /// Shadow color. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// 影の色。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color shadow; + + /// Inverted black and white [surface] color. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// 白黒反転させた[surface]の色。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color inverseSurface; + + /// Color of text and icons on [inverseSurface]. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// [inverseSurface]上のテキストやアイコンのカラー。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color onInverseSurface; + + /// Inverted black and white [primary] color. + /// + /// These are colors outside of the Material3 color scheme. + /// + /// 白黒反転させた[primary]の色。 + /// + /// Material3のカラースキーム外のカラーです。 + final Color inversePrimary; +} + +/// Define a text theme. +/// +/// New themes can be defined by extending [TextThemeData]. +/// +/// テキストテーマを定義します。 +/// +/// [TextThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 +/// +/// See also: +/// +/// - https://m3.material.io/styles/typography/type-scale-tokens +@immutable +class TextThemeData { + const TextThemeData._({ + required this.displayLarge, + required this.displayMedium, + required this.displaySmall, + required this.headlineLarge, + required this.headlineMedium, + required this.headlineSmall, + required this.titleLarge, + required this.titleMedium, + required this.titleSmall, + required this.bodyLarge, + required this.bodyMedium, + required this.bodySmall, + required this.labelLarge, + required this.labelMedium, + required this.labelSmall, + this.fontSizeFactor = 1.0, + this.fontSizeDelta = 0.0, + this.defaultFontFamily, + }); + + /// Large letters for display. + /// + /// Get the larger [TextStyle] of them. + /// + /// ディスプレイ用の大きな文字。 + /// + /// その中でも大きめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle displayLarge; + + /// Large letters for display. + /// + /// Get the medium [TextStyle] of them. + /// + /// ディスプレイ用の大きな文字。 + /// + /// その中でも中くらいの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle displayMedium; + + /// Large letters for display. + /// + /// Get the smaller [TextStyle] of them. + /// + /// ディスプレイ用の大きな文字。 + /// + /// その中でも小さめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle displaySmall; + + /// Text for headlines. + /// + /// Get the larger [TextStyle] of them. + /// + /// ヘッドライン(見出し)用の文字。 + /// + /// その中でも大きめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle headlineLarge; + + /// Text for headlines. + /// + /// Get the medium [TextStyle] of them. + /// + /// ヘッドライン(見出し)用の文字。 + /// + /// その中でも中くらいの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle headlineMedium; + + /// Text for headlines. + /// + /// Get the smaller [TextStyle] of them. + /// + /// ヘッドライン(見出し)用の文字。 + /// + /// その中でも小さめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle headlineSmall; + + /// Text for the title of each widget. + /// + /// Get the larger [TextStyle] of them. + /// + /// 各ウィジェットのタイトル用の文字。 + /// + /// その中でも大きめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle titleLarge; + + /// Text for the title of each widget. + /// + /// Get the medium [TextStyle] of them. + /// + /// 各ウィジェットのタイトル用の文字。 + /// + /// その中でも中くらいの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle titleMedium; + + /// Text for the title of each widget. + /// + /// Get the smaller [TextStyle] of them. + /// + /// 各ウィジェットのタイトル用の文字。 + /// + /// その中でも小さめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle titleSmall; + + /// Text for regular text. + /// + /// Get the larger [TextStyle] of them. + /// + /// 通常文章用の文字。 + /// + /// その中でも大きめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle bodyLarge; + + /// Text for regular text. + /// + /// Get the medium [TextStyle] of them. + /// + /// 通常文章用の文字。 + /// + /// その中でも中くらいの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle bodyMedium; + + /// Text for regular text. + /// + /// Get the smaller [TextStyle] of them. + /// + /// 通常文章用の文字。 + /// + /// その中でも小さめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle bodySmall; + + /// Characters used for text, captions, etc. within each widget. + /// + /// Get the larger [TextStyle] of them. + /// + /// 各ウィジェット内の文字やキャプション等に用いる文字。 + /// + /// その中でも大きめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle labelLarge; + + /// Characters used for text, captions, etc. within each widget. + /// + /// Get the medium [TextStyle] of them. + /// + /// 各ウィジェット内の文字やキャプション等に用いる文字。 + /// + /// その中でも中くらいの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle labelMedium; + + /// Characters used for text, captions, etc. within each widget. + /// + /// Get the smaller [TextStyle] of them. + /// + /// 各ウィジェット内の文字やキャプション等に用いる文字。 + /// + /// その中でも小さめの[TextStyle]を取得します。 + /// + /// See also: + /// + /// - https://m3.material.io/styles/typography/type-scale-tokens + /// - https://m3.material.io/styles/typography/applying-type + final TextStyle labelSmall; + + /// Increase the font size of the entire app by a multiple of this value. + /// + /// For more detailed adjustment, specify [fontSizeDelta]. + /// + /// アプリ全体のフォントサイズをこの値の倍数だけ大きくします。 + /// + /// さらに細かい調整をしたい場合は[fontSizeDelta]を指定してください。 + final double fontSizeFactor; + + /// Increase the font size of the entire app by this value. + /// + /// For larger adjustments, specify [fontSizeFactor]. + /// + /// アプリ全体のフォントサイズをこの値分だけ大きくします。 + /// + /// 大きい調整をしたい場合は[fontSizeFactor]を指定してください。 + final double fontSizeDelta; + + /// Default font family. + /// + /// If this is specified, this is the font family when none is specified. + /// + /// デフォルトのフォントファミリー。 + /// + /// これが指定されている場合、何も指定されないときのフォントファミリーはこれになります。 + final String? defaultFontFamily; +} + +/// Defines the theme of the widget. +/// +/// New themes can be defined by extending [WidgetThemeData]. +/// +/// ウィジェットのテーマを定義します。 +/// +/// [WidgetThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 +@immutable +class WidgetThemeData { + const WidgetThemeData._(); +} + +/// Defines a list of asset paths. +/// +/// The builder will allow you to retrieve the assets defined in pubspec.yaml. +/// +/// New themes can be defined by extending [AssetThemeData]. +/// +/// アセットのパス一覧を定義します。 +/// +/// ビルダーによってpubspec.yaml内に定義されたアセットを取得することができるようになります。 +/// +/// [AssetThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 +@immutable +class AssetThemeData { + const AssetThemeData._(); +} + +/// Define font themes. +/// +/// The builder will allow you to retrieve the font families defined in pubspec.yaml. +/// +/// New themes can be defined by extending [FontThemeData]. +/// +/// フォントテーマを定義します。 +/// +/// ビルダーによってpubspec.yaml内に定義されたフォントファミリーを取得することができるようになります。 +/// +/// [FontThemeData]をエクステンションすることで新しいテーマを定義することが可能です。 +@immutable +class FontThemeData { + const FontThemeData._(); +} diff --git a/packages/katana_theme/lib/src/extensions.dart b/packages/katana_theme/lib/src/extensions.dart index 0f9cb1b22..d5d62cc1d 100644 --- a/packages/katana_theme/lib/src/extensions.dart +++ b/packages/katana_theme/lib/src/extensions.dart @@ -1,6 +1,38 @@ part of katana_theme; +/// Define a theme extension for [BuildContext]. +/// +/// [BuildContext]用のテーマエクステンションを定義します。 +extension ThemeBuildContextExtensions on BuildContext { + /// Get [AppThemeData] placed on the widget tree. + /// + /// ウィジェットツリー上に配置されている[AppThemeData]を取得します。 + AppThemeData get theme { + return AppThemeData.of(this); + } +} + +/// Define a theme extension for [Color]. +/// +/// [Color]用のテーマエクステンションを定義します。 extension ThemeColorExtensions on Color { + /// Detects [GradientColor] stored in [Color] and creates [LinearGradient]. + /// + /// If [Color] is not [GradientColor], [Color] will create a single-color [Gradient]. + /// + /// [begin] determines the start position of the gradient and [end] determines the end position of the gradient. + /// + /// [Color]に格納されている[GradientColor]を検出し、[LinearGradient]を作成します。 + /// + /// [Color]が[GradientColor]出ない場合は、[Color]単色の[Gradient]が作成されます。 + /// + /// [begin]でグラデーションの開始位置、[end]でグラデーションの終了位置を決定します。 + /// + /// ```dart + /// final gradientColor = GradientColor(Colors.red, Colors.white); + /// + /// final gradient = gradientColor.toLinearGradient(); + /// ``` Gradient toLinearGradient({ AlignmentGeometry begin = Alignment.centerLeft, AlignmentGeometry end = Alignment.centerRight, @@ -30,10 +62,16 @@ extension ThemeColorExtensions on Color { } } + /// Returns `true` if [Color] is [GradientColor]. + /// + /// [Color]が[GradientColor]の場合`true`を返します。 bool get isGradient { return this is GradientColor; } + /// Darkens [Color] by the amount of [amount]. + /// + /// [Color]を[amount]の分だけより暗くします。 Color darken([double amount = 0.1]) { assert(amount >= 0 && amount <= 1); final hsl = HSLColor.fromColor(this); @@ -41,6 +79,9 @@ extension ThemeColorExtensions on Color { return hslDark.toColor(); } + /// Make [Color] brighter by the amount of [amount]. + /// + /// [Color]を[amount]の分だけより明るくします。 Color lighten([double amount = 0.1]) { assert(amount >= 0 && amount <= 1); final hsl = HSLColor.fromColor(this); @@ -50,40 +91,75 @@ extension ThemeColorExtensions on Color { } } +/// Define a theme extension for [TextStyle]. +/// +/// [TextStyle]用のテーマエクステンションを定義します。 extension ThemeTextStyleExtensions on TextStyle { + /// Darkens [TextStyle.color] of the text by [amount]. + /// + /// テキストの[TextStyle.color]を[amount]の分だけより暗くします。 TextStyle darken([double amount = 0.1]) { return copyWith( color: color?.darken(amount), ); } + /// Makes [TextStyle.color] of the text brighter by [amount]. + /// + /// テキストの[TextStyle.color]を[amount]の分だけより明るくします。 TextStyle lighten([double amount = 0.1]) { return copyWith( color: color?.lighten(amount), ); } + /// Decrease [TextStyle.fontSize] of the text by the amount of [amount]. + /// + /// テキストの[TextStyle.fontSize]を[amount]の分だけ小さくします。 TextStyle smallize([double amount = 1]) { return copyWith(fontSize: fontSize == null ? null : (fontSize! - amount)); } + /// Increase [TextStyle.fontSize] of the text by the amount of [amount]. + /// + /// テキストの[TextStyle.fontSize]を[amount]の分だけ大きくします。 TextStyle largize([double amount = 1]) { return copyWith(fontSize: fontSize == null ? null : (fontSize! + amount)); } + /// Set the transparency of the text's [TextStyle.color] to [opacity]. + /// + /// Transparency should be set between 0.0 and 1.0. + /// + /// テキストの[TextStyle.color]の透過度を[opacity]に設定します。 + /// + /// 透過度は0.0〜1.0の間で設定してください。 TextStyle withOpacity(double opacity) { return copyWith(color: color?.withOpacity(opacity)); } + /// Set [TextStyle.color] to [color] for the text. + /// + /// テキストの[TextStyle.color]を[color]に設定します。 TextStyle withColor(Color color) { return copyWith(color: color); } + /// Set [TextStyle.fontWeight] to [fontWeight] for the text. + /// + /// By default, [FontWeight.bold] is set. + /// + /// テキストの[TextStyle.fontWeight]を[fontWeight]に設定します。 + /// + /// デフォルトだと[FontWeight.bold]が設定されます。 TextStyle withBold([FontWeight fontWeight = FontWeight.bold]) { return copyWith(fontWeight: fontWeight); } - TextStyle withFont(String fontfamily) { - return copyWith(fontFamily: fontfamily); + /// Set [TextStyle.fontSize] to [fontSize] for the text. + /// + /// テキストの[TextStyle.fontSize]を[fontSize]に設定します。 + TextStyle withSize(double fontSize) { + return copyWith(fontSize: fontSize); } } diff --git a/packages/katana_theme/lib/src/fonts.dart b/packages/katana_theme/lib/src/fonts.dart deleted file mode 100644 index 5ed08c9fd..000000000 --- a/packages/katana_theme/lib/src/fonts.dart +++ /dev/null @@ -1,4211 +0,0 @@ -part of katana_theme; - -@immutable -class Fonts { - const Fonts._(); - - /// GoogleFont: `ABeeZee`. - static const String aBeeZee = "ABeeZee"; - - /// GoogleFont: `Abel`. - static const String abel = "Abel"; - - /// GoogleFont: `Abhaya Libre`. - static const String abhayaLibre = "Abhaya Libre"; - - /// GoogleFont: `Abril Fatface`. - static const String abrilFatface = "Abril Fatface"; - - /// GoogleFont: `Aclonica`. - static const String aclonica = "Aclonica"; - - /// GoogleFont: `Acme`. - static const String acme = "Acme"; - - /// GoogleFont: `Actor`. - static const String actor = "Actor"; - - /// GoogleFont: `Adamina`. - static const String adamina = "Adamina"; - - /// GoogleFont: `Advent Pro`. - static const String adventPro = "Advent Pro"; - - /// GoogleFont: `Aguafina Script`. - static const String aguafinaScript = "Aguafina Script"; - - /// GoogleFont: `Akaya Kanadaka`. - static const String akayaKanadaka = "Akaya Kanadaka"; - - /// GoogleFont: `Akaya Telivigala`. - static const String akayaTelivigala = "Akaya Telivigala"; - - /// GoogleFont: `Akronim`. - static const String akronim = "Akronim"; - - /// GoogleFont: `Akshar`. - static const String akshar = "Akshar"; - - /// GoogleFont: `Aladin`. - static const String aladin = "Aladin"; - - /// GoogleFont: `Alata`. - static const String alata = "Alata"; - - /// GoogleFont: `Alatsi`. - static const String alatsi = "Alatsi"; - - /// GoogleFont: `Aldrich`. - static const String aldrich = "Aldrich"; - - /// GoogleFont: `Alef`. - static const String alef = "Alef"; - - /// GoogleFont: `Alegreya`. - static const String alegreya = "Alegreya"; - - /// GoogleFont: `Alegreya SC`. - static const String alegreyaSc = "Alegreya SC"; - - /// GoogleFont: `Alegreya Sans`. - static const String alegreyaSans = "Alegreya Sans"; - - /// GoogleFont: `Alegreya Sans SC`. - static const String alegreyaSansSc = "Alegreya Sans SC"; - - /// GoogleFont: `Aleo`. - static const String aleo = "Aleo"; - - /// GoogleFont: `Alex Brush`. - static const String alexBrush = "Alex Brush"; - - /// GoogleFont: `Alfa Slab One`. - static const String alfaSlabOne = "Alfa Slab One"; - - /// GoogleFont: `Alice`. - static const String alice = "Alice"; - - /// GoogleFont: `Alike`. - static const String alike = "Alike"; - - /// GoogleFont: `Alike Angular`. - static const String alikeAngular = "Alike Angular"; - - /// GoogleFont: `Allan`. - static const String allan = "Allan"; - - /// GoogleFont: `Allerta`. - static const String allerta = "Allerta"; - - /// GoogleFont: `Allerta Stencil`. - static const String allertaStencil = "Allerta Stencil"; - - /// GoogleFont: `Allison`. - static const String allison = "Allison"; - - /// GoogleFont: `Allura`. - static const String allura = "Allura"; - - /// GoogleFont: `Almarai`. - static const String almarai = "Almarai"; - - /// GoogleFont: `Almendra`. - static const String almendra = "Almendra"; - - /// GoogleFont: `Almendra Display`. - static const String almendraDisplay = "Almendra Display"; - - /// GoogleFont: `Almendra SC`. - static const String almendraSc = "Almendra SC"; - - /// GoogleFont: `Alumni Sans`. - static const String alumniSans = "Alumni Sans"; - - /// GoogleFont: `Alumni Sans Inline One`. - static const String alumniSansInlineOne = "Alumni Sans Inline One"; - - /// GoogleFont: `Amarante`. - static const String amarante = "Amarante"; - - /// GoogleFont: `Amaranth`. - static const String amaranth = "Amaranth"; - - /// GoogleFont: `Amatic SC`. - static const String amaticSc = "Amatic SC"; - - /// GoogleFont: `Amethysta`. - static const String amethysta = "Amethysta"; - - /// GoogleFont: `Amiko`. - static const String amiko = "Amiko"; - - /// GoogleFont: `Amiri`. - static const String amiri = "Amiri"; - - /// GoogleFont: `Amita`. - static const String amita = "Amita"; - - /// GoogleFont: `Anaheim`. - static const String anaheim = "Anaheim"; - - /// GoogleFont: `Andada Pro`. - static const String andadaPro = "Andada Pro"; - - /// GoogleFont: `Andika`. - static const String andika = "Andika"; - - /// GoogleFont: `Andika New Basic`. - static const String andikaNewBasic = "Andika New Basic"; - - /// GoogleFont: `Anek Bangla`. - static const String anekBangla = "Anek Bangla"; - - /// GoogleFont: `Anek Devanagari`. - static const String anekDevanagari = "Anek Devanagari"; - - /// GoogleFont: `Anek Gujarati`. - static const String anekGujarati = "Anek Gujarati"; - - /// GoogleFont: `Anek Gurmukhi`. - static const String anekGurmukhi = "Anek Gurmukhi"; - - /// GoogleFont: `Anek Kannada`. - static const String anekKannada = "Anek Kannada"; - - /// GoogleFont: `Anek Latin`. - static const String anekLatin = "Anek Latin"; - - /// GoogleFont: `Anek Malayalam`. - static const String anekMalayalam = "Anek Malayalam"; - - /// GoogleFont: `Anek Odia`. - static const String anekOdia = "Anek Odia"; - - /// GoogleFont: `Anek Tamil`. - static const String anekTamil = "Anek Tamil"; - - /// GoogleFont: `Anek Telugu`. - static const String anekTelugu = "Anek Telugu"; - - /// GoogleFont: `Angkor`. - static const String angkor = "Angkor"; - - /// GoogleFont: `Annie Use Your Telescope`. - static const String annieUseYourTelescope = "Annie Use Your Telescope"; - - /// GoogleFont: `Anonymous Pro`. - static const String anonymousPro = "Anonymous Pro"; - - /// GoogleFont: `Antic`. - static const String antic = "Antic"; - - /// GoogleFont: `Antic Didone`. - static const String anticDidone = "Antic Didone"; - - /// GoogleFont: `Antic Slab`. - static const String anticSlab = "Antic Slab"; - - /// GoogleFont: `Anton`. - static const String anton = "Anton"; - - /// GoogleFont: `Antonio`. - static const String antonio = "Antonio"; - - /// GoogleFont: `Anybody`. - static const String anybody = "Anybody"; - - /// GoogleFont: `Arapey`. - static const String arapey = "Arapey"; - - /// GoogleFont: `Arbutus`. - static const String arbutus = "Arbutus"; - - /// GoogleFont: `Arbutus Slab`. - static const String arbutusSlab = "Arbutus Slab"; - - /// GoogleFont: `Architects Daughter`. - static const String architectsDaughter = "Architects Daughter"; - - /// GoogleFont: `Archivo`. - static const String archivo = "Archivo"; - - /// GoogleFont: `Archivo Black`. - static const String archivoBlack = "Archivo Black"; - - /// GoogleFont: `Archivo Narrow`. - static const String archivoNarrow = "Archivo Narrow"; - - /// GoogleFont: `Are You Serious`. - static const String areYouSerious = "Are You Serious"; - - /// GoogleFont: `Aref Ruqaa`. - static const String arefRuqaa = "Aref Ruqaa"; - - /// GoogleFont: `Arima Madurai`. - static const String arimaMadurai = "Arima Madurai"; - - /// GoogleFont: `Arimo`. - static const String arimo = "Arimo"; - - /// GoogleFont: `Arizonia`. - static const String arizonia = "Arizonia"; - - /// GoogleFont: `Armata`. - static const String armata = "Armata"; - - /// GoogleFont: `Arsenal`. - static const String arsenal = "Arsenal"; - - /// GoogleFont: `Artifika`. - static const String artifika = "Artifika"; - - /// GoogleFont: `Arvo`. - static const String arvo = "Arvo"; - - /// GoogleFont: `Arya`. - static const String arya = "Arya"; - - /// GoogleFont: `Asap`. - static const String asap = "Asap"; - - /// GoogleFont: `Asap Condensed`. - static const String asapCondensed = "Asap Condensed"; - - /// GoogleFont: `Asar`. - static const String asar = "Asar"; - - /// GoogleFont: `Asset`. - static const String asset = "Asset"; - - /// GoogleFont: `Assistant`. - static const String assistant = "Assistant"; - - /// GoogleFont: `Astloch`. - static const String astloch = "Astloch"; - - /// GoogleFont: `Asul`. - static const String asul = "Asul"; - - /// GoogleFont: `Athiti`. - static const String athiti = "Athiti"; - - /// GoogleFont: `Atkinson Hyperlegible`. - static const String atkinsonHyperlegible = "Atkinson Hyperlegible"; - - /// GoogleFont: `Atma`. - static const String atma = "Atma"; - - /// GoogleFont: `Atomic Age`. - static const String atomicAge = "Atomic Age"; - - /// GoogleFont: `Aubrey`. - static const String aubrey = "Aubrey"; - - /// GoogleFont: `Audiowide`. - static const String audiowide = "Audiowide"; - - /// GoogleFont: `Autour One`. - static const String autourOne = "Autour One"; - - /// GoogleFont: `Average`. - static const String average = "Average"; - - /// GoogleFont: `Average Sans`. - static const String averageSans = "Average Sans"; - - /// GoogleFont: `Averia Gruesa Libre`. - static const String averiaGruesaLibre = "Averia Gruesa Libre"; - - /// GoogleFont: `Averia Libre`. - static const String averiaLibre = "Averia Libre"; - - /// GoogleFont: `Averia Sans Libre`. - static const String averiaSansLibre = "Averia Sans Libre"; - - /// GoogleFont: `Averia Serif Libre`. - static const String averiaSerifLibre = "Averia Serif Libre"; - - /// GoogleFont: `Azeret Mono`. - static const String azeretMono = "Azeret Mono"; - - /// GoogleFont: `B612`. - static const String b612 = "B612"; - - /// GoogleFont: `B612 Mono`. - static const String b612Mono = "B612 Mono"; - - /// GoogleFont: `BIZ UDGothic`. - static const String bizUDGothic = "BIZ UDGothic"; - - /// GoogleFont: `BIZ UDMincho`. - static const String bizUDMincho = "BIZ UDMincho"; - - /// GoogleFont: `BIZ UDPGothic`. - static const String bizUDPGothic = "BIZ UDPGothic"; - - /// GoogleFont: `BIZ UDPMincho`. - static const String bizUDPMincho = "BIZ UDPMincho"; - - /// GoogleFont: `Babylonica`. - static const String babylonica = "Babylonica"; - - /// GoogleFont: `Bad Script`. - static const String badScript = "Bad Script"; - - /// GoogleFont: `Bahiana`. - static const String bahiana = "Bahiana"; - - /// GoogleFont: `Bahianita`. - static const String bahianita = "Bahianita"; - - /// GoogleFont: `Bai Jamjuree`. - static const String baiJamjuree = "Bai Jamjuree"; - - /// GoogleFont: `Bakbak One`. - static const String bakbakOne = "Bakbak One"; - - /// GoogleFont: `Ballet`. - static const String ballet = "Ballet"; - - /// GoogleFont: `Baloo 2`. - static const String baloo2 = "Baloo 2"; - - /// GoogleFont: `Baloo Bhai 2`. - static const String balooBhai2 = "Baloo Bhai 2"; - - /// GoogleFont: `Baloo Bhaijaan 2`. - static const String balooBhaijaan2 = "Baloo Bhaijaan 2"; - - /// GoogleFont: `Baloo Bhaina 2`. - static const String balooBhaina2 = "Baloo Bhaina 2"; - - /// GoogleFont: `Baloo Chettan 2`. - static const String balooChettan2 = "Baloo Chettan 2"; - - /// GoogleFont: `Baloo Da 2`. - static const String balooDa2 = "Baloo Da 2"; - - /// GoogleFont: `Baloo Paaji 2`. - static const String balooPaaji2 = "Baloo Paaji 2"; - - /// GoogleFont: `Baloo Tamma 2`. - static const String balooTamma2 = "Baloo Tamma 2"; - - /// GoogleFont: `Baloo Tammudu 2`. - static const String balooTammudu2 = "Baloo Tammudu 2"; - - /// GoogleFont: `Baloo Thambi 2`. - static const String balooThambi2 = "Baloo Thambi 2"; - - /// GoogleFont: `Balsamiq Sans`. - static const String balsamiqSans = "Balsamiq Sans"; - - /// GoogleFont: `Balthazar`. - static const String balthazar = "Balthazar"; - - /// GoogleFont: `Bangers`. - static const String bangers = "Bangers"; - - /// GoogleFont: `Barlow`. - static const String barlow = "Barlow"; - - /// GoogleFont: `Barlow Condensed`. - static const String barlowCondensed = "Barlow Condensed"; - - /// GoogleFont: `Barlow Semi Condensed`. - static const String barlowSemiCondensed = "Barlow Semi Condensed"; - - /// GoogleFont: `Barriecito`. - static const String barriecito = "Barriecito"; - - /// GoogleFont: `Barrio`. - static const String barrio = "Barrio"; - - /// GoogleFont: `Basic`. - static const String basic = "Basic"; - - /// GoogleFont: `Baskervville`. - static const String baskervville = "Baskervville"; - - /// GoogleFont: `Battambang`. - static const String battambang = "Battambang"; - - /// GoogleFont: `Baumans`. - static const String baumans = "Baumans"; - - /// GoogleFont: `Bayon`. - static const String bayon = "Bayon"; - - /// GoogleFont: `Be Vietnam Pro`. - static const String beVietnamPro = "Be Vietnam Pro"; - - /// GoogleFont: `Beau Rivage`. - static const String beauRivage = "Beau Rivage"; - - /// GoogleFont: `Bebas Neue`. - static const String bebasNeue = "Bebas Neue"; - - /// GoogleFont: `Belgrano`. - static const String belgrano = "Belgrano"; - - /// GoogleFont: `Bellefair`. - static const String bellefair = "Bellefair"; - - /// GoogleFont: `Belleza`. - static const String belleza = "Belleza"; - - /// GoogleFont: `Bellota`. - static const String bellota = "Bellota"; - - /// GoogleFont: `Bellota Text`. - static const String bellotaText = "Bellota Text"; - - /// GoogleFont: `BenchNine`. - static const String benchNine = "BenchNine"; - - /// GoogleFont: `Benne`. - static const String benne = "Benne"; - - /// GoogleFont: `Bentham`. - static const String bentham = "Bentham"; - - /// GoogleFont: `Berkshire Swash`. - static const String berkshireSwash = "Berkshire Swash"; - - /// GoogleFont: `Besley`. - static const String besley = "Besley"; - - /// GoogleFont: `Beth Ellen`. - static const String bethEllen = "Beth Ellen"; - - /// GoogleFont: `Bevan`. - static const String bevan = "Bevan"; - - /// GoogleFont: `BhuTuka Expanded One`. - static const String bhuTukaExpandedOne = "BhuTuka Expanded One"; - - /// GoogleFont: `Big Shoulders Display`. - static const String bigShouldersDisplay = "Big Shoulders Display"; - - /// GoogleFont: `Big Shoulders Inline Display`. - static const String bigShouldersInlineDisplay = - "Big Shoulders Inline Display"; - - /// GoogleFont: `Big Shoulders Inline Text`. - static const String bigShouldersInlineText = "Big Shoulders Inline Text"; - - /// GoogleFont: `Big Shoulders Stencil Display`. - static const String bigShouldersStencilDisplay = - "Big Shoulders Stencil Display"; - - /// GoogleFont: `Big Shoulders Stencil Text`. - static const String bigShouldersStencilText = "Big Shoulders Stencil Text"; - - /// GoogleFont: `Big Shoulders Text`. - static const String bigShouldersText = "Big Shoulders Text"; - - /// GoogleFont: `Bigelow Rules`. - static const String bigelowRules = "Bigelow Rules"; - - /// GoogleFont: `Bigshot One`. - static const String bigshotOne = "Bigshot One"; - - /// GoogleFont: `Bilbo`. - static const String bilbo = "Bilbo"; - - /// GoogleFont: `Bilbo Swash Caps`. - static const String bilboSwashCaps = "Bilbo Swash Caps"; - - /// GoogleFont: `BioRhyme`. - static const String bioRhyme = "BioRhyme"; - - /// GoogleFont: `BioRhyme Expanded`. - static const String bioRhymeExpanded = "BioRhyme Expanded"; - - /// GoogleFont: `Birthstone`. - static const String birthstone = "Birthstone"; - - /// GoogleFont: `Birthstone Bounce`. - static const String birthstoneBounce = "Birthstone Bounce"; - - /// GoogleFont: `Biryani`. - static const String biryani = "Biryani"; - - /// GoogleFont: `Bitter`. - static const String bitter = "Bitter"; - - /// GoogleFont: `Black And White Picture`. - static const String blackAndWhitePicture = "Black And White Picture"; - - /// GoogleFont: `Black Han Sans`. - static const String blackHanSans = "Black Han Sans"; - - /// GoogleFont: `Black Ops One`. - static const String blackOpsOne = "Black Ops One"; - - /// GoogleFont: `Blinker`. - static const String blinker = "Blinker"; - - /// GoogleFont: `Bodoni Moda`. - static const String bodoniModa = "Bodoni Moda"; - - /// GoogleFont: `Bokor`. - static const String bokor = "Bokor"; - - /// GoogleFont: `Bona Nova`. - static const String bonaNova = "Bona Nova"; - - /// GoogleFont: `Bonbon`. - static const String bonbon = "Bonbon"; - - /// GoogleFont: `Bonheur Royale`. - static const String bonheurRoyale = "Bonheur Royale"; - - /// GoogleFont: `Boogaloo`. - static const String boogaloo = "Boogaloo"; - - /// GoogleFont: `Bowlby One`. - static const String bowlbyOne = "Bowlby One"; - - /// GoogleFont: `Bowlby One SC`. - static const String bowlbyOneSc = "Bowlby One SC"; - - /// GoogleFont: `Brawler`. - static const String brawler = "Brawler"; - - /// GoogleFont: `Bree Serif`. - static const String breeSerif = "Bree Serif"; - - /// GoogleFont: `Brygada 1918`. - static const String brygada1918 = "Brygada 1918"; - - /// GoogleFont: `Bubblegum Sans`. - static const String bubblegumSans = "Bubblegum Sans"; - - /// GoogleFont: `Bubbler One`. - static const String bubblerOne = "Bubbler One"; - - /// GoogleFont: `Buda`. - static const String buda = "Buda"; - - /// GoogleFont: `Buenard`. - static const String buenard = "Buenard"; - - /// GoogleFont: `Bungee`. - static const String bungee = "Bungee"; - - /// GoogleFont: `Bungee Hairline`. - static const String bungeeHairline = "Bungee Hairline"; - - /// GoogleFont: `Bungee Inline`. - static const String bungeeInline = "Bungee Inline"; - - /// GoogleFont: `Bungee Outline`. - static const String bungeeOutline = "Bungee Outline"; - - /// GoogleFont: `Bungee Shade`. - static const String bungeeShade = "Bungee Shade"; - - /// GoogleFont: `Butcherman`. - static const String butcherman = "Butcherman"; - - /// GoogleFont: `Butterfly Kids`. - static const String butterflyKids = "Butterfly Kids"; - - /// GoogleFont: `Cabin`. - static const String cabin = "Cabin"; - - /// GoogleFont: `Cabin Condensed`. - static const String cabinCondensed = "Cabin Condensed"; - - /// GoogleFont: `Cabin Sketch`. - static const String cabinSketch = "Cabin Sketch"; - - /// GoogleFont: `Caesar Dressing`. - static const String caesarDressing = "Caesar Dressing"; - - /// GoogleFont: `Cagliostro`. - static const String cagliostro = "Cagliostro"; - - /// GoogleFont: `Cairo`. - static const String cairo = "Cairo"; - - /// GoogleFont: `Caladea`. - static const String caladea = "Caladea"; - - /// GoogleFont: `Calistoga`. - static const String calistoga = "Calistoga"; - - /// GoogleFont: `Calligraffitti`. - static const String calligraffitti = "Calligraffitti"; - - /// GoogleFont: `Cambay`. - static const String cambay = "Cambay"; - - /// GoogleFont: `Cambo`. - static const String cambo = "Cambo"; - - /// GoogleFont: `Candal`. - static const String candal = "Candal"; - - /// GoogleFont: `Cantarell`. - static const String cantarell = "Cantarell"; - - /// GoogleFont: `Cantata One`. - static const String cantataOne = "Cantata One"; - - /// GoogleFont: `Cantora One`. - static const String cantoraOne = "Cantora One"; - - /// GoogleFont: `Capriola`. - static const String capriola = "Capriola"; - - /// GoogleFont: `Caramel`. - static const String caramel = "Caramel"; - - /// GoogleFont: `Carattere`. - static const String carattere = "Carattere"; - - /// GoogleFont: `Cardo`. - static const String cardo = "Cardo"; - - /// GoogleFont: `Carme`. - static const String carme = "Carme"; - - /// GoogleFont: `Carrois Gothic`. - static const String carroisGothic = "Carrois Gothic"; - - /// GoogleFont: `Carrois Gothic SC`. - static const String carroisGothicSc = "Carrois Gothic SC"; - - /// GoogleFont: `Carter One`. - static const String carterOne = "Carter One"; - - /// GoogleFont: `Castoro`. - static const String castoro = "Castoro"; - - /// GoogleFont: `Catamaran`. - static const String catamaran = "Catamaran"; - - /// GoogleFont: `Caudex`. - static const String caudex = "Caudex"; - - /// GoogleFont: `Caveat`. - static const String caveat = "Caveat"; - - /// GoogleFont: `Caveat Brush`. - static const String caveatBrush = "Caveat Brush"; - - /// GoogleFont: `Cedarville Cursive`. - static const String cedarvilleCursive = "Cedarville Cursive"; - - /// GoogleFont: `Ceviche One`. - static const String cevicheOne = "Ceviche One"; - - /// GoogleFont: `Chakra Petch`. - static const String chakraPetch = "Chakra Petch"; - - /// GoogleFont: `Changa`. - static const String changa = "Changa"; - - /// GoogleFont: `Changa One`. - static const String changaOne = "Changa One"; - - /// GoogleFont: `Chango`. - static const String chango = "Chango"; - - /// GoogleFont: `Charm`. - static const String charm = "Charm"; - - /// GoogleFont: `Charmonman`. - static const String charmonman = "Charmonman"; - - /// GoogleFont: `Chathura`. - static const String chathura = "Chathura"; - - /// GoogleFont: `Chau Philomene One`. - static const String chauPhilomeneOne = "Chau Philomene One"; - - /// GoogleFont: `Chela One`. - static const String chelaOne = "Chela One"; - - /// GoogleFont: `Chelsea Market`. - static const String chelseaMarket = "Chelsea Market"; - - /// GoogleFont: `Chenla`. - static const String chenla = "Chenla"; - - /// GoogleFont: `Cherish`. - static const String cherish = "Cherish"; - - /// GoogleFont: `Cherry Cream Soda`. - static const String cherryCreamSoda = "Cherry Cream Soda"; - - /// GoogleFont: `Cherry Swash`. - static const String cherrySwash = "Cherry Swash"; - - /// GoogleFont: `Chewy`. - static const String chewy = "Chewy"; - - /// GoogleFont: `Chicle`. - static const String chicle = "Chicle"; - - /// GoogleFont: `Chilanka`. - static const String chilanka = "Chilanka"; - - /// GoogleFont: `Chivo`. - static const String chivo = "Chivo"; - - /// GoogleFont: `Chonburi`. - static const String chonburi = "Chonburi"; - - /// GoogleFont: `Cinzel`. - static const String cinzel = "Cinzel"; - - /// GoogleFont: `Cinzel Decorative`. - static const String cinzelDecorative = "Cinzel Decorative"; - - /// GoogleFont: `Clicker Script`. - static const String clickerScript = "Clicker Script"; - - /// GoogleFont: `Coda`. - static const String coda = "Coda"; - - /// GoogleFont: `Coda Caption`. - static const String codaCaption = "Coda Caption"; - - /// GoogleFont: `Codystar`. - static const String codystar = "Codystar"; - - /// GoogleFont: `Coiny`. - static const String coiny = "Coiny"; - - /// GoogleFont: `Combo`. - static const String combo = "Combo"; - - /// GoogleFont: `Comfortaa`. - static const String comfortaa = "Comfortaa"; - - /// GoogleFont: `Comforter`. - static const String comforter = "Comforter"; - - /// GoogleFont: `Comforter Brush`. - static const String comforterBrush = "Comforter Brush"; - - /// GoogleFont: `Comic Neue`. - static const String comicNeue = "Comic Neue"; - - /// GoogleFont: `Coming Soon`. - static const String comingSoon = "Coming Soon"; - - /// GoogleFont: `Commissioner`. - static const String commissioner = "Commissioner"; - - /// GoogleFont: `Concert One`. - static const String concertOne = "Concert One"; - - /// GoogleFont: `Condiment`. - static const String condiment = "Condiment"; - - /// GoogleFont: `Content`. - static const String content = "Content"; - - /// GoogleFont: `Contrail One`. - static const String contrailOne = "Contrail One"; - - /// GoogleFont: `Convergence`. - static const String convergence = "Convergence"; - - /// GoogleFont: `Cookie`. - static const String cookie = "Cookie"; - - /// GoogleFont: `Copse`. - static const String copse = "Copse"; - - /// GoogleFont: `Corben`. - static const String corben = "Corben"; - - /// GoogleFont: `Corinthia`. - static const String corinthia = "Corinthia"; - - /// GoogleFont: `Cormorant`. - static const String cormorant = "Cormorant"; - - /// GoogleFont: `Cormorant Garamond`. - static const String cormorantGaramond = "Cormorant Garamond"; - - /// GoogleFont: `Cormorant Infant`. - static const String cormorantInfant = "Cormorant Infant"; - - /// GoogleFont: `Cormorant SC`. - static const String cormorantSc = "Cormorant SC"; - - /// GoogleFont: `Cormorant Unicase`. - static const String cormorantUnicase = "Cormorant Unicase"; - - /// GoogleFont: `Cormorant Upright`. - static const String cormorantUpright = "Cormorant Upright"; - - /// GoogleFont: `Courgette`. - static const String courgette = "Courgette"; - - /// GoogleFont: `Courier Prime`. - static const String courierPrime = "Courier Prime"; - - /// GoogleFont: `Cousine`. - static const String cousine = "Cousine"; - - /// GoogleFont: `Coustard`. - static const String coustard = "Coustard"; - - /// GoogleFont: `Covered By Your Grace`. - static const String coveredByYourGrace = "Covered By Your Grace"; - - /// GoogleFont: `Crafty Girls`. - static const String craftyGirls = "Crafty Girls"; - - /// GoogleFont: `Creepster`. - static const String creepster = "Creepster"; - - /// GoogleFont: `Crete Round`. - static const String creteRound = "Crete Round"; - - /// GoogleFont: `Crimson Pro`. - static const String crimsonPro = "Crimson Pro"; - - /// GoogleFont: `Croissant One`. - static const String croissantOne = "Croissant One"; - - /// GoogleFont: `Crushed`. - static const String crushed = "Crushed"; - - /// GoogleFont: `Cuprum`. - static const String cuprum = "Cuprum"; - - /// GoogleFont: `Cute Font`. - static const String cuteFont = "Cute Font"; - - /// GoogleFont: `Cutive`. - static const String cutive = "Cutive"; - - /// GoogleFont: `Cutive Mono`. - static const String cutiveMono = "Cutive Mono"; - - /// GoogleFont: `DM Mono`. - static const String dmMono = "DM Mono"; - - /// GoogleFont: `DM Sans`. - static const String dmSans = "DM Sans"; - - /// GoogleFont: `DM Serif Display`. - static const String dmSerifDisplay = "DM Serif Display"; - - /// GoogleFont: `DM Serif Text`. - static const String dmSerifText = "DM Serif Text"; - - /// GoogleFont: `Damion`. - static const String damion = "Damion"; - - /// GoogleFont: `Dancing Script`. - static const String dancingScript = "Dancing Script"; - - /// GoogleFont: `Dangrek`. - static const String dangrek = "Dangrek"; - - /// GoogleFont: `Darker Grotesque`. - static const String darkerGrotesque = "Darker Grotesque"; - - /// GoogleFont: `David Libre`. - static const String davidLibre = "David Libre"; - - /// GoogleFont: `Dawning of a New Day`. - static const String dawningOfANewDay = "Dawning of a New Day"; - - /// GoogleFont: `Days One`. - static const String daysOne = "Days One"; - - /// GoogleFont: `Dekko`. - static const String dekko = "Dekko"; - - /// GoogleFont: `Dela Gothic One`. - static const String delaGothicOne = "Dela Gothic One"; - - /// GoogleFont: `Delius`. - static const String delius = "Delius"; - - /// GoogleFont: `Delius Swash Caps`. - static const String deliusSwashCaps = "Delius Swash Caps"; - - /// GoogleFont: `Delius Unicase`. - static const String deliusUnicase = "Delius Unicase"; - - /// GoogleFont: `Della Respira`. - static const String dellaRespira = "Della Respira"; - - /// GoogleFont: `Denk One`. - static const String denkOne = "Denk One"; - - /// GoogleFont: `Devonshire`. - static const String devonshire = "Devonshire"; - - /// GoogleFont: `Dhurjati`. - static const String dhurjati = "Dhurjati"; - - /// GoogleFont: `Didact Gothic`. - static const String didactGothic = "Didact Gothic"; - - /// GoogleFont: `Diplomata`. - static const String diplomata = "Diplomata"; - - /// GoogleFont: `Diplomata SC`. - static const String diplomataSc = "Diplomata SC"; - - /// GoogleFont: `Do Hyeon`. - static const String doHyeon = "Do Hyeon"; - - /// GoogleFont: `Dokdo`. - static const String dokdo = "Dokdo"; - - /// GoogleFont: `Domine`. - static const String domine = "Domine"; - - /// GoogleFont: `Donegal One`. - static const String donegalOne = "Donegal One"; - - /// GoogleFont: `Dongle`. - static const String dongle = "Dongle"; - - /// GoogleFont: `Doppio One`. - static const String doppioOne = "Doppio One"; - - /// GoogleFont: `Dorsa`. - static const String dorsa = "Dorsa"; - - /// GoogleFont: `Dosis`. - static const String dosis = "Dosis"; - - /// GoogleFont: `DotGothic16`. - static const String dotGothic16 = "DotGothic16"; - - /// GoogleFont: `Dr Sugiyama`. - static const String drSugiyama = "Dr Sugiyama"; - - /// GoogleFont: `Duru Sans`. - static const String duruSans = "Duru Sans"; - - /// GoogleFont: `Dynalight`. - static const String dynalight = "Dynalight"; - - /// GoogleFont: `EB Garamond`. - static const String ebGaramond = "EB Garamond"; - - /// GoogleFont: `Eagle Lake`. - static const String eagleLake = "Eagle Lake"; - - /// GoogleFont: `East Sea Dokdo`. - static const String eastSeaDokdo = "East Sea Dokdo"; - - /// GoogleFont: `Eater`. - static const String eater = "Eater"; - - /// GoogleFont: `Economica`. - static const String economica = "Economica"; - - /// GoogleFont: `Eczar`. - static const String eczar = "Eczar"; - - /// GoogleFont: `El Messiri`. - static const String elMessiri = "El Messiri"; - - /// GoogleFont: `Electrolize`. - static const String electrolize = "Electrolize"; - - /// GoogleFont: `Elsie`. - static const String elsie = "Elsie"; - - /// GoogleFont: `Elsie Swash Caps`. - static const String elsieSwashCaps = "Elsie Swash Caps"; - - /// GoogleFont: `Emblema One`. - static const String emblemaOne = "Emblema One"; - - /// GoogleFont: `Emilys Candy`. - static const String emilysCandy = "Emilys Candy"; - - /// GoogleFont: `Encode Sans`. - static const String encodeSans = "Encode Sans"; - - /// GoogleFont: `Encode Sans Condensed`. - static const String encodeSansCondensed = "Encode Sans Condensed"; - - /// GoogleFont: `Encode Sans Expanded`. - static const String encodeSansExpanded = "Encode Sans Expanded"; - - /// GoogleFont: `Encode Sans SC`. - static const String encodeSansSc = "Encode Sans SC"; - - /// GoogleFont: `Encode Sans Semi Condensed`. - static const String encodeSansSemiCondensed = "Encode Sans Semi Condensed"; - - /// GoogleFont: `Encode Sans Semi Expanded`. - static const String encodeSansSemiExpanded = "Encode Sans Semi Expanded"; - - /// GoogleFont: `Engagement`. - static const String engagement = "Engagement"; - - /// GoogleFont: `Englebert`. - static const String englebert = "Englebert"; - - /// GoogleFont: `Enriqueta`. - static const String enriqueta = "Enriqueta"; - - /// GoogleFont: `Ephesis`. - static const String ephesis = "Ephesis"; - - /// GoogleFont: `Epilogue`. - static const String epilogue = "Epilogue"; - - /// GoogleFont: `Erica One`. - static const String ericaOne = "Erica One"; - - /// GoogleFont: `Esteban`. - static const String esteban = "Esteban"; - - /// GoogleFont: `Estonia`. - static const String estonia = "Estonia"; - - /// GoogleFont: `Euphoria Script`. - static const String euphoriaScript = "Euphoria Script"; - - /// GoogleFont: `Ewert`. - static const String ewert = "Ewert"; - - /// GoogleFont: `Exo`. - static const String exo = "Exo"; - - /// GoogleFont: `Exo 2`. - static const String exo2 = "Exo 2"; - - /// GoogleFont: `Expletus Sans`. - static const String expletusSans = "Expletus Sans"; - - /// GoogleFont: `Explora`. - static const String explora = "Explora"; - - /// GoogleFont: `Fahkwang`. - static const String fahkwang = "Fahkwang"; - - /// GoogleFont: `Familjen Grotesk`. - static const String familjenGrotesk = "Familjen Grotesk"; - - /// GoogleFont: `Fanwood Text`. - static const String fanwoodText = "Fanwood Text"; - - /// GoogleFont: `Farro`. - static const String farro = "Farro"; - - /// GoogleFont: `Farsan`. - static const String farsan = "Farsan"; - - /// GoogleFont: `Fascinate`. - static const String fascinate = "Fascinate"; - - /// GoogleFont: `Fascinate Inline`. - static const String fascinateInline = "Fascinate Inline"; - - /// GoogleFont: `Faster One`. - static const String fasterOne = "Faster One"; - - /// GoogleFont: `Fasthand`. - static const String fasthand = "Fasthand"; - - /// GoogleFont: `Fauna One`. - static const String faunaOne = "Fauna One"; - - /// GoogleFont: `Faustina`. - static const String faustina = "Faustina"; - - /// GoogleFont: `Federant`. - static const String federant = "Federant"; - - /// GoogleFont: `Federo`. - static const String federo = "Federo"; - - /// GoogleFont: `Felipa`. - static const String felipa = "Felipa"; - - /// GoogleFont: `Fenix`. - static const String fenix = "Fenix"; - - /// GoogleFont: `Festive`. - static const String festive = "Festive"; - - /// GoogleFont: `Finger Paint`. - static const String fingerPaint = "Finger Paint"; - - /// GoogleFont: `Fira Code`. - static const String firaCode = "Fira Code"; - - /// GoogleFont: `Fira Mono`. - static const String firaMono = "Fira Mono"; - - /// GoogleFont: `Fira Sans`. - static const String firaSans = "Fira Sans"; - - /// GoogleFont: `Fira Sans Condensed`. - static const String firaSansCondensed = "Fira Sans Condensed"; - - /// GoogleFont: `Fira Sans Extra Condensed`. - static const String firaSansExtraCondensed = "Fira Sans Extra Condensed"; - - /// GoogleFont: `Fjalla One`. - static const String fjallaOne = "Fjalla One"; - - /// GoogleFont: `Fjord One`. - static const String fjordOne = "Fjord One"; - - /// GoogleFont: `Flamenco`. - static const String flamenco = "Flamenco"; - - /// GoogleFont: `Flavors`. - static const String flavors = "Flavors"; - - /// GoogleFont: `Fleur De Leah`. - static const String fleurDeLeah = "Fleur De Leah"; - - /// GoogleFont: `Flow Block`. - static const String flowBlock = "Flow Block"; - - /// GoogleFont: `Flow Circular`. - static const String flowCircular = "Flow Circular"; - - /// GoogleFont: `Flow Rounded`. - static const String flowRounded = "Flow Rounded"; - - /// GoogleFont: `Fondamento`. - static const String fondamento = "Fondamento"; - - /// GoogleFont: `Fontdiner Swanky`. - static const String fontdinerSwanky = "Fontdiner Swanky"; - - /// GoogleFont: `Forum`. - static const String forum = "Forum"; - - /// GoogleFont: `Francois One`. - static const String francoisOne = "Francois One"; - - /// GoogleFont: `Frank Ruhl Libre`. - static const String frankRuhlLibre = "Frank Ruhl Libre"; - - /// GoogleFont: `Fraunces`. - static const String fraunces = "Fraunces"; - - /// GoogleFont: `Freckle Face`. - static const String freckleFace = "Freckle Face"; - - /// GoogleFont: `Fredericka the Great`. - static const String frederickaTheGreat = "Fredericka the Great"; - - /// GoogleFont: `Fredoka`. - static const String fredoka = "Fredoka"; - - /// GoogleFont: `Fredoka One`. - static const String fredokaOne = "Fredoka One"; - - /// GoogleFont: `Freehand`. - static const String freehand = "Freehand"; - - /// GoogleFont: `Fresca`. - static const String fresca = "Fresca"; - - /// GoogleFont: `Frijole`. - static const String frijole = "Frijole"; - - /// GoogleFont: `Fruktur`. - static const String fruktur = "Fruktur"; - - /// GoogleFont: `Fugaz One`. - static const String fugazOne = "Fugaz One"; - - /// GoogleFont: `Fuggles`. - static const String fuggles = "Fuggles"; - - /// GoogleFont: `Fuzzy Bubbles`. - static const String fuzzyBubbles = "Fuzzy Bubbles"; - - /// GoogleFont: `GFS Didot`. - static const String gfsDidot = "GFS Didot"; - - /// GoogleFont: `GFS Neohellenic`. - static const String gfsNeohellenic = "GFS Neohellenic"; - - /// GoogleFont: `Gabriela`. - static const String gabriela = "Gabriela"; - - /// GoogleFont: `Gaegu`. - static const String gaegu = "Gaegu"; - - /// GoogleFont: `Gafata`. - static const String gafata = "Gafata"; - - /// GoogleFont: `Galada`. - static const String galada = "Galada"; - - /// GoogleFont: `Galdeano`. - static const String galdeano = "Galdeano"; - - /// GoogleFont: `Galindo`. - static const String galindo = "Galindo"; - - /// GoogleFont: `Gamja Flower`. - static const String gamjaFlower = "Gamja Flower"; - - /// GoogleFont: `Gayathri`. - static const String gayathri = "Gayathri"; - - /// GoogleFont: `Gelasio`. - static const String gelasio = "Gelasio"; - - /// GoogleFont: `Gemunu Libre`. - static const String gemunuLibre = "Gemunu Libre"; - - /// GoogleFont: `Genos`. - static const String genos = "Genos"; - - /// GoogleFont: `Gentium Basic`. - static const String gentiumBasic = "Gentium Basic"; - - /// GoogleFont: `Gentium Book Basic`. - static const String gentiumBookBasic = "Gentium Book Basic"; - - /// GoogleFont: `Geo`. - static const String geo = "Geo"; - - /// GoogleFont: `Georama`. - static const String georama = "Georama"; - - /// GoogleFont: `Geostar`. - static const String geostar = "Geostar"; - - /// GoogleFont: `Geostar Fill`. - static const String geostarFill = "Geostar Fill"; - - /// GoogleFont: `Germania One`. - static const String germaniaOne = "Germania One"; - - /// GoogleFont: `Gideon Roman`. - static const String gideonRoman = "Gideon Roman"; - - /// GoogleFont: `Gidugu`. - static const String gidugu = "Gidugu"; - - /// GoogleFont: `Gilda Display`. - static const String gildaDisplay = "Gilda Display"; - - /// GoogleFont: `Girassol`. - static const String girassol = "Girassol"; - - /// GoogleFont: `Give You Glory`. - static const String giveYouGlory = "Give You Glory"; - - /// GoogleFont: `Glass Antiqua`. - static const String glassAntiqua = "Glass Antiqua"; - - /// GoogleFont: `Glegoo`. - static const String glegoo = "Glegoo"; - - /// GoogleFont: `Gloria Hallelujah`. - static const String gloriaHallelujah = "Gloria Hallelujah"; - - /// GoogleFont: `Glory`. - static const String glory = "Glory"; - - /// GoogleFont: `Gluten`. - static const String gluten = "Gluten"; - - /// GoogleFont: `Goblin One`. - static const String goblinOne = "Goblin One"; - - /// GoogleFont: `Gochi Hand`. - static const String gochiHand = "Gochi Hand"; - - /// GoogleFont: `Goldman`. - static const String goldman = "Goldman"; - - /// GoogleFont: `Gorditas`. - static const String gorditas = "Gorditas"; - - /// GoogleFont: `Gothic A1`. - static const String gothicA1 = "Gothic A1"; - - /// GoogleFont: `Gotu`. - static const String gotu = "Gotu"; - - /// GoogleFont: `Goudy Bookletter 1911`. - static const String goudyBookletter1911 = "Goudy Bookletter 1911"; - - /// GoogleFont: `Gowun Batang`. - static const String gowunBatang = "Gowun Batang"; - - /// GoogleFont: `Gowun Dodum`. - static const String gowunDodum = "Gowun Dodum"; - - /// GoogleFont: `Graduate`. - static const String graduate = "Graduate"; - - /// GoogleFont: `Grand Hotel`. - static const String grandHotel = "Grand Hotel"; - - /// GoogleFont: `Grandstander`. - static const String grandstander = "Grandstander"; - - /// GoogleFont: `Grape Nuts`. - static const String grapeNuts = "Grape Nuts"; - - /// GoogleFont: `Gravitas One`. - static const String gravitasOne = "Gravitas One"; - - /// GoogleFont: `Great Vibes`. - static const String greatVibes = "Great Vibes"; - - /// GoogleFont: `Grechen Fuemen`. - static const String grechenFuemen = "Grechen Fuemen"; - - /// GoogleFont: `Grenze`. - static const String grenze = "Grenze"; - - /// GoogleFont: `Grenze Gotisch`. - static const String grenzeGotisch = "Grenze Gotisch"; - - /// GoogleFont: `Grey Qo`. - static const String greyQo = "Grey Qo"; - - /// GoogleFont: `Griffy`. - static const String griffy = "Griffy"; - - /// GoogleFont: `Gruppo`. - static const String gruppo = "Gruppo"; - - /// GoogleFont: `Gudea`. - static const String gudea = "Gudea"; - - /// GoogleFont: `Gugi`. - static const String gugi = "Gugi"; - - /// GoogleFont: `Gupter`. - static const String gupter = "Gupter"; - - /// GoogleFont: `Gurajada`. - static const String gurajada = "Gurajada"; - - /// GoogleFont: `Gwendolyn`. - static const String gwendolyn = "Gwendolyn"; - - /// GoogleFont: `Habibi`. - static const String habibi = "Habibi"; - - /// GoogleFont: `Hachi Maru Pop`. - static const String hachiMaruPop = "Hachi Maru Pop"; - - /// GoogleFont: `Hahmlet`. - static const String hahmlet = "Hahmlet"; - - /// GoogleFont: `Halant`. - static const String halant = "Halant"; - - /// GoogleFont: `Hammersmith One`. - static const String hammersmithOne = "Hammersmith One"; - - /// GoogleFont: `Hanalei`. - static const String hanalei = "Hanalei"; - - /// GoogleFont: `Hanalei Fill`. - static const String hanaleiFill = "Hanalei Fill"; - - /// GoogleFont: `Handlee`. - static const String handlee = "Handlee"; - - /// GoogleFont: `Hanuman`. - static const String hanuman = "Hanuman"; - - /// GoogleFont: `Happy Monkey`. - static const String happyMonkey = "Happy Monkey"; - - /// GoogleFont: `Harmattan`. - static const String harmattan = "Harmattan"; - - /// GoogleFont: `Headland One`. - static const String headlandOne = "Headland One"; - - /// GoogleFont: `Heebo`. - static const String heebo = "Heebo"; - - /// GoogleFont: `Henny Penny`. - static const String hennyPenny = "Henny Penny"; - - /// GoogleFont: `Hepta Slab`. - static const String heptaSlab = "Hepta Slab"; - - /// GoogleFont: `Herr Von Muellerhoff`. - static const String herrVonMuellerhoff = "Herr Von Muellerhoff"; - - /// GoogleFont: `Hi Melody`. - static const String hiMelody = "Hi Melody"; - - /// GoogleFont: `Hina Mincho`. - static const String hinaMincho = "Hina Mincho"; - - /// GoogleFont: `Hind`. - static const String hind = "Hind"; - - /// GoogleFont: `Hind Guntur`. - static const String hindGuntur = "Hind Guntur"; - - /// GoogleFont: `Hind Madurai`. - static const String hindMadurai = "Hind Madurai"; - - /// GoogleFont: `Hind Siliguri`. - static const String hindSiliguri = "Hind Siliguri"; - - /// GoogleFont: `Hind Vadodara`. - static const String hindVadodara = "Hind Vadodara"; - - /// GoogleFont: `Holtwood One SC`. - static const String holtwoodOneSc = "Holtwood One SC"; - - /// GoogleFont: `Homemade Apple`. - static const String homemadeApple = "Homemade Apple"; - - /// GoogleFont: `Homenaje`. - static const String homenaje = "Homenaje"; - - /// GoogleFont: `Hubballi`. - static const String hubballi = "Hubballi"; - - /// GoogleFont: `Hurricane`. - static const String hurricane = "Hurricane"; - - /// GoogleFont: `IBM Plex Mono`. - static const String ibmPlexMono = "IBM Plex Mono"; - - /// GoogleFont: `IBM Plex Sans`. - static const String ibmPlexSans = "IBM Plex Sans"; - - /// GoogleFont: `IBM Plex Sans Arabic`. - static const String ibmPlexSansArabic = "IBM Plex Sans Arabic"; - - /// GoogleFont: `IBM Plex Sans Condensed`. - static const String ibmPlexSansCondensed = "IBM Plex Sans Condensed"; - - /// GoogleFont: `IBM Plex Sans Devanagari`. - static const String ibmPlexSansDevanagari = "IBM Plex Sans Devanagari"; - - /// GoogleFont: `IBM Plex Sans Hebrew`. - static const String ibmPlexSansHebrew = "IBM Plex Sans Hebrew"; - - /// GoogleFont: `IBM Plex Sans KR`. - static const String ibmPlexSansKr = "IBM Plex Sans KR"; - - /// GoogleFont: `IBM Plex Sans Thai`. - static const String ibmPlexSansThai = "IBM Plex Sans Thai"; - - /// GoogleFont: `IBM Plex Sans Thai Looped`. - static const String ibmPlexSansThaiLooped = "IBM Plex Sans Thai Looped"; - - /// GoogleFont: `IBM Plex Serif`. - static const String ibmPlexSerif = "IBM Plex Serif"; - - /// GoogleFont: `IM Fell DW Pica`. - static const String imFellDwPica = "IM Fell DW Pica"; - - /// GoogleFont: `IM Fell DW Pica SC`. - static const String imFellDwPicaSc = "IM Fell DW Pica SC"; - - /// GoogleFont: `IM Fell Double Pica`. - static const String imFellDoublePica = "IM Fell Double Pica"; - - /// GoogleFont: `IM Fell Double Pica SC`. - static const String imFellDoublePicaSc = "IM Fell Double Pica SC"; - - /// GoogleFont: `IM Fell English`. - static const String imFellEnglish = "IM Fell English"; - - /// GoogleFont: `IM Fell English SC`. - static const String imFellEnglishSc = "IM Fell English SC"; - - /// GoogleFont: `IM Fell French Canon`. - static const String imFellFrenchCanon = "IM Fell French Canon"; - - /// GoogleFont: `IM Fell French Canon SC`. - static const String imFellFrenchCanonSc = "IM Fell French Canon SC"; - - /// GoogleFont: `IM Fell Great Primer`. - static const String imFellGreatPrimer = "IM Fell Great Primer"; - - /// GoogleFont: `IM Fell Great Primer SC`. - static const String imFellGreatPrimerSc = "IM Fell Great Primer SC"; - - /// GoogleFont: `Ibarra Real Nova`. - static const String ibarraRealNova = "Ibarra Real Nova"; - - /// GoogleFont: `Iceberg`. - static const String iceberg = "Iceberg"; - - /// GoogleFont: `Iceland`. - static const String iceland = "Iceland"; - - /// GoogleFont: `Imbue`. - static const String imbue = "Imbue"; - - /// GoogleFont: `Imperial Script`. - static const String imperialScript = "Imperial Script"; - - /// GoogleFont: `Imprima`. - static const String imprima = "Imprima"; - - /// GoogleFont: `Inconsolata`. - static const String inconsolata = "Inconsolata"; - - /// GoogleFont: `Inder`. - static const String inder = "Inder"; - - /// GoogleFont: `Indie Flower`. - static const String indieFlower = "Indie Flower"; - - /// GoogleFont: `Ingrid Darling`. - static const String ingridDarling = "Ingrid Darling"; - - /// GoogleFont: `Inika`. - static const String inika = "Inika"; - - /// GoogleFont: `Inknut Antiqua`. - static const String inknutAntiqua = "Inknut Antiqua"; - - /// GoogleFont: `Inria Sans`. - static const String inriaSans = "Inria Sans"; - - /// GoogleFont: `Inria Serif`. - static const String inriaSerif = "Inria Serif"; - - /// GoogleFont: `Inspiration`. - static const String inspiration = "Inspiration"; - - /// GoogleFont: `Inter`. - static const String inter = "Inter"; - - /// GoogleFont: `Irish Grover`. - static const String irishGrover = "Irish Grover"; - - /// GoogleFont: `Island Moments`. - static const String islandMoments = "Island Moments"; - - /// GoogleFont: `Istok Web`. - static const String istokWeb = "Istok Web"; - - /// GoogleFont: `Italiana`. - static const String italiana = "Italiana"; - - /// GoogleFont: `Italianno`. - static const String italianno = "Italianno"; - - /// GoogleFont: `Itim`. - static const String itim = "Itim"; - - /// GoogleFont: `Jacques Francois`. - static const String jacquesFrancois = "Jacques Francois"; - - /// GoogleFont: `Jacques Francois Shadow`. - static const String jacquesFrancoisShadow = "Jacques Francois Shadow"; - - /// GoogleFont: `Jaldi`. - static const String jaldi = "Jaldi"; - - /// GoogleFont: `JetBrains Mono`. - static const String jetBrainsMono = "JetBrains Mono"; - - /// GoogleFont: `Jim Nightshade`. - static const String jimNightshade = "Jim Nightshade"; - - /// GoogleFont: `Jockey One`. - static const String jockeyOne = "Jockey One"; - - /// GoogleFont: `Jolly Lodger`. - static const String jollyLodger = "Jolly Lodger"; - - /// GoogleFont: `Jomhuria`. - static const String jomhuria = "Jomhuria"; - - /// GoogleFont: `Jomolhari`. - static const String jomolhari = "Jomolhari"; - - /// GoogleFont: `Josefin Sans`. - static const String josefinSans = "Josefin Sans"; - - /// GoogleFont: `Josefin Slab`. - static const String josefinSlab = "Josefin Slab"; - - /// GoogleFont: `Jost`. - static const String jost = "Jost"; - - /// GoogleFont: `Joti One`. - static const String jotiOne = "Joti One"; - - /// GoogleFont: `Jua`. - static const String jua = "Jua"; - - /// GoogleFont: `Judson`. - static const String judson = "Judson"; - - /// GoogleFont: `Julee`. - static const String julee = "Julee"; - - /// GoogleFont: `Julius Sans One`. - static const String juliusSansOne = "Julius Sans One"; - - /// GoogleFont: `Junge`. - static const String junge = "Junge"; - - /// GoogleFont: `Jura`. - static const String jura = "Jura"; - - /// GoogleFont: `Just Another Hand`. - static const String justAnotherHand = "Just Another Hand"; - - /// GoogleFont: `Just Me Again Down Here`. - static const String justMeAgainDownHere = "Just Me Again Down Here"; - - /// GoogleFont: `K2D`. - static const String k2d = "K2D"; - - /// GoogleFont: `Kadwa`. - static const String kadwa = "Kadwa"; - - /// GoogleFont: `Kaisei Decol`. - static const String kaiseiDecol = "Kaisei Decol"; - - /// GoogleFont: `Kaisei HarunoUmi`. - static const String kaiseiHarunoUmi = "Kaisei HarunoUmi"; - - /// GoogleFont: `Kaisei Opti`. - static const String kaiseiOpti = "Kaisei Opti"; - - /// GoogleFont: `Kaisei Tokumin`. - static const String kaiseiTokumin = "Kaisei Tokumin"; - - /// GoogleFont: `Kalam`. - static const String kalam = "Kalam"; - - /// GoogleFont: `Kameron`. - static const String kameron = "Kameron"; - - /// GoogleFont: `Kanit`. - static const String kanit = "Kanit"; - - /// GoogleFont: `Kantumruy`. - static const String kantumruy = "Kantumruy"; - - /// GoogleFont: `Karantina`. - static const String karantina = "Karantina"; - - /// GoogleFont: `Karla`. - static const String karla = "Karla"; - - /// GoogleFont: `Karma`. - static const String karma = "Karma"; - - /// GoogleFont: `Katibeh`. - static const String katibeh = "Katibeh"; - - /// GoogleFont: `Kaushan Script`. - static const String kaushanScript = "Kaushan Script"; - - /// GoogleFont: `Kavivanar`. - static const String kavivanar = "Kavivanar"; - - /// GoogleFont: `Kavoon`. - static const String kavoon = "Kavoon"; - - /// GoogleFont: `Kdam Thmor`. - static const String kdamThmor = "Kdam Thmor"; - - /// GoogleFont: `Keania One`. - static const String keaniaOne = "Keania One"; - - /// GoogleFont: `Kelly Slab`. - static const String kellySlab = "Kelly Slab"; - - /// GoogleFont: `Kenia`. - static const String kenia = "Kenia"; - - /// GoogleFont: `Khand`. - static const String khand = "Khand"; - - /// GoogleFont: `Khmer`. - static const String khmer = "Khmer"; - - /// GoogleFont: `Khula`. - static const String khula = "Khula"; - - /// GoogleFont: `Kings`. - static const String kings = "Kings"; - - /// GoogleFont: `Kirang Haerang`. - static const String kirangHaerang = "Kirang Haerang"; - - /// GoogleFont: `Kite One`. - static const String kiteOne = "Kite One"; - - /// GoogleFont: `Kiwi Maru`. - static const String kiwiMaru = "Kiwi Maru"; - - /// GoogleFont: `Klee One`. - static const String kleeOne = "Klee One"; - - /// GoogleFont: `Knewave`. - static const String knewave = "Knewave"; - - /// GoogleFont: `KoHo`. - static const String koHo = "KoHo"; - - /// GoogleFont: `Kodchasan`. - static const String kodchasan = "Kodchasan"; - - /// GoogleFont: `Koh Santepheap`. - static const String kohSantepheap = "Koh Santepheap"; - - /// GoogleFont: `Kolker Brush`. - static const String kolkerBrush = "Kolker Brush"; - - /// GoogleFont: `Kosugi`. - static const String kosugi = "Kosugi"; - - /// GoogleFont: `Kosugi Maru`. - static const String kosugiMaru = "Kosugi Maru"; - - /// GoogleFont: `Kotta One`. - static const String kottaOne = "Kotta One"; - - /// GoogleFont: `Koulen`. - static const String koulen = "Koulen"; - - /// GoogleFont: `Kranky`. - static const String kranky = "Kranky"; - - /// GoogleFont: `Kreon`. - static const String kreon = "Kreon"; - - /// GoogleFont: `Kristi`. - static const String kristi = "Kristi"; - - /// GoogleFont: `Krona One`. - static const String kronaOne = "Krona One"; - - /// GoogleFont: `Krub`. - static const String krub = "Krub"; - - /// GoogleFont: `Kufam`. - static const String kufam = "Kufam"; - - /// GoogleFont: `Kulim Park`. - static const String kulimPark = "Kulim Park"; - - /// GoogleFont: `Kumar One`. - static const String kumarOne = "Kumar One"; - - /// GoogleFont: `Kumar One Outline`. - static const String kumarOneOutline = "Kumar One Outline"; - - /// GoogleFont: `Kumbh Sans`. - static const String kumbhSans = "Kumbh Sans"; - - /// GoogleFont: `Kurale`. - static const String kurale = "Kurale"; - - /// GoogleFont: `La Belle Aurore`. - static const String laBelleAurore = "La Belle Aurore"; - - /// GoogleFont: `Lacquer`. - static const String lacquer = "Lacquer"; - - /// GoogleFont: `Laila`. - static const String laila = "Laila"; - - /// GoogleFont: `Lakki Reddy`. - static const String lakkiReddy = "Lakki Reddy"; - - /// GoogleFont: `Lalezar`. - static const String lalezar = "Lalezar"; - - /// GoogleFont: `Lancelot`. - static const String lancelot = "Lancelot"; - - /// GoogleFont: `Langar`. - static const String langar = "Langar"; - - /// GoogleFont: `Lateef`. - static const String lateef = "Lateef"; - - /// GoogleFont: `Lato`. - static const String lato = "Lato"; - - /// GoogleFont: `Lavishly Yours`. - static const String lavishlyYours = "Lavishly Yours"; - - /// GoogleFont: `League Gothic`. - static const String leagueGothic = "League Gothic"; - - /// GoogleFont: `League Script`. - static const String leagueScript = "League Script"; - - /// GoogleFont: `League Spartan`. - static const String leagueSpartan = "League Spartan"; - - /// GoogleFont: `Leckerli One`. - static const String leckerliOne = "Leckerli One"; - - /// GoogleFont: `Ledger`. - static const String ledger = "Ledger"; - - /// GoogleFont: `Lekton`. - static const String lekton = "Lekton"; - - /// GoogleFont: `Lemon`. - static const String lemon = "Lemon"; - - /// GoogleFont: `Lemonada`. - static const String lemonada = "Lemonada"; - - /// GoogleFont: `Lexend`. - static const String lexend = "Lexend"; - - /// GoogleFont: `Lexend Deca`. - static const String lexendDeca = "Lexend Deca"; - - /// GoogleFont: `Lexend Exa`. - static const String lexendExa = "Lexend Exa"; - - /// GoogleFont: `Lexend Giga`. - static const String lexendGiga = "Lexend Giga"; - - /// GoogleFont: `Lexend Mega`. - static const String lexendMega = "Lexend Mega"; - - /// GoogleFont: `Lexend Peta`. - static const String lexendPeta = "Lexend Peta"; - - /// GoogleFont: `Lexend Tera`. - static const String lexendTera = "Lexend Tera"; - - /// GoogleFont: `Lexend Zetta`. - static const String lexendZetta = "Lexend Zetta"; - - /// GoogleFont: `Libre Barcode 128`. - static const String libreBarcode128 = "Libre Barcode 128"; - - /// GoogleFont: `Libre Barcode 128 Text`. - static const String libreBarcode128Text = "Libre Barcode 128 Text"; - - /// GoogleFont: `Libre Barcode 39`. - static const String libreBarcode39 = "Libre Barcode 39"; - - /// GoogleFont: `Libre Barcode 39 Extended`. - static const String libreBarcode39Extended = "Libre Barcode 39 Extended"; - - /// GoogleFont: `Libre Barcode 39 Extended Text`. - static const String libreBarcode39ExtendedText = - "Libre Barcode 39 Extended Text"; - - /// GoogleFont: `Libre Barcode 39 Text`. - static const String libreBarcode39Text = "Libre Barcode 39 Text"; - - /// GoogleFont: `Libre Barcode EAN13 Text`. - static const String libreBarcodeEan13Text = "Libre Barcode EAN13 Text"; - - /// GoogleFont: `Libre Baskerville`. - static const String libreBaskerville = "Libre Baskerville"; - - /// GoogleFont: `Libre Bodoni`. - static const String libreBodoni = "Libre Bodoni"; - - /// GoogleFont: `Libre Caslon Display`. - static const String libreCaslonDisplay = "Libre Caslon Display"; - - /// GoogleFont: `Libre Caslon Text`. - static const String libreCaslonText = "Libre Caslon Text"; - - /// GoogleFont: `Libre Franklin`. - static const String libreFranklin = "Libre Franklin"; - - /// GoogleFont: `Licorice`. - static const String licorice = "Licorice"; - - /// GoogleFont: `Life Savers`. - static const String lifeSavers = "Life Savers"; - - /// GoogleFont: `Lilita One`. - static const String lilitaOne = "Lilita One"; - - /// GoogleFont: `Lily Script One`. - static const String lilyScriptOne = "Lily Script One"; - - /// GoogleFont: `Limelight`. - static const String limelight = "Limelight"; - - /// GoogleFont: `Linden Hill`. - static const String lindenHill = "Linden Hill"; - - /// GoogleFont: `Literata`. - static const String literata = "Literata"; - - /// GoogleFont: `Liu Jian Mao Cao`. - static const String liuJianMaoCao = "Liu Jian Mao Cao"; - - /// GoogleFont: `Livvic`. - static const String livvic = "Livvic"; - - /// GoogleFont: `Lobster`. - static const String lobster = "Lobster"; - - /// GoogleFont: `Lobster Two`. - static const String lobsterTwo = "Lobster Two"; - - /// GoogleFont: `Londrina Outline`. - static const String londrinaOutline = "Londrina Outline"; - - /// GoogleFont: `Londrina Shadow`. - static const String londrinaShadow = "Londrina Shadow"; - - /// GoogleFont: `Londrina Sketch`. - static const String londrinaSketch = "Londrina Sketch"; - - /// GoogleFont: `Londrina Solid`. - static const String londrinaSolid = "Londrina Solid"; - - /// GoogleFont: `Long Cang`. - static const String longCang = "Long Cang"; - - /// GoogleFont: `Lora`. - static const String lora = "Lora"; - - /// GoogleFont: `Love Light`. - static const String loveLight = "Love Light"; - - /// GoogleFont: `Love Ya Like A Sister`. - static const String loveYaLikeASister = "Love Ya Like A Sister"; - - /// GoogleFont: `Loved by the King`. - static const String lovedByTheKing = "Loved by the King"; - - /// GoogleFont: `Lovers Quarrel`. - static const String loversQuarrel = "Lovers Quarrel"; - - /// GoogleFont: `Luckiest Guy`. - static const String luckiestGuy = "Luckiest Guy"; - - /// GoogleFont: `Lusitana`. - static const String lusitana = "Lusitana"; - - /// GoogleFont: `Lustria`. - static const String lustria = "Lustria"; - - /// GoogleFont: `Luxurious Roman`. - static const String luxuriousRoman = "Luxurious Roman"; - - /// GoogleFont: `Luxurious Script`. - static const String luxuriousScript = "Luxurious Script"; - - /// GoogleFont: `M PLUS 1`. - static const String mPlus1 = "M PLUS 1"; - - /// GoogleFont: `M PLUS 1 Code`. - static const String mPlus1Code = "M PLUS 1 Code"; - - /// GoogleFont: `M PLUS 1p`. - static const String mPlus1p = "M PLUS 1p"; - - /// GoogleFont: `M PLUS 2`. - static const String mPlus2 = "M PLUS 2"; - - /// GoogleFont: `M PLUS Code Latin`. - static const String mPlusCodeLatin = "M PLUS Code Latin"; - - /// GoogleFont: `M PLUS Rounded 1c`. - static const String mPlusRounded1c = "M PLUS Rounded 1c"; - - /// GoogleFont: `Ma Shan Zheng`. - static const String maShanZheng = "Ma Shan Zheng"; - - /// GoogleFont: `Macondo`. - static const String macondo = "Macondo"; - - /// GoogleFont: `Macondo Swash Caps`. - static const String macondoSwashCaps = "Macondo Swash Caps"; - - /// GoogleFont: `Mada`. - static const String mada = "Mada"; - - /// GoogleFont: `Magra`. - static const String magra = "Magra"; - - /// GoogleFont: `Maiden Orange`. - static const String maidenOrange = "Maiden Orange"; - - /// GoogleFont: `Maitree`. - static const String maitree = "Maitree"; - - /// GoogleFont: `Major Mono Display`. - static const String majorMonoDisplay = "Major Mono Display"; - - /// GoogleFont: `Mako`. - static const String mako = "Mako"; - - /// GoogleFont: `Mali`. - static const String mali = "Mali"; - - /// GoogleFont: `Mallanna`. - static const String mallanna = "Mallanna"; - - /// GoogleFont: `Mandali`. - static const String mandali = "Mandali"; - - /// GoogleFont: `Manjari`. - static const String manjari = "Manjari"; - - /// GoogleFont: `Manrope`. - static const String manrope = "Manrope"; - - /// GoogleFont: `Mansalva`. - static const String mansalva = "Mansalva"; - - /// GoogleFont: `Manuale`. - static const String manuale = "Manuale"; - - /// GoogleFont: `Marcellus`. - static const String marcellus = "Marcellus"; - - /// GoogleFont: `Marcellus SC`. - static const String marcellusSc = "Marcellus SC"; - - /// GoogleFont: `Marck Script`. - static const String marckScript = "Marck Script"; - - /// GoogleFont: `Margarine`. - static const String margarine = "Margarine"; - - /// GoogleFont: `Markazi Text`. - static const String markaziText = "Markazi Text"; - - /// GoogleFont: `Marko One`. - static const String markoOne = "Marko One"; - - /// GoogleFont: `Marmelad`. - static const String marmelad = "Marmelad"; - - /// GoogleFont: `Martel`. - static const String martel = "Martel"; - - /// GoogleFont: `Martel Sans`. - static const String martelSans = "Martel Sans"; - - /// GoogleFont: `Marvel`. - static const String marvel = "Marvel"; - - /// GoogleFont: `Mate`. - static const String mate = "Mate"; - - /// GoogleFont: `Mate SC`. - static const String mateSc = "Mate SC"; - - /// GoogleFont: `Maven Pro`. - static const String mavenPro = "Maven Pro"; - - /// GoogleFont: `McLaren`. - static const String mcLaren = "McLaren"; - - /// GoogleFont: `Mea Culpa`. - static const String meaCulpa = "Mea Culpa"; - - /// GoogleFont: `Meddon`. - static const String meddon = "Meddon"; - - /// GoogleFont: `MedievalSharp`. - static const String medievalSharp = "MedievalSharp"; - - /// GoogleFont: `Medula One`. - static const String medulaOne = "Medula One"; - - /// GoogleFont: `Meera Inimai`. - static const String meeraInimai = "Meera Inimai"; - - /// GoogleFont: `Megrim`. - static const String megrim = "Megrim"; - - /// GoogleFont: `Meie Script`. - static const String meieScript = "Meie Script"; - - /// GoogleFont: `Meow Script`. - static const String meowScript = "Meow Script"; - - /// GoogleFont: `Merienda`. - static const String merienda = "Merienda"; - - /// GoogleFont: `Merienda One`. - static const String meriendaOne = "Merienda One"; - - /// GoogleFont: `Merriweather`. - static const String merriweather = "Merriweather"; - - /// GoogleFont: `Merriweather Sans`. - static const String merriweatherSans = "Merriweather Sans"; - - /// GoogleFont: `Metal`. - static const String metal = "Metal"; - - /// GoogleFont: `Metal Mania`. - static const String metalMania = "Metal Mania"; - - /// GoogleFont: `Metamorphous`. - static const String metamorphous = "Metamorphous"; - - /// GoogleFont: `Metrophobic`. - static const String metrophobic = "Metrophobic"; - - /// GoogleFont: `Michroma`. - static const String michroma = "Michroma"; - - /// GoogleFont: `Milonga`. - static const String milonga = "Milonga"; - - /// GoogleFont: `Miltonian`. - static const String miltonian = "Miltonian"; - - /// GoogleFont: `Miltonian Tattoo`. - static const String miltonianTattoo = "Miltonian Tattoo"; - - /// GoogleFont: `Mina`. - static const String mina = "Mina"; - - /// GoogleFont: `Miniver`. - static const String miniver = "Miniver"; - - /// GoogleFont: `Miriam Libre`. - static const String miriamLibre = "Miriam Libre"; - - /// GoogleFont: `Mirza`. - static const String mirza = "Mirza"; - - /// GoogleFont: `Miss Fajardose`. - static const String missFajardose = "Miss Fajardose"; - - /// GoogleFont: `Mitr`. - static const String mitr = "Mitr"; - - /// GoogleFont: `Mochiy Pop One`. - static const String mochiyPopOne = "Mochiy Pop One"; - - /// GoogleFont: `Mochiy Pop P One`. - static const String mochiyPopPOne = "Mochiy Pop P One"; - - /// GoogleFont: `Modak`. - static const String modak = "Modak"; - - /// GoogleFont: `Modern Antiqua`. - static const String modernAntiqua = "Modern Antiqua"; - - /// GoogleFont: `Mogra`. - static const String mogra = "Mogra"; - - /// GoogleFont: `Mohave`. - static const String mohave = "Mohave"; - - /// GoogleFont: `Molengo`. - static const String molengo = "Molengo"; - - /// GoogleFont: `Molle`. - static const String molle = "Molle"; - - /// GoogleFont: `Monda`. - static const String monda = "Monda"; - - /// GoogleFont: `Monofett`. - static const String monofett = "Monofett"; - - /// GoogleFont: `Monoton`. - static const String monoton = "Monoton"; - - /// GoogleFont: `Monsieur La Doulaise`. - static const String monsieurLaDoulaise = "Monsieur La Doulaise"; - - /// GoogleFont: `Montaga`. - static const String montaga = "Montaga"; - - /// GoogleFont: `Montagu Slab`. - static const String montaguSlab = "Montagu Slab"; - - /// GoogleFont: `MonteCarlo`. - static const String monteCarlo = "MonteCarlo"; - - /// GoogleFont: `Montez`. - static const String montez = "Montez"; - - /// GoogleFont: `Montserrat`. - static const String montserrat = "Montserrat"; - - /// GoogleFont: `Montserrat Alternates`. - static const String montserratAlternates = "Montserrat Alternates"; - - /// GoogleFont: `Montserrat Subrayada`. - static const String montserratSubrayada = "Montserrat Subrayada"; - - /// GoogleFont: `Moo Lah Lah`. - static const String mooLahLah = "Moo Lah Lah"; - - /// GoogleFont: `Moon Dance`. - static const String moonDance = "Moon Dance"; - - /// GoogleFont: `Moul`. - static const String moul = "Moul"; - - /// GoogleFont: `Moulpali`. - static const String moulpali = "Moulpali"; - - /// GoogleFont: `Mountains of Christmas`. - static const String mountainsOfChristmas = "Mountains of Christmas"; - - /// GoogleFont: `Mouse Memoirs`. - static const String mouseMemoirs = "Mouse Memoirs"; - - /// GoogleFont: `Mr Bedfort`. - static const String mrBedfort = "Mr Bedfort"; - - /// GoogleFont: `Mr Dafoe`. - static const String mrDafoe = "Mr Dafoe"; - - /// GoogleFont: `Mr De Haviland`. - static const String mrDeHaviland = "Mr De Haviland"; - - /// GoogleFont: `Mrs Saint Delafield`. - static const String mrsSaintDelafield = "Mrs Saint Delafield"; - - /// GoogleFont: `Mrs Sheppards`. - static const String mrsSheppards = "Mrs Sheppards"; - - /// GoogleFont: `Ms Madi`. - static const String msMadi = "Ms Madi"; - - /// GoogleFont: `Mukta`. - static const String mukta = "Mukta"; - - /// GoogleFont: `Mukta Mahee`. - static const String muktaMahee = "Mukta Mahee"; - - /// GoogleFont: `Mukta Malar`. - static const String muktaMalar = "Mukta Malar"; - - /// GoogleFont: `Mukta Vaani`. - static const String muktaVaani = "Mukta Vaani"; - - /// GoogleFont: `Mulish`. - static const String mulish = "Mulish"; - - /// GoogleFont: `Murecho`. - static const String murecho = "Murecho"; - - /// GoogleFont: `MuseoModerno`. - static const String museoModerno = "MuseoModerno"; - - /// GoogleFont: `My Soul`. - static const String mySoul = "My Soul"; - - /// GoogleFont: `Mystery Quest`. - static const String mysteryQuest = "Mystery Quest"; - - /// GoogleFont: `NTR`. - static const String ntr = "NTR"; - - /// GoogleFont: `Nanum Brush Script`. - static const String nanumBrushScript = "Nanum Brush Script"; - - /// GoogleFont: `Nanum Gothic`. - static const String nanumGothic = "Nanum Gothic"; - - /// GoogleFont: `Nanum Gothic Coding`. - static const String nanumGothicCoding = "Nanum Gothic Coding"; - - /// GoogleFont: `Nanum Myeongjo`. - static const String nanumMyeongjo = "Nanum Myeongjo"; - - /// GoogleFont: `Nanum Pen Script`. - static const String nanumPenScript = "Nanum Pen Script"; - - /// GoogleFont: `Neonderthaw`. - static const String neonderthaw = "Neonderthaw"; - - /// GoogleFont: `Nerko One`. - static const String nerkoOne = "Nerko One"; - - /// GoogleFont: `Neucha`. - static const String neucha = "Neucha"; - - /// GoogleFont: `Neuton`. - static const String neuton = "Neuton"; - - /// GoogleFont: `New Rocker`. - static const String newRocker = "New Rocker"; - - /// GoogleFont: `New Tegomin`. - static const String newTegomin = "New Tegomin"; - - /// GoogleFont: `News Cycle`. - static const String newsCycle = "News Cycle"; - - /// GoogleFont: `Newsreader`. - static const String newsreader = "Newsreader"; - - /// GoogleFont: `Niconne`. - static const String niconne = "Niconne"; - - /// GoogleFont: `Niramit`. - static const String niramit = "Niramit"; - - /// GoogleFont: `Nixie One`. - static const String nixieOne = "Nixie One"; - - /// GoogleFont: `Nobile`. - static const String nobile = "Nobile"; - - /// GoogleFont: `Nokora`. - static const String nokora = "Nokora"; - - /// GoogleFont: `Norican`. - static const String norican = "Norican"; - - /// GoogleFont: `Nosifer`. - static const String nosifer = "Nosifer"; - - /// GoogleFont: `Notable`. - static const String notable = "Notable"; - - /// GoogleFont: `Nothing You Could Do`. - static const String nothingYouCouldDo = "Nothing You Could Do"; - - /// GoogleFont: `Noticia Text`. - static const String noticiaText = "Noticia Text"; - - /// GoogleFont: `Noto Emoji`. - static const String notoEmoji = "Noto Emoji"; - - /// GoogleFont: `Noto Kufi Arabic`. - static const String notoKufiArabic = "Noto Kufi Arabic"; - - /// GoogleFont: `Noto Music`. - static const String notoMusic = "Noto Music"; - - /// GoogleFont: `Noto Naskh Arabic`. - static const String notoNaskhArabic = "Noto Naskh Arabic"; - - /// GoogleFont: `Noto Nastaliq Urdu`. - static const String notoNastaliqUrdu = "Noto Nastaliq Urdu"; - - /// GoogleFont: `Noto Rashi Hebrew`. - static const String notoRashiHebrew = "Noto Rashi Hebrew"; - - /// GoogleFont: `Noto Sans`. - static const String notoSans = "Noto Sans"; - - /// GoogleFont: `Noto Sans Adlam`. - static const String notoSansAdlam = "Noto Sans Adlam"; - - /// GoogleFont: `Noto Sans Adlam Unjoined`. - static const String notoSansAdlamUnjoined = "Noto Sans Adlam Unjoined"; - - /// GoogleFont: `Noto Sans Anatolian Hieroglyphs`. - static const String notoSansAnatolianHieroglyphs = - "Noto Sans Anatolian Hieroglyphs"; - - /// GoogleFont: `Noto Sans Arabic`. - static const String notoSansArabic = "Noto Sans Arabic"; - - /// GoogleFont: `Noto Sans Armenian`. - static const String notoSansArmenian = "Noto Sans Armenian"; - - /// GoogleFont: `Noto Sans Avestan`. - static const String notoSansAvestan = "Noto Sans Avestan"; - - /// GoogleFont: `Noto Sans Balinese`. - static const String notoSansBalinese = "Noto Sans Balinese"; - - /// GoogleFont: `Noto Sans Bamum`. - static const String notoSansBamum = "Noto Sans Bamum"; - - /// GoogleFont: `Noto Sans Bassa Vah`. - static const String notoSansBassaVah = "Noto Sans Bassa Vah"; - - /// GoogleFont: `Noto Sans Batak`. - static const String notoSansBatak = "Noto Sans Batak"; - - /// GoogleFont: `Noto Sans Bengali`. - static const String notoSansBengali = "Noto Sans Bengali"; - - /// GoogleFont: `Noto Sans Bhaiksuki`. - static const String notoSansBhaiksuki = "Noto Sans Bhaiksuki"; - - /// GoogleFont: `Noto Sans Brahmi`. - static const String notoSansBrahmi = "Noto Sans Brahmi"; - - /// GoogleFont: `Noto Sans Buginese`. - static const String notoSansBuginese = "Noto Sans Buginese"; - - /// GoogleFont: `Noto Sans Buhid`. - static const String notoSansBuhid = "Noto Sans Buhid"; - - /// GoogleFont: `Noto Sans Canadian Aboriginal`. - static const String notoSansCanadianAboriginal = - "Noto Sans Canadian Aboriginal"; - - /// GoogleFont: `Noto Sans Carian`. - static const String notoSansCarian = "Noto Sans Carian"; - - /// GoogleFont: `Noto Sans Caucasian Albanian`. - static const String notoSansCaucasianAlbanian = - "Noto Sans Caucasian Albanian"; - - /// GoogleFont: `Noto Sans Chakma`. - static const String notoSansChakma = "Noto Sans Chakma"; - - /// GoogleFont: `Noto Sans Cham`. - static const String notoSansCham = "Noto Sans Cham"; - - /// GoogleFont: `Noto Sans Cherokee`. - static const String notoSansCherokee = "Noto Sans Cherokee"; - - /// GoogleFont: `Noto Sans Coptic`. - static const String notoSansCoptic = "Noto Sans Coptic"; - - /// GoogleFont: `Noto Sans Cuneiform`. - static const String notoSansCuneiform = "Noto Sans Cuneiform"; - - /// GoogleFont: `Noto Sans Cypriot`. - static const String notoSansCypriot = "Noto Sans Cypriot"; - - /// GoogleFont: `Noto Sans Deseret`. - static const String notoSansDeseret = "Noto Sans Deseret"; - - /// GoogleFont: `Noto Sans Devanagari`. - static const String notoSansDevanagari = "Noto Sans Devanagari"; - - /// GoogleFont: `Noto Sans Display`. - static const String notoSansDisplay = "Noto Sans Display"; - - /// GoogleFont: `Noto Sans Duployan`. - static const String notoSansDuployan = "Noto Sans Duployan"; - - /// GoogleFont: `Noto Sans Egyptian Hieroglyphs`. - static const String notoSansEgyptianHieroglyphs = - "Noto Sans Egyptian Hieroglyphs"; - - /// GoogleFont: `Noto Sans Elbasan`. - static const String notoSansElbasan = "Noto Sans Elbasan"; - - /// GoogleFont: `Noto Sans Elymaic`. - static const String notoSansElymaic = "Noto Sans Elymaic"; - - /// GoogleFont: `Noto Sans Georgian`. - static const String notoSansGeorgian = "Noto Sans Georgian"; - - /// GoogleFont: `Noto Sans Glagolitic`. - static const String notoSansGlagolitic = "Noto Sans Glagolitic"; - - /// GoogleFont: `Noto Sans Gothic`. - static const String notoSansGothic = "Noto Sans Gothic"; - - /// GoogleFont: `Noto Sans Grantha`. - static const String notoSansGrantha = "Noto Sans Grantha"; - - /// GoogleFont: `Noto Sans Gujarati`. - static const String notoSansGujarati = "Noto Sans Gujarati"; - - /// GoogleFont: `Noto Sans Gunjala Gondi`. - static const String notoSansGunjalaGondi = "Noto Sans Gunjala Gondi"; - - /// GoogleFont: `Noto Sans Gurmukhi`. - static const String notoSansGurmukhi = "Noto Sans Gurmukhi"; - - /// GoogleFont: `Noto Sans Hanifi Rohingya`. - static const String notoSansHanifiRohingya = "Noto Sans Hanifi Rohingya"; - - /// GoogleFont: `Noto Sans Hanunoo`. - static const String notoSansHanunoo = "Noto Sans Hanunoo"; - - /// GoogleFont: `Noto Sans Hatran`. - static const String notoSansHatran = "Noto Sans Hatran"; - - /// GoogleFont: `Noto Sans Hebrew`. - static const String notoSansHebrew = "Noto Sans Hebrew"; - - /// GoogleFont: `Noto Sans Imperial Aramaic`. - static const String notoSansImperialAramaic = "Noto Sans Imperial Aramaic"; - - /// GoogleFont: `Noto Sans Indic Siyaq Numbers`. - static const String notoSansIndicSiyaqNumbers = - "Noto Sans Indic Siyaq Numbers"; - - /// GoogleFont: `Noto Sans Inscriptional Pahlavi`. - static const String notoSansInscriptionalPahlavi = - "Noto Sans Inscriptional Pahlavi"; - - /// GoogleFont: `Noto Sans Inscriptional Parthian`. - static const String notoSansInscriptionalParthian = - "Noto Sans Inscriptional Parthian"; - - /// GoogleFont: `Noto Sans Javanese`. - static const String notoSansJavanese = "Noto Sans Javanese"; - - /// GoogleFont: `Noto Sans Kaithi`. - static const String notoSansKaithi = "Noto Sans Kaithi"; - - /// GoogleFont: `Noto Sans Kannada`. - static const String notoSansKannada = "Noto Sans Kannada"; - - /// GoogleFont: `Noto Sans Kayah Li`. - static const String notoSansKayahLi = "Noto Sans Kayah Li"; - - /// GoogleFont: `Noto Sans Kharoshthi`. - static const String notoSansKharoshthi = "Noto Sans Kharoshthi"; - - /// GoogleFont: `Noto Sans Khmer`. - static const String notoSansKhmer = "Noto Sans Khmer"; - - /// GoogleFont: `Noto Sans Khojki`. - static const String notoSansKhojki = "Noto Sans Khojki"; - - /// GoogleFont: `Noto Sans Khudawadi`. - static const String notoSansKhudawadi = "Noto Sans Khudawadi"; - - /// GoogleFont: `Noto Sans Lao`. - static const String notoSansLao = "Noto Sans Lao"; - - /// GoogleFont: `Noto Sans Lepcha`. - static const String notoSansLepcha = "Noto Sans Lepcha"; - - /// GoogleFont: `Noto Sans Limbu`. - static const String notoSansLimbu = "Noto Sans Limbu"; - - /// GoogleFont: `Noto Sans Linear A`. - static const String notoSansLinearA = "Noto Sans Linear A"; - - /// GoogleFont: `Noto Sans Linear B`. - static const String notoSansLinearB = "Noto Sans Linear B"; - - /// GoogleFont: `Noto Sans Lisu`. - static const String notoSansLisu = "Noto Sans Lisu"; - - /// GoogleFont: `Noto Sans Lycian`. - static const String notoSansLycian = "Noto Sans Lycian"; - - /// GoogleFont: `Noto Sans Lydian`. - static const String notoSansLydian = "Noto Sans Lydian"; - - /// GoogleFont: `Noto Sans Mahajani`. - static const String notoSansMahajani = "Noto Sans Mahajani"; - - /// GoogleFont: `Noto Sans Malayalam`. - static const String notoSansMalayalam = "Noto Sans Malayalam"; - - /// GoogleFont: `Noto Sans Mandaic`. - static const String notoSansMandaic = "Noto Sans Mandaic"; - - /// GoogleFont: `Noto Sans Manichaean`. - static const String notoSansManichaean = "Noto Sans Manichaean"; - - /// GoogleFont: `Noto Sans Marchen`. - static const String notoSansMarchen = "Noto Sans Marchen"; - - /// GoogleFont: `Noto Sans Masaram Gondi`. - static const String notoSansMasaramGondi = "Noto Sans Masaram Gondi"; - - /// GoogleFont: `Noto Sans Math`. - static const String notoSansMath = "Noto Sans Math"; - - /// GoogleFont: `Noto Sans Mayan Numerals`. - static const String notoSansMayanNumerals = "Noto Sans Mayan Numerals"; - - /// GoogleFont: `Noto Sans Medefaidrin`. - static const String notoSansMedefaidrin = "Noto Sans Medefaidrin"; - - /// GoogleFont: `Noto Sans Meetei Mayek`. - static const String notoSansMeeteiMayek = "Noto Sans Meetei Mayek"; - - /// GoogleFont: `Noto Sans Meroitic`. - static const String notoSansMeroitic = "Noto Sans Meroitic"; - - /// GoogleFont: `Noto Sans Miao`. - static const String notoSansMiao = "Noto Sans Miao"; - - /// GoogleFont: `Noto Sans Modi`. - static const String notoSansModi = "Noto Sans Modi"; - - /// GoogleFont: `Noto Sans Mongolian`. - static const String notoSansMongolian = "Noto Sans Mongolian"; - - /// GoogleFont: `Noto Sans Mono`. - static const String notoSansMono = "Noto Sans Mono"; - - /// GoogleFont: `Noto Sans Mro`. - static const String notoSansMro = "Noto Sans Mro"; - - /// GoogleFont: `Noto Sans Multani`. - static const String notoSansMultani = "Noto Sans Multani"; - - /// GoogleFont: `Noto Sans Myanmar`. - static const String notoSansMyanmar = "Noto Sans Myanmar"; - - /// GoogleFont: `Noto Sans N Ko`. - static const String notoSansNKo = "Noto Sans N Ko"; - - /// GoogleFont: `Noto Sans Nabataean`. - static const String notoSansNabataean = "Noto Sans Nabataean"; - - /// GoogleFont: `Noto Sans New Tai Lue`. - static const String notoSansNewTaiLue = "Noto Sans New Tai Lue"; - - /// GoogleFont: `Noto Sans Newa`. - static const String notoSansNewa = "Noto Sans Newa"; - - /// GoogleFont: `Noto Sans Nushu`. - static const String notoSansNushu = "Noto Sans Nushu"; - - /// GoogleFont: `Noto Sans Ogham`. - static const String notoSansOgham = "Noto Sans Ogham"; - - /// GoogleFont: `Noto Sans Ol Chiki`. - static const String notoSansOlChiki = "Noto Sans Ol Chiki"; - - /// GoogleFont: `Noto Sans Old Hungarian`. - static const String notoSansOldHungarian = "Noto Sans Old Hungarian"; - - /// GoogleFont: `Noto Sans Old Italic`. - static const String notoSansOldItalic = "Noto Sans Old Italic"; - - /// GoogleFont: `Noto Sans Old North Arabian`. - static const String notoSansOldNorthArabian = "Noto Sans Old North Arabian"; - - /// GoogleFont: `Noto Sans Old Permic`. - static const String notoSansOldPermic = "Noto Sans Old Permic"; - - /// GoogleFont: `Noto Sans Old Persian`. - static const String notoSansOldPersian = "Noto Sans Old Persian"; - - /// GoogleFont: `Noto Sans Old Sogdian`. - static const String notoSansOldSogdian = "Noto Sans Old Sogdian"; - - /// GoogleFont: `Noto Sans Old South Arabian`. - static const String notoSansOldSouthArabian = "Noto Sans Old South Arabian"; - - /// GoogleFont: `Noto Sans Old Turkic`. - static const String notoSansOldTurkic = "Noto Sans Old Turkic"; - - /// GoogleFont: `Noto Sans Oriya`. - static const String notoSansOriya = "Noto Sans Oriya"; - - /// GoogleFont: `Noto Sans Osage`. - static const String notoSansOsage = "Noto Sans Osage"; - - /// GoogleFont: `Noto Sans Osmanya`. - static const String notoSansOsmanya = "Noto Sans Osmanya"; - - /// GoogleFont: `Noto Sans Pahawh Hmong`. - static const String notoSansPahawhHmong = "Noto Sans Pahawh Hmong"; - - /// GoogleFont: `Noto Sans Palmyrene`. - static const String notoSansPalmyrene = "Noto Sans Palmyrene"; - - /// GoogleFont: `Noto Sans Pau Cin Hau`. - static const String notoSansPauCinHau = "Noto Sans Pau Cin Hau"; - - /// GoogleFont: `Noto Sans Phags Pa`. - static const String notoSansPhagsPa = "Noto Sans Phags Pa"; - - /// GoogleFont: `Noto Sans Phoenician`. - static const String notoSansPhoenician = "Noto Sans Phoenician"; - - /// GoogleFont: `Noto Sans Psalter Pahlavi`. - static const String notoSansPsalterPahlavi = "Noto Sans Psalter Pahlavi"; - - /// GoogleFont: `Noto Sans Rejang`. - static const String notoSansRejang = "Noto Sans Rejang"; - - /// GoogleFont: `Noto Sans Runic`. - static const String notoSansRunic = "Noto Sans Runic"; - - /// GoogleFont: `Noto Sans Samaritan`. - static const String notoSansSamaritan = "Noto Sans Samaritan"; - - /// GoogleFont: `Noto Sans Saurashtra`. - static const String notoSansSaurashtra = "Noto Sans Saurashtra"; - - /// GoogleFont: `Noto Sans Sharada`. - static const String notoSansSharada = "Noto Sans Sharada"; - - /// GoogleFont: `Noto Sans Shavian`. - static const String notoSansShavian = "Noto Sans Shavian"; - - /// GoogleFont: `Noto Sans Siddham`. - static const String notoSansSiddham = "Noto Sans Siddham"; - - /// GoogleFont: `Noto Sans Sinhala`. - static const String notoSansSinhala = "Noto Sans Sinhala"; - - /// GoogleFont: `Noto Sans Sogdian`. - static const String notoSansSogdian = "Noto Sans Sogdian"; - - /// GoogleFont: `Noto Sans Sora Sompeng`. - static const String notoSansSoraSompeng = "Noto Sans Sora Sompeng"; - - /// GoogleFont: `Noto Sans Soyombo`. - static const String notoSansSoyombo = "Noto Sans Soyombo"; - - /// GoogleFont: `Noto Sans Sundanese`. - static const String notoSansSundanese = "Noto Sans Sundanese"; - - /// GoogleFont: `Noto Sans Syloti Nagri`. - static const String notoSansSylotiNagri = "Noto Sans Syloti Nagri"; - - /// GoogleFont: `Noto Sans Symbols`. - static const String notoSansSymbols = "Noto Sans Symbols"; - - /// GoogleFont: `Noto Sans Symbols 2`. - static const String notoSansSymbols2 = "Noto Sans Symbols 2"; - - /// GoogleFont: `Noto Sans Syriac`. - static const String notoSansSyriac = "Noto Sans Syriac"; - - /// GoogleFont: `Noto Sans Tagalog`. - static const String notoSansTagalog = "Noto Sans Tagalog"; - - /// GoogleFont: `Noto Sans Tagbanwa`. - static const String notoSansTagbanwa = "Noto Sans Tagbanwa"; - - /// GoogleFont: `Noto Sans Tai Le`. - static const String notoSansTaiLe = "Noto Sans Tai Le"; - - /// GoogleFont: `Noto Sans Tai Tham`. - static const String notoSansTaiTham = "Noto Sans Tai Tham"; - - /// GoogleFont: `Noto Sans Tai Viet`. - static const String notoSansTaiViet = "Noto Sans Tai Viet"; - - /// GoogleFont: `Noto Sans Takri`. - static const String notoSansTakri = "Noto Sans Takri"; - - /// GoogleFont: `Noto Sans Tamil`. - static const String notoSansTamil = "Noto Sans Tamil"; - - /// GoogleFont: `Noto Sans Tamil Supplement`. - static const String notoSansTamilSupplement = "Noto Sans Tamil Supplement"; - - /// GoogleFont: `Noto Sans Telugu`. - static const String notoSansTelugu = "Noto Sans Telugu"; - - /// GoogleFont: `Noto Sans Thaana`. - static const String notoSansThaana = "Noto Sans Thaana"; - - /// GoogleFont: `Noto Sans Thai`. - static const String notoSansThai = "Noto Sans Thai"; - - /// GoogleFont: `Noto Sans Thai Looped`. - static const String notoSansThaiLooped = "Noto Sans Thai Looped"; - - /// GoogleFont: `Noto Sans Tifinagh`. - static const String notoSansTifinagh = "Noto Sans Tifinagh"; - - /// GoogleFont: `Noto Sans Tirhuta`. - static const String notoSansTirhuta = "Noto Sans Tirhuta"; - - /// GoogleFont: `Noto Sans Ugaritic`. - static const String notoSansUgaritic = "Noto Sans Ugaritic"; - - /// GoogleFont: `Noto Sans Vai`. - static const String notoSansVai = "Noto Sans Vai"; - - /// GoogleFont: `Noto Sans Wancho`. - static const String notoSansWancho = "Noto Sans Wancho"; - - /// GoogleFont: `Noto Sans Warang Citi`. - static const String notoSansWarangCiti = "Noto Sans Warang Citi"; - - /// GoogleFont: `Noto Sans Yi`. - static const String notoSansYi = "Noto Sans Yi"; - - /// GoogleFont: `Noto Sans Zanabazar Square`. - static const String notoSansZanabazarSquare = "Noto Sans Zanabazar Square"; - - /// GoogleFont: `Noto Serif`. - static const String notoSerif = "Noto Serif"; - - /// GoogleFont: `Noto Serif Ahom`. - static const String notoSerifAhom = "Noto Serif Ahom"; - - /// GoogleFont: `Noto Serif Armenian`. - static const String notoSerifArmenian = "Noto Serif Armenian"; - - /// GoogleFont: `Noto Serif Balinese`. - static const String notoSerifBalinese = "Noto Serif Balinese"; - - /// GoogleFont: `Noto Serif Bengali`. - static const String notoSerifBengali = "Noto Serif Bengali"; - - /// GoogleFont: `Noto Serif Devanagari`. - static const String notoSerifDevanagari = "Noto Serif Devanagari"; - - /// GoogleFont: `Noto Serif Display`. - static const String notoSerifDisplay = "Noto Serif Display"; - - /// GoogleFont: `Noto Serif Dogra`. - static const String notoSerifDogra = "Noto Serif Dogra"; - - /// GoogleFont: `Noto Serif Ethiopic`. - static const String notoSerifEthiopic = "Noto Serif Ethiopic"; - - /// GoogleFont: `Noto Serif Georgian`. - static const String notoSerifGeorgian = "Noto Serif Georgian"; - - /// GoogleFont: `Noto Serif Grantha`. - static const String notoSerifGrantha = "Noto Serif Grantha"; - - /// GoogleFont: `Noto Serif Gujarati`. - static const String notoSerifGujarati = "Noto Serif Gujarati"; - - /// GoogleFont: `Noto Serif Gurmukhi`. - static const String notoSerifGurmukhi = "Noto Serif Gurmukhi"; - - /// GoogleFont: `Noto Serif Hebrew`. - static const String notoSerifHebrew = "Noto Serif Hebrew"; - - /// GoogleFont: `Noto Serif Kannada`. - static const String notoSerifKannada = "Noto Serif Kannada"; - - /// GoogleFont: `Noto Serif Khmer`. - static const String notoSerifKhmer = "Noto Serif Khmer"; - - /// GoogleFont: `Noto Serif Lao`. - static const String notoSerifLao = "Noto Serif Lao"; - - /// GoogleFont: `Noto Serif Malayalam`. - static const String notoSerifMalayalam = "Noto Serif Malayalam"; - - /// GoogleFont: `Noto Serif Myanmar`. - static const String notoSerifMyanmar = "Noto Serif Myanmar"; - - /// GoogleFont: `Noto Serif Nyiakeng Puachue Hmong`. - static const String notoSerifNyiakengPuachueHmong = - "Noto Serif Nyiakeng Puachue Hmong"; - - /// GoogleFont: `Noto Serif Sinhala`. - static const String notoSerifSinhala = "Noto Serif Sinhala"; - - /// GoogleFont: `Noto Serif Tamil`. - static const String notoSerifTamil = "Noto Serif Tamil"; - - /// GoogleFont: `Noto Serif Tangut`. - static const String notoSerifTangut = "Noto Serif Tangut"; - - /// GoogleFont: `Noto Serif Telugu`. - static const String notoSerifTelugu = "Noto Serif Telugu"; - - /// GoogleFont: `Noto Serif Thai`. - static const String notoSerifThai = "Noto Serif Thai"; - - /// GoogleFont: `Noto Serif Tibetan`. - static const String notoSerifTibetan = "Noto Serif Tibetan"; - - /// GoogleFont: `Noto Serif Yezidi`. - static const String notoSerifYezidi = "Noto Serif Yezidi"; - - /// GoogleFont: `Noto Traditional Nushu`. - static const String notoTraditionalNushu = "Noto Traditional Nushu"; - - /// GoogleFont: `Nova Cut`. - static const String novaCut = "Nova Cut"; - - /// GoogleFont: `Nova Flat`. - static const String novaFlat = "Nova Flat"; - - /// GoogleFont: `Nova Mono`. - static const String novaMono = "Nova Mono"; - - /// GoogleFont: `Nova Oval`. - static const String novaOval = "Nova Oval"; - - /// GoogleFont: `Nova Round`. - static const String novaRound = "Nova Round"; - - /// GoogleFont: `Nova Script`. - static const String novaScript = "Nova Script"; - - /// GoogleFont: `Nova Slim`. - static const String novaSlim = "Nova Slim"; - - /// GoogleFont: `Nova Square`. - static const String novaSquare = "Nova Square"; - - /// GoogleFont: `Numans`. - static const String numans = "Numans"; - - /// GoogleFont: `Nunito`. - static const String nunito = "Nunito"; - - /// GoogleFont: `Nunito Sans`. - static const String nunitoSans = "Nunito Sans"; - - /// GoogleFont: `Odibee Sans`. - static const String odibeeSans = "Odibee Sans"; - - /// GoogleFont: `Odor Mean Chey`. - static const String odorMeanChey = "Odor Mean Chey"; - - /// GoogleFont: `Offside`. - static const String offside = "Offside"; - - /// GoogleFont: `Oi`. - static const String oi = "Oi"; - - /// GoogleFont: `Old Standard TT`. - static const String oldStandardTt = "Old Standard TT"; - - /// GoogleFont: `Oldenburg`. - static const String oldenburg = "Oldenburg"; - - /// GoogleFont: `Ole`. - static const String ole = "Ole"; - - /// GoogleFont: `Oleo Script`. - static const String oleoScript = "Oleo Script"; - - /// GoogleFont: `Oleo Script Swash Caps`. - static const String oleoScriptSwashCaps = "Oleo Script Swash Caps"; - - /// GoogleFont: `Oooh Baby`. - static const String ooohBaby = "Oooh Baby"; - - /// GoogleFont: `Open Sans`. - static const String openSans = "Open Sans"; - - /// GoogleFont: `Open Sans Condensed`. - static const String openSansCondensed = "Open Sans Condensed"; - - /// GoogleFont: `Oranienbaum`. - static const String oranienbaum = "Oranienbaum"; - - /// GoogleFont: `Orbitron`. - static const String orbitron = "Orbitron"; - - /// GoogleFont: `Oregano`. - static const String oregano = "Oregano"; - - /// GoogleFont: `Orelega One`. - static const String orelegaOne = "Orelega One"; - - /// GoogleFont: `Orienta`. - static const String orienta = "Orienta"; - - /// GoogleFont: `Original Surfer`. - static const String originalSurfer = "Original Surfer"; - - /// GoogleFont: `Oswald`. - static const String oswald = "Oswald"; - - /// GoogleFont: `Otomanopee One`. - static const String otomanopeeOne = "Otomanopee One"; - - /// GoogleFont: `Outfit`. - static const String outfit = "Outfit"; - - /// GoogleFont: `Over the Rainbow`. - static const String overTheRainbow = "Over the Rainbow"; - - /// GoogleFont: `Overlock`. - static const String overlock = "Overlock"; - - /// GoogleFont: `Overlock SC`. - static const String overlockSc = "Overlock SC"; - - /// GoogleFont: `Overpass`. - static const String overpass = "Overpass"; - - /// GoogleFont: `Overpass Mono`. - static const String overpassMono = "Overpass Mono"; - - /// GoogleFont: `Ovo`. - static const String ovo = "Ovo"; - - /// GoogleFont: `Oxanium`. - static const String oxanium = "Oxanium"; - - /// GoogleFont: `Oxygen`. - static const String oxygen = "Oxygen"; - - /// GoogleFont: `Oxygen Mono`. - static const String oxygenMono = "Oxygen Mono"; - - /// GoogleFont: `PT Mono`. - static const String ptMono = "PT Mono"; - - /// GoogleFont: `PT Sans`. - static const String ptSans = "PT Sans"; - - /// GoogleFont: `PT Sans Caption`. - static const String ptSansCaption = "PT Sans Caption"; - - /// GoogleFont: `PT Sans Narrow`. - static const String ptSansNarrow = "PT Sans Narrow"; - - /// GoogleFont: `PT Serif`. - static const String ptSerif = "PT Serif"; - - /// GoogleFont: `PT Serif Caption`. - static const String ptSerifCaption = "PT Serif Caption"; - - /// GoogleFont: `Pacifico`. - static const String pacifico = "Pacifico"; - - /// GoogleFont: `Padauk`. - static const String padauk = "Padauk"; - - /// GoogleFont: `Palanquin`. - static const String palanquin = "Palanquin"; - - /// GoogleFont: `Palanquin Dark`. - static const String palanquinDark = "Palanquin Dark"; - - /// GoogleFont: `Palette Mosaic`. - static const String paletteMosaic = "Palette Mosaic"; - - /// GoogleFont: `Pangolin`. - static const String pangolin = "Pangolin"; - - /// GoogleFont: `Paprika`. - static const String paprika = "Paprika"; - - /// GoogleFont: `Parisienne`. - static const String parisienne = "Parisienne"; - - /// GoogleFont: `Passero One`. - static const String passeroOne = "Passero One"; - - /// GoogleFont: `Passion One`. - static const String passionOne = "Passion One"; - - /// GoogleFont: `Passions Conflict`. - static const String passionsConflict = "Passions Conflict"; - - /// GoogleFont: `Pathway Gothic One`. - static const String pathwayGothicOne = "Pathway Gothic One"; - - /// GoogleFont: `Patrick Hand`. - static const String patrickHand = "Patrick Hand"; - - /// GoogleFont: `Patrick Hand SC`. - static const String patrickHandSc = "Patrick Hand SC"; - - /// GoogleFont: `Pattaya`. - static const String pattaya = "Pattaya"; - - /// GoogleFont: `Patua One`. - static const String patuaOne = "Patua One"; - - /// GoogleFont: `Pavanam`. - static const String pavanam = "Pavanam"; - - /// GoogleFont: `Paytone One`. - static const String paytoneOne = "Paytone One"; - - /// GoogleFont: `Peddana`. - static const String peddana = "Peddana"; - - /// GoogleFont: `Peralta`. - static const String peralta = "Peralta"; - - /// GoogleFont: `Permanent Marker`. - static const String permanentMarker = "Permanent Marker"; - - /// GoogleFont: `Petemoss`. - static const String petemoss = "Petemoss"; - - /// GoogleFont: `Petit Formal Script`. - static const String petitFormalScript = "Petit Formal Script"; - - /// GoogleFont: `Petrona`. - static const String petrona = "Petrona"; - - /// GoogleFont: `Philosopher`. - static const String philosopher = "Philosopher"; - - /// GoogleFont: `Piazzolla`. - static const String piazzolla = "Piazzolla"; - - /// GoogleFont: `Piedra`. - static const String piedra = "Piedra"; - - /// GoogleFont: `Pinyon Script`. - static const String pinyonScript = "Pinyon Script"; - - /// GoogleFont: `Pirata One`. - static const String pirataOne = "Pirata One"; - - /// GoogleFont: `Plaster`. - static const String plaster = "Plaster"; - - /// GoogleFont: `Play`. - static const String play = "Play"; - - /// GoogleFont: `Playball`. - static const String playball = "Playball"; - - /// GoogleFont: `Playfair Display`. - static const String playfairDisplay = "Playfair Display"; - - /// GoogleFont: `Playfair Display SC`. - static const String playfairDisplaySc = "Playfair Display SC"; - - /// GoogleFont: `Plus Jakarta Sans`. - static const String plusJakartaSans = "Plus Jakarta Sans"; - - /// GoogleFont: `Podkova`. - static const String podkova = "Podkova"; - - /// GoogleFont: `Poiret One`. - static const String poiretOne = "Poiret One"; - - /// GoogleFont: `Poller One`. - static const String pollerOne = "Poller One"; - - /// GoogleFont: `Poly`. - static const String poly = "Poly"; - - /// GoogleFont: `Pompiere`. - static const String pompiere = "Pompiere"; - - /// GoogleFont: `Pontano Sans`. - static const String pontanoSans = "Pontano Sans"; - - /// GoogleFont: `Poor Story`. - static const String poorStory = "Poor Story"; - - /// GoogleFont: `Poppins`. - static const String poppins = "Poppins"; - - /// GoogleFont: `Port Lligat Sans`. - static const String portLligatSans = "Port Lligat Sans"; - - /// GoogleFont: `Port Lligat Slab`. - static const String portLligatSlab = "Port Lligat Slab"; - - /// GoogleFont: `Potta One`. - static const String pottaOne = "Potta One"; - - /// GoogleFont: `Pragati Narrow`. - static const String pragatiNarrow = "Pragati Narrow"; - - /// GoogleFont: `Praise`. - static const String praise = "Praise"; - - /// GoogleFont: `Prata`. - static const String prata = "Prata"; - - /// GoogleFont: `Preahvihear`. - static const String preahvihear = "Preahvihear"; - - /// GoogleFont: `Press Start 2P`. - static const String pressStart2p = "Press Start 2P"; - - /// GoogleFont: `Pridi`. - static const String pridi = "Pridi"; - - /// GoogleFont: `Princess Sofia`. - static const String princessSofia = "Princess Sofia"; - - /// GoogleFont: `Prociono`. - static const String prociono = "Prociono"; - - /// GoogleFont: `Prompt`. - static const String prompt = "Prompt"; - - /// GoogleFont: `Prosto One`. - static const String prostoOne = "Prosto One"; - - /// GoogleFont: `Proza Libre`. - static const String prozaLibre = "Proza Libre"; - - /// GoogleFont: `Public Sans`. - static const String publicSans = "Public Sans"; - - /// GoogleFont: `Puppies Play`. - static const String puppiesPlay = "Puppies Play"; - - /// GoogleFont: `Puritan`. - static const String puritan = "Puritan"; - - /// GoogleFont: `Purple Purse`. - static const String purplePurse = "Purple Purse"; - - /// GoogleFont: `Qahiri`. - static const String qahiri = "Qahiri"; - - /// GoogleFont: `Quando`. - static const String quando = "Quando"; - - /// GoogleFont: `Quantico`. - static const String quantico = "Quantico"; - - /// GoogleFont: `Quattrocento`. - static const String quattrocento = "Quattrocento"; - - /// GoogleFont: `Quattrocento Sans`. - static const String quattrocentoSans = "Quattrocento Sans"; - - /// GoogleFont: `Questrial`. - static const String questrial = "Questrial"; - - /// GoogleFont: `Quicksand`. - static const String quicksand = "Quicksand"; - - /// GoogleFont: `Quintessential`. - static const String quintessential = "Quintessential"; - - /// GoogleFont: `Qwigley`. - static const String qwigley = "Qwigley"; - - /// GoogleFont: `Qwitcher Grypen`. - static const String qwitcherGrypen = "Qwitcher Grypen"; - - /// GoogleFont: `Racing Sans One`. - static const String racingSansOne = "Racing Sans One"; - - /// GoogleFont: `Radio Canada`. - static const String radioCanada = "Radio Canada"; - - /// GoogleFont: `Radley`. - static const String radley = "Radley"; - - /// GoogleFont: `Rajdhani`. - static const String rajdhani = "Rajdhani"; - - /// GoogleFont: `Rakkas`. - static const String rakkas = "Rakkas"; - - /// GoogleFont: `Raleway`. - static const String raleway = "Raleway"; - - /// GoogleFont: `Raleway Dots`. - static const String ralewayDots = "Raleway Dots"; - - /// GoogleFont: `Ramabhadra`. - static const String ramabhadra = "Ramabhadra"; - - /// GoogleFont: `Ramaraja`. - static const String ramaraja = "Ramaraja"; - - /// GoogleFont: `Rambla`. - static const String rambla = "Rambla"; - - /// GoogleFont: `Rammetto One`. - static const String rammettoOne = "Rammetto One"; - - /// GoogleFont: `Rampart One`. - static const String rampartOne = "Rampart One"; - - /// GoogleFont: `Ranchers`. - static const String ranchers = "Ranchers"; - - /// GoogleFont: `Rancho`. - static const String rancho = "Rancho"; - - /// GoogleFont: `Ranga`. - static const String ranga = "Ranga"; - - /// GoogleFont: `Rasa`. - static const String rasa = "Rasa"; - - /// GoogleFont: `Rationale`. - static const String rationale = "Rationale"; - - /// GoogleFont: `Ravi Prakash`. - static const String raviPrakash = "Ravi Prakash"; - - /// GoogleFont: `Readex Pro`. - static const String readexPro = "Readex Pro"; - - /// GoogleFont: `Recursive`. - static const String recursive = "Recursive"; - - /// GoogleFont: `Red Hat Display`. - static const String redHatDisplay = "Red Hat Display"; - - /// GoogleFont: `Red Hat Mono`. - static const String redHatMono = "Red Hat Mono"; - - /// GoogleFont: `Red Hat Text`. - static const String redHatText = "Red Hat Text"; - - /// GoogleFont: `Red Rose`. - static const String redRose = "Red Rose"; - - /// GoogleFont: `Redacted`. - static const String redacted = "Redacted"; - - /// GoogleFont: `Redacted Script`. - static const String redactedScript = "Redacted Script"; - - /// GoogleFont: `Redressed`. - static const String redressed = "Redressed"; - - /// GoogleFont: `Reem Kufi`. - static const String reemKufi = "Reem Kufi"; - - /// GoogleFont: `Reenie Beanie`. - static const String reenieBeanie = "Reenie Beanie"; - - /// GoogleFont: `Reggae One`. - static const String reggaeOne = "Reggae One"; - - /// GoogleFont: `Revalia`. - static const String revalia = "Revalia"; - - /// GoogleFont: `Rhodium Libre`. - static const String rhodiumLibre = "Rhodium Libre"; - - /// GoogleFont: `Ribeye`. - static const String ribeye = "Ribeye"; - - /// GoogleFont: `Ribeye Marrow`. - static const String ribeyeMarrow = "Ribeye Marrow"; - - /// GoogleFont: `Righteous`. - static const String righteous = "Righteous"; - - /// GoogleFont: `Risque`. - static const String risque = "Risque"; - - /// GoogleFont: `Road Rage`. - static const String roadRage = "Road Rage"; - - /// GoogleFont: `Roboto`. - static const String roboto = "Roboto"; - - /// GoogleFont: `Roboto Condensed`. - static const String robotoCondensed = "Roboto Condensed"; - - /// GoogleFont: `Roboto Flex`. - static const String robotoFlex = "Roboto Flex"; - - /// GoogleFont: `Roboto Mono`. - static const String robotoMono = "Roboto Mono"; - - /// GoogleFont: `Roboto Serif`. - static const String robotoSerif = "Roboto Serif"; - - /// GoogleFont: `Roboto Slab`. - static const String robotoSlab = "Roboto Slab"; - - /// GoogleFont: `Rochester`. - static const String rochester = "Rochester"; - - /// GoogleFont: `Rock 3D`. - static const String rock3d = "Rock 3D"; - - /// GoogleFont: `Rock Salt`. - static const String rockSalt = "Rock Salt"; - - /// GoogleFont: `RocknRoll One`. - static const String rocknRollOne = "RocknRoll One"; - - /// GoogleFont: `Rokkitt`. - static const String rokkitt = "Rokkitt"; - - /// GoogleFont: `Romanesco`. - static const String romanesco = "Romanesco"; - - /// GoogleFont: `Ropa Sans`. - static const String ropaSans = "Ropa Sans"; - - /// GoogleFont: `Rosario`. - static const String rosario = "Rosario"; - - /// GoogleFont: `Rosarivo`. - static const String rosarivo = "Rosarivo"; - - /// GoogleFont: `Rouge Script`. - static const String rougeScript = "Rouge Script"; - - /// GoogleFont: `Rowdies`. - static const String rowdies = "Rowdies"; - - /// GoogleFont: `Rozha One`. - static const String rozhaOne = "Rozha One"; - - /// GoogleFont: `Rubik`. - static const String rubik = "Rubik"; - - /// GoogleFont: `Rubik Beastly`. - static const String rubikBeastly = "Rubik Beastly"; - - /// GoogleFont: `Rubik Bubbles`. - static const String rubikBubbles = "Rubik Bubbles"; - - /// GoogleFont: `Rubik Glitch`. - static const String rubikGlitch = "Rubik Glitch"; - - /// GoogleFont: `Rubik Microbe`. - static const String rubikMicrobe = "Rubik Microbe"; - - /// GoogleFont: `Rubik Mono One`. - static const String rubikMonoOne = "Rubik Mono One"; - - /// GoogleFont: `Rubik Moonrocks`. - static const String rubikMoonrocks = "Rubik Moonrocks"; - - /// GoogleFont: `Rubik Puddles`. - static const String rubikPuddles = "Rubik Puddles"; - - /// GoogleFont: `Rubik Wet Paint`. - static const String rubikWetPaint = "Rubik Wet Paint"; - - /// GoogleFont: `Ruda`. - static const String ruda = "Ruda"; - - /// GoogleFont: `Rufina`. - static const String rufina = "Rufina"; - - /// GoogleFont: `Ruge Boogie`. - static const String rugeBoogie = "Ruge Boogie"; - - /// GoogleFont: `Ruluko`. - static const String ruluko = "Ruluko"; - - /// GoogleFont: `Rum Raisin`. - static const String rumRaisin = "Rum Raisin"; - - /// GoogleFont: `Ruslan Display`. - static const String ruslanDisplay = "Ruslan Display"; - - /// GoogleFont: `Russo One`. - static const String russoOne = "Russo One"; - - /// GoogleFont: `Ruthie`. - static const String ruthie = "Ruthie"; - - /// GoogleFont: `Rye`. - static const String rye = "Rye"; - - /// GoogleFont: `STIX Two Text`. - static const String stixTwoText = "STIX Two Text"; - - /// GoogleFont: `Sacramento`. - static const String sacramento = "Sacramento"; - - /// GoogleFont: `Sahitya`. - static const String sahitya = "Sahitya"; - - /// GoogleFont: `Sail`. - static const String sail = "Sail"; - - /// GoogleFont: `Saira`. - static const String saira = "Saira"; - - /// GoogleFont: `Saira Condensed`. - static const String sairaCondensed = "Saira Condensed"; - - /// GoogleFont: `Saira Extra Condensed`. - static const String sairaExtraCondensed = "Saira Extra Condensed"; - - /// GoogleFont: `Saira Semi Condensed`. - static const String sairaSemiCondensed = "Saira Semi Condensed"; - - /// GoogleFont: `Saira Stencil One`. - static const String sairaStencilOne = "Saira Stencil One"; - - /// GoogleFont: `Salsa`. - static const String salsa = "Salsa"; - - /// GoogleFont: `Sanchez`. - static const String sanchez = "Sanchez"; - - /// GoogleFont: `Sancreek`. - static const String sancreek = "Sancreek"; - - /// GoogleFont: `Sansita`. - static const String sansita = "Sansita"; - - /// GoogleFont: `Sansita Swashed`. - static const String sansitaSwashed = "Sansita Swashed"; - - /// GoogleFont: `Sarabun`. - static const String sarabun = "Sarabun"; - - /// GoogleFont: `Sarala`. - static const String sarala = "Sarala"; - - /// GoogleFont: `Sarina`. - static const String sarina = "Sarina"; - - /// GoogleFont: `Sarpanch`. - static const String sarpanch = "Sarpanch"; - - /// GoogleFont: `Sassy Frass`. - static const String sassyFrass = "Sassy Frass"; - - /// GoogleFont: `Satisfy`. - static const String satisfy = "Satisfy"; - - /// GoogleFont: `Sawarabi Gothic`. - static const String sawarabiGothic = "Sawarabi Gothic"; - - /// GoogleFont: `Sawarabi Mincho`. - static const String sawarabiMincho = "Sawarabi Mincho"; - - /// GoogleFont: `Scada`. - static const String scada = "Scada"; - - /// GoogleFont: `Scheherazade New`. - static const String scheherazadeNew = "Scheherazade New"; - - /// GoogleFont: `Schoolbell`. - static const String schoolbell = "Schoolbell"; - - /// GoogleFont: `Scope One`. - static const String scopeOne = "Scope One"; - - /// GoogleFont: `Seaweed Script`. - static const String seaweedScript = "Seaweed Script"; - - /// GoogleFont: `Secular One`. - static const String secularOne = "Secular One"; - - /// GoogleFont: `Sedgwick Ave`. - static const String sedgwickAve = "Sedgwick Ave"; - - /// GoogleFont: `Sedgwick Ave Display`. - static const String sedgwickAveDisplay = "Sedgwick Ave Display"; - - /// GoogleFont: `Sen`. - static const String sen = "Sen"; - - /// GoogleFont: `Send Flowers`. - static const String sendFlowers = "Send Flowers"; - - /// GoogleFont: `Sevillana`. - static const String sevillana = "Sevillana"; - - /// GoogleFont: `Seymour One`. - static const String seymourOne = "Seymour One"; - - /// GoogleFont: `Shadows Into Light`. - static const String shadowsIntoLight = "Shadows Into Light"; - - /// GoogleFont: `Shadows Into Light Two`. - static const String shadowsIntoLightTwo = "Shadows Into Light Two"; - - /// GoogleFont: `Shalimar`. - static const String shalimar = "Shalimar"; - - /// GoogleFont: `Shanti`. - static const String shanti = "Shanti"; - - /// GoogleFont: `Share`. - static const String share = "Share"; - - /// GoogleFont: `Share Tech`. - static const String shareTech = "Share Tech"; - - /// GoogleFont: `Share Tech Mono`. - static const String shareTechMono = "Share Tech Mono"; - - /// GoogleFont: `Shippori Antique`. - static const String shipporiAntique = "Shippori Antique"; - - /// GoogleFont: `Shippori Antique B1`. - static const String shipporiAntiqueB1 = "Shippori Antique B1"; - - /// GoogleFont: `Shippori Mincho`. - static const String shipporiMincho = "Shippori Mincho"; - - /// GoogleFont: `Shippori Mincho B1`. - static const String shipporiMinchoB1 = "Shippori Mincho B1"; - - /// GoogleFont: `Shizuru`. - static const String shizuru = "Shizuru"; - - /// GoogleFont: `Shojumaru`. - static const String shojumaru = "Shojumaru"; - - /// GoogleFont: `Short Stack`. - static const String shortStack = "Short Stack"; - - /// GoogleFont: `Shrikhand`. - static const String shrikhand = "Shrikhand"; - - /// GoogleFont: `Siemreap`. - static const String siemreap = "Siemreap"; - - /// GoogleFont: `Sigmar One`. - static const String sigmarOne = "Sigmar One"; - - /// GoogleFont: `Signika`. - static const String signika = "Signika"; - - /// GoogleFont: `Signika Negative`. - static const String signikaNegative = "Signika Negative"; - - /// GoogleFont: `Simonetta`. - static const String simonetta = "Simonetta"; - - /// GoogleFont: `Single Day`. - static const String singleDay = "Single Day"; - - /// GoogleFont: `Sintony`. - static const String sintony = "Sintony"; - - /// GoogleFont: `Sirin Stencil`. - static const String sirinStencil = "Sirin Stencil"; - - /// GoogleFont: `Six Caps`. - static const String sixCaps = "Six Caps"; - - /// GoogleFont: `Skranji`. - static const String skranji = "Skranji"; - - /// GoogleFont: `Slabo 13px`. - static const String slabo13px = "Slabo 13px"; - - /// GoogleFont: `Slabo 27px`. - static const String slabo27px = "Slabo 27px"; - - /// GoogleFont: `Slackey`. - static const String slackey = "Slackey"; - - /// GoogleFont: `Smokum`. - static const String smokum = "Smokum"; - - /// GoogleFont: `Smooch`. - static const String smooch = "Smooch"; - - /// GoogleFont: `Smooch Sans`. - static const String smoochSans = "Smooch Sans"; - - /// GoogleFont: `Smythe`. - static const String smythe = "Smythe"; - - /// GoogleFont: `Sniglet`. - static const String sniglet = "Sniglet"; - - /// GoogleFont: `Snippet`. - static const String snippet = "Snippet"; - - /// GoogleFont: `Snowburst One`. - static const String snowburstOne = "Snowburst One"; - - /// GoogleFont: `Sofadi One`. - static const String sofadiOne = "Sofadi One"; - - /// GoogleFont: `Sofia`. - static const String sofia = "Sofia"; - - /// GoogleFont: `Solway`. - static const String solway = "Solway"; - - /// GoogleFont: `Song Myung`. - static const String songMyung = "Song Myung"; - - /// GoogleFont: `Sonsie One`. - static const String sonsieOne = "Sonsie One"; - - /// GoogleFont: `Sora`. - static const String sora = "Sora"; - - /// GoogleFont: `Sorts Mill Goudy`. - static const String sortsMillGoudy = "Sorts Mill Goudy"; - - /// GoogleFont: `Source Code Pro`. - static const String sourceCodePro = "Source Code Pro"; - - /// GoogleFont: `Source Sans 3`. - static const String sourceSans3 = "Source Sans 3"; - - /// GoogleFont: `Source Sans Pro`. - static const String sourceSansPro = "Source Sans Pro"; - - /// GoogleFont: `Source Serif 4`. - static const String sourceSerif4 = "Source Serif 4"; - - /// GoogleFont: `Source Serif Pro`. - static const String sourceSerifPro = "Source Serif Pro"; - - /// GoogleFont: `Space Grotesk`. - static const String spaceGrotesk = "Space Grotesk"; - - /// GoogleFont: `Space Mono`. - static const String spaceMono = "Space Mono"; - - /// GoogleFont: `Special Elite`. - static const String specialElite = "Special Elite"; - - /// GoogleFont: `Spectral`. - static const String spectral = "Spectral"; - - /// GoogleFont: `Spectral SC`. - static const String spectralSc = "Spectral SC"; - - /// GoogleFont: `Spicy Rice`. - static const String spicyRice = "Spicy Rice"; - - /// GoogleFont: `Spinnaker`. - static const String spinnaker = "Spinnaker"; - - /// GoogleFont: `Spirax`. - static const String spirax = "Spirax"; - - /// GoogleFont: `Spline Sans`. - static const String splineSans = "Spline Sans"; - - /// GoogleFont: `Squada One`. - static const String squadaOne = "Squada One"; - - /// GoogleFont: `Square Peg`. - static const String squarePeg = "Square Peg"; - - /// GoogleFont: `Sree Krushnadevaraya`. - static const String sreeKrushnadevaraya = "Sree Krushnadevaraya"; - - /// GoogleFont: `Sriracha`. - static const String sriracha = "Sriracha"; - - /// GoogleFont: `Srisakdi`. - static const String srisakdi = "Srisakdi"; - - /// GoogleFont: `Staatliches`. - static const String staatliches = "Staatliches"; - - /// GoogleFont: `Stalemate`. - static const String stalemate = "Stalemate"; - - /// GoogleFont: `Stalinist One`. - static const String stalinistOne = "Stalinist One"; - - /// GoogleFont: `Stardos Stencil`. - static const String stardosStencil = "Stardos Stencil"; - - /// GoogleFont: `Stick`. - static const String stick = "Stick"; - - /// GoogleFont: `Stick No Bills`. - static const String stickNoBills = "Stick No Bills"; - - /// GoogleFont: `Stint Ultra Condensed`. - static const String stintUltraCondensed = "Stint Ultra Condensed"; - - /// GoogleFont: `Stint Ultra Expanded`. - static const String stintUltraExpanded = "Stint Ultra Expanded"; - - /// GoogleFont: `Stoke`. - static const String stoke = "Stoke"; - - /// GoogleFont: `Strait`. - static const String strait = "Strait"; - - /// GoogleFont: `Style Script`. - static const String styleScript = "Style Script"; - - /// GoogleFont: `Stylish`. - static const String stylish = "Stylish"; - - /// GoogleFont: `Sue Ellen Francisco`. - static const String sueEllenFrancisco = "Sue Ellen Francisco"; - - /// GoogleFont: `Suez One`. - static const String suezOne = "Suez One"; - - /// GoogleFont: `Sulphur Point`. - static const String sulphurPoint = "Sulphur Point"; - - /// GoogleFont: `Sumana`. - static const String sumana = "Sumana"; - - /// GoogleFont: `Sunflower`. - static const String sunflower = "Sunflower"; - - /// GoogleFont: `Sunshiney`. - static const String sunshiney = "Sunshiney"; - - /// GoogleFont: `Supermercado One`. - static const String supermercadoOne = "Supermercado One"; - - /// GoogleFont: `Sura`. - static const String sura = "Sura"; - - /// GoogleFont: `Suranna`. - static const String suranna = "Suranna"; - - /// GoogleFont: `Suravaram`. - static const String suravaram = "Suravaram"; - - /// GoogleFont: `Suwannaphum`. - static const String suwannaphum = "Suwannaphum"; - - /// GoogleFont: `Swanky and Moo Moo`. - static const String swankyAndMooMoo = "Swanky and Moo Moo"; - - /// GoogleFont: `Syncopate`. - static const String syncopate = "Syncopate"; - - /// GoogleFont: `Syne`. - static const String syne = "Syne"; - - /// GoogleFont: `Syne Mono`. - static const String syneMono = "Syne Mono"; - - /// GoogleFont: `Syne Tactile`. - static const String syneTactile = "Syne Tactile"; - - /// GoogleFont: `Tajawal`. - static const String tajawal = "Tajawal"; - - /// GoogleFont: `Tangerine`. - static const String tangerine = "Tangerine"; - - /// GoogleFont: `Tapestry`. - static const String tapestry = "Tapestry"; - - /// GoogleFont: `Taprom`. - static const String taprom = "Taprom"; - - /// GoogleFont: `Tauri`. - static const String tauri = "Tauri"; - - /// GoogleFont: `Taviraj`. - static const String taviraj = "Taviraj"; - - /// GoogleFont: `Teko`. - static const String teko = "Teko"; - - /// GoogleFont: `Telex`. - static const String telex = "Telex"; - - /// GoogleFont: `Tenali Ramakrishna`. - static const String tenaliRamakrishna = "Tenali Ramakrishna"; - - /// GoogleFont: `Tenor Sans`. - static const String tenorSans = "Tenor Sans"; - - /// GoogleFont: `Text Me One`. - static const String textMeOne = "Text Me One"; - - /// GoogleFont: `Texturina`. - static const String texturina = "Texturina"; - - /// GoogleFont: `Thasadith`. - static const String thasadith = "Thasadith"; - - /// GoogleFont: `The Girl Next Door`. - static const String theGirlNextDoor = "The Girl Next Door"; - - /// GoogleFont: `The Nautigal`. - static const String theNautigal = "The Nautigal"; - - /// GoogleFont: `Tienne`. - static const String tienne = "Tienne"; - - /// GoogleFont: `Tillana`. - static const String tillana = "Tillana"; - - /// GoogleFont: `Timmana`. - static const String timmana = "Timmana"; - - /// GoogleFont: `Tinos`. - static const String tinos = "Tinos"; - - /// GoogleFont: `Titan One`. - static const String titanOne = "Titan One"; - - /// GoogleFont: `Titillium Web`. - static const String titilliumWeb = "Titillium Web"; - - /// GoogleFont: `Tomorrow`. - static const String tomorrow = "Tomorrow"; - - /// GoogleFont: `Tourney`. - static const String tourney = "Tourney"; - - /// GoogleFont: `Trade Winds`. - static const String tradeWinds = "Trade Winds"; - - /// GoogleFont: `Train One`. - static const String trainOne = "Train One"; - - /// GoogleFont: `Trirong`. - static const String trirong = "Trirong"; - - /// GoogleFont: `Trispace`. - static const String trispace = "Trispace"; - - /// GoogleFont: `Trocchi`. - static const String trocchi = "Trocchi"; - - /// GoogleFont: `Trochut`. - static const String trochut = "Trochut"; - - /// GoogleFont: `Truculenta`. - static const String truculenta = "Truculenta"; - - /// GoogleFont: `Trykker`. - static const String trykker = "Trykker"; - - /// GoogleFont: `Tulpen One`. - static const String tulpenOne = "Tulpen One"; - - /// GoogleFont: `Turret Road`. - static const String turretRoad = "Turret Road"; - - /// GoogleFont: `Twinkle Star`. - static const String twinkleStar = "Twinkle Star"; - - /// GoogleFont: `Ubuntu`. - static const String ubuntu = "Ubuntu"; - - /// GoogleFont: `Ubuntu Condensed`. - static const String ubuntuCondensed = "Ubuntu Condensed"; - - /// GoogleFont: `Ubuntu Mono`. - static const String ubuntuMono = "Ubuntu Mono"; - - /// GoogleFont: `Uchen`. - static const String uchen = "Uchen"; - - /// GoogleFont: `Ultra`. - static const String ultra = "Ultra"; - - /// GoogleFont: `Uncial Antiqua`. - static const String uncialAntiqua = "Uncial Antiqua"; - - /// GoogleFont: `Underdog`. - static const String underdog = "Underdog"; - - /// GoogleFont: `Unica One`. - static const String unicaOne = "Unica One"; - - /// GoogleFont: `UnifrakturCook`. - static const String unifrakturCook = "UnifrakturCook"; - - /// GoogleFont: `UnifrakturMaguntia`. - static const String unifrakturMaguntia = "UnifrakturMaguntia"; - - /// GoogleFont: `Unkempt`. - static const String unkempt = "Unkempt"; - - /// GoogleFont: `Unlock`. - static const String unlock = "Unlock"; - - /// GoogleFont: `Unna`. - static const String unna = "Unna"; - - /// GoogleFont: `Updock`. - static const String updock = "Updock"; - - /// GoogleFont: `Urbanist`. - static const String urbanist = "Urbanist"; - - /// GoogleFont: `VT323`. - static const String vt323 = "VT323"; - - /// GoogleFont: `Vampiro One`. - static const String vampiroOne = "Vampiro One"; - - /// GoogleFont: `Varela`. - static const String varela = "Varela"; - - /// GoogleFont: `Varela Round`. - static const String varelaRound = "Varela Round"; - - /// GoogleFont: `Varta`. - static const String varta = "Varta"; - - /// GoogleFont: `Vast Shadow`. - static const String vastShadow = "Vast Shadow"; - - /// GoogleFont: `Vazirmatn`. - static const String vazirmatn = "Vazirmatn"; - - /// GoogleFont: `Vesper Libre`. - static const String vesperLibre = "Vesper Libre"; - - /// GoogleFont: `Viaoda Libre`. - static const String viaodaLibre = "Viaoda Libre"; - - /// GoogleFont: `Vibes`. - static const String vibes = "Vibes"; - - /// GoogleFont: `Vibur`. - static const String vibur = "Vibur"; - - /// GoogleFont: `Vidaloka`. - static const String vidaloka = "Vidaloka"; - - /// GoogleFont: `Viga`. - static const String viga = "Viga"; - - /// GoogleFont: `Voces`. - static const String voces = "Voces"; - - /// GoogleFont: `Volkhov`. - static const String volkhov = "Volkhov"; - - /// GoogleFont: `Vollkorn`. - static const String vollkorn = "Vollkorn"; - - /// GoogleFont: `Vollkorn SC`. - static const String vollkornSc = "Vollkorn SC"; - - /// GoogleFont: `Voltaire`. - static const String voltaire = "Voltaire"; - - /// GoogleFont: `Vujahday Script`. - static const String vujahdayScript = "Vujahday Script"; - - /// GoogleFont: `Waiting for the Sunrise`. - static const String waitingForTheSunrise = "Waiting for the Sunrise"; - - /// GoogleFont: `Wallpoet`. - static const String wallpoet = "Wallpoet"; - - /// GoogleFont: `Walter Turncoat`. - static const String walterTurncoat = "Walter Turncoat"; - - /// GoogleFont: `Warnes`. - static const String warnes = "Warnes"; - - /// GoogleFont: `Water Brush`. - static const String waterBrush = "Water Brush"; - - /// GoogleFont: `Waterfall`. - static const String waterfall = "Waterfall"; - - /// GoogleFont: `Wellfleet`. - static const String wellfleet = "Wellfleet"; - - /// GoogleFont: `Wendy One`. - static const String wendyOne = "Wendy One"; - - /// GoogleFont: `Whisper`. - static const String whisper = "Whisper"; - - /// GoogleFont: `WindSong`. - static const String windSong = "WindSong"; - - /// GoogleFont: `Wire One`. - static const String wireOne = "Wire One"; - - /// GoogleFont: `Work Sans`. - static const String workSans = "Work Sans"; - - /// GoogleFont: `Xanh Mono`. - static const String xanhMono = "Xanh Mono"; - - /// GoogleFont: `Yaldevi`. - static const String yaldevi = "Yaldevi"; - - /// GoogleFont: `Yanone Kaffeesatz`. - static const String yanoneKaffeesatz = "Yanone Kaffeesatz"; - - /// GoogleFont: `Yantramanav`. - static const String yantramanav = "Yantramanav"; - - /// GoogleFont: `Yatra One`. - static const String yatraOne = "Yatra One"; - - /// GoogleFont: `Yellowtail`. - static const String yellowtail = "Yellowtail"; - - /// GoogleFont: `Yeon Sung`. - static const String yeonSung = "Yeon Sung"; - - /// GoogleFont: `Yeseva One`. - static const String yesevaOne = "Yeseva One"; - - /// GoogleFont: `Yesteryear`. - static const String yesteryear = "Yesteryear"; - - /// GoogleFont: `Yomogi`. - static const String yomogi = "Yomogi"; - - /// GoogleFont: `Yrsa`. - static const String yrsa = "Yrsa"; - - /// GoogleFont: `Yuji Boku`. - static const String yujiBoku = "Yuji Boku"; - - /// GoogleFont: `Yuji Hentaigana Akari`. - static const String yujiHentaiganaAkari = "Yuji Hentaigana Akari"; - - /// GoogleFont: `Yuji Hentaigana Akebono`. - static const String yujiHentaiganaAkebono = "Yuji Hentaigana Akebono"; - - /// GoogleFont: `Yuji Mai`. - static const String yujiMai = "Yuji Mai"; - - /// GoogleFont: `Yuji Syuku`. - static const String yujiSyuku = "Yuji Syuku"; - - /// GoogleFont: `Yusei Magic`. - static const String yuseiMagic = "Yusei Magic"; - - /// GoogleFont: `ZCOOL KuaiLe`. - static const String zcoolKuaiLe = "ZCOOL KuaiLe"; - - /// GoogleFont: `ZCOOL QingKe HuangYou`. - static const String zcoolQingKeHuangYou = "ZCOOL QingKe HuangYou"; - - /// GoogleFont: `ZCOOL XiaoWei`. - static const String zcoolXiaoWei = "ZCOOL XiaoWei"; - - /// GoogleFont: `Zen Antique`. - static const String zenAntique = "Zen Antique"; - - /// GoogleFont: `Zen Antique Soft`. - static const String zenAntiqueSoft = "Zen Antique Soft"; - - /// GoogleFont: `Zen Dots`. - static const String zenDots = "Zen Dots"; - - /// GoogleFont: `Zen Kaku Gothic Antique`. - static const String zenKakuGothicAntique = "Zen Kaku Gothic Antique"; - - /// GoogleFont: `Zen Kaku Gothic New`. - static const String zenKakuGothicNew = "Zen Kaku Gothic New"; - - /// GoogleFont: `Zen Kurenaido`. - static const String zenKurenaido = "Zen Kurenaido"; - - /// GoogleFont: `Zen Loop`. - static const String zenLoop = "Zen Loop"; - - /// GoogleFont: `Zen Maru Gothic`. - static const String zenMaruGothic = "Zen Maru Gothic"; - - /// GoogleFont: `Zen Old Mincho`. - static const String zenOldMincho = "Zen Old Mincho"; - - /// GoogleFont: `Zen Tokyo Zoo`. - static const String zenTokyoZoo = "Zen Tokyo Zoo"; - - /// GoogleFont: `Zeyada`. - static const String zeyada = "Zeyada"; - - /// GoogleFont: `Zhi Mang Xing`. - static const String zhiMangXing = "Zhi Mang Xing"; - - /// GoogleFont: `Zilla Slab`. - static const String zillaSlab = "Zilla Slab"; - - /// GoogleFont: `Zilla Slab Highlight`. - static const String zillaSlabHighlight = "Zilla Slab Highlight"; -} diff --git a/packages/katana_theme/lib/src/gradient_color.dart b/packages/katana_theme/lib/src/gradient_color.dart index 0410709c0..b92f13fab 100644 --- a/packages/katana_theme/lib/src/gradient_color.dart +++ b/packages/katana_theme/lib/src/gradient_color.dart @@ -1,14 +1,54 @@ part of katana_theme; +/// You can add gradient elements to the theme's color settings. +/// +/// Two color gradients can be set by passing [mainColor] and [subColor]. +/// +/// To use it as a gradient, it must be converted to a gradient object using [Color.toLinearGradient]. +/// +/// When used as a normal [Color], the color of [mainColor] is used. +/// +/// テーマの色設定にグラデーションの要素を加えることができます。 +/// +/// [mainColor]と[subColor]を渡すことで2色のグラデーションを設定可能です。 +/// +/// グラデーションとして用いるためには[Color.toLinearGradient]を利用してグラデーションオブジェクトに変換する必要があります。 +/// +/// 通常の[Color]として利用される場合、[mainColor]の色が使用されます。 @immutable class GradientColor implements Color { + /// You can add gradient elements to the theme's color settings. + /// + /// Two color gradients can be set by passing [mainColor] and [subColor]. + /// + /// To use it as a gradient, it must be converted to a gradient object using [Color.toLinearGradient]. + /// + /// When used as a normal [Color], the color of [mainColor] is used. + /// + /// テーマの色設定にグラデーションの要素を加えることができます。 + /// + /// [mainColor]と[subColor]を渡すことで2色のグラデーションを設定可能です。 + /// + /// グラデーションとして用いるためには[Color.toLinearGradient]を利用してグラデーションオブジェクトに変換する必要があります。 + /// + /// 通常の[Color]として利用される場合、[mainColor]の色が使用されます。 const GradientColor( this.mainColor, this.subColor, ); + /// The color of the starting point of the gradient color. + /// + /// This color is used when used as [Color]. + /// + /// グラデーション色の開始地点の色。 + /// + /// [Color]として利用される場合はこの色が利用されます。 final Color mainColor; + /// The color at the end of the gradient color. + /// + /// グラデーション色の終了地点の色。 final Color subColor; List _toGradient() { diff --git a/packages/katana_theme/lib/src/text_provider.dart b/packages/katana_theme/lib/src/text_provider.dart new file mode 100644 index 000000000..f62a2f15d --- /dev/null +++ b/packages/katana_theme/lib/src/text_provider.dart @@ -0,0 +1,102 @@ +part of katana_theme; + +/// {@template text_provider} +/// Provider for loading text data and displaying it in widgets, etc. +/// +/// Inherits from [ChangeNotifier] and automatically loads text and notifies after loading is complete. +/// +/// The loaded text is stored in [value]. +/// +/// [AssetTextProvider], etc. +/// +/// テキストのデータをロードしてウィジェット等で表示するためのプロバイダー。 +/// +/// [ChangeNotifier]を継承しており、自動でテキストをロードしロード完了後に通知を行います。 +/// +/// ロードされたテキストは[value]に格納されます。 +/// +/// [AssetTextProvider]などがあります。 +/// {@endtemplate} +abstract class TextProvider extends ChangeNotifier + implements ValueListenable { + /// {@template text_provider} + /// Provider for loading text data and displaying it in widgets, etc. + /// + /// Inherits from [ChangeNotifier] and automatically loads text and notifies after loading is complete. + /// + /// The loaded text is stored in [value]. + /// + /// [AssetTextProvider], etc. + /// + /// テキストのデータをロードしてウィジェット等で表示するためのプロバイダー。 + /// + /// [ChangeNotifier]を継承しており、自動でテキストをロードしロード完了後に通知を行います。 + /// + /// ロードされたテキストは[value]に格納されます。 + /// + /// [AssetTextProvider]などがあります。 + /// {@endtemplate} + TextProvider(); + + /// You can wait when loading. + /// + /// The text retrieved when [Future] finishes is returned. + /// + /// ロードを行っている際に待つことができます。 + /// + /// [Future]が終了した際に取得したテキストが返されます。 + Future? get future; +} + +/// Provider to load text files from assets and display them in widgets, etc. +/// +/// アセットからテキストファイルをロードしてウィジェット等で表示するためのプロバイダー。 +/// +/// {@macro text_provider} +class AssetTextProvider extends TextProvider { + /// Provider to load text files from assets and display them in widgets, etc. + /// + /// アセットからテキストファイルをロードしてウィジェット等で表示するためのプロバイダー。 + /// + /// {@macro text_provider} + AssetTextProvider(this.path) { + _load(); + } + + /// Paths in the asset. + /// + /// アセット内のパス。 + final String path; + + @override + String? get value => _value; + String? _value; + + Future _load() async { + _completer = Completer(); + try { + _value = await rootBundle.loadString(path); + _completer?.complete(value); + _completer = null; + } catch (e) { + _completer?.completeError(e); + _completer = null; + } finally { + _completer?.complete(value); + _completer = null; + } + } + + @override + Future? get future => _completer?.future; + + Completer? _completer; + + @override + // ignore: avoid_equals_and_hash_code_on_mutable_classes + bool operator ==(Object other) => hashCode == other.hashCode; + + @override + // ignore: avoid_equals_and_hash_code_on_mutable_classes + int get hashCode => path.hashCode; +} diff --git a/packages/katana_theme/lib/src/theme_scope.dart b/packages/katana_theme/lib/src/theme_scope.dart index 80eb4a262..f8d72a0c0 100644 --- a/packages/katana_theme/lib/src/theme_scope.dart +++ b/packages/katana_theme/lib/src/theme_scope.dart @@ -1,17 +1,27 @@ part of katana_theme; -class ThemeScope extends InheritedWidget { - const ThemeScope({ +/// [InheritedWidget] for placing [AppThemeData] on the widget tree. +/// +/// You can take the value of [AppThemeData] passed here in [AppThemeData.of]. +/// +/// [AppThemeData]をウィジェットツリー上に配置するための[InheritedWidget]。 +/// +/// [AppThemeData.of]でここで渡した[AppThemeData]の値を取ることができます。 +@immutable +class AppThemeScope extends InheritedWidget { + const AppThemeScope({ required super.child, required this.theme, super.key, }); - final T theme; + /// Value of [AppThemeData]. + /// + /// [AppThemeData]の値。 + final AppThemeData theme; @override - // ignore: avoid_renaming_method_parameters - bool updateShouldNotify(ThemeScope old) { - return true; + bool updateShouldNotify(AppThemeScope oldWidget) { + return false; } } diff --git a/packages/katana_theme/lib/src/video_provider.dart b/packages/katana_theme/lib/src/video_provider.dart new file mode 100644 index 000000000..a73374889 --- /dev/null +++ b/packages/katana_theme/lib/src/video_provider.dart @@ -0,0 +1,50 @@ +part of katana_theme; + +/// {@template video_provider} +/// Provider to load video data and display it in widgets. +/// +/// [AssetVideoProvider], etc. +/// +/// ビデオのデータをロードしてウィジェットで表示するためのプロバイダー。 +/// +/// [AssetVideoProvider]などがあります。 +/// {@endtemplate} +@immutable +abstract class VideoProvider { + /// {@template video_provider} + /// Provider to load video data and display it in widgets. + /// + /// [AssetVideoProvider], etc. + /// + /// ビデオのデータをロードしてウィジェットで表示するためのプロバイダー。 + /// + /// [AssetVideoProvider]などがあります。 + /// {@endtemplate} + const VideoProvider(); +} + +/// Provider to load video files from assets and display them in widgets. +/// +/// アセットからビデオファイルをロードしてウィジェットで表示するためのプロバイダー。 +/// +/// {@macro video_provider} +@immutable +class AssetVideoProvider extends VideoProvider { + /// Provider to load video files from assets and display them in widgets. + /// + /// アセットからビデオファイルをロードしてウィジェットで表示するためのプロバイダー。 + /// + /// {@macro video_provider} + const AssetVideoProvider(this.path); + + /// Paths in the asset. + /// + /// アセット内のパス。 + final String path; + + @override + bool operator ==(Object other) => hashCode == other.hashCode; + + @override + int get hashCode => path.hashCode; +} diff --git a/packages/katana_theme/pubspec.lock b/packages/katana_theme/pubspec.lock index 034a5fe10..afa444f96 100644 --- a/packages/katana_theme/pubspec.lock +++ b/packages/katana_theme/pubspec.lock @@ -14,7 +14,7 @@ packages: name: asn1lib url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.4.0" async: dependency: transitive description: @@ -78,20 +78,6 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.3.1" - ffi: - dependency: transitive - description: - name: ffi - url: "https://pub.dartlang.org" - source: hosted - version: "2.0.1" - file: - dependency: transitive - description: - name: file - url: "https://pub.dartlang.org" - source: hosted - version: "6.1.4" flutter: dependency: "direct main" description: flutter @@ -102,13 +88,6 @@ packages: description: flutter source: sdk version: "0.0.0" - google_fonts: - dependency: "direct main" - description: - name: google_fonts - url: "https://pub.dartlang.org" - source: hosted - version: "3.0.1" http: dependency: transitive description: @@ -143,7 +122,14 @@ packages: name: katana url: "https://pub.dartlang.org" source: hosted - version: "0.15.6" + version: "0.15.10" + katana_theme_annotation: + dependency: "direct main" + description: + name: katana_theme_annotation + url: "https://pub.dartlang.org" + source: hosted + version: "1.1.5" matcher: dependency: transitive description: @@ -172,69 +158,6 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.8.2" - path_provider: - dependency: transitive - description: - name: path_provider - url: "https://pub.dartlang.org" - source: hosted - version: "2.0.11" - path_provider_android: - dependency: transitive - description: - name: path_provider_android - url: "https://pub.dartlang.org" - source: hosted - version: "2.0.20" - path_provider_ios: - dependency: transitive - description: - name: path_provider_ios - url: "https://pub.dartlang.org" - source: hosted - version: "2.0.11" - path_provider_linux: - dependency: transitive - description: - name: path_provider_linux - url: "https://pub.dartlang.org" - source: hosted - version: "2.1.7" - path_provider_macos: - dependency: transitive - description: - name: path_provider_macos - url: "https://pub.dartlang.org" - source: hosted - version: "2.0.6" - path_provider_platform_interface: - dependency: transitive - description: - name: path_provider_platform_interface - url: "https://pub.dartlang.org" - source: hosted - version: "2.0.5" - path_provider_windows: - dependency: transitive - description: - name: path_provider_windows - url: "https://pub.dartlang.org" - source: hosted - version: "2.1.3" - platform: - dependency: transitive - description: - name: platform - url: "https://pub.dartlang.org" - source: hosted - version: "3.1.0" - plugin_platform_interface: - dependency: transitive - description: - name: plugin_platform_interface - url: "https://pub.dartlang.org" - source: hosted - version: "2.1.3" pointycastle: dependency: transitive description: @@ -242,13 +165,6 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "3.6.2" - process: - dependency: transitive - description: - name: process - url: "https://pub.dartlang.org" - source: hosted - version: "4.2.4" recase: dependency: transitive description: @@ -323,7 +239,7 @@ packages: name: uuid url: "https://pub.dartlang.org" source: hosted - version: "3.0.6" + version: "3.0.7" vector_math: dependency: transitive description: @@ -331,20 +247,6 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.1.2" - win32: - dependency: transitive - description: - name: win32 - url: "https://pub.dartlang.org" - source: hosted - version: "3.0.1" - xdg_directories: - dependency: transitive - description: - name: xdg_directories - url: "https://pub.dartlang.org" - source: hosted - version: "0.2.0+2" sdks: dart: ">=2.18.0 <3.0.0" - flutter: ">=3.0.0" + flutter: ">=2.0.0" diff --git a/packages/katana_theme_annotation/lib/src/app_theme.dart b/packages/katana_theme_annotation/lib/src/app_theme.dart index 53539b7cf..da76f726a 100644 --- a/packages/katana_theme_annotation/lib/src/app_theme.dart +++ b/packages/katana_theme_annotation/lib/src/app_theme.dart @@ -1,7 +1,31 @@ part of katana_theme_annotation; +/// Annotation to be given to the theme of the application. +/// +/// Granting this will create the assets and font data defined in pubspec.yaml in the target application theme. +/// +/// アプリのテーマに対して付与するアノテーション。 +/// +/// これを付与することで対象となるアプリテーマにpubspec.yamlで定義されているアセットとフォントのデータが作成されます。 +/// +/// ```dart +/// @appTheme +/// final theme = AppThemeData(); +/// ``` const appTheme = AppTheme(); +/// Annotation to be given to the theme of the application. +/// +/// Granting this will create the assets and font data defined in pubspec.yaml in the target application theme. +/// +/// アプリのテーマに対して付与するアノテーション。 +/// +/// これを付与することで対象となるアプリテーマにpubspec.yamlで定義されているアセットとフォントのデータが作成されます。 +/// +/// ```dart +/// @appTheme +/// final theme = AppThemeData(); +/// ``` class AppTheme { const AppTheme(); } diff --git a/packages/katana_theme_annotation/pubspec.lock b/packages/katana_theme_annotation/pubspec.lock index 4d2f5bc65..0968783b2 100644 --- a/packages/katana_theme_annotation/pubspec.lock +++ b/packages/katana_theme_annotation/pubspec.lock @@ -7,14 +7,14 @@ packages: name: _fe_analyzer_shared url: "https://pub.dartlang.org" source: hosted - version: "49.0.0" + version: "50.0.0" analyzer: dependency: transitive description: name: analyzer url: "https://pub.dartlang.org" source: hosted - version: "5.1.0" + version: "5.2.0" args: dependency: transitive description: @@ -28,21 +28,21 @@ packages: name: asn1lib url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.4.0" async: dependency: transitive description: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.9.0" + version: "2.10.0" boolean_selector: dependency: transitive description: name: boolean_selector url: "https://pub.dartlang.org" source: hosted - version: "2.1.0" + version: "2.1.1" clock: dependency: transitive description: @@ -105,7 +105,7 @@ packages: name: glob url: "https://pub.dartlang.org" source: hosted - version: "2.1.0" + version: "2.1.1" http: dependency: transitive description: @@ -154,7 +154,7 @@ packages: name: katana url: "https://pub.dartlang.org" source: hosted - version: "0.15.6" + version: "0.15.10" logging: dependency: transitive description: @@ -168,7 +168,7 @@ packages: name: matcher url: "https://pub.dartlang.org" source: hosted - version: "0.12.12" + version: "0.12.13" meta: dependency: transitive description: @@ -224,7 +224,7 @@ packages: name: pub_semver url: "https://pub.dartlang.org" source: hosted - version: "2.1.2" + version: "2.1.3" recase: dependency: transitive description: @@ -259,7 +259,7 @@ packages: name: shelf_web_socket url: "https://pub.dartlang.org" source: hosted - version: "1.0.2" + version: "1.0.3" source_map_stack_trace: dependency: transitive description: @@ -308,7 +308,7 @@ packages: name: string_scanner url: "https://pub.dartlang.org" source: hosted - version: "1.1.1" + version: "1.2.0" term_glyph: dependency: transitive description: @@ -322,21 +322,21 @@ packages: name: test url: "https://pub.dartlang.org" source: hosted - version: "1.21.6" + version: "1.22.0" test_api: dependency: transitive description: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.14" + version: "0.4.16" test_core: dependency: transitive description: name: test_core url: "https://pub.dartlang.org" source: hosted - version: "0.4.18" + version: "0.4.20" typed_data: dependency: transitive description: @@ -350,7 +350,7 @@ packages: name: uuid url: "https://pub.dartlang.org" source: hosted - version: "3.0.6" + version: "3.0.7" vm_service: dependency: transitive description: diff --git a/packages/katana_theme_builder/lib/common/base_class.dart b/packages/katana_theme_builder/lib/common/base_class.dart deleted file mode 100644 index 9f182c2d6..000000000 --- a/packages/katana_theme_builder/lib/common/base_class.dart +++ /dev/null @@ -1,236 +0,0 @@ -part of katana_listenables_builder; - -/// Create a base class. -/// -/// Pass the value for the query to [model]. -/// -/// ベースを作成します。 -/// -/// [model]にクエリー用の値を渡します。 -List baseClass( - ClassValue model, -) { - return [ - Class( - (c) => c - ..name = "_\$${model.name}" - ..abstract = true - ..implements.addAll([ - const Reference("ChangeNotifier"), - ]) - ..methods.addAll([ - ...model.parameters.map((param) { - return Method( - (m) => m - ..name = param.name - ..type = MethodType.getter - ..lambda = true - ..returns = Reference( - "${param.type.toString().trimStringRight("?")}${param.required ? "" : "?"}", - ) - ..body = const Code("throw UnimplementedError()"), - ); - }), - Method( - (m) => m - ..name = "addListener" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("void") - ..lambda = true - ..requiredParameters.addAll([ - Parameter( - (p) => p - ..name = "listener" - ..type = const Reference("VoidCallback"), - ) - ]) - ..body = const Code("throw UnimplementedError()"), - ), - Method( - (m) => m - ..name = "removeListener" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("void") - ..lambda = true - ..requiredParameters.addAll([ - Parameter( - (p) => p - ..name = "listener" - ..type = const Reference("VoidCallback"), - ) - ]) - ..body = const Code("throw UnimplementedError()"), - ), - Method( - (m) => m - ..name = "notifyListeners" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("void") - ..lambda = true - ..body = const Code("throw UnimplementedError()"), - ), - Method( - (m) => m - ..name = "dispose" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("void") - ..lambda = true - ..body = const Code("throw UnimplementedError()"), - ), - Method( - (m) => m - ..name = "hasListeners" - ..type = MethodType.getter - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("bool") - ..lambda = true - ..body = const Code("throw UnimplementedError()"), - ), - Method( - (m) => m - ..name = "toString" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("String") - ..body = Code( - "return \"\$runtimeType(${model.parameters.map((e) => "${e.name}: \$${e.name}").join(", ")})\";", - ), - ), - ]), - ), - if (model.existUnderbarConstructor) ...[ - Class( - (c) => c - ..name = "_${model.name}" - ..extend = Reference(model.name) - ..mixins.addAll([ - if (!model.existChangeNotifierMixin) - const Reference("ChangeNotifier"), - ]) - ..constructors.addAll([ - Constructor( - (c) => c - ..optionalParameters.addAll([ - ...model.parameters.map((param) { - return Parameter( - (p) => p - ..name = param.name - ..toThis = true - ..named = true - ..required = param.required, - ); - }), - ]) - ..initializers.addAll([const Code("super._()")]) - ..body = Code( - model.parameters - .map( - (e) => - "if(${e.name} is Listenable){${e.name}${e.required ? "" : "?"}.addListener(_handledOnUpdate);}", - ) - .join("\n"), - ), - ), - ]) - ..fields.addAll([ - ...model.parameters.map((param) { - return Field( - (f) => f - ..name = param.name - ..modifier = FieldModifier.final$ - ..annotations.addAll([const Reference("override")]) - ..type = Reference( - "${param.type.toString().trimStringRight("?")}${param.required ? "" : "?"}", - ), - ); - }) - ]) - ..methods.addAll([ - Method( - (m) => m - ..name = "dispose" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("void") - ..body = Code( - "super.dispose(); ${model.parameters.map((e) => "if(${e.name} is Listenable){${e.name}${e.required ? "" : "?"}.removeListener(_handledOnUpdate); ${e.name}${e.required ? "" : "?"}.dispose();}").join("\n")}", - ), - ), - Method( - (m) => m - ..name = "_handledOnUpdate" - ..returns = const Reference("void") - ..body = const Code( - "notifyListeners();", - ), - ), - ]), - ), - ] else ...[ - Class( - (c) => c - ..name = "_${model.name}" - ..mixins.addAll([ - const Reference("ChangeNotifier"), - ]) - ..implements.addAll([ - Reference(model.name), - ]) - ..constructors.addAll([ - Constructor( - (c) => c - ..optionalParameters.addAll([ - ...model.parameters.map((param) { - return Parameter( - (p) => p - ..name = param.name - ..toThis = true - ..named = true - ..required = param.required, - ); - }), - ]) - ..body = Code( - model.parameters - .map( - (e) => - "if(${e.name} is Listenable){${e.name}${e.required ? "" : "?"}.addListener(_handledOnUpdate);}", - ) - .join("\n"), - ), - ), - ]) - ..fields.addAll([ - ...model.parameters.map((param) { - return Field( - (f) => f - ..name = param.name - ..annotations.addAll([const Reference("override")]) - ..modifier = FieldModifier.final$ - ..type = Reference( - "${param.type.toString().trimStringRight("?")}${param.required ? "" : "?"}", - ), - ); - }) - ]) - ..methods.addAll([ - Method( - (m) => m - ..name = "dispose" - ..annotations.addAll([const Reference("override")]) - ..returns = const Reference("void") - ..body = Code( - "super.dispose(); ${model.parameters.map((e) => "if(${e.name} is Listenable){${e.name}${e.required ? "" : "?"}.removeListener(_handledOnUpdate); ${e.name}${e.required ? "" : "?"}.dispose();}").join("\n")}", - ), - ), - Method( - (m) => m - ..name = "_handledOnUpdate" - ..returns = const Reference("void") - ..body = const Code( - "notifyListeners();", - ), - ), - ]), - ), - ], - ]; -} diff --git a/packages/katana_theme_builder/lib/common/extensions.dart b/packages/katana_theme_builder/lib/common/extensions.dart new file mode 100644 index 000000000..57094e339 --- /dev/null +++ b/packages/katana_theme_builder/lib/common/extensions.dart @@ -0,0 +1,45 @@ +part of katana_theme_builder; + +List extension( + List assets, + List fonts, + AssetConfig config, +) { + return [ + if (assets.isNotEmpty) ...[ + Extension( + (e) => e + ..name = r"$ThemeAssetsExtensions" + ..on = const Reference("AssetThemeData") + ..methods.addAll([ + ...assets.map((node) { + return node.toExtensionSpec(config); + }) + ]), + ), + Extension( + (e) => e + ..name = r"$FontAssetsExtensions" + ..on = const Reference("FontThemeData") + ..methods.addAll([ + ...fonts.map((node) { + return node.toExtensionSpec(config); + }) + ]), + ), + Extension( + (e) => e + ..name = r"$FontTextStyleExtensions" + ..on = const Reference("TextStyle") + ..methods.addAll([ + ...fonts.map((node) { + return node.toTextStyleSpec(config); + }) + ]), + ), + ...assets.expand((node) { + return node.toClassSpec(config); + }) + ], + ]; +} diff --git a/packages/katana_theme_builder/lib/generator/listenables_generator.dart b/packages/katana_theme_builder/lib/generator/listenables_generator.dart deleted file mode 100644 index 50afb402f..000000000 --- a/packages/katana_theme_builder/lib/generator/listenables_generator.dart +++ /dev/null @@ -1,48 +0,0 @@ -part of katana_theme_builder; - -/// Generator to automatically create Listenable groups. -/// -/// Listenableのグループを自動作成するジェネレーター。 -class ThemeGenerator extends GeneratorForAnnotation { - /// Generator to automatically create Listenable groups. - /// - /// Listenableのグループを自動作成するジェネレーター。 - ThemeGenerator(); - - @override - FutureOr generateForAnnotatedElement( - Element element, - ConstantReader annotation, - BuildStep buildStep, - ) async { - if (!element.library!.isNonNullableByDefault) { - throw InvalidGenerationSourceError( - "Generator cannot target libraries that have not been migrated to " - "null-safety.", - element: element, - ); - } - - if (element is! ClassElement) { - throw InvalidGenerationSourceError( - "`@AppTheme()` can only be used on classes.", - element: element, - ); - } - - final _class = ClassValue(element); - - final generated = Library( - (l) => l - ..body.addAll( - [ - ...baseClass(_class), - ], - ), - ); - final emitter = DartEmitter(); - return DartFormatter().format( - "${generated.accept(emitter)}", - ); - } -} diff --git a/packages/katana_theme_builder/lib/generator/theme_generator.dart b/packages/katana_theme_builder/lib/generator/theme_generator.dart new file mode 100644 index 000000000..812f95c73 --- /dev/null +++ b/packages/katana_theme_builder/lib/generator/theme_generator.dart @@ -0,0 +1,90 @@ +part of katana_theme_builder; + +/// Generator that automatically creates data for themes. +/// +/// テーマ用のデータを自動作成するジェネレーター。 +class ThemeGenerator extends GeneratorForAnnotation { + /// Generator that automatically creates data for themes. + /// + /// テーマ用のデータを自動作成するジェネレーター。 + ThemeGenerator(); + + static final _ignoreRegExp = RegExp("/[0-9].[0-9]x/"); + + @override + FutureOr generateForAnnotatedElement( + Element element, + ConstantReader annotation, + BuildStep buildStep, + ) async { + if (!element.library!.isNonNullableByDefault) { + throw InvalidGenerationSourceError( + "Generator cannot target libraries that have not been migrated to " + "null-safety.", + element: element, + ); + } + + if (element is! TopLevelVariableElement) { + throw InvalidGenerationSourceError( + "`@AppTheme()` should only be given to top-level fields.\n" + "```\n" + "\n" + "```\n", + element: element, + ); + } + + final assets = {}; + final fonts = {}; + final pubspecFile = File("pubspec.yaml"); + final content = pubspecFile.readAsStringSync(); + final map = loadYaml(content) as YamlMap; + final dependency = map.getAsMap("dependencies"); + final assetsSource = map.getAsMap("flutter").getAsList("assets"); + final fontsSource = map.getAsMap("flutter").getAsList("fonts"); + for (var assetInput in assetsSource) { + if (assetInput.isEmpty) { + continue; + } + if (assetInput.endsWith("/")) { + assetInput += "*"; + } + await for (final assetId in buildStep.findAssets(Glob(assetInput))) { + final path = assetId.path.trimQuery().trimString("/"); + if (_ignoreRegExp.hasMatch(path) || + path.contains("/.") || + path.startsWith(".")) { + continue; + } + assets[path] = AssetValue(path: path, type: _type(path)); + } + } + for (final fontInput in fontsSource) { + final family = fontInput.get("family", ""); + if (family.isEmpty) { + continue; + } + fonts[family] = FontValue(path: family); + } + + final assetNodes = AssetNode.parse( + assets + .toTreeMap((key) => key.split(".").first.toCamelCase()) + .getAsMap("assets"), + ); + final fontNodes = FontNode.parse(fonts); + final config = AssetConfig(useSvg: dependency.containsKey("flutter_svg")); + + final generated = Library( + (l) => l + ..body.addAll( + extension(assetNodes, fontNodes, config), + ), + ); + final emitter = DartEmitter(); + return DartFormatter().format( + "${generated.accept(emitter)}", + ); + } +} diff --git a/packages/katana_theme_builder/lib/katana_theme_builder.dart b/packages/katana_theme_builder/lib/katana_theme_builder.dart index 7c51a4149..8affa22eb 100644 --- a/packages/katana_theme_builder/lib/katana_theme_builder.dart +++ b/packages/katana_theme_builder/lib/katana_theme_builder.dart @@ -9,18 +9,22 @@ library katana_theme_builder; import 'dart:async'; +import 'dart:io'; import 'package:analyzer/dart/element/element.dart'; -import 'package:analyzer/dart/element/type.dart'; import 'package:build/build.dart'; import 'package:code_builder/code_builder.dart'; import 'package:dart_style/dart_style.dart'; +import 'package:glob/glob.dart'; import 'package:katana_theme_annotation/katana_theme_annotation.dart'; import 'package:source_gen/source_gen.dart'; +import 'package:yaml/yaml.dart'; -part 'common/base_class.dart'; -part 'generator/listenables_generator.dart'; +part 'common/extensions.dart'; +part 'generator/theme_generator.dart'; part 'src/builder.dart'; -part 'src/config.dart'; -part 'value/class_value.dart'; -part 'value/parameter_value.dart'; +part 'value/asset_value.dart'; +part 'value/font_node.dart'; +part 'value/asset_node.dart'; +part 'value/asset_config.dart'; +part 'value/font_value.dart'; diff --git a/packages/katana_theme_builder/lib/src/builder.dart b/packages/katana_theme_builder/lib/src/builder.dart index d28b52499..2cc5ae2a0 100644 --- a/packages/katana_theme_builder/lib/src/builder.dart +++ b/packages/katana_theme_builder/lib/src/builder.dart @@ -1,15 +1,15 @@ part of katana_theme_builder; -/// Builder to create a group of Listenable. +/// Builder for creating data for themes. /// -/// Listenableのグループを作成するためのビルダー。 +/// テーマ用のデータを作成するためのビルダー。 Builder katanaThemeBuilderFactory(BuilderOptions options) { return PartBuilder( [ - ListenablesGenerator(), + ThemeGenerator(), ], ".theme.dart", header: - "// ignore_for_file: unused_field, unused_element, require_trailing_commas, prefer_const_constructors, unnecessary_overrides, prefer_const_literals_to_create_immutables, unnecessary_null_in_if_null_operators, library_prefixes, directives_ordering, no_leading_underscores_for_local_identifiers, unnecessary_brace_in_string_interps, unnecessary_type_check", + "// ignore_for_file: unused_field, unused_element, require_trailing_commas, prefer_const_constructors, unnecessary_overrides, prefer_const_literals_to_create_immutables, unnecessary_null_in_if_null_operators, library_prefixes, directives_ordering, no_leading_underscores_for_local_identifiers, unnecessary_brace_in_string_interps, unnecessary_type_check, library_private_types_in_public_api", ); } diff --git a/packages/katana_theme_builder/lib/src/config.dart b/packages/katana_theme_builder/lib/src/config.dart deleted file mode 100644 index 7dcd4890a..000000000 --- a/packages/katana_theme_builder/lib/src/config.dart +++ /dev/null @@ -1,9 +0,0 @@ -part of katana_theme_builder; - -final _ignoreWords = [ - "dispose", - "addListener", - "removeListener", - "hasListeners", - "notifyListeners", -]; diff --git a/packages/katana_theme_builder/lib/value/asset_config.dart b/packages/katana_theme_builder/lib/value/asset_config.dart new file mode 100644 index 000000000..b323377da --- /dev/null +++ b/packages/katana_theme_builder/lib/value/asset_config.dart @@ -0,0 +1,18 @@ +part of katana_theme_builder; + +class AssetConfig { + const AssetConfig({required this.useSvg}); + + final bool useSvg; + + bool checkEnabled(AssetValueType type) { + switch (type) { + case AssetValueType.svg: + return useSvg; + case AssetValueType.font: + return false; + default: + return true; + } + } +} diff --git a/packages/katana_theme_builder/lib/value/asset_node.dart b/packages/katana_theme_builder/lib/value/asset_node.dart new file mode 100644 index 000000000..9fff9f236 --- /dev/null +++ b/packages/katana_theme_builder/lib/value/asset_node.dart @@ -0,0 +1,170 @@ +part of katana_theme_builder; + +class AssetNode { + AssetNode._withNode({ + required this.name, + required this.path, + required this.value, + }) : children = const []; + AssetNode._withChildren({ + required this.name, + required this.path, + required this.children, + }) : value = null; + + final AssetValue? value; + final String path; + final String name; + + final List children; + + static List parse( + Map values, [ + String path = "", + ]) { + final res = []; + for (final tmp in values.entries) { + final value = tmp.value; + if (value is Map) { + res.add( + AssetNode._withChildren( + name: tmp.key, + path: "$path/${tmp.key}", + children: parse(value, "$path/${tmp.key}"), + ), + ); + } else if (value is AssetValue) { + res.add( + AssetNode._withNode( + name: tmp.key, + path: "$path/${tmp.key}", + value: value, + ), + ); + } + } + return res; + } + + Method? buildProvider() { + if (value == null) { + return null; + } + switch (value!.type) { + case AssetValueType.image: + return Method( + (f) => f + ..name = "provider" + ..returns = const Reference("ImageProvider") + ..lambda = true + ..type = MethodType.getter + ..body = const Code("AssetImage(path)"), + ); + case AssetValueType.svg: + return Method( + (f) => f + ..name = "provider" + ..returns = const Reference("PictureProvider") + ..lambda = true + ..type = MethodType.getter + ..body = const Code( + "ExactAssetPicture(SvgPicture.svgStringDecoderBuilder, path)", + ), + ); + case AssetValueType.text: + return Method( + (f) => f + ..name = "provider" + ..returns = const Reference("TextProvider") + ..lambda = true + ..type = MethodType.getter + ..body = const Code("AssetTextProvider(path)"), + ); + case AssetValueType.video: + return Method( + (f) => f + ..name = "provider" + ..returns = const Reference("VideoProvider") + ..lambda = true + ..type = MethodType.getter + ..body = const Code("AssetVideoProvider(path)"), + ); + default: + return null; + } + } + + Method toExtensionSpec(AssetConfig config) { + return Method( + (m) => m + ..name = name + ..type = MethodType.getter + ..lambda = true + ..returns = Reference("_\$${path.toSHA1()}") + ..body = Code("const _\$${path.toSHA1()}()"), + ); + } + + List toClassSpec(AssetConfig config) { + if (value != null) { + if (!config.checkEnabled(value!.type)) { + return []; + } + final provider = buildProvider(); + return [ + Class( + (c) => c + ..name = "_\$${path.toSHA1()}" + ..constructors.addAll([ + Constructor( + (c) => c..constant = true, + ) + ]) + ..fields.addAll([ + Field( + (f) => f + ..name = "path" + ..modifier = FieldModifier.final$ + ..assignment = Code("\"${value!.path}\""), + ), + ]) + ..methods.addAll([ + if (provider != null) provider, + ]), + ), + ]; + } else { + return [ + Class( + (c) => c + ..name = "_\$${path.toSHA1()}" + ..constructors.addAll([ + Constructor( + (c) => c..constant = true, + ) + ]) + ..fields.addAll([ + ...children.mapAndRemoveEmpty((node) { + if (node.value != null && + !config.checkEnabled(node.value!.type)) { + return null; + } + return Field( + (f) => f + ..name = node.name + ..modifier = FieldModifier.final$ + ..assignment = Code("const _\$${node.path.toSHA1()}()"), + ); + }), + ]), + ), + ...children.expand((node) { + if (node.value != null && !config.checkEnabled(node.value!.type)) { + return []; + } + return node.toClassSpec(config); + }) + ]; + } + } +} diff --git a/packages/katana_theme_builder/lib/value/asset_value.dart b/packages/katana_theme_builder/lib/value/asset_value.dart new file mode 100644 index 000000000..b1bd59ab2 --- /dev/null +++ b/packages/katana_theme_builder/lib/value/asset_value.dart @@ -0,0 +1,39 @@ +part of katana_theme_builder; + +class AssetValue { + AssetValue({ + required this.path, + required this.type, + }); + + final String path; + final AssetValueType type; +} + +AssetValueType _type(String path) { + switch (path.last(separator: ".").toLowerCase()) { + case "jpeg": + case "jpg": + case "png": + case "gif": + case "webp": + case "bmp": + return AssetValueType.image; + case "svg": + return AssetValueType.svg; + case "mp4": + return AssetValueType.video; + case "otf": + case "ttf": + return AssetValueType.font; + } + return AssetValueType.text; +} + +enum AssetValueType { + image, + svg, + text, + video, + font, +} diff --git a/packages/katana_theme_builder/lib/value/class_value.dart b/packages/katana_theme_builder/lib/value/class_value.dart deleted file mode 100644 index ea3a126eb..000000000 --- a/packages/katana_theme_builder/lib/value/class_value.dart +++ /dev/null @@ -1,39 +0,0 @@ -part of katana_theme_builder; - -/// Defines the value of the class to which the annotation is assigned. -/// -/// Specify the element to live in [element]. -/// -/// アノテーションが付与されたクラスの値を定義します。 -/// -/// [element]に暮らすエレメントを指定します。 -class ClassValue { - /// Defines the value of the class to which the annotation is assigned. - /// - /// Specify the element to live in [element]. - /// - /// アノテーションが付与されたクラスの値を定義します。 - /// - /// [element]に暮らすエレメントを指定します。 - ClassValue(this.element) { - name = element.displayName; - final contstuctor = element.constructors.firstWhere((e) { - return e.name.isEmpty; - }); - } - - /// Class Element. - /// - /// クラスエレメント。 - final ClassElement element; - - /// Class Name. - /// - /// クラス名。 - late final String name; - - @override - String toString() { - return name; - } -} diff --git a/packages/katana_theme_builder/lib/value/font_node.dart b/packages/katana_theme_builder/lib/value/font_node.dart new file mode 100644 index 000000000..a6b9584eb --- /dev/null +++ b/packages/katana_theme_builder/lib/value/font_node.dart @@ -0,0 +1,32 @@ +part of katana_theme_builder; + +class FontNode { + FontNode(this.value); + + final FontValue value; + + static List parse(Map values) { + return values.values.map((e) => FontNode(e)).toList(); + } + + Method toExtensionSpec(AssetConfig config) { + return Method( + (m) => m + ..name = value.path.toCamelCase() + ..lambda = true + ..returns = const Reference("String") + ..type = MethodType.getter + ..body = Code("\"${value.path}\""), + ); + } + + Method toTextStyleSpec(AssetConfig config) { + return Method( + (m) => m + ..name = "with${value.path.toPascalCase()}Font" + ..lambda = true + ..returns = const Reference("TextStyle") + ..body = Code("copyWith(fontFamily: \"${value.path}\")"), + ); + } +} diff --git a/packages/katana_theme_builder/lib/value/font_value.dart b/packages/katana_theme_builder/lib/value/font_value.dart new file mode 100644 index 000000000..a7f2e1592 --- /dev/null +++ b/packages/katana_theme_builder/lib/value/font_value.dart @@ -0,0 +1,9 @@ +part of katana_theme_builder; + +class FontValue { + FontValue({ + required this.path, + }); + + final String path; +} diff --git a/packages/katana_theme_builder/lib/value/parameter_value.dart b/packages/katana_theme_builder/lib/value/parameter_value.dart deleted file mode 100644 index 4e986b353..000000000 --- a/packages/katana_theme_builder/lib/value/parameter_value.dart +++ /dev/null @@ -1,53 +0,0 @@ -part of katana_listenables_builder; - -/// Parameter Value. -/// -/// Specify the parameter element in [element]. -/// -/// パラメーターの値。 -/// -/// [element]にパラメーターエレメントを指定します。 -class ParamaterValue { - /// Parameter Value. - /// - /// Specify the parameter element in [element]. - /// - /// パラメーターの値。 - /// - /// [element]にパラメーターエレメントを指定します。 - ParamaterValue(this.element) { - name = element.displayName; - if (_ignoreWords.contains(name)) { - throw Exception( - "`$name` is a prohibited word. This word cannot be set as a parameter. Please specify another name.", - ); - } - type = element.type; - required = element.isRequired; - } - - /// Parameter Element. - /// - /// パラメーターエレメント。 - final ParameterElement element; - - /// Parameter Type. - /// - /// パラメーターのタイプ。 - late final DartType type; - - /// Name of parameter. - /// - /// パラメーターの名前。 - late final String name; - - /// True if Required. - /// - /// Requiredな場合true. - late final bool required; - - @override - String toString() { - return "$name($type)"; - } -} diff --git a/packages/katana_theme_builder/pubspec.lock b/packages/katana_theme_builder/pubspec.lock index 0e779fb62..d1fa8292b 100644 --- a/packages/katana_theme_builder/pubspec.lock +++ b/packages/katana_theme_builder/pubspec.lock @@ -7,14 +7,14 @@ packages: name: _fe_analyzer_shared url: "https://pub.dartlang.org" source: hosted - version: "49.0.0" + version: "50.0.0" analyzer: dependency: "direct main" description: name: analyzer url: "https://pub.dartlang.org" source: hosted - version: "5.1.0" + version: "5.2.0" args: dependency: transitive description: @@ -28,21 +28,21 @@ packages: name: asn1lib url: "https://pub.dartlang.org" source: hosted - version: "1.2.1" + version: "1.4.0" async: dependency: transitive description: name: async url: "https://pub.dartlang.org" source: hosted - version: "2.9.0" + version: "2.10.0" boolean_selector: dependency: transitive description: name: boolean_selector url: "https://pub.dartlang.org" source: hosted - version: "2.1.0" + version: "2.1.1" build: dependency: "direct main" description: @@ -63,7 +63,7 @@ packages: name: built_value url: "https://pub.dartlang.org" source: hosted - version: "8.4.1" + version: "8.4.2" clock: dependency: transitive description: @@ -142,12 +142,12 @@ packages: source: hosted version: "3.1.0" glob: - dependency: transitive + dependency: "direct main" description: name: glob url: "https://pub.dartlang.org" source: hosted - version: "2.1.0" + version: "2.1.1" http: dependency: transitive description: @@ -196,14 +196,14 @@ packages: name: katana url: "https://pub.dartlang.org" source: hosted - version: "0.15.6" - katana_listenables_annotation: + version: "0.15.10" + katana_theme_annotation: dependency: "direct main" description: - name: katana_listenables_annotation + name: katana_theme_annotation url: "https://pub.dartlang.org" source: hosted - version: "1.1.1" + version: "1.1.5" logging: dependency: transitive description: @@ -217,7 +217,7 @@ packages: name: matcher url: "https://pub.dartlang.org" source: hosted - version: "0.12.12" + version: "0.12.13" meta: dependency: transitive description: @@ -273,7 +273,7 @@ packages: name: pub_semver url: "https://pub.dartlang.org" source: hosted - version: "2.1.2" + version: "2.1.3" recase: dependency: transitive description: @@ -308,7 +308,7 @@ packages: name: shelf_web_socket url: "https://pub.dartlang.org" source: hosted - version: "1.0.2" + version: "1.0.3" source_gen: dependency: "direct main" description: @@ -364,7 +364,7 @@ packages: name: string_scanner url: "https://pub.dartlang.org" source: hosted - version: "1.1.1" + version: "1.2.0" term_glyph: dependency: transitive description: @@ -378,21 +378,21 @@ packages: name: test url: "https://pub.dartlang.org" source: hosted - version: "1.21.6" + version: "1.22.0" test_api: dependency: transitive description: name: test_api url: "https://pub.dartlang.org" source: hosted - version: "0.4.14" + version: "0.4.16" test_core: dependency: transitive description: name: test_core url: "https://pub.dartlang.org" source: hosted - version: "0.4.18" + version: "0.4.20" typed_data: dependency: transitive description: @@ -406,7 +406,7 @@ packages: name: uuid url: "https://pub.dartlang.org" source: hosted - version: "3.0.6" + version: "3.0.7" vm_service: dependency: transitive description: @@ -436,7 +436,7 @@ packages: source: hosted version: "1.2.0" yaml: - dependency: transitive + dependency: "direct main" description: name: yaml url: "https://pub.dartlang.org"