├── .gitignore ├── CHANGELOG.md ├── README.md ├── desktop_plugins ├── README.md ├── path_provider_fde │ ├── .gitignore │ ├── LICENSE │ ├── macos │ │ ├── Classes │ │ │ └── PathProviderPlugin.swift │ │ └── path_provider_fde.podspec │ └── pubspec.yaml └── shared_preferences_fde │ ├── .gitignore │ ├── LICENSE │ ├── macos │ ├── Classes │ │ └── SharedPreferencesPlugin.swift │ └── shared_preferences_fde.podspec │ └── pubspec.yaml ├── docs ├── assets │ ├── AssetManifest.json │ ├── FontManifest.json │ ├── fonts │ │ ├── MaterialIcons-Regular.ttf │ │ ├── Roboto-Regular.ttf │ │ └── RobotoMono-Regular.ttf │ ├── home.png │ ├── logo.png │ ├── packages │ │ ├── flutter_web_ui │ │ │ └── assets │ │ │ │ └── Roboto-Regular.ttf │ │ ├── panache_core │ │ │ └── lib │ │ │ │ └── logo.png │ │ └── panache_ui │ │ │ └── assets │ │ │ └── github.png │ ├── screenshot.png │ ├── screenshot2.png │ ├── screenshot3.png │ └── screenshot4.png ├── index.html └── main.dart.js ├── panache_core ├── .gitignore ├── .metadata ├── CHANGELOG.md ├── LICENSE ├── README.md ├── lib │ ├── logo.png │ ├── panache_core.dart │ └── src │ │ ├── app_theme.dart │ │ ├── converters │ │ ├── button_theme_converters.dart │ │ ├── chip_theme_converter.dart │ │ ├── converter_utils.dart │ │ ├── icon_theme_converter.dart │ │ ├── input_theme_converter.dart │ │ ├── text_theme_converters.dart │ │ └── theme_converter.dart │ │ ├── models.dart │ │ ├── services │ │ ├── cloud_service.dart │ │ ├── link_service.dart │ │ ├── persistence_service.dart │ │ ├── screenshot_service.dart │ │ ├── theme_service.dart │ │ └── user_service.dart │ │ ├── theme_model.dart │ │ └── utils │ │ ├── color_utils.dart │ │ ├── constants.dart │ │ ├── example_code_parser.dart │ │ ├── syntax_highlighter.dart │ │ ├── theme_defaults.dart │ │ └── uuid.dart ├── pubspec.yaml └── test │ ├── color_utils_test.dart │ ├── converters │ ├── convert_button_theme_test.dart │ ├── mock_button_theme.dart │ └── theme_converter_test.dart │ └── flutterial_components_test.dart ├── panache_desktop ├── .gitignore ├── .metadata ├── README.md ├── lib │ ├── main.dart │ └── services │ │ └── desktop_local_data.dart ├── macos │ ├── .gitignore │ ├── Flutter │ │ ├── Flutter-Debug.xcconfig │ │ ├── Flutter-Release.xcconfig │ │ ├── GeneratedPluginRegistrant.swift │ │ └── ephemeral │ │ │ ├── .app_filename │ │ │ ├── .symlinks │ │ │ ├── flutter │ │ │ └── plugins │ │ │ │ ├── path_provider │ │ │ │ ├── path_provider_fde │ │ │ │ ├── shared_preferences │ │ │ │ └── shared_preferences_fde │ │ │ ├── App.framework │ │ │ ├── App │ │ │ ├── Resources │ │ │ └── Versions │ │ │ │ ├── A │ │ │ │ ├── App │ │ │ │ └── Resources │ │ │ │ │ ├── Info.plist │ │ │ │ │ └── flutter_assets │ │ │ │ │ ├── AssetManifest.json │ │ │ │ │ ├── FontManifest.json │ │ │ │ │ ├── LICENSE │ │ │ │ │ ├── fonts │ │ │ │ │ └── MaterialIcons-Regular.ttf │ │ │ │ │ ├── isolate_snapshot_data │ │ │ │ │ ├── kernel_blob.bin │ │ │ │ │ ├── packages │ │ │ │ │ └── panache_core │ │ │ │ │ │ ├── lib │ │ │ │ │ │ └── logo.png │ │ │ │ │ │ └── logo.png │ │ │ │ │ └── vm_snapshot_data │ │ │ │ └── Current │ │ │ ├── Flutter-Generated.xcconfig │ │ │ ├── FlutterInputs.xcfilelist │ │ │ ├── FlutterMacOS.framework │ │ │ ├── FlutterMacOS │ │ │ ├── Headers │ │ │ ├── Modules │ │ │ ├── Resources │ │ │ └── Versions │ │ │ │ ├── A │ │ │ │ ├── FlutterMacOS │ │ │ │ ├── Headers │ │ │ │ │ ├── FLEDartProject.h │ │ │ │ │ ├── FLEEngine.h │ │ │ │ │ ├── FLEOpenGLContextHandling.h │ │ │ │ │ ├── FLEReshapeListener.h │ │ │ │ │ ├── FLEView.h │ │ │ │ │ ├── FLEViewController.h │ │ │ │ │ ├── FlutterBinaryMessenger.h │ │ │ │ │ ├── FlutterChannels.h │ │ │ │ │ ├── FlutterCodecs.h │ │ │ │ │ ├── FlutterDartProject.h │ │ │ │ │ ├── FlutterEngine.h │ │ │ │ │ ├── FlutterMacOS.h │ │ │ │ │ ├── FlutterMacros.h │ │ │ │ │ ├── FlutterPluginMacOS.h │ │ │ │ │ ├── FlutterPluginRegistrarMacOS.h │ │ │ │ │ └── FlutterViewController.h │ │ │ │ ├── Modules │ │ │ │ │ └── module.modulemap │ │ │ │ └── Resources │ │ │ │ │ ├── Info.plist │ │ │ │ │ └── icudtl.dat │ │ │ │ └── Current │ │ │ ├── FlutterOutputs.xcfilelist │ │ │ ├── flutter_export_environment.sh │ │ │ └── tripwire │ ├── Podfile │ ├── Pods │ │ ├── Local Podspecs │ │ │ ├── FlutterMacOS.podspec.json │ │ │ ├── path_provider_fde.podspec.json │ │ │ └── shared_preferences_fde.podspec.json │ │ ├── Pods.xcodeproj │ │ │ ├── project.pbxproj │ │ │ └── xcuserdata │ │ │ │ └── rxlabz.xcuserdatad │ │ │ │ └── xcschemes │ │ │ │ ├── FlutterMacOS.xcscheme │ │ │ │ ├── Pods-Runner.xcscheme │ │ │ │ ├── path_provider_fde.xcscheme │ │ │ │ ├── shared_preferences_fde.xcscheme │ │ │ │ └── xcschememanagement.plist │ │ └── Target Support Files │ │ │ ├── FlutterMacOS │ │ │ └── FlutterMacOS.xcconfig │ │ │ ├── Pods-Runner │ │ │ ├── Pods-Runner-Info.plist │ │ │ ├── Pods-Runner-acknowledgements.markdown │ │ │ ├── Pods-Runner-acknowledgements.plist │ │ │ ├── Pods-Runner-dummy.m │ │ │ ├── Pods-Runner-frameworks.sh │ │ │ ├── Pods-Runner-umbrella.h │ │ │ ├── Pods-Runner.debug.xcconfig │ │ │ ├── Pods-Runner.modulemap │ │ │ ├── Pods-Runner.profile.xcconfig │ │ │ └── Pods-Runner.release.xcconfig │ │ │ ├── path_provider_fde │ │ │ ├── path_provider_fde-Info.plist │ │ │ ├── path_provider_fde-dummy.m │ │ │ ├── path_provider_fde-prefix.pch │ │ │ ├── path_provider_fde-umbrella.h │ │ │ ├── path_provider_fde.modulemap │ │ │ └── path_provider_fde.xcconfig │ │ │ └── shared_preferences_fde │ │ │ ├── shared_preferences_fde-Info.plist │ │ │ ├── shared_preferences_fde-dummy.m │ │ │ ├── shared_preferences_fde-prefix.pch │ │ │ ├── shared_preferences_fde-umbrella.h │ │ │ ├── shared_preferences_fde.modulemap │ │ │ └── shared_preferences_fde.xcconfig │ ├── Runner.xcodeproj │ │ ├── project.pbxproj │ │ ├── project.xcworkspace │ │ │ ├── contents.xcworkspacedata │ │ │ └── xcshareddata │ │ │ │ └── IDEWorkspaceChecks.plist │ │ ├── xcshareddata │ │ │ └── xcschemes │ │ │ │ └── Runner.xcscheme │ │ └── xcuserdata │ │ │ └── rxlabz.xcuserdatad │ │ │ └── xcschemes │ │ │ └── xcschememanagement.plist │ ├── Runner.xcworkspace │ │ ├── contents.xcworkspacedata │ │ ├── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ │ └── xcuserdata │ │ │ └── rxlabz.xcuserdatad │ │ │ └── UserInterfaceState.xcuserstate │ └── Runner │ │ ├── AppDelegate.swift │ │ ├── Assets.xcassets │ │ └── AppIcon.appiconset │ │ │ ├── Contents.json │ │ │ ├── app_icon_1024.png │ │ │ ├── app_icon_128.png │ │ │ ├── app_icon_16.png │ │ │ ├── app_icon_256.png │ │ │ ├── app_icon_32.png │ │ │ ├── app_icon_512.png │ │ │ └── app_icon_64.png │ │ ├── Base.lproj │ │ └── MainMenu.xib │ │ ├── Configs │ │ ├── AppInfo.xcconfig │ │ ├── Debug.xcconfig │ │ ├── Release.xcconfig │ │ └── Warnings.xcconfig │ │ ├── DebugProfile.entitlements │ │ ├── Info.plist │ │ ├── MainFlutterWindow.swift │ │ └── Release.entitlements ├── pubspec.yaml └── test │ └── widget_test.dart ├── panache_mobile ├── .metadata ├── README.md ├── android │ ├── .gitignore │ ├── app │ │ ├── build.gradle │ │ └── src │ │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ │ ├── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── java │ │ │ │ ├── bz │ │ │ │ │ └── rxla │ │ │ │ │ │ └── panache │ │ │ │ │ │ └── MainActivity.java │ │ │ │ └── com │ │ │ │ │ └── example │ │ │ │ │ └── flutterial │ │ │ │ │ └── MainActivity.java │ │ │ └── res │ │ │ │ ├── drawable │ │ │ │ └── launch_background.xml │ │ │ │ ├── mipmap-hdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ └── ic_launcher.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ └── ic_launcher.png │ │ │ │ └── values │ │ │ │ └── styles.xml │ │ │ └── profile │ │ │ └── AndroidManifest.xml │ ├── build.gradle │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ └── gradle-wrapper.properties │ ├── key.properties │ └── settings.gradle ├── assets │ ├── google-drive.png │ ├── google.png │ └── theme.json ├── ios │ ├── Flutter │ │ ├── AppFrameworkInfo.plist │ │ ├── Debug.xcconfig │ │ ├── Release.xcconfig │ │ └── flutter_export_environment.sh │ ├── Podfile │ ├── Runner.xcodeproj │ │ ├── project.pbxproj │ │ ├── project.xcworkspace │ │ │ └── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── Runner.xcscheme │ ├── Runner.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── IDEWorkspaceChecks.plist │ │ │ └── WorkspaceSettings.xcsettings │ └── Runner │ │ ├── AppDelegate.h │ │ ├── AppDelegate.m │ │ ├── Assets.xcassets │ │ ├── AppIcon.appiconset │ │ │ ├── Contents.json │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ ├── icon1024.png │ │ │ ├── icon20.png │ │ │ ├── icon20@2x-1.png │ │ │ ├── icon20@2x.png │ │ │ ├── icon20@3x.png │ │ │ ├── icon29-1.png │ │ │ ├── icon29.png │ │ │ ├── icon29@2x-1.png │ │ │ ├── icon29@2x.png │ │ │ ├── icon29@3x.png │ │ │ ├── icon40.png │ │ │ ├── icon40@2x-1.png │ │ │ ├── icon40@2x.png │ │ │ ├── icon40@3x.png │ │ │ ├── icon60@2x.png │ │ │ ├── icon60@3x.png │ │ │ ├── icon76.png │ │ │ ├── icon76@2x.png │ │ │ └── icon83@2x.png │ │ └── LaunchImage.imageset │ │ │ ├── Contents.json │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ └── README.md │ │ ├── Base.lproj │ │ ├── LaunchScreen.storyboard │ │ └── Main.storyboard │ │ ├── Info.plist │ │ └── main.m ├── lib │ ├── export │ │ └── drive_service.dart │ └── main.dart ├── macos │ └── Flutter │ │ └── GeneratedPluginRegistrant.swift ├── pubspec.yaml ├── test │ ├── panache_test.dart │ └── widget_test.dart └── tmp │ └── generated_theme.dart ├── panache_services ├── .metadata ├── CHANGELOG.md ├── LICENSE ├── README.md ├── lib │ ├── panache_services.dart │ └── src │ │ └── services │ │ ├── google_mobile_service.dart │ │ ├── http_client.dart │ │ ├── io_theme_service.dart │ │ ├── local_data.dart │ │ └── screenshot_service.dart ├── pubspec.yaml └── test │ └── panache_services_test.dart ├── panache_ui ├── .gitignore ├── .metadata ├── CHANGELOG.md ├── LICENSE ├── README.md ├── assets │ └── github.png ├── lib │ ├── panache_ui.dart │ └── src │ │ ├── help │ │ ├── button_theme_help.dart │ │ ├── global_theme_help.dart │ │ └── help.dart │ │ └── screens │ │ ├── editor │ │ ├── action_bar.dart │ │ ├── color_stream.dart │ │ ├── color_swatch.dart │ │ ├── controls │ │ │ ├── brightness_control.dart │ │ │ ├── color_picker │ │ │ │ ├── color_pickers.dart │ │ │ │ ├── color_slider.dart │ │ │ │ ├── colorpicker_dialog.dart │ │ │ │ └── swatches.dart │ │ │ ├── color_scheme_control.dart │ │ │ ├── color_selector.dart │ │ │ ├── control_container.dart │ │ │ ├── font_size_slider.dart │ │ │ ├── help_button.dart │ │ │ ├── inputs_border_control.dart │ │ │ ├── shape_form_control.dart │ │ │ ├── slider_control.dart │ │ │ ├── switcher_control.dart │ │ │ └── text_style_control.dart │ │ ├── drive_menu.dart │ │ ├── editor_screen.dart │ │ ├── editor_utils.dart │ │ ├── panel_header.dart │ │ ├── panels │ │ │ ├── button_theme_panel.dart │ │ │ ├── chip_theme_panel.dart │ │ │ ├── dialog_theme_panel.dart │ │ │ ├── editor_topbar.dart │ │ │ ├── editor_topbar_web.dart │ │ │ ├── icon_theme_panel.dart │ │ │ ├── input_decoration_theme_panel.dart │ │ │ ├── panels.dart │ │ │ ├── slider_theme_panel.dart │ │ │ ├── tabbar_theme_panel.dart │ │ │ ├── theme_color_panel.dart │ │ │ └── typography_panel.dart │ │ ├── show_color_picker.dart │ │ └── theme_editor.dart │ │ ├── launch │ │ ├── io_stub.dart │ │ ├── launch_large_layout.dart │ │ ├── launch_screen.dart │ │ ├── logo.dart │ │ ├── new_theme_panel.dart │ │ ├── screenshot_renderer.dart │ │ └── web_screenshot_renderer.dart │ │ └── preview │ │ ├── app_preview.dart │ │ ├── code_preview.dart │ │ └── subscreens │ │ ├── chips_preview.dart │ │ ├── inputs_preview.dart │ │ ├── others_preview.dart │ │ ├── slider_preview.dart │ │ ├── typography_preview.dart │ │ └── widgets_preview.dart ├── pubspec.yaml └── test │ └── panache_ui_test.dart ├── panache_web ├── .metadata ├── README.md ├── generated │ └── theme.dart ├── lib │ ├── main.dart │ ├── src │ │ ├── theme_exporter_web.dart │ │ ├── web_link_service.dart │ │ ├── web_local_data.dart │ │ ├── web_persistence_bridge.dart │ │ └── web_theme_service.dart │ └── theme.dart ├── pubspec.yaml └── web │ ├── assets │ ├── .FontManifest.json │ ├── Roboto-Regular.ttf │ └── RobotoMono-Regular.ttf │ └── index.html └── tools └── publish.sh /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Miscellaneous 3 | *.jks 4 | GoogleService-Info.plist 5 | *.class 6 | *.lock 7 | *.log 8 | *.pyc 9 | *.swp 10 | .DS_Store 11 | _DEV.md 12 | .atom/ 13 | .buildlog/ 14 | .history 15 | .svn/ 16 | *.scss 17 | *.css.map 18 | *.js.map 19 | 20 | # IntelliJ related 21 | *.iml 22 | *.ipr 23 | *.iws 24 | .idea/ 25 | 26 | # Visual Studio Code related 27 | .vscode/ 28 | 29 | # Flutter/Dart/Pub related 30 | **/doc/api/ 31 | .dart_tool/ 32 | .flutter-plugins 33 | .packages 34 | .pub-cache/ 35 | .pub/ 36 | build/ 37 | 38 | # Android related 39 | **/android/**/gradle-wrapper.jar 40 | **/android/.gradle 41 | **/android/captures/ 42 | **/android/gradlew 43 | **/android/gradlew.bat 44 | **/android/local.properties 45 | **/android/**/GeneratedPluginRegistrant.java 46 | 47 | # iOS/XCode related 48 | **/ios/**/*.mode1v3 49 | **/ios/**/*.mode2v3 50 | **/ios/**/*.moved-aside 51 | **/ios/**/*.pbxuser 52 | **/ios/**/*.perspectivev3 53 | **/ios/**/*sync/ 54 | **/ios/**/.sconsign.dblite 55 | **/ios/**/.tags* 56 | **/ios/**/.vagrant/ 57 | **/ios/**/DerivedData/ 58 | **/ios/**/Icon? 59 | **/ios/**/Pods/ 60 | **/ios/**/.symlinks/ 61 | **/ios/**/profile 62 | **/ios/**/xcuserdata 63 | **/ios/.generated/ 64 | **/ios/Flutter/App.framework 65 | **/ios/Flutter/Flutter.framework 66 | **/ios/Flutter/Generated.xcconfig 67 | **/ios/Flutter/app.flx 68 | **/ios/Flutter/app.zip 69 | **/ios/Flutter/flutter_assets/ 70 | **/ios/ServiceDefinitions.json 71 | **/ios/Runner/GeneratedPluginRegistrant.* 72 | 73 | # Exceptions to above rules. 74 | !**/ios/**/default.mode1v3 75 | !**/ios/**/default.mode2v3 76 | !**/ios/**/default.pbxuser 77 | !**/ios/**/default.perspectivev3 78 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 79 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## 0.0.4 4 | 5 | - support Dart 2.1 (thanks @csells) 6 | 7 | ## 0.0.3 8 | 9 | - theme saving 10 | - flutterial companion 11 | 12 | ## 0.0.2 13 | 14 | - fixes for iOS layout 15 | 16 | ## 0.0.1 17 | 18 | - basic colors and text theme preview 19 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 🎨 Panache 2 | 3 | A [Flutter](https://flutter.io) [Material Theme](https://docs.flutter.io/flutter/material/ThemeData-class.html) editor. 4 | 5 | Panache helps you to create beautiful [Material](http://material.io) themes for your Flutter applications. 6 | 7 | Customize widgets colors and shapes, and download your `theme.dart` file. 8 | 9 | ## :earth_americas: [Try Panache in your browser](https://rxlabz.github.io/panache) 10 | 11 | ![home](docs/assets/home.png) 12 | 13 | ## Getting Started 14 | 15 | To apply a theme to whole application 16 | - add the generated theme file to your project/lib 17 | - set the theme property to the generated theme (`myTheme`) in your main file 18 | 19 | ```dart 20 | // ... 21 | 22 | MaterialApp( theme: myTheme , home: Home() ); 23 | 24 | // ... 25 | ``` 26 | 27 | - [Using theme in Flutter](https://flutter.dev/docs/cookbook/design/themes) 28 | 29 | ## :coffee: Support this project 30 | 31 | [![Buy Me A Coffee](https://bmc-cdn.nyc3.digitaloceanspaces.com/BMC-button-images/custom_images/orange_img.png)](https://www.buymeacoffee.com/6NHRAj4P5) 32 | 33 | ## 🍿 Videos 34 | 35 | - [Beyond Mobile: Material Design, Adaptable UIs, and Flutter (Google I/O'19)](https://www.youtube.com/watch?v=YSULAJf6R6M) 36 | - [Code beautiful UI with Flutter and Material Design (Google I/O '18)](https://www.youtube.com/watch?v=hA0hrpR-o8U) 37 | 38 | ## Screenshots 39 | 40 | ![screenshot](docs/assets/screenshot.png) 41 | 42 | ![screenshot2](docs/assets/screenshot2.png) 43 | 44 | ![screenshot3](docs/assets/screenshot3.png) 45 | 46 | ![screenshot4](docs/assets/screenshot4.png) 47 | 48 | -------------------------------------------------------------------------------- /desktop_plugins/README.md: -------------------------------------------------------------------------------- 1 | # Temporary 2 | 3 | until macos plugins are published -------------------------------------------------------------------------------- /desktop_plugins/path_provider_fde/.gitignore: -------------------------------------------------------------------------------- 1 | .packages 2 | .flutter-plugins 3 | pubspec.lock 4 | -------------------------------------------------------------------------------- /desktop_plugins/path_provider_fde/macos/path_provider_fde.podspec: -------------------------------------------------------------------------------- 1 | # 2 | # To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html 3 | # 4 | Pod::Spec.new do |s| 5 | s.name = 'path_provider_fde' 6 | s.version = '0.0.1' 7 | s.summary = 'A Flutter plugin for getting commonly used locations on the filesystem.' 8 | s.description = <<-DESC 9 | A temporary macOS implmentation of the path_provider plugin from flutter/plugins. 10 | DESC 11 | s.homepage = 'https://github.com/google/flutter-desktop-embedding/tree/master/plugins/flutter_plugins/path_provider_fde' 12 | s.license = { :file => '../LICENSE' } 13 | s.author = { 'Flutter Desktop Embedding Developers' => 'flutter-desktop-embedding-dev@googlegroups.com' } 14 | s.source = { :path => '.' } 15 | s.source_files = 'Classes/**/*' 16 | s.dependency 'FlutterMacOS' 17 | 18 | s.platform = :osx 19 | s.osx.deployment_target = '10.11' 20 | end 21 | 22 | -------------------------------------------------------------------------------- /desktop_plugins/path_provider_fde/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: path_provider_fde 2 | description: Temporary desktop implmentations of path_provider from flutter/plugins 3 | version: 0.0.1 4 | author: Flutter Desktop Embedding Developers 5 | homepage: https://github.com/google/flutter-desktop-embedding/tree/master/plugins/flutter_plugins/path_provider_fde 6 | 7 | flutter: 8 | plugin: 9 | platforms: 10 | macos: 11 | pluginClass: PathProviderPlugin 12 | 13 | environment: 14 | sdk: ">=2.1.0 <3.0.0" 15 | 16 | dependencies: 17 | flutter: 18 | sdk: flutter 19 | -------------------------------------------------------------------------------- /desktop_plugins/shared_preferences_fde/.gitignore: -------------------------------------------------------------------------------- 1 | .packages 2 | .flutter-plugins 3 | pubspec.lock 4 | -------------------------------------------------------------------------------- /desktop_plugins/shared_preferences_fde/macos/shared_preferences_fde.podspec: -------------------------------------------------------------------------------- 1 | # 2 | # To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html 3 | # 4 | Pod::Spec.new do |s| 5 | s.name = 'shared_preferences_fde' 6 | s.version = '0.0.1' 7 | s.summary = 'Flutter plugin for reading and writing simple key-value pairs.' 8 | s.description = <<-DESC 9 | A temporary macOS implmentation of the shared_preferences plugin from flutter/plugins. 10 | DESC 11 | s.homepage = 'https://github.com/google/flutter-desktop-embedding/tree/master/plugins/flutter_plugins/shared_preferences_fde' 12 | s.license = { :file => '../LICENSE' } 13 | s.author = { 'Flutter Desktop Embedding Developers' => 'flutter-desktop-embedding-dev@googlegroups.com' } 14 | s.source = { :path => '.' } 15 | s.source_files = 'Classes/**/*' 16 | s.dependency 'FlutterMacOS' 17 | 18 | s.platform = :osx 19 | s.osx.deployment_target = '10.11' 20 | end 21 | 22 | -------------------------------------------------------------------------------- /desktop_plugins/shared_preferences_fde/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: shared_preferences_fde 2 | description: Temporary desktop implmentations of shared_preferences from flutter/plugins 3 | version: 0.0.1 4 | author: Flutter Desktop Embedding Developers 5 | homepage: https://github.com/google/flutter-desktop-embedding/tree/master/plugins/flutter_plugins/shared_preferences_fde 6 | 7 | flutter: 8 | plugin: 9 | platforms: 10 | macos: 11 | pluginClass: SharedPreferencesPlugin 12 | 13 | environment: 14 | sdk: ">=2.1.0 <3.0.0" 15 | 16 | dependencies: 17 | flutter: 18 | sdk: flutter 19 | -------------------------------------------------------------------------------- /docs/assets/AssetManifest.json: -------------------------------------------------------------------------------- 1 | {"packages/panache_ui/github.png":["packages/panache_ui/assets/github.png"],"packages/panache_core/logo.png":["packages/panache_core/lib/logo.png"]} -------------------------------------------------------------------------------- /docs/assets/FontManifest.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "fonts": [ 4 | { 5 | "asset": "fonts/MaterialIcons-Regular.ttf" 6 | } 7 | ], 8 | "family": "MaterialIcons" 9 | }, 10 | { 11 | "family": "Roboto", 12 | "fonts": [ 13 | { 14 | "asset": "fonts/Roboto-Regular.ttf" 15 | } 16 | ] 17 | }, 18 | { 19 | "family": "RobotoMono", 20 | "fonts": [ 21 | { 22 | "asset": "fonts/RobotoMono-Regular.ttf" 23 | } 24 | ] 25 | } 26 | ] 27 | -------------------------------------------------------------------------------- /docs/assets/fonts/MaterialIcons-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/fonts/MaterialIcons-Regular.ttf -------------------------------------------------------------------------------- /docs/assets/fonts/Roboto-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/fonts/Roboto-Regular.ttf -------------------------------------------------------------------------------- /docs/assets/fonts/RobotoMono-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/fonts/RobotoMono-Regular.ttf -------------------------------------------------------------------------------- /docs/assets/home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/home.png -------------------------------------------------------------------------------- /docs/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/logo.png -------------------------------------------------------------------------------- /docs/assets/packages/flutter_web_ui/assets/Roboto-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/packages/flutter_web_ui/assets/Roboto-Regular.ttf -------------------------------------------------------------------------------- /docs/assets/packages/panache_core/lib/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/packages/panache_core/lib/logo.png -------------------------------------------------------------------------------- /docs/assets/packages/panache_ui/assets/github.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/packages/panache_ui/assets/github.png -------------------------------------------------------------------------------- /docs/assets/screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/screenshot.png -------------------------------------------------------------------------------- /docs/assets/screenshot2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/screenshot2.png -------------------------------------------------------------------------------- /docs/assets/screenshot3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/screenshot3.png -------------------------------------------------------------------------------- /docs/assets/screenshot4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/docs/assets/screenshot4.png -------------------------------------------------------------------------------- /docs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | panache_web 6 | 8 | 31 | 32 | 33 | 34 | 35 | 36 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /panache_core/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | # The .vscode folder contains launch configuration and tasks you configure in 19 | # VS Code which you may wish to be included in version control, so this line 20 | # is commented out by default. 21 | #.vscode/ 22 | 23 | # Flutter/Dart/Pub related 24 | **/doc/api/ 25 | .dart_tool/ 26 | .flutter-plugins 27 | .packages 28 | .pub-cache/ 29 | .pub/ 30 | build/ 31 | 32 | # Android related 33 | **/android/**/gradle-wrapper.jar 34 | **/android/.gradle 35 | **/android/captures/ 36 | **/android/gradlew 37 | **/android/gradlew.bat 38 | **/android/local.properties 39 | **/android/**/GeneratedPluginRegistrant.java 40 | 41 | # iOS/XCode related 42 | **/ios/**/*.mode1v3 43 | **/ios/**/*.mode2v3 44 | **/ios/**/*.moved-aside 45 | **/ios/**/*.pbxuser 46 | **/ios/**/*.perspectivev3 47 | **/ios/**/*sync/ 48 | **/ios/**/.sconsign.dblite 49 | **/ios/**/.tags* 50 | **/ios/**/.vagrant/ 51 | **/ios/**/DerivedData/ 52 | **/ios/**/Icon? 53 | **/ios/**/Pods/ 54 | **/ios/**/.symlinks/ 55 | **/ios/**/profile 56 | **/ios/**/xcuserdata 57 | **/ios/.generated/ 58 | **/ios/Flutter/App.framework 59 | **/ios/Flutter/Flutter.framework 60 | **/ios/Flutter/Generated.xcconfig 61 | **/ios/Flutter/app.flx 62 | **/ios/Flutter/app.zip 63 | **/ios/Flutter/flutter_assets/ 64 | **/ios/Flutter/flutter_export_environment.sh 65 | **/ios/ServiceDefinitions.json 66 | **/ios/Runner/GeneratedPluginRegistrant.* 67 | 68 | # Exceptions to above rules. 69 | !**/ios/**/default.mode1v3 70 | !**/ios/**/default.mode2v3 71 | !**/ios/**/default.pbxuser 72 | !**/ios/**/default.perspectivev3 73 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 74 | -------------------------------------------------------------------------------- /panache_core/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: af9f210443971a86484c4772f54003838e64b388 8 | channel: master 9 | 10 | project_type: package 11 | -------------------------------------------------------------------------------- /panache_core/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## [0.0.1] - TODO: Add release date. 2 | 3 | * TODO: Describe initial release. 4 | -------------------------------------------------------------------------------- /panache_core/LICENSE: -------------------------------------------------------------------------------- 1 | TODO: Add your license here. 2 | -------------------------------------------------------------------------------- /panache_core/README.md: -------------------------------------------------------------------------------- 1 | # panache_core 2 | 3 | Panache main lib 4 | -------------------------------------------------------------------------------- /panache_core/lib/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_core/lib/logo.png -------------------------------------------------------------------------------- /panache_core/lib/panache_core.dart: -------------------------------------------------------------------------------- 1 | library panache_core; 2 | 3 | export 'src/app_theme.dart'; 4 | export 'src/models.dart'; 5 | export 'src/utils/color_utils.dart'; 6 | export 'src/utils/constants.dart'; 7 | export 'src/utils/syntax_highlighter.dart'; 8 | export 'src/services/theme_service.dart'; 9 | export 'src/services/persistence_service.dart'; 10 | export 'src/services/cloud_service.dart'; 11 | export 'src/services/screenshot_service.dart'; 12 | export 'src/services/user_service.dart'; 13 | export 'src/services/link_service.dart'; 14 | export 'src/converters/theme_converter.dart'; 15 | export 'src/theme_model.dart'; 16 | -------------------------------------------------------------------------------- /panache_core/lib/src/app_theme.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | const panachePrimarySwatch = Colors.blueGrey; 4 | 5 | /*final panacheTheme = ThemeData.localize( 6 | ThemeData( 7 | fontFamily: 'Roboto', 8 | primarySwatch: panachePrimarySwatch, 9 | textTheme: Typography.blackCupertino.copyWith( 10 | body1: Typography.blackCupertino.body1.copyWith(fontSize: 12), 11 | body2: Typography.blackCupertino.body2.copyWith(fontSize: 12), 12 | subtitle: Typography.blackCupertino.subtitle 13 | .copyWith(color: panachePrimarySwatch.shade400, fontSize: 12), 14 | title: Typography.blackCupertino.title 15 | .copyWith(color: panachePrimarySwatch.shade300), 16 | headline: Typography.blackCupertino.headline 17 | .copyWith(color: panachePrimarySwatch), 18 | ), 19 | primaryIconTheme: IconThemeData.fallback().copyWith(color: Colors.yellow), 20 | sliderTheme: ThemeData.light().sliderTheme), 21 | Typography.blackCupertino, 22 | );*/ 23 | 24 | ThemeData buildAppTheme(ThemeData theme, MaterialColor primarySwatch) { 25 | final textTheme = theme.textTheme; 26 | final accentColor = primarySwatch[500]; 27 | final primaryColorDark = primarySwatch[700]; 28 | 29 | return theme.copyWith( 30 | textTheme: textTheme.copyWith( 31 | body1: textTheme.body1.copyWith(fontSize: 12), 32 | body2: textTheme.body2.copyWith(fontSize: 12), 33 | subtitle: 34 | textTheme.subtitle.copyWith(color: primarySwatch[400], fontSize: 12), 35 | title: textTheme.title.copyWith(color: primarySwatch[300]), 36 | headline: textTheme.headline.copyWith(color: primarySwatch), 37 | ), 38 | primaryColor: primarySwatch, 39 | primaryColorBrightness: ThemeData.estimateBrightnessForColor(primarySwatch), 40 | primaryColorLight: primarySwatch[100], 41 | primaryColorDark: primaryColorDark, 42 | toggleableActiveColor: primarySwatch[600], 43 | accentColor: accentColor, 44 | primaryIconTheme: IconThemeData.fallback().copyWith(color: Colors.yellow), 45 | secondaryHeaderColor: primarySwatch[50], 46 | textSelectionColor: primarySwatch[200], 47 | textSelectionHandleColor: primarySwatch[300], 48 | backgroundColor: primarySwatch[200], 49 | colorScheme: ColorScheme.fromSwatch( 50 | primarySwatch: primarySwatch, 51 | primaryColorDark: primarySwatch[700], 52 | accentColor: accentColor, 53 | cardColor: Colors.white, 54 | ), 55 | ); 56 | } 57 | -------------------------------------------------------------------------------- /panache_core/lib/src/converters/chip_theme_converter.dart: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_core/lib/src/converters/chip_theme_converter.dart -------------------------------------------------------------------------------- /panache_core/lib/src/converters/icon_theme_converter.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | import 'converter_utils.dart'; 4 | 5 | String iconThemeToCode(IconThemeData theme) { 6 | final iconTheme = IconThemeData.fallback().merge(theme); 7 | return '''IconThemeData( 8 | color: ${colorToCode(iconTheme.color)}, 9 | opacity: ${iconTheme.opacity}, 10 | size: ${iconTheme.size}, 11 | )'''; 12 | } 13 | 14 | Map iconThemeToMap(IconThemeData theme) { 15 | final iconTheme = IconThemeData.fallback().merge(theme); 16 | return { 17 | 'color': iconTheme.color.value, 18 | 'opacity': iconTheme.opacity, 19 | 'size': iconTheme.size, 20 | }; 21 | } 22 | 23 | IconThemeData iconThemeFromMap(Map data) { 24 | if (data == null) return null; 25 | return IconThemeData( 26 | color: Color(data['color']), 27 | opacity: data['opacity'] ?? 1.0, 28 | size: data['size'] ?? 12.0, 29 | ); 30 | } 31 | -------------------------------------------------------------------------------- /panache_core/lib/src/models.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:flutter/material.dart'; 4 | 5 | import 'utils/color_utils.dart'; 6 | 7 | class User { 8 | final String name; 9 | final String avatarPath; 10 | 11 | const User(this.name, this.avatarPath); 12 | } 13 | 14 | class PanacheTheme { 15 | final String id; 16 | final String name; 17 | final ColorSwatch primarySwatch; 18 | final Brightness brightness; 19 | 20 | const PanacheTheme({ 21 | @required this.id, 22 | @required this.name, 23 | @required this.primarySwatch, 24 | @required this.brightness, 25 | }); 26 | 27 | factory PanacheTheme.fromJson(String data) { 28 | final rawTheme = json.decode(data); 29 | return PanacheTheme( 30 | id: rawTheme['id'], 31 | name: rawTheme['name'], 32 | primarySwatch: swatchFor(color: Color(rawTheme['primarySwatch'])), 33 | brightness: Brightness.values[rawTheme['brightness']], 34 | ); 35 | } 36 | 37 | String toJson() { 38 | final data = { 39 | 'id': id, 40 | 'name': name, 41 | 'primarySwatch': primarySwatch.value, 42 | 'brightness': Brightness.values.indexOf(brightness), 43 | }; 44 | return json.encode(data); 45 | } 46 | 47 | @override 48 | String toString() { 49 | return 'PanacheTheme{' 50 | 'id: $id, name: $name, ' 51 | 'primarySwatch: $primarySwatch, ' 52 | 'brightness: $brightness' 53 | '}'; 54 | } 55 | 56 | @override 57 | bool operator ==(Object other) => 58 | identical(this, other) || 59 | other is PanacheTheme && 60 | runtimeType == other.runtimeType && 61 | id == other.id && 62 | name == other.name && 63 | primarySwatch == other.primarySwatch; 64 | 65 | @override 66 | int get hashCode => id.hashCode ^ name.hashCode ^ primarySwatch.hashCode; 67 | } 68 | -------------------------------------------------------------------------------- /panache_core/lib/src/services/cloud_service.dart: -------------------------------------------------------------------------------- 1 | import 'package:panache_core/panache_core.dart'; 2 | 3 | abstract class CloudService { 4 | Future get authenticated; 5 | //User get user; 6 | Stream get currentUser$; 7 | 8 | Future login(); 9 | Future logout(); 10 | Future save(String content); 11 | } 12 | -------------------------------------------------------------------------------- /panache_core/lib/src/services/link_service.dart: -------------------------------------------------------------------------------- 1 | abstract class LinkService { 2 | void open(String url); 3 | } 4 | -------------------------------------------------------------------------------- /panache_core/lib/src/services/persistence_service.dart: -------------------------------------------------------------------------------- 1 | import '../models.dart'; 2 | 3 | const Map defaultPanelStates = const { 4 | 'colorPanelExpanded': false, 5 | 'buttonThemePanelExpanded': false, 6 | 'iconThemePanelExpanded': false, 7 | 'sliderThemePanelExpanded': false, 8 | 'tabBarThemePanelExpanded': false, 9 | 'chipThemePanelExpanded': false, 10 | 'dialogThemePanelExpanded': false, 11 | 'textPanelExpanded': false, 12 | 'primaryTextPanelExpanded': false, 13 | 'accentTextPanelExpanded': false, 14 | 'inputsPanelExpanded': false, 15 | }; 16 | 17 | abstract class LocalStorage { 18 | List get themes; 19 | 20 | Map get panelStates; 21 | 22 | double get scrollPosition; 23 | 24 | void updateThemeList(List themes); 25 | 26 | void saveEditorState(Map panelStates, double pixels); 27 | 28 | void saveScrollPosition(double pixels); 29 | 30 | void deleteTheme(PanacheTheme theme); 31 | 32 | void clear(); 33 | } 34 | -------------------------------------------------------------------------------- /panache_core/lib/src/services/screenshot_service.dart: -------------------------------------------------------------------------------- 1 | import 'dart:typed_data'; 2 | 3 | abstract class ScreenshotService { 4 | void capture(String filename, Uint8List pngBytes); 5 | } 6 | -------------------------------------------------------------------------------- /panache_core/lib/src/services/theme_service.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/foundation.dart'; 2 | import 'package:flutter/material.dart'; 3 | import 'package:flutter/services.dart'; 4 | 5 | abstract class ThemeService { 6 | final Function(String, String) themeExporter; 7 | 8 | final Future Function() dirProvider; 9 | D _dir; 10 | D get dir => _dir; 11 | 12 | ThemeData _theme; 13 | ThemeData get theme => _theme; 14 | 15 | List _themes; 16 | List get themes => _themes; 17 | 18 | VoidCallback _onChange; 19 | 20 | ThemeService({this.themeExporter, this.dirProvider}); 21 | 22 | init(VoidCallback onChange) { 23 | _onChange = onChange; 24 | if (dirProvider != null) 25 | dirProvider().then((dir) { 26 | _dir = dir; 27 | _onChange(); 28 | }); 29 | } 30 | 31 | ThemeData _localize(ThemeData theme) => 32 | ThemeData.localize(theme, Typography.englishLike2018); 33 | 34 | void initTheme( 35 | {MaterialColor primarySwatch: Colors.blue, 36 | Brightness brightness: Brightness.light}) { 37 | //final inputTheme = InputDecoration().applyDefaults(InputDecorationTheme()); 38 | 39 | _theme = ThemeData( 40 | fontFamily: 'Roboto', 41 | primarySwatch: primarySwatch, 42 | brightness: brightness, 43 | platform: TargetPlatform.iOS 44 | /*Platform.isAndroid 45 | ? TargetPlatform.android 46 | : TargetPlatform.iOS*/ 47 | , 48 | ); 49 | } 50 | 51 | void updateTheme(ThemeData newTheme) => _theme = newTheme; 52 | 53 | void exportTheme({String filename, String code}) => 54 | themeExporter(code, filename); 55 | 56 | void saveTheme(String filename); 57 | 58 | Future loadTheme(String path); 59 | 60 | bool themeExists(String path) {} 61 | } 62 | -------------------------------------------------------------------------------- /panache_core/lib/src/services/user_service.dart: -------------------------------------------------------------------------------- 1 | abstract class UserService { 2 | Future login(); 3 | /*async { 4 | final result = await _cloudService.login(); 5 | notifyListeners(); 6 | return result; 7 | }*/ 8 | 9 | void logout(); 10 | /*async { 11 | await _cloudService.logout(); 12 | notifyListeners(); 13 | }*/ 14 | 15 | Future exportTheme(String theme); 16 | /* async { 17 | bool authenticated = await _cloudService.authenticated; 18 | if (!authenticated) authenticated = await _cloudService.login(); 19 | 20 | if (!authenticated) return false; 21 | final result = await _cloudService.save(themeToCode(_service.theme)); 22 | print('ThemeModel.exportThemeToDrive... $result'); 23 | return result.originalFilename ?? result.name; 24 | }*/ 25 | 26 | } 27 | -------------------------------------------------------------------------------- /panache_core/lib/src/utils/constants.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | const EdgeInsets kPadding = const EdgeInsets.all(8.0); 4 | 5 | const h3 = TextStyle( 6 | fontWeight: FontWeight.bold, fontSize: 18.0, color: Colors.blueGrey); 7 | 8 | const kSwatchSize = 48.0; 9 | 10 | const kDarkTextStyle = const TextStyle(color: Colors.black, fontSize: 11.0); 11 | 12 | const kLightTextStyle = const TextStyle(color: Colors.white, fontSize: 11.0); 13 | 14 | final enabledRaisedButton = RaisedButton(onPressed: () {}); 15 | 16 | const disabledRaisedButton = RaisedButton(onPressed: null); 17 | -------------------------------------------------------------------------------- /panache_core/lib/src/utils/example_code_parser.dart: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Chromium Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | import 'dart:async'; 6 | 7 | const String _kStartTag = '// START '; 8 | const String _kEndTag = '// END'; 9 | 10 | Map _exampleCode; 11 | 12 | Future getExampleCode(String tag, String code) async { 13 | if (_exampleCode == null) await _parseExampleCode(code); 14 | return _exampleCode[tag]; 15 | } 16 | 17 | Future _parseExampleCode(String code) async { 18 | //final String code = await bundle.loadString('lib/gallery/example_code.dart') ?? 19 | //'// lib/gallery/example_code.dart not found\n'; 20 | _exampleCode = {}; 21 | 22 | final List lines = code.split('\n'); 23 | 24 | List codeBlock; 25 | String codeTag; 26 | 27 | for (String line in lines) { 28 | if (codeBlock == null) { 29 | // Outside a block. 30 | if (line.startsWith(_kStartTag)) { 31 | // Starting a new code block. 32 | codeBlock = []; 33 | codeTag = line.substring(_kStartTag.length).trim(); 34 | } else { 35 | // Just skipping the line. 36 | } 37 | } else { 38 | // Inside a block. 39 | if (line.startsWith(_kEndTag)) { 40 | // Add the block. 41 | _exampleCode[codeTag] = codeBlock.join('\n'); 42 | codeBlock = null; 43 | codeTag = null; 44 | } else { 45 | // Add to the current block 46 | // trimRight() to remove any \r on Windows 47 | // without removing any useful indentation 48 | codeBlock.add(line.trimRight()); 49 | } 50 | } 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /panache_core/lib/src/utils/theme_defaults.dart: -------------------------------------------------------------------------------- 1 | /* 2 | final defaultInputDecorationtheme = InputDecorationTheme( 3 | labelStyle: , 4 | helperStyle: , 5 | hintStyle: ,errorStyle: , 6 | errorBorder: 7 | );*/ 8 | -------------------------------------------------------------------------------- /panache_core/lib/src/utils/uuid.dart: -------------------------------------------------------------------------------- 1 | import 'dart:math'; 2 | 3 | class Uuid { 4 | final Random _random = Random(); 5 | 6 | /// Generate a version 4 (random) uuid. This is a uuid scheme that only uses 7 | /// random numbers as the source of the generated uuid. 8 | String generateV4() { 9 | // Generate xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx / 8-4-4-4-12. 10 | final int special = 8 + _random.nextInt(4); 11 | 12 | return '${_bitsDigits(16, 4)}${_bitsDigits(16, 4)}-' 13 | '${_bitsDigits(16, 4)}-' 14 | '4${_bitsDigits(12, 3)}-' 15 | '${_printDigits(special, 1)}${_bitsDigits(12, 3)}-' 16 | '${_bitsDigits(16, 4)}${_bitsDigits(16, 4)}${_bitsDigits(16, 4)}'; 17 | } 18 | 19 | String _bitsDigits(int bitCount, int digitCount) => 20 | _printDigits(_generateBits(bitCount), digitCount); 21 | 22 | int _generateBits(int bitCount) => _random.nextInt(1 << bitCount); 23 | 24 | String _printDigits(int value, int count) => 25 | value.toRadixString(16).padLeft(count, '0'); 26 | } 27 | -------------------------------------------------------------------------------- /panache_core/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: panache_core 2 | description: Panache app core 3 | version: 0.1.0 4 | author: Erick Ghaumez 5 | homepage: https://github.com/rxlabz/panache 6 | 7 | environment: 8 | sdk: ">=2.2.2 <3.0.0" 9 | 10 | dependencies: 11 | flutter: 12 | sdk: flutter 13 | 14 | scoped_model: ^1.0.1 15 | path_provider: ^1.2.0 16 | string_scanner: ^1.0.5 17 | http: ^0.12.0 18 | 19 | dev_dependencies: 20 | flutter_test: 21 | sdk: flutter 22 | 23 | flutter: 24 | assets: 25 | - logo.png -------------------------------------------------------------------------------- /panache_core/test/color_utils_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_test/flutter_test.dart'; 2 | 3 | void main() { 4 | /*test('',(){ 5 | expect( , ); 6 | });*/ 7 | } 8 | -------------------------------------------------------------------------------- /panache_core/test/converters/convert_button_theme_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_test/flutter_test.dart'; 3 | import 'package:panache_core/src/converters/button_theme_converters.dart'; 4 | 5 | import 'mock_button_theme.dart'; 6 | 7 | void main() { 8 | ButtonThemeData buttonTheme; 9 | 10 | group('convert buttonTheme', () { 11 | /*setUp(() { 12 | final theme = ThemeData.light(); 13 | buttonTheme = theme.buttonTheme; 14 | });*/ 15 | 16 | test('buttonShapeToCode', () { 17 | expect( 18 | buttonShapeToCode( 19 | RoundedRectangleBorder(borderRadius: BorderRadius.circular(2))), 20 | roundedRectangleBorderCode); 21 | expect(buttonShapeToCode(BeveledRectangleBorder()), 22 | beveledRectangleBorderCode); 23 | expect(buttonShapeToCode(StadiumBorder()), stadiumBorderCode); 24 | expect(buttonShapeToCode(CircleBorder()), circleBorderCode); 25 | }); 26 | 27 | test('buttonShapeToCode - with border', () { 28 | expect( 29 | buttonShapeToCode( 30 | RoundedRectangleBorder( 31 | side: BorderSide(color: Color(0xff000000), width: 1.0), 32 | borderRadius: BorderRadius.all(Radius.circular(2.0)), 33 | ), 34 | ), 35 | roundedRectangleBorderSideCode); 36 | 37 | expect( 38 | buttonShapeToCode(BeveledRectangleBorder( 39 | side: BorderSide(color: Color(0xff000000), width: 1.0))), 40 | beveledRectangleBorderSideCode); 41 | 42 | expect( 43 | buttonShapeToCode(StadiumBorder( 44 | side: BorderSide(color: Color(0xff000000), width: 1.0))), 45 | stadiumRectangleBorderSideCode); 46 | 47 | expect( 48 | buttonShapeToCode(CircleBorder( 49 | side: BorderSide(color: Color(0xff000000), width: 1.0))), 50 | circleBorderSideCode); 51 | }); 52 | }); 53 | } 54 | -------------------------------------------------------------------------------- /panache_core/test/converters/mock_button_theme.dart: -------------------------------------------------------------------------------- 1 | const roundedRectangleBorderCode = ''' 2 | RoundedRectangleBorder( 3 | side: BorderSide(color: Color(0xff000000), width: 0.0, style: BorderStyle.none, ), 4 | borderRadius: BorderRadius.all(Radius.circular(2.0)), 5 | ) 6 | '''; 7 | const roundedRectangleBorderSideCode = ''' 8 | RoundedRectangleBorder( 9 | side: BorderSide(color: Color(0xff000000), width: 1.0, style: BorderStyle.solid, ), 10 | borderRadius: BorderRadius.all(Radius.circular(2.0)), 11 | ) 12 | '''; 13 | 14 | const beveledRectangleBorderCode = ''' 15 | BeveledRectangleBorder( 16 | side: BorderSide(color: Color(0xff000000), width: 0.0, style: BorderStyle.none, ), 17 | borderRadius: BorderRadius.all(Radius.circular(0.0)), 18 | ) 19 | '''; 20 | 21 | const beveledRectangleBorderSideCode = ''' 22 | BeveledRectangleBorder( 23 | side: BorderSide(color: Color(0xff000000), width: 1.0, style: BorderStyle.solid, ), 24 | borderRadius: BorderRadius.all(Radius.circular(0.0)), 25 | ) 26 | '''; 27 | 28 | const stadiumBorderCode = 29 | '''StadiumBorder( side: BorderSide(color: Color(0xff000000), width: 0.0, style: BorderStyle.none, ) )'''; 30 | 31 | const stadiumRectangleBorderSideCode = 32 | '''StadiumBorder( side: BorderSide(color: Color(0xff000000), width: 1.0, style: BorderStyle.solid, ) )'''; 33 | 34 | const circleBorderCode = 35 | '''CircleBorder( side: BorderSide(color: Color(0xff000000), width: 0.0, style: BorderStyle.none, ) )'''; 36 | 37 | const circleBorderSideCode = 38 | '''CircleBorder( side: BorderSide(color: Color(0xff000000), width: 1.0, style: BorderStyle.solid, ) )'''; 39 | -------------------------------------------------------------------------------- /panache_core/test/converters/theme_converter_test.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:flutter_test/flutter_test.dart'; 5 | import 'package:panache_core/src/converters/theme_converter.dart'; 6 | 7 | const codeStart = ''' 8 | import 'package:flutter/material.dart'; 9 | final ThemeData myTheme = ThemeData('''; 10 | 11 | void main() { 12 | test('can export theme to code', () { 13 | final theme = ThemeData.light(); 14 | final themeCode = themeToCode(theme); 15 | expect(themeCode.contains(codeStart), true); 16 | expect(themeCode.contains('primarySwatch: Colors.blue,'), true); 17 | expect(themeCode.contains('sliderTheme: SliderThemeData('), true); 18 | expect(themeCode.contains('tabBarTheme: TabBarTheme('), true); 19 | expect(themeCode.contains('chipTheme: ChipThemeData('), true); 20 | expect(themeCode.contains('dialogTheme: DialogTheme('), true); 21 | }); 22 | 23 | test('can save theme to / load theme from JSON', () { 24 | final theme = ThemeData.light(); 25 | final themeMap = themeToMap(theme); 26 | final generatedTheme = themeFromJson(json.encode(themeMap)); 27 | expect(generatedTheme.primaryColor.value, Colors.blue.value); 28 | expect(themeMap, themeToMap(generatedTheme)); 29 | }); 30 | } 31 | -------------------------------------------------------------------------------- /panache_core/test/flutterial_components_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_test/flutter_test.dart'; 2 | 3 | void main() { 4 | group('A group of tests', () { 5 | setUp(() {}); 6 | 7 | test('First Test', () {}); 8 | }); 9 | } 10 | -------------------------------------------------------------------------------- /panache_desktop/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | # The .vscode folder contains launch configuration and tasks you configure in 19 | # VS Code which you may wish to be included in version control, so this line 20 | # is commented out by default. 21 | #.vscode/ 22 | 23 | # Flutter/Dart/Pub related 24 | **/doc/api/ 25 | .dart_tool/ 26 | .flutter-plugins 27 | .packages 28 | .pub-cache/ 29 | .pub/ 30 | /build/ 31 | 32 | # Android related 33 | **/android/**/gradle-wrapper.jar 34 | **/android/.gradle 35 | **/android/captures/ 36 | **/android/gradlew 37 | **/android/gradlew.bat 38 | **/android/local.properties 39 | **/android/**/GeneratedPluginRegistrant.java 40 | 41 | # iOS/XCode related 42 | **/ios/**/*.mode1v3 43 | **/ios/**/*.mode2v3 44 | **/ios/**/*.moved-aside 45 | **/ios/**/*.pbxuser 46 | **/ios/**/*.perspectivev3 47 | **/ios/**/*sync/ 48 | **/ios/**/.sconsign.dblite 49 | **/ios/**/.tags* 50 | **/ios/**/.vagrant/ 51 | **/ios/**/DerivedData/ 52 | **/ios/**/Icon? 53 | **/ios/**/Pods/ 54 | **/ios/**/.symlinks/ 55 | **/ios/**/profile 56 | **/ios/**/xcuserdata 57 | **/ios/.generated/ 58 | **/ios/Flutter/App.framework 59 | **/ios/Flutter/Flutter.framework 60 | **/ios/Flutter/Generated.xcconfig 61 | **/ios/Flutter/app.flx 62 | **/ios/Flutter/app.zip 63 | **/ios/Flutter/flutter_assets/ 64 | **/ios/Flutter/flutter_export_environment.sh 65 | **/ios/ServiceDefinitions.json 66 | **/ios/Runner/GeneratedPluginRegistrant.* 67 | 68 | # Web related 69 | lib/generated_plugin_registrant.dart 70 | 71 | # Exceptions to above rules. 72 | !**/ios/**/default.mode1v3 73 | !**/ios/**/default.mode2v3 74 | !**/ios/**/default.pbxuser 75 | !**/ios/**/default.perspectivev3 76 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 77 | -------------------------------------------------------------------------------- /panache_desktop/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: af07bb50faecbfe7d576113058c94cae0e21b91e 8 | channel: master 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /panache_desktop/README.md: -------------------------------------------------------------------------------- 1 | # panache_desktop 2 | 3 | Panache MacOS 4 | 5 | ```bash 6 | flutter run -d macos 7 | ``` -------------------------------------------------------------------------------- /panache_desktop/macos/.gitignore: -------------------------------------------------------------------------------- 1 | xcuserdata 2 | 3 | # Generated by flutter tooling as needed. 4 | Flutter/ephemeral/ 5 | # Created by CocoaPods for plugins. 6 | Pods/ 7 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "ephemeral/Flutter-Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import path_provider_fde 9 | import shared_preferences_fde 10 | 11 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 12 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 13 | SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) 14 | } 15 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/.app_filename: -------------------------------------------------------------------------------- 1 | Panache.app 2 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/.symlinks/flutter: -------------------------------------------------------------------------------- 1 | /Users/rxlabz/dev/tools/flutter/bin/cache/artifacts/engine -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/.symlinks/plugins/path_provider: -------------------------------------------------------------------------------- 1 | /Users/rxlabz/.pub-cache/hosted/pub.dartlang.org/path_provider-1.3.0 -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/.symlinks/plugins/path_provider_fde: -------------------------------------------------------------------------------- 1 | /Users/rxlabz/projects/Panache/dev/panache/desktop_plugins/path_provider_fde -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/.symlinks/plugins/shared_preferences: -------------------------------------------------------------------------------- 1 | /Users/rxlabz/.pub-cache/hosted/pub.dartlang.org/shared_preferences-0.5.3+4 -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/.symlinks/plugins/shared_preferences_fde: -------------------------------------------------------------------------------- 1 | /Users/rxlabz/projects/Panache/dev/panache/desktop_plugins/shared_preferences_fde -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/App: -------------------------------------------------------------------------------- 1 | Versions/Current/App -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Resources: -------------------------------------------------------------------------------- 1 | Versions/Current/Resources -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/App: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/App -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1.0 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/AssetManifest.json: -------------------------------------------------------------------------------- 1 | {"packages/panache_core/logo.png":["packages/panache_core/lib/logo.png"]} -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/FontManifest.json: -------------------------------------------------------------------------------- 1 | [{"fonts":[{"asset":"fonts/MaterialIcons-Regular.ttf"}],"family":"MaterialIcons"}] -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/fonts/MaterialIcons-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/fonts/MaterialIcons-Regular.ttf -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/isolate_snapshot_data: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/isolate_snapshot_data -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/kernel_blob.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/kernel_blob.bin -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/packages/panache_core/lib/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/packages/panache_core/lib/logo.png -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/packages/panache_core/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/packages/panache_core/logo.png -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/vm_snapshot_data: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/A/Resources/flutter_assets/vm_snapshot_data -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/App.framework/Versions/Current: -------------------------------------------------------------------------------- 1 | A -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/Flutter-Generated.xcconfig: -------------------------------------------------------------------------------- 1 | // This is a generated file; do not edit or check into version control. 2 | FLUTTER_ROOT=/Users/rxlabz/dev/tools/flutter 3 | FLUTTER_APPLICATION_PATH=/Users/rxlabz/projects/Panache/dev/panache/panache_desktop 4 | FLUTTER_TARGET=/Users/rxlabz/projects/Panache/dev/panache/panache_desktop/lib/main.dart 5 | FLUTTER_BUILD_DIR=build 6 | FLUTTER_FRAMEWORK_DIR=/Users/rxlabz/dev/tools/flutter/bin/cache/artifacts/engine/darwin-x64 7 | FLUTTER_BUILD_NAME=0.2.2 8 | FLUTTER_BUILD_NUMBER=0.2.2 9 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/FlutterMacOS: -------------------------------------------------------------------------------- 1 | Versions/Current/FlutterMacOS -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Headers: -------------------------------------------------------------------------------- 1 | Versions/Current/Headers -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Modules: -------------------------------------------------------------------------------- 1 | Versions/Current/Modules -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Resources: -------------------------------------------------------------------------------- 1 | Versions/Current/Resources -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/FlutterMacOS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/FlutterMacOS -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FLEDartProject.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #ifndef FLUTTER_FLEDARTPROJECT_H_ 6 | #define FLUTTER_FLEDARTPROJECT_H_ 7 | 8 | #import 9 | 10 | #include "FlutterMacros.h" 11 | 12 | /** 13 | * A set of Flutter and Dart assets used by a `FlutterEngine` to initialize execution. 14 | * 15 | * TODO(stuartmorgan): Align API with FlutterDartProject. 16 | */ 17 | FLUTTER_EXPORT 18 | @interface FLEDartProject : NSObject 19 | 20 | /** 21 | * Initializes a Flutter Dart project from a bundle. 22 | * 23 | * The bundle must either contain a flutter_assets resource directory, or set the Info.plist key 24 | * FLTAssetsPath to override that name (if you are doing a custom build using a different name). 25 | * 26 | * @param bundle The bundle containing the Flutter assets directory. If nil, the main bundle is 27 | * used. 28 | */ 29 | - (nonnull instancetype)initWithBundle:(nullable NSBundle*)bundle NS_DESIGNATED_INITIALIZER; 30 | 31 | /** 32 | * Switches to pass to the Flutter engine. See 33 | * https://github.com/flutter/engine/blob/master/shell/common/switches.h 34 | * for details. Not all switches will apply to embedding mode. 35 | * 36 | * Note: This property is likely to be removed in the future in favor of exposing specific switches 37 | * via their own APIs. 38 | */ 39 | @property(nullable) NSArray* engineSwitches; 40 | 41 | @end 42 | 43 | #endif // FLUTTER_FLEDARTPROJECT_H_ 44 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FLEOpenGLContextHandling.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import "FlutterMacros.h" 6 | 7 | /** 8 | * Protocol for views owned by FLEViewController to handle context changes, specifically relating to 9 | * OpenGL context changes. 10 | */ 11 | FLUTTER_EXPORT 12 | @protocol FLEOpenGLContextHandling 13 | 14 | /** 15 | * Sets the receiver as the current context object. 16 | */ 17 | - (void)makeCurrentContext; 18 | 19 | /** 20 | * Called when the display is updated. In an NSOpenGLView this is best handled via a flushBuffer 21 | * call. 22 | */ 23 | - (void)onPresent; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FLEReshapeListener.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import 6 | 7 | #import "FlutterMacros.h" 8 | 9 | /** 10 | * Protocol for listening to reshape events on this FlutterView. 11 | * Used to notify the underlying Flutter engine of the new screen dimensions. 12 | * Reflected from [NSOpenGLView.reshape]. 13 | */ 14 | FLUTTER_EXPORT 15 | @protocol FLEReshapeListener 16 | 17 | - (void)viewDidReshape:(nonnull NSOpenGLView*)view; 18 | 19 | @end 20 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FLEView.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import 6 | 7 | #import "FLEOpenGLContextHandling.h" 8 | #import "FLEReshapeListener.h" 9 | #import "FlutterMacros.h" 10 | 11 | /** 12 | * View capable of acting as a rendering target and input source for the Flutter 13 | * engine. 14 | */ 15 | FLUTTER_EXPORT 16 | @interface FLEView : NSOpenGLView 17 | 18 | /** 19 | * Listener for reshape events. See protocol description. 20 | */ 21 | @property(nonatomic, weak, nullable) IBOutlet id reshapeListener; 22 | 23 | @end 24 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FLEViewController.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import 6 | 7 | #import "FLEEngine.h" 8 | #import "FlutterMacros.h" 9 | #import "FlutterPluginRegistrarMacOS.h" 10 | 11 | typedef NS_ENUM(NSInteger, FlutterMouseTrackingMode) { 12 | // Hover events will never be sent to Flutter. 13 | FlutterMouseTrackingModeNone = 0, 14 | // Hover events will be sent to Flutter when the view is in the key window. 15 | FlutterMouseTrackingModeInKeyWindow, 16 | // Hover events will be sent to Flutter when the view is in the active app. 17 | FlutterMouseTrackingModeInActiveApp, 18 | // Hover events will be sent to Flutter regardless of window and app focus. 19 | FlutterMouseTrackingModeAlways, 20 | }; 21 | 22 | /** 23 | * Controls embedder plugins and communication with the underlying Flutter engine, managing a view 24 | * intended to handle key inputs and drawing protocols (see |view|). 25 | * 26 | * Can be launched headless (no managed view), at which point a Dart executable will be run on the 27 | * Flutter engine in non-interactive mode, or with a drawable Flutter canvas. 28 | */ 29 | FLUTTER_EXPORT 30 | @interface FLEViewController : NSViewController 31 | 32 | /** 33 | * The Flutter engine associated with this view controller. 34 | */ 35 | @property(nonatomic, nonnull, readonly) FLEEngine* engine; 36 | 37 | /** 38 | * The style of mouse tracking to use for the view. Defaults to 39 | * FlutterMouseTrackingModeInKeyWindow. 40 | */ 41 | @property(nonatomic) FlutterMouseTrackingMode mouseTrackingMode; 42 | 43 | /** 44 | * Initializes a controller that will run the given project. 45 | * 46 | * @param project The project to run in this view controller. If nil, a default `FLEDartProject` 47 | * will be used. 48 | */ 49 | - (nonnull instancetype)initWithProject:(nullable FLEDartProject*)project NS_DESIGNATED_INITIALIZER; 50 | 51 | - (nonnull instancetype)initWithNibName:(nullable NSString*)nibNameOrNil 52 | bundle:(nullable NSBundle*)nibBundleOrNil 53 | NS_DESIGNATED_INITIALIZER; 54 | - (nonnull instancetype)initWithCoder:(nonnull NSCoder*)nibNameOrNil NS_DESIGNATED_INITIALIZER; 55 | 56 | @end 57 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FlutterDartProject.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #ifndef FLUTTER_FLUTTERDARTPROJECT_H_ 6 | #define FLUTTER_FLUTTERDARTPROJECT_H_ 7 | 8 | #import 9 | 10 | #include "FlutterMacros.h" 11 | 12 | /** 13 | * A set of Flutter and Dart assets used by a `FlutterEngine` to initialize execution. 14 | * 15 | * TODO(stuartmorgan): Align API with FlutterDartProject, and combine. 16 | */ 17 | FLUTTER_EXPORT 18 | @interface FlutterDartProject : NSObject 19 | 20 | /** 21 | * Initializes a Flutter Dart project from a bundle. 22 | * 23 | * The bundle must either contain a flutter_assets resource directory, or set the Info.plist key 24 | * FLTAssetsPath to override that name (if you are doing a custom build using a different name). 25 | * 26 | * @param bundle The bundle containing the Flutter assets directory. If nil, the App framework 27 | * created by Flutter will be used. 28 | */ 29 | - (nonnull instancetype)initWithPrecompiledDartBundle:(nullable NSBundle*)bundle 30 | NS_DESIGNATED_INITIALIZER; 31 | 32 | /** 33 | * Switches to pass to the Flutter engine. See 34 | * https://github.com/flutter/engine/blob/master/shell/common/switches.h 35 | * for details. Not all switches will apply to embedding mode. Switches have not stability 36 | * guarantee, and are subject to change without notice. 37 | * 38 | * Note: This property WILL BE REMOVED in the future. If you use this property, please see 39 | * https://github.com/flutter/flutter/issue/38569. 40 | */ 41 | @property(nullable) NSArray* engineSwitches; 42 | 43 | @end 44 | 45 | #endif // FLUTTER_FLUTTERDARTPROJECT_H_ 46 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FlutterMacOS.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import "FlutterBinaryMessenger.h" 6 | #import "FlutterChannels.h" 7 | #import "FlutterCodecs.h" 8 | #import "FlutterDartProject.h" 9 | #import "FlutterEngine.h" 10 | #import "FlutterMacros.h" 11 | #import "FlutterPluginMacOS.h" 12 | #import "FlutterPluginRegistrarMacOS.h" 13 | #import "FlutterViewController.h" 14 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FlutterMacros.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #ifndef FLUTTER_FLUTTERMACROS_H_ 6 | #define FLUTTER_FLUTTERMACROS_H_ 7 | 8 | #if defined(FLUTTER_FRAMEWORK) 9 | 10 | #define FLUTTER_EXPORT __attribute__((visibility("default"))) 11 | 12 | #else // defined(FLUTTER_SDK) 13 | 14 | #define FLUTTER_EXPORT 15 | 16 | #endif // defined(FLUTTER_SDK) 17 | 18 | #ifndef NS_ASSUME_NONNULL_BEGIN 19 | #define NS_ASSUME_NONNULL_BEGIN _Pragma("clang assume_nonnull begin") 20 | #define NS_ASSUME_NONNULL_END _Pragma("clang assume_nonnull end") 21 | #endif // defined(NS_ASSUME_NONNULL_BEGIN) 22 | 23 | /** 24 | * Indicates that the API has been deprecated for the specified reason. Code 25 | * that uses the deprecated API will continue to work as before. However, the 26 | * API will soon become unavailable and users are encouraged to immediately take 27 | * the appropriate action mentioned in the deprecation message and the BREAKING 28 | * CHANGES section present in the Flutter.h umbrella header. 29 | */ 30 | #define FLUTTER_DEPRECATED(msg) __attribute__((__deprecated__(msg))) 31 | 32 | /** 33 | * Indicates that the previously deprecated API is now unavailable. Code that 34 | * uses the API will not work and the declaration of the API is only a stub 35 | * meant to display the given message detailing the actions for the user to take 36 | * immediately. 37 | */ 38 | #define FLUTTER_UNAVAILABLE(msg) __attribute__((__unavailable__(msg))) 39 | 40 | #endif // FLUTTER_FLUTTERMACROS_H_ 41 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FlutterPluginMacOS.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import 6 | 7 | #import "FlutterChannels.h" 8 | #import "FlutterCodecs.h" 9 | #import "FlutterMacros.h" 10 | 11 | // TODO: Merge this file and FlutterPluginRegistrarMacOS.h with the iOS FlutterPlugin.h, sharing 12 | // all but the platform-specific methods. 13 | 14 | @protocol FlutterPluginRegistrar; 15 | 16 | /** 17 | * Implemented by the platform side of a Flutter plugin. 18 | * 19 | * Defines a set of optional callback methods and a method to set up the plugin 20 | * and register it to be called by other application components. 21 | * 22 | * Currently the macOS version of FlutterPlugin has very limited functionality, but is expected to 23 | * expand over time to more closely match the functionality of the iOS FlutterPlugin. 24 | */ 25 | FLUTTER_EXPORT 26 | @protocol FlutterPlugin 27 | 28 | /** 29 | * Creates an instance of the plugin to register with |registrar| using the desired 30 | * FlutterPluginRegistrar methods. 31 | */ 32 | + (void)registerWithRegistrar:(nonnull id)registrar; 33 | 34 | @optional 35 | 36 | /** 37 | * Called when a message is sent from Flutter on a channel that a plugin instance has subscribed 38 | * to via -[FlutterPluginRegistrar addMethodCallDelegate:channel:]. 39 | * 40 | * The |result| callback must be called exactly once, with one of: 41 | * - FlutterMethodNotImplemented, if the method call is unknown. 42 | * - A FlutterError, if the method call was understood but there was a 43 | * problem handling it. 44 | * - Any other value (including nil) to indicate success. The value will 45 | * be returned to the Flutter caller, and must be serializable to JSON. 46 | */ 47 | - (void)handleMethodCall:(nonnull FlutterMethodCall*)call result:(nonnull FlutterResult)result; 48 | 49 | @end 50 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Headers/FlutterViewController.h: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Flutter Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style license that can be 3 | // found in the LICENSE file. 4 | 5 | #import 6 | 7 | #import "FlutterEngine.h" 8 | #import "FlutterMacros.h" 9 | #import "FlutterPluginRegistrarMacOS.h" 10 | 11 | /** 12 | * Values for the `mouseTrackingMode` property. 13 | */ 14 | typedef NS_ENUM(NSInteger, FlutterMouseTrackingMode) { 15 | // Hover events will never be sent to Flutter. 16 | FlutterMouseTrackingModeNone = 0, 17 | // Hover events will be sent to Flutter when the view is in the key window. 18 | FlutterMouseTrackingModeInKeyWindow, 19 | // Hover events will be sent to Flutter when the view is in the active app. 20 | FlutterMouseTrackingModeInActiveApp, 21 | // Hover events will be sent to Flutter regardless of window and app focus. 22 | FlutterMouseTrackingModeAlways, 23 | }; 24 | 25 | /** 26 | * Controls a view that displays Flutter content and manages input. 27 | */ 28 | FLUTTER_EXPORT 29 | @interface FlutterViewController : NSViewController 30 | 31 | /** 32 | * The Flutter engine associated with this view controller. 33 | */ 34 | @property(nonatomic, nonnull, readonly) FlutterEngine* engine; 35 | 36 | /** 37 | * The style of mouse tracking to use for the view. Defaults to 38 | * FlutterMouseTrackingModeInKeyWindow. 39 | */ 40 | @property(nonatomic) FlutterMouseTrackingMode mouseTrackingMode; 41 | 42 | /** 43 | * Initializes a controller that will run the given project. 44 | * 45 | * @param project The project to run in this view controller. If nil, a default `FlutterDartProject` 46 | * will be used. 47 | */ 48 | - (nonnull instancetype)initWithProject:(nullable FlutterDartProject*)project 49 | NS_DESIGNATED_INITIALIZER; 50 | 51 | - (nonnull instancetype)initWithNibName:(nullable NSString*)nibNameOrNil 52 | bundle:(nullable NSBundle*)nibBundleOrNil 53 | NS_DESIGNATED_INITIALIZER; 54 | - (nonnull instancetype)initWithCoder:(nonnull NSCoder*)nibNameOrNil NS_DESIGNATED_INITIALIZER; 55 | 56 | @end 57 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Modules/module.modulemap: -------------------------------------------------------------------------------- 1 | framework module FlutterMacOS { 2 | umbrella header "FlutterMacOS.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Resources/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | FlutterMacOS 9 | CFBundleIdentifier 10 | io.flutter.flutter-macos 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | FlutterMacOS 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1.0 21 | NSPrincipalClass 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Resources/icudtl.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/A/Resources/icudtl.dat -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/FlutterMacOS.framework/Versions/Current: -------------------------------------------------------------------------------- 1 | A -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/flutter_export_environment.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # This is a generated file; do not edit or check into version control. 3 | export "FLUTTER_ROOT=/Users/rxlabz/dev/tools/flutter" 4 | export "FLUTTER_APPLICATION_PATH=/Users/rxlabz/projects/Panache/dev/panache/panache_desktop" 5 | export "FLUTTER_TARGET=/Users/rxlabz/projects/Panache/dev/panache/panache_desktop/lib/main.dart" 6 | export "FLUTTER_BUILD_DIR=build" 7 | export "FLUTTER_FRAMEWORK_DIR=/Users/rxlabz/dev/tools/flutter/bin/cache/artifacts/engine/darwin-x64" 8 | export "FLUTTER_BUILD_NAME=0.2.2" 9 | export "FLUTTER_BUILD_NUMBER=0.2.2" 10 | -------------------------------------------------------------------------------- /panache_desktop/macos/Flutter/ephemeral/tripwire: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Flutter/ephemeral/tripwire -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Local Podspecs/FlutterMacOS.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "FlutterMacOS", 3 | "version": "1.0.0", 4 | "summary": "High-performance, high-fidelity cross-platform apps.", 5 | "description": "Flutter is Google's portable UI toolkit for building beautiful, natively-compiled applications for mobile, web, and desktop from a single codebase.", 6 | "homepage": "https://flutter.dev", 7 | "license": { 8 | "type": "MIT" 9 | }, 10 | "authors": { 11 | "Flutter Dev Team": "flutter-dev@googlegroups.com" 12 | }, 13 | "source": { 14 | "git": "https://github.com/flutter/engine", 15 | "tag": "1.0.0" 16 | }, 17 | "platforms": { 18 | "osx": "10.11" 19 | }, 20 | "vendored_frameworks": "FlutterMacOS.framework" 21 | } 22 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Local Podspecs/path_provider_fde.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "path_provider_fde", 3 | "version": "0.0.1", 4 | "summary": "A Flutter plugin for getting commonly used locations on the filesystem.", 5 | "description": "A temporary macOS implmentation of the path_provider plugin from flutter/plugins.", 6 | "homepage": "https://github.com/google/flutter-desktop-embedding/tree/master/plugins/flutter_plugins/path_provider_fde", 7 | "license": { 8 | "file": "../LICENSE" 9 | }, 10 | "authors": { 11 | "Flutter Desktop Embedding Developers": "flutter-desktop-embedding-dev@googlegroups.com" 12 | }, 13 | "source": { 14 | "path": "." 15 | }, 16 | "source_files": "Classes/**/*", 17 | "dependencies": { 18 | "FlutterMacOS": [ 19 | 20 | ] 21 | }, 22 | "platforms": { 23 | "osx": "10.11" 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Local Podspecs/shared_preferences_fde.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "shared_preferences_fde", 3 | "version": "0.0.1", 4 | "summary": "Flutter plugin for reading and writing simple key-value pairs.", 5 | "description": "A temporary macOS implmentation of the shared_preferences plugin from flutter/plugins.", 6 | "homepage": "https://github.com/google/flutter-desktop-embedding/tree/master/plugins/flutter_plugins/shared_preferences_fde", 7 | "license": { 8 | "file": "../LICENSE" 9 | }, 10 | "authors": { 11 | "Flutter Desktop Embedding Developers": "flutter-desktop-embedding-dev@googlegroups.com" 12 | }, 13 | "source": { 14 | "path": "." 15 | }, 16 | "source_files": "Classes/**/*", 17 | "dependencies": { 18 | "FlutterMacOS": [ 19 | 20 | ] 21 | }, 22 | "platforms": { 23 | "osx": "10.11" 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Pods.xcodeproj/xcuserdata/rxlabz.xcuserdatad/xcschemes/FlutterMacOS.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Pods.xcodeproj/xcuserdata/rxlabz.xcuserdatad/xcschemes/Pods-Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Pods.xcodeproj/xcuserdata/rxlabz.xcuserdatad/xcschemes/path_provider_fde.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Pods.xcodeproj/xcuserdata/rxlabz.xcuserdatad/xcschemes/shared_preferences_fde.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Pods.xcodeproj/xcuserdata/rxlabz.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | FlutterMacOS.xcscheme 8 | 9 | isShown 10 | 11 | 12 | Pods-Runner.xcscheme 13 | 14 | isShown 15 | 16 | 17 | path_provider_fde.xcscheme 18 | 19 | isShown 20 | 21 | 22 | shared_preferences_fde.xcscheme 23 | 24 | isShown 25 | 26 | 27 | 28 | SuppressBuildableAutocreation 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/FlutterMacOS/FlutterMacOS.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/FlutterMacOS 3 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64" 4 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 5 | PODS_BUILD_DIR = ${BUILD_DIR} 6 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_Runner : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_Runner 5 | @end 6 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double Pods_RunnerVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char Pods_RunnerVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde" "${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde/path_provider_fde.framework/Headers" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde/shared_preferences_fde.framework/Headers" 5 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' 6 | OTHER_LDFLAGS = $(inherited) -framework "FlutterMacOS" -framework "path_provider_fde" -framework "shared_preferences_fde" 7 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 8 | PODS_BUILD_DIR = ${BUILD_DIR} 9 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_Runner { 2 | umbrella header "Pods-Runner-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde" "${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde/path_provider_fde.framework/Headers" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde/shared_preferences_fde.framework/Headers" 5 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' 6 | OTHER_LDFLAGS = $(inherited) -framework "FlutterMacOS" -framework "path_provider_fde" -framework "shared_preferences_fde" 7 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 8 | PODS_BUILD_DIR = ${BUILD_DIR} 9 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde" "${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde/path_provider_fde.framework/Headers" "${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde/shared_preferences_fde.framework/Headers" 5 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' 6 | OTHER_LDFLAGS = $(inherited) -framework "FlutterMacOS" -framework "path_provider_fde" -framework "shared_preferences_fde" 7 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 8 | PODS_BUILD_DIR = ${BUILD_DIR} 9 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/path_provider_fde/path_provider_fde-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 0.0.1 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/path_provider_fde/path_provider_fde-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_path_provider_fde : NSObject 3 | @end 4 | @implementation PodsDummy_path_provider_fde 5 | @end 6 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/path_provider_fde/path_provider_fde-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/path_provider_fde/path_provider_fde-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double path_provider_fdeVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char path_provider_fdeVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/path_provider_fde/path_provider_fde.modulemap: -------------------------------------------------------------------------------- 1 | framework module path_provider_fde { 2 | umbrella header "path_provider_fde-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/path_provider_fde/path_provider_fde.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/path_provider_fde 3 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64" 4 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 5 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 6 | PODS_BUILD_DIR = ${BUILD_DIR} 7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 8 | PODS_ROOT = ${SRCROOT} 9 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/../Flutter/ephemeral/.symlinks/plugins/path_provider_fde/macos 10 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | SKIP_INSTALL = YES 12 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/shared_preferences_fde/shared_preferences_fde-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | ${PRODUCT_BUNDLE_IDENTIFIER} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 0.0.1 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/shared_preferences_fde/shared_preferences_fde-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_shared_preferences_fde : NSObject 3 | @end 4 | @implementation PodsDummy_shared_preferences_fde 5 | @end 6 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/shared_preferences_fde/shared_preferences_fde-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/shared_preferences_fde/shared_preferences_fde-umbrella.h: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #else 4 | #ifndef FOUNDATION_EXPORT 5 | #if defined(__cplusplus) 6 | #define FOUNDATION_EXPORT extern "C" 7 | #else 8 | #define FOUNDATION_EXPORT extern 9 | #endif 10 | #endif 11 | #endif 12 | 13 | 14 | FOUNDATION_EXPORT double shared_preferences_fdeVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char shared_preferences_fdeVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/shared_preferences_fde/shared_preferences_fde.modulemap: -------------------------------------------------------------------------------- 1 | framework module shared_preferences_fde { 2 | umbrella header "shared_preferences_fde-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /panache_desktop/macos/Pods/Target Support Files/shared_preferences_fde/shared_preferences_fde.xcconfig: -------------------------------------------------------------------------------- 1 | CODE_SIGN_IDENTITY = 2 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/shared_preferences_fde 3 | FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/../Flutter/ephemeral/.symlinks/flutter/darwin-x64" 4 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 5 | OTHER_SWIFT_FLAGS = $(inherited) -D COCOAPODS 6 | PODS_BUILD_DIR = ${BUILD_DIR} 7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 8 | PODS_ROOT = ${SRCROOT} 9 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/../Flutter/ephemeral/.symlinks/plugins/shared_preferences_fde/macos 10 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | SKIP_INSTALL = YES 12 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner.xcodeproj/xcuserdata/rxlabz.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | Flutter Assemble.xcscheme_^#shared#^_ 8 | 9 | orderHint 10 | 1 11 | 12 | Runner.xcscheme_^#shared#^_ 13 | 14 | orderHint 15 | 0 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner.xcworkspace/xcuserdata/rxlabz.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner.xcworkspace/xcuserdata/rxlabz.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // Copyright 2018 Google LLC 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); 4 | // you may not use this file except in compliance with the License. 5 | // You may obtain a copy of the License at 6 | // 7 | // http://www.apache.org/licenses/LICENSE-2.0 8 | // 9 | // Unless required by applicable law or agreed to in writing, software 10 | // distributed under the License is distributed on an "AS IS" BASIS, 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | // See the License for the specific language governing permissions and 13 | // limitations under the License. 14 | 15 | import Cocoa 16 | 17 | @NSApplicationMain 18 | class AppDelegate: NSObject, NSApplicationDelegate { 19 | @IBOutlet weak var window: NSWindow! 20 | @IBOutlet weak var applicationMenu: NSMenu! 21 | 22 | func applicationWillFinishLaunching(_ notification: Notification) { 23 | // Update UI elements to match the application name. 24 | // TODO: Move this logic to a Flutter framework application delegate. 25 | // See https://github.com/flutter/flutter/issues/32419. 26 | let appName = applicationName() 27 | window.title = appName 28 | for menuItem in applicationMenu.items { 29 | menuItem.title = menuItem.title.replacingOccurrences(of: "APP_NAME", with: appName) 30 | } 31 | } 32 | 33 | func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { 34 | return true 35 | } 36 | 37 | /** 38 | * Returns the name of the application as set in the Info.plist 39 | */ 40 | private func applicationName() -> String { 41 | var applicationName: String? = Bundle.main.object(forInfoDictionaryKey: "CFBundleDisplayName") 42 | as? String 43 | if applicationName == nil { 44 | applicationName = Bundle.main.object(forInfoDictionaryKey: "CFBundleName") as? String 45 | } 46 | return applicationName! 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "16x16", 5 | "idiom" : "mac", 6 | "filename" : "app_icon_16.png", 7 | "scale" : "1x" 8 | }, 9 | { 10 | "size" : "16x16", 11 | "idiom" : "mac", 12 | "filename" : "app_icon_32.png", 13 | "scale" : "2x" 14 | }, 15 | { 16 | "size" : "32x32", 17 | "idiom" : "mac", 18 | "filename" : "app_icon_32.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "32x32", 23 | "idiom" : "mac", 24 | "filename" : "app_icon_64.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "128x128", 29 | "idiom" : "mac", 30 | "filename" : "app_icon_128.png", 31 | "scale" : "1x" 32 | }, 33 | { 34 | "size" : "128x128", 35 | "idiom" : "mac", 36 | "filename" : "app_icon_256.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "256x256", 41 | "idiom" : "mac", 42 | "filename" : "app_icon_256.png", 43 | "scale" : "1x" 44 | }, 45 | { 46 | "size" : "256x256", 47 | "idiom" : "mac", 48 | "filename" : "app_icon_512.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "512x512", 53 | "idiom" : "mac", 54 | "filename" : "app_icon_512.png", 55 | "scale" : "1x" 56 | }, 57 | { 58 | "size" : "512x512", 59 | "idiom" : "mac", 60 | "filename" : "app_icon_1024.png", 61 | "scale" : "2x" 62 | } 63 | ], 64 | "info" : { 65 | "version" : 1, 66 | "author" : "xcode" 67 | } 68 | } -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_desktop/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Configs/AppInfo.xcconfig: -------------------------------------------------------------------------------- 1 | // Application-level settings for the Runner target. 2 | 3 | PRODUCT_NAME = Panache 4 | PRODUCT_BUNDLE_IDENTIFIER = bz.rxla.panache 5 | PRODUCT_COPYRIGHT = Copyright © 2019 RX Labz. All rights reserved. 6 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Configs/Warnings.xcconfig: -------------------------------------------------------------------------------- 1 | WARNING_CFLAGS = -Wall -Wconditional-uninitialized -Wnullable-to-nonnull-conversion -Wmissing-method-return-type -Woverlength-strings 2 | GCC_WARN_UNDECLARED_SELECTOR = YES 3 | CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY = YES 4 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE 5 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES 6 | CLANG_WARN_PRAGMA_PACK = YES 7 | CLANG_WARN_STRICT_PROTOTYPES = YES 8 | CLANG_WARN_COMMA = YES 9 | GCC_WARN_STRICT_SELECTOR_MATCH = YES 10 | CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES 11 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES 12 | GCC_WARN_SHADOW = YES 13 | CLANG_WARN_UNREACHABLE_CODE = YES 14 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/DebugProfile.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | com.apple.security.cs.allow-jit 8 | 9 | com.apple.security.network.server 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIconFile 10 | 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(FLUTTER_BUILD_NAME) 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSMinimumSystemVersion 24 | $(MACOSX_DEPLOYMENT_TARGET) 25 | NSHumanReadableCopyright 26 | $(PRODUCT_COPYRIGHT) 27 | NSMainNibFile 28 | MainMenu 29 | NSPrincipalClass 30 | NSApplication 31 | 32 | 33 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/MainFlutterWindow.swift: -------------------------------------------------------------------------------- 1 | // Copyright 2018 Google LLC 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); 4 | // you may not use this file except in compliance with the License. 5 | // You may obtain a copy of the License at 6 | // 7 | // http://www.apache.org/licenses/LICENSE-2.0 8 | // 9 | // Unless required by applicable law or agreed to in writing, software 10 | // distributed under the License is distributed on an "AS IS" BASIS, 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | // See the License for the specific language governing permissions and 13 | // limitations under the License. 14 | 15 | import Cocoa 16 | import FlutterMacOS 17 | 18 | class MainFlutterWindow: NSWindow { 19 | override func awakeFromNib() { 20 | let flutterViewController = FlutterViewController.init() 21 | let windowFrame = self.frame 22 | self.contentViewController = flutterViewController 23 | self.setFrame(windowFrame, display: true) 24 | 25 | RegisterGeneratedPlugins(registry: flutterViewController) 26 | 27 | super.awakeFromNib() 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /panache_desktop/macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /panache_desktop/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: panache_desktop 2 | description: panache on desktop 3 | 4 | version: 0.2.2 5 | author: Erick Ghaumez 6 | homepage: https://github.com/rxlabz/panache 7 | 8 | dependencies: 9 | flutter: 10 | sdk: flutter 11 | 12 | scoped_model: ^1.0.1 13 | string_scanner: any 14 | 15 | shared_preferences: ^0.5.3 16 | shared_preferences_fde: 17 | path: ../desktop_plugins/shared_preferences_fde 18 | 19 | path_provider: ^1.3.0 20 | path_provider_fde: 21 | path: ../desktop_plugins/path_provider_fde 22 | 23 | panache_core: 24 | path: ../panache_core 25 | panache_ui: 26 | path: ../panache_ui 27 | panache_services: 28 | path: ../panache_services 29 | 30 | dev_dependencies: 31 | flutter_test: 32 | sdk: flutter 33 | mockito: any 34 | 35 | flutter: 36 | uses-material-design: true 37 | assets: 38 | - packages/panache_core/logo.png 39 | -------------------------------------------------------------------------------- /panache_desktop/test/widget_test.dart: -------------------------------------------------------------------------------- 1 | // This is a basic Flutter widget test. 2 | // 3 | // To perform an interaction with a widget in your test, use the WidgetTester 4 | // utility that Flutter provides. For example, you can send tap and scroll 5 | // gestures. You can also use WidgetTester to find child widgets in the widget 6 | // tree, read text, and verify that the values of widget properties are correct. 7 | 8 | import 'package:flutter/material.dart'; 9 | import 'package:flutter_test/flutter_test.dart'; 10 | 11 | import 'package:panache_desktop/main.dart'; 12 | 13 | void main() { 14 | testWidgets('Counter increments smoke test', (WidgetTester tester) async { 15 | /*// Build our app and trigger a frame. 16 | await tester.pumpWidget(MyApp()); 17 | 18 | // Verify that our counter starts at 0. 19 | expect(find.text('0'), findsOneWidget); 20 | expect(find.text('1'), findsNothing); 21 | 22 | // Tap the '+' icon and trigger a frame. 23 | await tester.tap(find.byIcon(Icons.add)); 24 | await tester.pump(); 25 | 26 | // Verify that our counter has incremented. 27 | expect(find.text('0'), findsNothing); 28 | expect(find.text('1'), findsOneWidget);*/ 29 | }); 30 | } 31 | -------------------------------------------------------------------------------- /panache_mobile/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: d51fd86cdb486192e187ccdf6f02cb2a38273d8d 8 | channel: dev 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /panache_mobile/README.md: -------------------------------------------------------------------------------- 1 | # Panache aka Flutterial 2 | 3 | A [Flutter](https://flutter.io) [Material Theme](https://docs.flutter.io/flutter/material/ThemeData-class.html) editor. 4 | 5 | Panache helps you to create beautiful [Material](http://material.io) themes for your Flutter applications. 6 | Customize components colors and shape, and export the generated theme.dart to your Google drive. 7 | 8 | ## Google drive 9 | 10 | to configure Google signin and Google drive : 11 | 12 | - https://pub.dartlang.org/packages/google_sign_in 13 | - https://pub.dartlang.org/packages/googleapis 14 | 15 | ### [x] iOS 16 | 17 | 1. Create a [Firebase project](https://firebase.google.com) 18 | 2. Add an iOS application 19 | 3. Download the GoogleService-info.plist and add it to your xcode project /Runner 20 | 4. In the info.plist, add the REVERSED_CLIENT_ID ( from GoogleService-info.plist ) 21 | 5. Run 22 | 23 | ### [x] Android 24 | 25 | 1. Create a [Firebase project](https://firebase.google.com) 26 | 2. Add an Android application 27 | 3. Enable OAuth for Drive API => https://console.developers.google.com/ 28 | 4. Run 29 | 30 | 31 | ## screenshots 32 | 33 | ![home](../docs/assets/home.png) 34 | 35 | ![screenshot](../docs/assets/screenshot.png) 36 | 37 | ![screenshot2](../docs/assets/screenshot2.png) 38 | 39 | ![screenshot3](../docs/assets/screenshot3.png) 40 | 41 | ![screenshot4](../docs/assets/screenshot4.png) 42 | 43 | ## Todo 44 | 45 | - [x] Theme editor / live app preview 46 | - [x] Dart 2.1 47 | - [x] Flutter 1.0 48 | - [ ] new Material Theme properties 49 | - [x] ButtonTheme 50 | - [x] ChipTheme 51 | - [x] TabBarTheme 52 | - [x] SliderTheme 53 | - [x] IconTheme 54 | - [x] DialogTheme 55 | - [x] InputDecorationTheme 56 | - [ ] [ColorScheme](https://github.com/rxlabz/color_scheme) 57 | - [x] Code preview 58 | - [x] Export to file 59 | - [x] Save 60 | - [x] Export to Google drive 61 | - [ ] material colors shades 62 | - [ ] colors opacity 63 | - more style options controls 64 | - [ ] BorderSide 65 | - [ ] BorderRadius 66 | - [x] typography options text styles : letter spacing, decoration... 67 | - [ ] Examples 68 | - [x] mobile version 69 | - [ ] desktop version 70 | - [ ] user preferences : 71 | - theme editor + preview last state 72 | - [ ] custom colorSwatch 73 | - [ ] platform selection 74 | - [ ] multiple fonts 75 | - ... 76 | 77 | ## Getting Started 78 | 79 | For help getting started with Flutter, view our online 80 | [documentation](http://flutter.io/). 81 | -------------------------------------------------------------------------------- /panache_mobile/android/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/android/.gitignore -------------------------------------------------------------------------------- /panache_mobile/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '1' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '1.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 26 | 27 | def keystoreProperties = new Properties() 28 | def keystorePropertiesFile = rootProject.file('key.properties') 29 | if (keystorePropertiesFile.exists()) { 30 | keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) 31 | } 32 | 33 | android { 34 | compileSdkVersion 27 35 | 36 | lintOptions { 37 | disable 'InvalidPackage' 38 | } 39 | 40 | defaultConfig { 41 | applicationId "bz.rxla.panache" 42 | minSdkVersion 16 43 | targetSdkVersion 27 44 | versionCode flutterVersionCode.toInteger() 45 | versionName flutterVersionName 46 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 47 | } 48 | 49 | signingConfigs { 50 | release { 51 | keyAlias keystoreProperties['keyAlias'] 52 | keyPassword keystoreProperties['keyPassword'] 53 | storeFile file(keystoreProperties['storeFile']) 54 | storePassword keystoreProperties['storePassword'] 55 | } 56 | } 57 | buildTypes { 58 | release { 59 | signingConfig signingConfigs.release 60 | } 61 | } 62 | } 63 | 64 | flutter { 65 | source '../..' 66 | } 67 | 68 | dependencies { 69 | testImplementation 'junit:junit:4.12' 70 | androidTestImplementation 'com.android.support.test:runner:1.0.2' 71 | androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' 72 | } 73 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 10 | 17 | 18 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 33 | 34 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/java/bz/rxla/panache/MainActivity.java: -------------------------------------------------------------------------------- 1 | package bz.rxla.panache; 2 | 3 | import android.os.Bundle; 4 | import io.flutter.app.FlutterActivity; 5 | import io.flutter.plugins.GeneratedPluginRegistrant; 6 | 7 | public class MainActivity extends FlutterActivity { 8 | @Override 9 | protected void onCreate(Bundle savedInstanceState) { 10 | super.onCreate(savedInstanceState); 11 | GeneratedPluginRegistrant.registerWith(this); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/java/com/example/flutterial/MainActivity.java: -------------------------------------------------------------------------------- 1 | package bz.rxla.panache; 2 | 3 | import android.os.Bundle; 4 | import io.flutter.app.FlutterActivity; 5 | import io.flutter.plugins.GeneratedPluginRegistrant; 6 | 7 | public class MainActivity extends FlutterActivity { 8 | @Override 9 | protected void onCreate(Bundle savedInstanceState) { 10 | super.onCreate(savedInstanceState); 11 | GeneratedPluginRegistrant.registerWith(this); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /panache_mobile/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | -------------------------------------------------------------------------------- /panache_mobile/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /panache_mobile/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | repositories { 3 | google() 4 | jcenter() 5 | } 6 | 7 | dependencies { 8 | classpath 'com.android.tools.build:gradle:3.2.1' 9 | } 10 | } 11 | 12 | allprojects { 13 | repositories { 14 | google() 15 | jcenter() 16 | } 17 | } 18 | 19 | rootProject.buildDir = '../build' 20 | subprojects { 21 | project.buildDir = "${rootProject.buildDir}/${project.name}" 22 | } 23 | subprojects { 24 | project.evaluationDependsOn(':app') 25 | } 26 | 27 | task clean(type: Delete) { 28 | delete rootProject.buildDir 29 | } 30 | -------------------------------------------------------------------------------- /panache_mobile/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | -------------------------------------------------------------------------------- /panache_mobile/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip 6 | -------------------------------------------------------------------------------- /panache_mobile/android/key.properties: -------------------------------------------------------------------------------- 1 | storePassword=RXL4bz#0407 2 | keyPassword=RXL4bz#0407 3 | keyAlias=key 4 | storeFile=/Users/rxlabz/projects/Panache/dev/017/key.jks -------------------------------------------------------------------------------- /panache_mobile/android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | 3 | def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() 4 | 5 | def plugins = new Properties() 6 | def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') 7 | if (pluginsFile.exists()) { 8 | pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } 9 | } 10 | 11 | plugins.each { name, path -> 12 | def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() 13 | include ":$name" 14 | project(":$name").projectDir = pluginDirectory 15 | } 16 | -------------------------------------------------------------------------------- /panache_mobile/assets/google-drive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/assets/google-drive.png -------------------------------------------------------------------------------- /panache_mobile/assets/google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/assets/google.png -------------------------------------------------------------------------------- /panache_mobile/assets/theme.json: -------------------------------------------------------------------------------- 1 | { 2 | "platform":"ios", 3 | "isDark":0, 4 | "primaryColor":"yellow", 5 | "accentColor":"cyan", 6 | "scaffoldBackgroundColor":"purple", 7 | "buttonColor":"green", 8 | "dividerColor":"green", 9 | "canvasColor":"lime", 10 | "cardColor":"orange", 11 | "disabledColor":"yellow", 12 | "backgroundColor":"deepOrange", 13 | "highlightColor":"amber", 14 | "splashColor":"pink", 15 | "dialogBackgroundColor":"pink", 16 | "hintColor":"green", 17 | "errorColor":"deepPurple", 18 | "indicatorColor":"teal", 19 | "selectedRowColor":"teal", 20 | "unselectedWidgetColor":"blueGrey", 21 | "secondaryHeaderColor":"red", 22 | "textSelectionColor":"lightGreen", 23 | "textSelectionHandleColor":"lightGreen" 24 | } -------------------------------------------------------------------------------- /panache_mobile/ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 8.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /panache_mobile/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /panache_mobile/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" 2 | #include "Generated.xcconfig" 3 | -------------------------------------------------------------------------------- /panache_mobile/ios/Flutter/flutter_export_environment.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # This is a generated file; do not edit or check into version control. 3 | export "FLUTTER_ROOT=/Users/rxlabz/dev/tools/flutter" 4 | export "FLUTTER_APPLICATION_PATH=/Users/rxlabz/dev/projects/panache/dev/panache/panache_mobile" 5 | export "FLUTTER_TARGET=lib/main.dart" 6 | export "FLUTTER_BUILD_DIR=build" 7 | export "SYMROOT=${SOURCE_ROOT}/../build/ios" 8 | export "FLUTTER_FRAMEWORK_DIR=/Users/rxlabz/dev/tools/flutter/bin/cache/artifacts/engine/ios" 9 | export "FLUTTER_BUILD_NAME=0.2.2" 10 | export "FLUTTER_BUILD_NUMBER=0.2.2" 11 | -------------------------------------------------------------------------------- /panache_mobile/ios/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment this line to define a global platform for your project 2 | platform :ios, '9.0' 3 | 4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency. 5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true' 6 | 7 | project 'Runner', { 8 | 'Debug' => :debug, 9 | 'Profile' => :release, 10 | 'Release' => :release, 11 | } 12 | 13 | def parse_KV_file(file, separator='=') 14 | file_abs_path = File.expand_path(file) 15 | if !File.exists? file_abs_path 16 | return []; 17 | end 18 | pods_ary = [] 19 | skip_line_start_symbols = ["#", "/"] 20 | File.foreach(file_abs_path) { |line| 21 | next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ } 22 | plugin = line.split(pattern=separator) 23 | if plugin.length == 2 24 | podname = plugin[0].strip() 25 | path = plugin[1].strip() 26 | podpath = File.expand_path("#{path}", file_abs_path) 27 | pods_ary.push({:name => podname, :path => podpath}); 28 | else 29 | puts "Invalid plugin specification: #{line}" 30 | end 31 | } 32 | return pods_ary 33 | end 34 | 35 | target 'Runner' do 36 | # Prepare symlinks folder. We use symlinks to avoid having Podfile.lock 37 | # referring to absolute paths on developers' machines. 38 | system('rm -rf .symlinks') 39 | system('mkdir -p .symlinks/plugins') 40 | 41 | # Flutter Pods 42 | generated_xcode_build_settings = parse_KV_file('./Flutter/Generated.xcconfig') 43 | if generated_xcode_build_settings.empty? 44 | puts "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter packages get is executed first." 45 | end 46 | generated_xcode_build_settings.map { |p| 47 | if p[:name] == 'FLUTTER_FRAMEWORK_DIR' 48 | symlink = File.join('.symlinks', 'flutter') 49 | File.symlink(File.dirname(p[:path]), symlink) 50 | pod 'Flutter', :path => File.join(symlink, File.basename(p[:path])) 51 | end 52 | } 53 | 54 | # Plugin Pods 55 | plugin_pods = parse_KV_file('../.flutter-plugins') 56 | plugin_pods.map { |p| 57 | symlink = File.join('.symlinks', 'plugins', p[:name]) 58 | File.symlink(p[:path], symlink) 59 | pod p[:name], :path => File.join(symlink, 'ios') 60 | } 61 | end 62 | 63 | post_install do |installer| 64 | installer.pods_project.targets.each do |target| 65 | target.build_configurations.each do |config| 66 | config.build_settings['ENABLE_BITCODE'] = 'NO' 67 | end 68 | end 69 | end 70 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | BuildSystemType 6 | Original 7 | 8 | 9 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/AppDelegate.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface AppDelegate : FlutterAppDelegate 5 | 6 | @end 7 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/AppDelegate.m: -------------------------------------------------------------------------------- 1 | #include "AppDelegate.h" 2 | #include "GeneratedPluginRegistrant.h" 3 | 4 | @implementation AppDelegate 5 | 6 | - (BOOL)application:(UIApplication *)application 7 | didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { 8 | [GeneratedPluginRegistrant registerWithRegistry:self]; 9 | // Override point for customization after application launch. 10 | return [super application:application didFinishLaunchingWithOptions:launchOptions]; 11 | } 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon1024.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20@2x-1.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon20@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29-1.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29@2x-1.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon29@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40@2x-1.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon40@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon60@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon60@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon76.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon76@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon83@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/AppIcon.appiconset/icon83@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleURLTypes 6 | 7 | 8 | CFBundleTypeRole 9 | Editor 10 | CFBundleURLSchemes 11 | 12 | com.googleusercontent.apps.1061683969655-8ic5eje41m81lvql1hs610595gljljp5 13 | 14 | 15 | 16 | CFBundleDevelopmentRegion 17 | en 18 | CFBundleDisplayName 19 | Panache 20 | CFBundleExecutable 21 | $(EXECUTABLE_NAME) 22 | CFBundleIdentifier 23 | $(PRODUCT_BUNDLE_IDENTIFIER) 24 | CFBundleInfoDictionaryVersion 25 | 6.0 26 | CFBundleName 27 | flutterial 28 | CFBundlePackageType 29 | APPL 30 | CFBundleShortVersionString 31 | $(FLUTTER_BUILD_NAME) 32 | CFBundleSignature 33 | ???? 34 | CFBundleVersion 35 | $(FLUTTER_BUILD_NUMBER) 36 | LSRequiresIPhoneOS 37 | 38 | UILaunchStoryboardName 39 | LaunchScreen 40 | UIMainStoryboardFile 41 | Main 42 | UISupportedInterfaceOrientations 43 | 44 | UIInterfaceOrientationPortrait 45 | UIInterfaceOrientationLandscapeLeft 46 | UIInterfaceOrientationLandscapeRight 47 | 48 | UISupportedInterfaceOrientations~ipad 49 | 50 | UIInterfaceOrientationPortrait 51 | UIInterfaceOrientationLandscapeLeft 52 | UIInterfaceOrientationLandscapeRight 53 | 54 | UIViewControllerBasedStatusBarAppearance 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /panache_mobile/ios/Runner/main.m: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | #import "AppDelegate.h" 4 | 5 | int main(int argc, char* argv[]) { 6 | @autoreleasepool { 7 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /panache_mobile/lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | 3 | import 'package:flutter/material.dart'; 4 | import 'package:flutter/widgets.dart'; 5 | import 'package:google_sign_in/google_sign_in.dart'; 6 | import 'package:panache_core/panache_core.dart'; 7 | import 'package:panache_services/panache_services.dart'; 8 | import 'package:path_provider/path_provider.dart'; 9 | import 'package:scoped_model/scoped_model.dart'; 10 | 11 | import 'package:panache_ui/panache_ui.dart'; 12 | 13 | GoogleSignIn _googleSignIn = GoogleSignIn( 14 | scopes: ['email', 'https://www.googleapis.com/auth/drive.file'], 15 | ); 16 | 17 | void main() async { 18 | WidgetsFlutterBinding.ensureInitialized(); 19 | final localData = LocalData(); 20 | await localData.init(); 21 | final dir = await getApplicationDocumentsDirectory(); 22 | 23 | final themeModel = ThemeModel( 24 | localData: localData, 25 | service: IOThemeService( 26 | themeExporter: exportTheme, 27 | dirProvider: getApplicationDocumentsDirectory, 28 | ), 29 | screenService: LocalScreenshotService(dir)); 30 | 31 | runApp(PanacheApp(themeModel: themeModel)); 32 | } 33 | 34 | class PanacheApp extends StatelessWidget { 35 | final ThemeModel themeModel; 36 | 37 | const PanacheApp({Key key, @required this.themeModel}) : super(key: key); 38 | 39 | @override 40 | Widget build(BuildContext context) { 41 | final theme = Theme.of(context); 42 | return ScopedModel( 43 | model: themeModel, 44 | child: MaterialApp( 45 | debugShowCheckedModeBanner: false, 46 | theme: buildAppTheme(theme, panachePrimarySwatch), 47 | home: LaunchScreen(model: themeModel), 48 | routes: { 49 | '/home': (context) => LaunchScreen(model: themeModel), 50 | '/editor': (context) => PanacheEditorScreen(), 51 | }, 52 | ), 53 | ); 54 | } 55 | } 56 | 57 | exportTheme(String code, String filename) async { 58 | var dir = await getApplicationDocumentsDirectory(); 59 | final themeFile = File('${dir.path}/themes/$filename.dart'); 60 | //print('exportTheme... ${themeFile.path}'); 61 | themeFile.createSync(recursive: true); 62 | themeFile.writeAsStringSync(code); 63 | } 64 | -------------------------------------------------------------------------------- /panache_mobile/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | import Foundation 5 | import FlutterMacOS 6 | 7 | 8 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 9 | } 10 | -------------------------------------------------------------------------------- /panache_mobile/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: panache 2 | description: Flutter Material Theme editor 3 | version: 0.2.2 4 | author: Erick Ghaumez 5 | homepage: https://github.com/rxlabz/panache 6 | 7 | dependencies: 8 | flutter: 9 | sdk: flutter 10 | 11 | scoped_model: ^1.0.1 12 | string_scanner: any 13 | google_sign_in: ^3.2.4 14 | googleapis: ^0.52.0+1 15 | shared_preferences: ^0.5.3 16 | 17 | panache_core: 18 | path: ../panache_core 19 | panache_ui: 20 | path: ../panache_ui 21 | panache_services: 22 | path: ../panache_services 23 | 24 | dev_dependencies: 25 | flutter_test: 26 | sdk: flutter 27 | mockito: any 28 | 29 | flutter: 30 | uses-material-design: true 31 | assets: 32 | - assets/google.png 33 | - assets/google-drive.png 34 | - packages/panache_core/logo.png 35 | -------------------------------------------------------------------------------- /panache_mobile/test/widget_test.dart: -------------------------------------------------------------------------------- 1 | // This is a basic Flutter widget test. 2 | // 3 | // To perform an interaction with a widget in your test, use the WidgetTester 4 | // utility that Flutter provides. For example, you can send tap and scroll 5 | // gestures. You can also use WidgetTester to find child widgets in the widget 6 | // tree, read text, and verify that the values of widget properties are correct. 7 | 8 | import 'package:flutter/material.dart'; 9 | import 'package:flutter_test/flutter_test.dart'; 10 | import 'package:panache/main.dart'; 11 | 12 | void main() { 13 | testWidgets('Counter increments smoke test', (WidgetTester tester) async {}); 14 | } 15 | -------------------------------------------------------------------------------- /panache_services/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 1363528eeed0302ef5a3d372cc81514d6960e722 8 | channel: master 9 | 10 | project_type: package 11 | -------------------------------------------------------------------------------- /panache_services/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## [0.0.1] - TODO: Add release date. 2 | 3 | * TODO: Describe initial release. 4 | -------------------------------------------------------------------------------- /panache_services/LICENSE: -------------------------------------------------------------------------------- 1 | TODO: Add your license here. 2 | -------------------------------------------------------------------------------- /panache_services/README.md: -------------------------------------------------------------------------------- 1 | # panache_services 2 | 3 | Panache mobile & desktop services 4 | 5 | ## Getting Started 6 | 7 | This project is a starting point for a Dart 8 | [package](https://flutter.dev/developing-packages/), 9 | a library module containing code that can be shared easily across 10 | multiple Flutter or Dart projects. 11 | 12 | For help getting started with Flutter, view our 13 | [online documentation](https://flutter.dev/docs), which offers tutorials, 14 | samples, guidance on mobile development, and a full API reference. 15 | -------------------------------------------------------------------------------- /panache_services/lib/panache_services.dart: -------------------------------------------------------------------------------- 1 | export 'src/services/local_data.dart'; 2 | export 'src/services/http_client.dart'; 3 | export 'src/services/screenshot_service.dart'; 4 | export 'src/services/io_theme_service.dart'; 5 | -------------------------------------------------------------------------------- /panache_services/lib/src/services/google_mobile_service.dart: -------------------------------------------------------------------------------- 1 | import 'package:panache_core/panache_core.dart'; 2 | 3 | class MobileUserService implements UserService { 4 | CloudService _cloudService; 5 | 6 | @override 7 | Future exportTheme(String content) async { 8 | bool authenticated = await _cloudService.authenticated; 9 | if (!authenticated) authenticated = await _cloudService.login(); 10 | 11 | if (!authenticated) return false; 12 | final result = await _cloudService.save(content); 13 | print('ThemeModel.exportThemeToDrive... $result'); 14 | return result.originalFilename ?? result.name; 15 | } 16 | 17 | @override 18 | Future login() async { 19 | final result = await _cloudService.login(); 20 | return result; 21 | } 22 | 23 | @override 24 | void logout() async { 25 | await _cloudService.logout(); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /panache_services/lib/src/services/http_client.dart: -------------------------------------------------------------------------------- 1 | import 'package:http/http.dart'; 2 | import 'package:http/io_client.dart'; 3 | 4 | class GoogleHttpClient extends IOClient { 5 | Map _headers; 6 | 7 | GoogleHttpClient(this._headers) : super(); 8 | 9 | @override 10 | Future send(BaseRequest request) => 11 | super.send(request..headers.addAll(_headers)); 12 | 13 | @override 14 | Future head(Object url, {Map headers}) => 15 | super.head(url, headers: headers..addAll(_headers)); 16 | } 17 | -------------------------------------------------------------------------------- /panache_services/lib/src/services/local_data.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:shared_preferences/shared_preferences.dart'; 4 | 5 | import 'package:panache_core/panache_core.dart'; 6 | 7 | const _themeKey = 'themes'; 8 | const _panelsKey = 'panelsState'; 9 | const _positionKey = 'scrollPosition'; 10 | 11 | /// local persistence 12 | class LocalData implements LocalStorage { 13 | // persistence destination 14 | SharedPreferences _prefs; 15 | 16 | /// synchronously loads local themes 17 | List get themes => 18 | _prefs 19 | .getStringList(_themeKey) 20 | ?.map(_themeDataFromJson) 21 | ?.toList() ?? 22 | []; 23 | 24 | /// loads ( mobile layout) 25 | Map get panelStates { 26 | final states = _prefs.getString(_panelsKey); 27 | 28 | if (states == null) return defaultPanelStates; 29 | return json.decode(states); 30 | } 31 | 32 | /// get the last scroll position ( mobile layout) 33 | double get scrollPosition => _prefs.getDouble(_positionKey); 34 | 35 | /// clear local themes list 36 | PanacheTheme _themeDataFromJson(String data) => PanacheTheme.fromJson(data); 37 | 38 | /// initialisation du stockage 39 | init() async => _prefs = await SharedPreferences.getInstance(); 40 | 41 | /// save the new local themes list 42 | void updateThemeList(List themes) => _prefs.setStringList( 43 | _themeKey, 44 | themes.map((theme) => theme.toJson()).toList(growable: false), 45 | ); 46 | 47 | /// remove the local theme list 48 | void clear() => _prefs.remove(_themeKey); 49 | 50 | /// delete a local theme 51 | void deleteTheme(PanacheTheme theme) { 52 | updateThemeList(themes.where((t) => t.id != theme.id).toList()); 53 | } 54 | 55 | /// saves panels states and editor scrollposition ( mobile layout ) 56 | void saveEditorState(Map panelStates, double pixels) { 57 | _prefs.setString(_panelsKey, json.encode(panelStates)); 58 | saveScrollPosition(pixels); 59 | } 60 | 61 | /// saves editor scrollposition ( mobile layout ) 62 | void saveScrollPosition(double pixels) { 63 | _prefs.setDouble(_positionKey, pixels); 64 | } 65 | } 66 | -------------------------------------------------------------------------------- /panache_services/lib/src/services/screenshot_service.dart: -------------------------------------------------------------------------------- 1 | import 'dart:io'; 2 | import 'dart:typed_data'; 3 | import 'package:panache_core/panache_core.dart'; 4 | 5 | class LocalScreenshotService extends ScreenshotService { 6 | final Directory dir; 7 | 8 | LocalScreenshotService(this.dir); 9 | 10 | @override 11 | void capture(String filename, Uint8List pngBytes) async { 12 | final screenshotName = '$filename.png'; 13 | final screenshotFile = File('${dir.path}/themes/$screenshotName'); 14 | await screenshotFile.create(recursive: true); 15 | await screenshotFile.writeAsBytes(pngBytes); 16 | print('ThemeService.screenshot => $screenshotFile'); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /panache_services/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: panache_services 2 | description: Panache mobile & desktop services 3 | version: 0.0.1 4 | author: 5 | homepage: 6 | 7 | environment: 8 | sdk: ">=2.1.0 <3.0.0" 9 | 10 | dependencies: 11 | flutter: 12 | sdk: flutter 13 | 14 | dev_dependencies: 15 | flutter_test: 16 | sdk: flutter 17 | 18 | http: ^0.12.0 19 | 20 | shared_preferences: ^0.5.3 21 | shared_preferences_fde: 22 | path: ../desktop_plugins/shared_preferences_fde 23 | 24 | panache_core: 25 | path: ../panache_core 26 | -------------------------------------------------------------------------------- /panache_services/test/panache_services_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_test/flutter_test.dart'; 2 | 3 | import 'package:panache_services/panache_services.dart'; 4 | 5 | void main() { 6 | test('adds one to input values', () {}); 7 | } 8 | -------------------------------------------------------------------------------- /panache_ui/.gitignore: -------------------------------------------------------------------------------- 1 | # Miscellaneous 2 | *.class 3 | *.log 4 | *.pyc 5 | *.swp 6 | .DS_Store 7 | .atom/ 8 | .buildlog/ 9 | .history 10 | .svn/ 11 | 12 | # IntelliJ related 13 | *.iml 14 | *.ipr 15 | *.iws 16 | .idea/ 17 | 18 | # The .vscode folder contains launch configuration and tasks you configure in 19 | # VS Code which you may wish to be included in version control, so this line 20 | # is commented out by default. 21 | #.vscode/ 22 | 23 | # Flutter/Dart/Pub related 24 | **/doc/api/ 25 | .dart_tool/ 26 | .flutter-plugins 27 | .packages 28 | .pub-cache/ 29 | .pub/ 30 | build/ 31 | 32 | # Android related 33 | **/android/**/gradle-wrapper.jar 34 | **/android/.gradle 35 | **/android/captures/ 36 | **/android/gradlew 37 | **/android/gradlew.bat 38 | **/android/local.properties 39 | **/android/**/GeneratedPluginRegistrant.java 40 | 41 | # iOS/XCode related 42 | **/ios/**/*.mode1v3 43 | **/ios/**/*.mode2v3 44 | **/ios/**/*.moved-aside 45 | **/ios/**/*.pbxuser 46 | **/ios/**/*.perspectivev3 47 | **/ios/**/*sync/ 48 | **/ios/**/.sconsign.dblite 49 | **/ios/**/.tags* 50 | **/ios/**/.vagrant/ 51 | **/ios/**/DerivedData/ 52 | **/ios/**/Icon? 53 | **/ios/**/Pods/ 54 | **/ios/**/.symlinks/ 55 | **/ios/**/profile 56 | **/ios/**/xcuserdata 57 | **/ios/.generated/ 58 | **/ios/Flutter/App.framework 59 | **/ios/Flutter/Flutter.framework 60 | **/ios/Flutter/Generated.xcconfig 61 | **/ios/Flutter/app.flx 62 | **/ios/Flutter/app.zip 63 | **/ios/Flutter/flutter_assets/ 64 | **/ios/Flutter/flutter_export_environment.sh 65 | **/ios/ServiceDefinitions.json 66 | **/ios/Runner/GeneratedPluginRegistrant.* 67 | 68 | # Exceptions to above rules. 69 | !**/ios/**/default.mode1v3 70 | !**/ios/**/default.mode2v3 71 | !**/ios/**/default.pbxuser 72 | !**/ios/**/default.perspectivev3 73 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages 74 | -------------------------------------------------------------------------------- /panache_ui/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: af07bb50faecbfe7d576113058c94cae0e21b91e 8 | channel: master 9 | 10 | project_type: package 11 | -------------------------------------------------------------------------------- /panache_ui/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## [0.0.1] - TODO: Add release date. 2 | 3 | * TODO: Describe initial release. 4 | -------------------------------------------------------------------------------- /panache_ui/LICENSE: -------------------------------------------------------------------------------- 1 | TODO: Add your license here. 2 | -------------------------------------------------------------------------------- /panache_ui/README.md: -------------------------------------------------------------------------------- 1 | # Panache UI 2 | 3 | -------------------------------------------------------------------------------- /panache_ui/assets/github.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_ui/assets/github.png -------------------------------------------------------------------------------- /panache_ui/lib/panache_ui.dart: -------------------------------------------------------------------------------- 1 | library panache_ui; 2 | 3 | export 'src/screens/launch/launch_screen.dart'; 4 | export 'src/screens/editor/editor_screen.dart'; 5 | export 'src/screens/editor/controls/color_selector.dart'; 6 | export 'src/screens/editor/controls/brightness_control.dart'; 7 | -------------------------------------------------------------------------------- /panache_ui/lib/src/help/button_theme_help.dart: -------------------------------------------------------------------------------- 1 | import 'help.dart'; 2 | 3 | const textThemeHelp = HelpData("textTheme", ''' 4 | - Normal : Button text is black or white depending on ThemeData.brightness. 5 | - Primary : Button text is based on ThemeData.primaryColor. 6 | - Accent : Button text is ThemeData.accentColor. 7 | '''); 8 | 9 | const buttonColorHelp = HelpData("buttonColor", ''' 10 | The background fill color for RaisedButtons. 11 | 12 | If the button is in the focused, hovering, or highlighted state, then the 13 | focusColor, hoverColor, or highlightColor will take precedence over 14 | the focusColor. 15 | '''); 16 | 17 | const disabledColorHelp = HelpData("disabledColor", ''' 18 | The background fill color for disabled RaisedButtons. 19 | '''); 20 | 21 | const highlightColorHelp = HelpData("highlightColor", ''' 22 | The color of the overlay that appears when a button is pressed. 23 | '''); 24 | 25 | const splashColorHelp = HelpData("splashColor", ''' 26 | The color of the ink "splash" overlay that appears when a button is tapped. 27 | '''); 28 | 29 | const focusColorHelp = HelpData("focusColorColor", ''' 30 | The fill color of the button when it has the input focus. 31 | 32 | If the button is in the hovering or highlighted state, then the hoverColor 33 | or highlightColor will take precedence over the focusColor. 34 | '''); 35 | 36 | const hoverColorHelp = HelpData("hoverColorColor", ''' 37 | The fill color of the button when a pointer is hovering over it. 38 | 39 | Returns the button's MaterialButton.hoverColor if it is non-null. 40 | Otherwise the focus color depends on ButtonThemeData.getTextColor(button): 41 | '''); 42 | -------------------------------------------------------------------------------- /panache_ui/lib/src/help/global_theme_help.dart: -------------------------------------------------------------------------------- 1 | import 'help.dart'; 2 | 3 | const primaryColorHelp = HelpData("primaryColor", ''' 4 | The background color for major parts of the app (toolbars, tab bars, etc) 5 | 6 | The theme's [colorScheme] property contains [ColorScheme.primary], as well as a color that contrasts well with the primary color called [ColorScheme.onPrimary]. It might be simpler to just configure an app's visuals in terms of the theme's [colorScheme]. 7 | '''); 8 | 9 | const accentColorHelp = HelpData("accentColor", ''' 10 | The foreground color for widgets (knobs, text, overscroll edge effect, etc). 11 | 12 | Accent color is also known as the secondary color. 13 | 14 | The theme's [colorScheme] property contains [ColorScheme.secondary], as well as a color that contrasts well with the secondary color called [ColorScheme.onSecondary]. It might be simpler to just configure an app's visuals in terms of the theme's [colorScheme]. 15 | '''); 16 | 17 | const scaffoldColorHelp = HelpData("scaffoldColor", ''' 18 | The default color of the [Material] that underlies the [Scaffold]. 19 | 20 | The background color for a typical material app or a page within the app. 21 | '''); 22 | -------------------------------------------------------------------------------- /panache_ui/lib/src/help/help.dart: -------------------------------------------------------------------------------- 1 | export 'button_theme_help.dart'; 2 | export 'global_theme_help.dart'; 3 | 4 | class HelpData { 5 | final String title; 6 | final String content; 7 | 8 | const HelpData(this.title, this.content); 9 | } 10 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/action_bar.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | import 'controls/brightness_control.dart'; 5 | import 'controls/color_selector.dart'; 6 | 7 | class GlobalThemePropertiesControl extends StatelessWidget { 8 | @override 9 | Widget build(BuildContext context) { 10 | final model = ThemeModel.of(context); 11 | 12 | final isDark = model.theme.brightness == Brightness.dark; 13 | return Padding( 14 | padding: const EdgeInsets.all(8.0), 15 | child: Row( 16 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 17 | children: [ 18 | Flexible( 19 | child: ColorSelector( 20 | 'Primary swatch', 21 | model.theme.primaryColor, 22 | (color) => _onSwatchSelection(model, swatchFor(color: color)), 23 | padding: 0, 24 | ), 25 | ), 26 | SizedBox(width: 10), 27 | BrightnessSelector( 28 | isDark: isDark, 29 | label: 'Brightness', 30 | onBrightnessChanged: (value) => _onBrightnessChanged(model, value), 31 | ), 32 | ], 33 | ), 34 | ); 35 | } 36 | 37 | void _onBrightnessChanged(ThemeModel model, Brightness brightness) => 38 | model.updateTheme(ThemeData.localize( 39 | ThemeData( 40 | primarySwatch: 41 | model.primarySwatch ?? swatchFor(color: model.theme.primaryColor), 42 | brightness: brightness, 43 | ), 44 | model.theme.textTheme, 45 | )); 46 | 47 | void _onSwatchSelection(ThemeModel model, MaterialColor swatch) { 48 | model.updateTheme(ThemeData.localize( 49 | ThemeData(primarySwatch: swatch, brightness: model.theme.brightness), 50 | model.theme.textTheme)); 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/color_stream.dart: -------------------------------------------------------------------------------- 1 | import 'dart:async'; 2 | import 'dart:ui'; 3 | 4 | class ColorStream { 5 | ColorStream(this._currentColor); 6 | 7 | StreamController _colorStreamer = new StreamController(); 8 | 9 | Color _currentColor; 10 | 11 | Stream get color$ => _colorStreamer.stream; 12 | 13 | void selectColor(Color color) { 14 | _currentColor = color; 15 | _colorStreamer.add(_currentColor); 16 | } 17 | 18 | void setOpacity(double opacity) { 19 | _currentColor = _currentColor.withOpacity(opacity); 20 | _colorStreamer.add(_currentColor); 21 | } 22 | 23 | void dispose() { 24 | _colorStreamer.close(); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/color_swatch.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | import 'controls/color_picker/colorpicker_dialog.dart'; 5 | //import 'controls/color_menu.dart'; 6 | 7 | class ColorSwatchControl extends StatelessWidget { 8 | final Color color; 9 | 10 | final ValueChanged onSelection; 11 | 12 | String get label { 13 | final namedPeer = namedColors().where((c) => c.color.value == color.value); 14 | return namedPeer.length > 0 15 | ? namedPeer.first.name 16 | : "#${color.value.toRadixString(16)}"; 17 | } 18 | 19 | ColorSwatchControl({this.color, this.onSelection}); 20 | 21 | @override 22 | Widget build(BuildContext context) => InkWell( 23 | onTap: onSelection != null 24 | ? () => showColorPicker( 25 | context: context, onColor: onSelection, currentColor: color) 26 | : null 27 | /*openColorMenu(context, onSelection: onSelection, color: color)*/, 28 | child: Container( 29 | width: kSwatchSize, 30 | height: kSwatchSize, 31 | decoration: BoxDecoration(color: color), 32 | )); 33 | } 34 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/brightness_control.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | import 'control_container.dart'; 4 | 5 | class BrightnessSelector extends StatelessWidget { 6 | final String label; 7 | final bool isDark; 8 | final ValueChanged onChange; 9 | final ValueChanged onBrightnessChanged; 10 | 11 | final Axis direction; 12 | 13 | BrightnessSelector( 14 | {this.label, 15 | this.isDark, 16 | this.onChange, 17 | this.onBrightnessChanged, 18 | this.direction: Axis.vertical}); 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | final textTheme = Theme.of(context).textTheme; 23 | final labelStyle = textTheme.subtitle; 24 | return ControlContainerBorder( 25 | child: Flex( 26 | direction: direction, 27 | mainAxisAlignment: MainAxisAlignment.start, 28 | children: [ 29 | Padding( 30 | padding: const EdgeInsets.only(right: 16.0), 31 | child: Text( 32 | label, 33 | style: labelStyle, 34 | ), 35 | ), 36 | Container( 37 | padding: EdgeInsets.symmetric(horizontal: 12.0), 38 | decoration: BoxDecoration( 39 | borderRadius: BorderRadius.circular(8), 40 | color: Colors.white, 41 | ), 42 | child: Row( 43 | children: [ 44 | Switch(value: isDark, onChanged: _onChange), 45 | Text('Dark'), 46 | ], 47 | ), 48 | ), 49 | ], 50 | ), 51 | ); 52 | } 53 | 54 | void _onChange(bool value) { 55 | if (onChange != null) onChange(value); 56 | 57 | if (onBrightnessChanged != null) 58 | onBrightnessChanged(value ? Brightness.dark : Brightness.light); 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/color_picker/swatches.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | const _kGridSpacing = 6.0; 5 | 6 | class ColorSwatchesWidget extends StatelessWidget { 7 | final Color color; 8 | 9 | ColorSwatchesWidget(this.color); 10 | 11 | @override 12 | Widget build(BuildContext context) { 13 | final c = newColorSwatch(color); 14 | 15 | return LayoutBuilder( 16 | builder: (context, constraints) { 17 | final itemWidth = (constraints.maxWidth - _kGridSpacing) / 2; 18 | return Column( 19 | children: [ 20 | Align( 21 | alignment: Alignment.centerLeft, 22 | child: Text( 23 | 'Swatches', 24 | style: Theme.of(context).textTheme.subhead.copyWith( 25 | color: getContrastColor(getSwatchShade(color, 700))), 26 | ), 27 | ), 28 | Wrap( 29 | spacing: _kGridSpacing, 30 | runSpacing: _kGridSpacing, 31 | children: getMaterialColorShades(c).map((c) { 32 | return Container( 33 | alignment: Alignment.center, 34 | color: c, 35 | width: itemWidth, 36 | height: 60.0, 37 | child: Text(colorToHex32(c), 38 | style: TextStyle( 39 | fontSize: 14.0, 40 | color: getContrastColor(c), 41 | )), 42 | ); 43 | }).toList(), 44 | ), 45 | ], 46 | ); 47 | }, 48 | ); 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/color_selector.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | import '../../../help/help.dart'; 5 | import '../color_swatch.dart'; 6 | import 'control_container.dart'; 7 | import 'help_button.dart'; 8 | 9 | class ColorSelector extends StatelessWidget { 10 | final String label; 11 | final Color value; 12 | final ValueChanged onSelection; 13 | final double padding; 14 | 15 | final double maxLabelWidth; 16 | 17 | final HelpData help; 18 | 19 | ColorSelector(this.label, this.value, this.onSelection, 20 | {this.padding: 8.0, this.maxLabelWidth: 100, this.help}); 21 | 22 | String get colorLabel { 23 | final namedPeer = 24 | namedColors().where((c) => c.color?.value == value?.value); 25 | return namedPeer.length > 0 26 | ? namedPeer.first.name 27 | : "#${value.value.toRadixString(16)}"; 28 | } 29 | 30 | @override 31 | Widget build(BuildContext context) { 32 | final textTheme = Theme.of(context).textTheme; 33 | return ControlContainerBorder( 34 | child: Row( 35 | mainAxisSize: MainAxisSize.max, 36 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 37 | children: [ 38 | Flexible( 39 | child: Row( 40 | children: [ 41 | Text.rich( 42 | TextSpan( 43 | text: '$label\n', 44 | style: Theme.of(context).textTheme.subtitle, 45 | children: [ 46 | TextSpan( 47 | text: colorLabel, 48 | style: textTheme.overline.copyWith(height: 1.5) 49 | /*kDarkTextStyle.copyWith(height: 2)*/) 50 | ]), 51 | ), 52 | if (help != null) HelpButton(help: help) 53 | ], 54 | ), 55 | ), 56 | ColorSwatchControl(color: value, onSelection: onSelection), 57 | ], 58 | ), 59 | ); 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/control_container.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class ControlContainerBorder extends StatelessWidget { 4 | final Widget child; 5 | final EdgeInsets margin; 6 | final EdgeInsets padding; 7 | 8 | const ControlContainerBorder({ 9 | Key key, 10 | this.child, 11 | this.margin: const EdgeInsets.all(4.0), 12 | this.padding: const EdgeInsets.all(8.0), 13 | }) : super(key: key); 14 | 15 | @override 16 | Widget build(BuildContext context) { 17 | return Padding( 18 | padding: margin, 19 | child: Container( 20 | padding: padding, 21 | decoration: BoxDecoration( 22 | borderRadius: BorderRadius.circular(8), 23 | color: Colors.white, 24 | ), 25 | child: child), 26 | ); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/font_size_slider.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | import 'control_container.dart'; 4 | 5 | class FontSizeSelector extends StatefulWidget { 6 | final double value; 7 | final double min; 8 | final double max; 9 | final bool vertical; 10 | final ValueChanged onValueChanged; 11 | 12 | FontSizeSelector(this.value, this.onValueChanged, 13 | {this.min: 0.0, this.max: 112.0, this.vertical}) 14 | : assert(value != null), 15 | assert(min != null), 16 | assert(max != null), 17 | assert(min <= max); 18 | 19 | @override 20 | FontSizeSelectorState createState() { 21 | return new FontSizeSelectorState(); 22 | } 23 | } 24 | 25 | class FontSizeSelectorState extends State { 26 | double visibleValue; 27 | 28 | @override 29 | void initState() { 30 | super.initState(); 31 | visibleValue = widget.value; 32 | } 33 | 34 | @override 35 | Widget build(BuildContext context) { 36 | final textTheme = Theme.of(context).textTheme; 37 | return ControlContainerBorder( 38 | child: Flex( 39 | direction: widget.vertical ? Axis.vertical : Axis.horizontal, 40 | children: [ 41 | Slider( 42 | value: visibleValue, 43 | onChanged: (currentValue) => 44 | setState(() => visibleValue = currentValue), 45 | onChangeEnd: (value) { 46 | print( 47 | 'FontSizeSelectorState onChangeEnd => $value ${value == 20.0}' 48 | ', ${double.parse('$value')}', 49 | ); 50 | 51 | widget.onValueChanged(double.parse('$value')); 52 | } /*widget.onValueChanged*/, 53 | divisions: (widget.max - widget.min) ~/ 2, 54 | min: widget.min, 55 | max: widget.max, 56 | label: '${visibleValue.toStringAsFixed(0)}', 57 | ), 58 | RichText( 59 | text: TextSpan( 60 | text: 'Font size ', 61 | style: textTheme.subtitle, 62 | children: [ 63 | TextSpan( 64 | text: widget.value.toStringAsFixed(1), 65 | style: textTheme.body1, 66 | ) 67 | ]), 68 | ), 69 | ], 70 | ), 71 | ); 72 | } 73 | } 74 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/help_button.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import '../../../help/help.dart'; 3 | 4 | class HelpButton extends StatelessWidget { 5 | final HelpData help; 6 | 7 | const HelpButton({Key key, this.help}) : super(key: key); 8 | 9 | @override 10 | Widget build(BuildContext context) { 11 | return IconButton( 12 | icon: Icon(Icons.help), 13 | color: Colors.blueGrey.shade300, 14 | onPressed: () => showHelp( 15 | context, 16 | title: help.title, 17 | content: help.content, 18 | ), 19 | ); 20 | } 21 | 22 | showHelp(BuildContext context, {String content, String title}) { 23 | final textTheme = Theme.of(context).textTheme; 24 | showDialog( 25 | context: context, 26 | builder: (context) => SimpleDialog( 27 | title: Text(title), 28 | contentPadding: const EdgeInsets.all(24), 29 | children: [Text(content, style: textTheme.subhead)], 30 | ), 31 | ); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/controls/switcher_control.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | import 'control_container.dart'; 4 | 5 | class SwitcherControl extends StatelessWidget { 6 | final String label; 7 | final String checkedLabel; 8 | final bool checked; 9 | final ValueChanged onChange; 10 | 11 | final Axis direction; 12 | 13 | SwitcherControl({ 14 | this.label, 15 | this.checkedLabel: '', 16 | this.checked, 17 | this.direction: Axis.horizontal, 18 | this.onChange, 19 | }); 20 | 21 | @override 22 | Widget build(BuildContext context) { 23 | final textTheme = Theme.of(context).textTheme; 24 | final labelStyle = textTheme.subtitle; 25 | 26 | final children = [ 27 | Flex( 28 | direction: direction, 29 | children: [ 30 | Switch(value: checked, onChanged: onChange), 31 | Text( 32 | checkedLabel, 33 | style: labelStyle, 34 | ), 35 | ], 36 | ), 37 | ]; 38 | if (label != null) 39 | children.add(Padding( 40 | padding: const EdgeInsets.only(right: 6.0), 41 | child: Text( 42 | label, 43 | style: labelStyle, 44 | ), 45 | )); 46 | 47 | return ControlContainerBorder( 48 | child: Flex( 49 | direction: direction, 50 | mainAxisSize: MainAxisSize.min, 51 | mainAxisAlignment: MainAxisAlignment.center, 52 | children: children), 53 | ); 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/panel_header.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/foundation.dart'; 2 | import 'package:flutter/material.dart'; 3 | 4 | class ExpanderHeader extends StatelessWidget { 5 | final Color color; 6 | final String label; 7 | final IconData icon; 8 | final bool dense; 9 | 10 | ExpanderHeader( 11 | {@required this.color, 12 | @required this.label, 13 | @required this.icon, 14 | this.dense}) { 15 | print('Label... $label $dense'); 16 | } 17 | 18 | @override 19 | Widget build(BuildContext context) { 20 | final textTheme = Theme.of(context).textTheme; 21 | return Padding( 22 | padding: const EdgeInsets.symmetric(horizontal: 16.0), 23 | child: Row( 24 | children: [ 25 | Padding( 26 | padding: EdgeInsets.only(left: 16.0, right: 8.0), 27 | child: Icon( 28 | icon, 29 | color: color, 30 | ), 31 | ), 32 | Text( 33 | label, 34 | style: dense ? textTheme.subhead : textTheme.title, 35 | ), 36 | ], 37 | ), 38 | ); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/panels/dialog_theme_panel.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | import '../controls/shape_form_control.dart'; 5 | 6 | final showIndicatorOptions = [ 7 | ShowValueIndicator.always, 8 | ShowValueIndicator.never, 9 | ShowValueIndicator.onlyForContinuous, 10 | ShowValueIndicator.onlyForDiscrete, 11 | ]; 12 | 13 | class DialogThemePanel extends StatelessWidget { 14 | final ThemeModel model; 15 | 16 | DialogTheme get dialogTheme => model.theme.dialogTheme; 17 | 18 | DialogThemePanel(this.model); 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | return Container( 23 | padding: kPadding, 24 | constraints: BoxConstraints.expand(height: 100), 25 | color: Colors.grey.shade100, 26 | child: Column( 27 | children: [ 28 | Padding( 29 | padding: const EdgeInsets.symmetric(vertical: 4.0), 30 | child: ShapeFormControl( 31 | shape: dialogTheme.shape, 32 | onShapeChanged: (shape) => 33 | _updateDialogTheme(DialogTheme(shape: shape)), 34 | ), 35 | ), 36 | ], 37 | ), 38 | ); 39 | } 40 | 41 | void _updateDialogTheme(DialogTheme dialogTheme) => 42 | model.updateTheme(model.theme.copyWith(dialogTheme: dialogTheme)); 43 | } 44 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/panels/editor_topbar.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | import '../drive_menu.dart'; 5 | 6 | class MobilePanacheEditorTopbar extends StatelessWidget 7 | implements PreferredSizeWidget { 8 | final bool isMobileInPortrait; 9 | final ThemeModel model; 10 | final bool showCode; 11 | final ValueChanged onShowCodeChanged; 12 | 13 | MobilePanacheEditorTopbar( 14 | {this.isMobileInPortrait, 15 | this.model, 16 | this.showCode, 17 | this.onShowCodeChanged}); 18 | 19 | @override 20 | Widget build(BuildContext context) { 21 | final textTheme = Theme.of(context).textTheme; 22 | final title = Text.rich(TextSpan(text: 'Panache', children: [ 23 | TextSpan( 24 | text: ' alpha', 25 | style: textTheme.caption.copyWith(color: Colors.blueGrey.shade900)) 26 | ])); 27 | 28 | if (isMobileInPortrait) { 29 | return AppBar( 30 | title: title, 31 | leading: IconButton( 32 | icon: Icon(Icons.color_lens), 33 | onPressed: () => Scaffold.of(context).openDrawer()), 34 | actions: [ 35 | IconButton( 36 | icon: Icon(showCode ? Icons.mobile_screen_share : Icons.keyboard), 37 | onPressed: () => onShowCodeChanged(!showCode), 38 | ), 39 | DriveMenu(model: model), 40 | IconButton( 41 | icon: Icon(Icons.close), 42 | onPressed: () => Navigator.of(context).maybePop(), 43 | ) 44 | ], 45 | ); 46 | } 47 | 48 | return AppBar( 49 | title: title, 50 | actions: [ 51 | FlatButton.icon( 52 | textColor: Colors.blueGrey.shade50, 53 | icon: Icon(Icons.mobile_screen_share), 54 | label: Text('App preview'), 55 | onPressed: showCode ? () => onShowCodeChanged(false) : null, 56 | ), 57 | FlatButton.icon( 58 | textColor: Colors.blueGrey.shade50, 59 | icon: Icon(Icons.keyboard), 60 | label: Text('Code preview'), 61 | onPressed: showCode ? null : () => onShowCodeChanged(true), 62 | ), 63 | DriveMenu(model: model) 64 | ], 65 | ); 66 | } 67 | 68 | @override 69 | // TODO: implement preferredSize 70 | Size get preferredSize => Size.fromHeight(kToolbarHeight); 71 | } 72 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/panels/editor_topbar_web.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | class WebPanacheEditorTopbar extends StatelessWidget 5 | implements PreferredSizeWidget { 6 | final bool isMobileInPortrait; 7 | final ThemeModel model; 8 | final bool showCode; 9 | final ValueChanged onShowCodeChanged; 10 | 11 | WebPanacheEditorTopbar( 12 | {this.isMobileInPortrait, 13 | this.model, 14 | this.showCode, 15 | this.onShowCodeChanged}); 16 | 17 | @override 18 | Widget build(BuildContext context) { 19 | final textTheme = Theme.of(context).textTheme; 20 | final title = Text.rich(TextSpan(text: 'Panache', children: [ 21 | TextSpan( 22 | text: ' alpha', 23 | style: textTheme.caption.copyWith(color: Colors.blueGrey.shade900)) 24 | ])); 25 | 26 | if (isMobileInPortrait) { 27 | return AppBar( 28 | title: title, 29 | leading: IconButton( 30 | icon: Icon(Icons.color_lens), 31 | onPressed: () => Scaffold.of(context).openDrawer()), 32 | actions: [ 33 | IconButton( 34 | icon: Icon(showCode ? Icons.mobile_screen_share : Icons.keyboard), 35 | onPressed: () => onShowCodeChanged(!showCode), 36 | ), 37 | IconButton( 38 | icon: Icon(Icons.close), 39 | onPressed: () => Navigator.of(context).maybePop(), 40 | ), 41 | IconButton(icon: Icon(Icons.file_download), onPressed: saveTheme) 42 | ], 43 | ); 44 | } 45 | 46 | return AppBar( 47 | title: title, 48 | actions: [ 49 | FlatButton.icon( 50 | textColor: Colors.blueGrey.shade50, 51 | icon: Icon(Icons.mobile_screen_share), 52 | label: Text('App preview'), 53 | onPressed: showCode ? () => onShowCodeChanged(false) : null, 54 | ), 55 | FlatButton.icon( 56 | textColor: Colors.blueGrey.shade50, 57 | icon: Icon(Icons.keyboard), 58 | label: Text('Code preview'), 59 | onPressed: showCode ? null : () => onShowCodeChanged(true), 60 | ), 61 | IconButton(icon: Icon(Icons.file_download), onPressed: saveTheme) 62 | ], 63 | ); 64 | } 65 | 66 | @override 67 | // TODO: implement preferredSize 68 | Size get preferredSize => Size.fromHeight(kToolbarHeight); 69 | 70 | void saveTheme() { 71 | model.exportTheme(name: 'theme.dart'); 72 | } 73 | } 74 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/editor/panels/panels.dart: -------------------------------------------------------------------------------- 1 | export 'button_theme_panel.dart'; 2 | export 'chip_theme_panel.dart'; 3 | export 'slider_theme_panel.dart'; 4 | export 'tabbar_theme_panel.dart'; 5 | export 'theme_color_panel.dart'; 6 | export 'typography_panel.dart'; 7 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/launch/io_stub.dart: -------------------------------------------------------------------------------- 1 | class File { 2 | File(String path); 3 | 4 | existsSync() {} 5 | } 6 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/launch/logo.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class PanacheLogo extends StatelessWidget { 4 | final bool minimized; 5 | 6 | const PanacheLogo({Key key, this.minimized}) : super(key: key); 7 | 8 | @override 9 | Widget build(BuildContext context) { 10 | final textTheme = Theme.of(context).textTheme; 11 | return Row( 12 | mainAxisAlignment: 13 | minimized ? MainAxisAlignment.start : MainAxisAlignment.center, 14 | children: [ 15 | Padding( 16 | padding: EdgeInsets.all(minimized ? 4 : 8), 17 | child: Image.asset('logo.png', 18 | package: 'panache_core', width: minimized ? 16 : 48), 19 | ), 20 | Text.rich( 21 | TextSpan( 22 | text: 'Panache', 23 | children: [ 24 | TextSpan( 25 | text: ' alpha', 26 | style: textTheme.body1.copyWith(color: Colors.grey), 27 | ) 28 | ], 29 | ), 30 | style: minimized ? textTheme.subhead : textTheme.display1, 31 | ) 32 | ], 33 | ); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/launch/screenshot_renderer.dart: -------------------------------------------------------------------------------- 1 | // ignore: uri_does_not_exists 2 | import 'package:flutter/foundation.dart'; 3 | 4 | import 'dart:io' if (dart.library.html) 'dart:html'; 5 | 6 | import 'package:flutter/material.dart'; 7 | import 'package:panache_core/panache_core.dart'; 8 | 9 | class ScreenshotRenderer extends StatelessWidget { 10 | final PanacheTheme theme; 11 | final String basePath; 12 | final bool removable; 13 | final Size size; 14 | final ValueChanged onThemeSelection; 15 | final ValueChanged onDeleteTheme; 16 | 17 | const ScreenshotRenderer( 18 | {Key key, 19 | @required this.theme, 20 | @required this.basePath, 21 | @required this.size, 22 | this.onThemeSelection, 23 | this.onDeleteTheme, 24 | this.removable: false}) 25 | : super(key: key); 26 | 27 | @override 28 | Widget build(BuildContext context) { 29 | final screenshotPath = '$basePath/${theme.id}.png'; 30 | final imageFile = File(screenshotPath); 31 | 32 | return Stack( 33 | alignment: Alignment.bottomLeft, 34 | children: [ 35 | InkWell( 36 | onTap: () => removable ? null : onThemeSelection(theme), 37 | child: Container( 38 | child: Material( 39 | elevation: 2.0, 40 | child: imageFile.existsSync() && !kIsWeb 41 | ? Image.file( 42 | imageFile, 43 | width: size.width, 44 | height: size.height, 45 | fit: BoxFit.fitHeight, 46 | ) 47 | : SizedBox( 48 | width: size.width, 49 | height: size.height, 50 | child: Icon(Icons.color_lens))), 51 | ), 52 | ), 53 | removable 54 | ? Positioned( 55 | right: 0, 56 | top: 0, 57 | child: RaisedButton( 58 | padding: EdgeInsets.zero, 59 | shape: CircleBorder(), 60 | color: Colors.red, 61 | onPressed: () => onDeleteTheme(theme), 62 | child: Icon( 63 | Icons.close, 64 | color: Colors.white, 65 | ), 66 | ), 67 | ) 68 | : SizedBox(), 69 | ], 70 | ); 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/launch/web_screenshot_renderer.dart: -------------------------------------------------------------------------------- 1 | // ignore: uri_does_not_exists 2 | import 'package:flutter/foundation.dart'; 3 | 4 | import 'package:flutter/material.dart'; 5 | import 'package:panache_core/panache_core.dart'; 6 | 7 | class ScreenshotRenderer extends StatelessWidget { 8 | final PanacheTheme theme; 9 | final String basePath; 10 | final bool removable; 11 | final Size size; 12 | final ValueChanged onThemeSelection; 13 | final ValueChanged onDeleteTheme; 14 | 15 | const ScreenshotRenderer( 16 | {Key key, 17 | @required this.theme, 18 | @required this.basePath, 19 | @required this.size, 20 | this.onThemeSelection, 21 | this.onDeleteTheme, 22 | this.removable: false}) 23 | : super(key: key); 24 | 25 | @override 26 | Widget build(BuildContext context) { 27 | final screenshotPath = '$basePath/${theme.id}.png'; 28 | 29 | return Stack( 30 | alignment: Alignment.bottomLeft, 31 | children: [ 32 | InkWell( 33 | onTap: () => removable ? null : onThemeSelection(theme), 34 | child: Container( 35 | child: Material( 36 | elevation: 2.0, 37 | child: SizedBox( 38 | width: size.width, 39 | height: size.height, 40 | child: Icon(Icons.color_lens))), 41 | ), 42 | ), 43 | removable 44 | ? Positioned( 45 | right: 0, 46 | top: 0, 47 | child: RaisedButton( 48 | padding: EdgeInsets.zero, 49 | shape: CircleBorder(), 50 | color: Colors.red, 51 | onPressed: () => onDeleteTheme(theme), 52 | child: Icon( 53 | Icons.close, 54 | color: Colors.white, 55 | ), 56 | ), 57 | ) 58 | : SizedBox(), 59 | ], 60 | ); 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/preview/code_preview.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | class ThemeCodePreview extends StatelessWidget { 5 | final ThemeModel model; 6 | String get code => model.themeCode; 7 | 8 | const ThemeCodePreview(this.model, {Key key}) : super(key: key); 9 | 10 | @override 11 | Widget build(BuildContext context) { 12 | final SyntaxHighlighterStyle style = 13 | SyntaxHighlighterStyle.panacheThemeStyle(); 14 | 15 | return Container( 16 | constraints: BoxConstraints.expand(), 17 | decoration: BoxDecoration( 18 | border: Border(left: BorderSide(color: Colors.blueGrey.shade800)), 19 | color: Colors.blueGrey.shade900), 20 | padding: EdgeInsets.only(top: 24, left: 24), 21 | child: SingleChildScrollView( 22 | child: RichText( 23 | text: TextSpan( 24 | style: const TextStyle(fontSize: 12.0), 25 | children: [DartSyntaxHighlighter(style).format(code)]), 26 | ), 27 | ), 28 | ); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /panache_ui/lib/src/screens/preview/subscreens/slider_preview.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | class SliderPreview extends StatelessWidget { 4 | final ThemeData theme; 5 | 6 | const SliderPreview({Key key, this.theme}) : super(key: key); 7 | 8 | @override 9 | Widget build(BuildContext context) { 10 | return Padding( 11 | padding: EdgeInsets.all(8.0), 12 | child: Column( 13 | mainAxisSize: MainAxisSize.max, 14 | mainAxisAlignment: MainAxisAlignment.spaceEvenly, 15 | children: [ 16 | _FakeSlider(divisions: 10), 17 | _FakeSlider( 18 | divisions: null, 19 | labelPrefix: '', 20 | ), 21 | _FakeSlider(disabled: true), 22 | ], 23 | ), 24 | ); 25 | } 26 | } 27 | 28 | class _FakeSlider extends StatefulWidget { 29 | final bool disabled; 30 | final int divisions; 31 | final int id; 32 | final String labelPrefix; 33 | 34 | _FakeSlider( 35 | {this.id, 36 | this.disabled: false, 37 | this.divisions: 10, 38 | this.labelPrefix: 'Value'}); 39 | 40 | @override 41 | _FakeSliderState createState() => _FakeSliderState(); 42 | } 43 | 44 | class _FakeSliderState extends State<_FakeSlider> { 45 | double value = 0.5; 46 | 47 | _FakeSliderState(); 48 | 49 | @override 50 | Widget build(BuildContext context) { 51 | print('_FakeSliderState.build... '); 52 | return Padding( 53 | padding: const EdgeInsets.all(8.0), 54 | child: Slider( 55 | key: Key(widget.id.toString()), 56 | divisions: widget.divisions, 57 | value: value, 58 | /*label: '${widget.labelPrefix}' */ /* ${value.toStringAsFixed(2)} */ /*,*/ 59 | onChanged: widget.disabled 60 | ? null 61 | : (newValue) => setState(() => value = newValue)), 62 | ); 63 | } 64 | } 65 | -------------------------------------------------------------------------------- /panache_ui/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: panache_ui 2 | description: A new Flutter project. 3 | version: 0.0.1 4 | author: 5 | homepage: 6 | 7 | environment: 8 | sdk: ">=2.2.2 <3.0.0" 9 | 10 | dependencies: 11 | flutter: 12 | sdk: flutter 13 | 14 | panache_core: 15 | path: ../panache_core 16 | 17 | provider: ^3.1.0 18 | 19 | #panache_services: 20 | #path: ../panache_services 21 | 22 | dev_dependencies: 23 | flutter_test: 24 | sdk: flutter 25 | 26 | flutter: 27 | assets: 28 | - github.png 29 | -------------------------------------------------------------------------------- /panache_ui/test/panache_ui_test.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter_test/flutter_test.dart'; 2 | 3 | void main() {} 4 | -------------------------------------------------------------------------------- /panache_web/.metadata: -------------------------------------------------------------------------------- 1 | # This file tracks properties of this Flutter project. 2 | # Used by Flutter tool to assess capabilities and perform upgrades etc. 3 | # 4 | # This file should be version controlled and should not be manually edited. 5 | 6 | version: 7 | revision: 1363528eeed0302ef5a3d372cc81514d6960e722 8 | channel: master 9 | 10 | project_type: app 11 | -------------------------------------------------------------------------------- /panache_web/README.md: -------------------------------------------------------------------------------- 1 | # Panache for your browser 2 | 3 | [Building Flutter apps for the web](https://github.com/flutter/flutter/wiki/Building-a-web-application-with-Flutter) 4 | 5 | ```bash 6 | flutter run -d chrome 7 | ``` -------------------------------------------------------------------------------- /panache_web/lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter/widgets.dart'; 3 | import 'package:panache_core/panache_core.dart'; 4 | import 'package:panache_ui/panache_ui.dart'; 5 | import 'package:panache_web/src/web_link_service.dart'; 6 | import 'package:scoped_model/scoped_model.dart'; 7 | import 'package:provider/provider.dart'; 8 | 9 | import 'src/theme_exporter_web.dart'; 10 | import 'src/web_local_data.dart'; 11 | import 'src/web_theme_service.dart'; 12 | 13 | void main() async { 14 | clearPersisted(); 15 | final localData = WebLocalData(); 16 | await localData.init(); 17 | 18 | final themeModel = ThemeModel( 19 | localData: localData, 20 | service: WebThemeService( 21 | themeExporter: exportTheme, 22 | dirProvider: null, 23 | ), 24 | ); 25 | 26 | runApp(PanacheApp(themeModel: themeModel)); 27 | } 28 | 29 | class PanacheApp extends StatelessWidget { 30 | final ThemeModel themeModel; 31 | 32 | const PanacheApp({Key key, @required this.themeModel}) : super(key: key); 33 | 34 | @override 35 | Widget build(BuildContext context) { 36 | final theme = Theme.of(context); 37 | return ScopedModel( 38 | model: themeModel, 39 | child: MultiProvider( 40 | child: MaterialApp( 41 | debugShowCheckedModeBanner: false, 42 | theme: /*panacheTheme*/ buildAppTheme(theme, panachePrimarySwatch), 43 | home: LaunchScreen(model: themeModel), 44 | routes: { 45 | '/home': (context) => LaunchScreen(model: themeModel), 46 | '/editor': (context) => PanacheEditorScreen(), 47 | }, 48 | ), 49 | providers: [ 50 | Provider.value(value: WebLinkService()) 51 | ], 52 | ), 53 | ); 54 | } 55 | } 56 | 57 | exportTheme(String code, String filename) async { 58 | // print('exportTheme... $code'); 59 | jsSaveTheme(code, filename, (success) => print('export $success')); 60 | } 61 | -------------------------------------------------------------------------------- /panache_web/lib/src/theme_exporter_web.dart: -------------------------------------------------------------------------------- 1 | @JS() 2 | library bridge; 3 | 4 | import 'package:js/js.dart'; 5 | 6 | @JS('saveTheme') 7 | external void jsSaveTheme( 8 | String content, 9 | String filename, 10 | void Function(bool result) onFileSaved, 11 | ); 12 | -------------------------------------------------------------------------------- /panache_web/lib/src/web_link_service.dart: -------------------------------------------------------------------------------- 1 | // ignore: uri_does_not_exist 2 | import 'dart:html' as html; 3 | 4 | import 'package:panache_core/panache_core.dart'; 5 | 6 | class WebLinkService extends LinkService { 7 | @override 8 | void open(String url) { 9 | print('WebLinkService.open... $url'); 10 | html.window.open(url, '_blank'); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /panache_web/lib/src/web_local_data.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'package:panache_core/panache_core.dart'; 3 | 4 | import 'web_persistence_bridge.dart'; 5 | 6 | const _themeKey = 'themes'; 7 | const _panelsKey = 'panelsState'; 8 | const _positionKey = 'scrollPosition'; 9 | 10 | /// local persistence 11 | class WebLocalData implements LocalStorage { 12 | /// synchronously loads local themes 13 | List get themes => [] 14 | /*_prefs 15 | .getStringList(_themeKey) 16 | ?.map(_themeDataFromJson) 17 | ?.toList() ?? 18 | []*/ 19 | ; 20 | 21 | /// loads ( mobile layout) 22 | Map get panelStates { 23 | final persistedStates = jsGet(_panelsKey); 24 | 25 | if (persistedStates == null) return defaultPanelStates; 26 | return json.decode(persistedStates); 27 | } 28 | 29 | /// get the last scroll position ( mobile layout) 30 | double get scrollPosition => double.parse(jsGet(_positionKey) ?? '0'); 31 | 32 | /// clear local themes list 33 | PanacheTheme _themeDataFromJson(String data) => PanacheTheme.fromJson(data); 34 | 35 | // FIXME 36 | /// initialisation du stockage 37 | init() async {} /* => print('WebLocalData.init()')*/ 38 | 39 | /// save the new local themes list 40 | void updateThemeList(List themes) { 41 | /* FIXME 42 | _prefs.setStringList( 43 | _themeKey, 44 | themes.map((theme) => theme.toJson()).toList(growable: false), 45 | );*/ 46 | } 47 | 48 | /// remove the local theme list 49 | void clear() => print('WebLocalData.clear()') /*_prefs.remove(_themeKey)*/; 50 | 51 | /// delete a local theme 52 | void deleteTheme(PanacheTheme theme) { 53 | updateThemeList(themes.where((t) => t.id != theme.id).toList()); 54 | } 55 | 56 | /// saves panels states and editor scrollposition ( mobile layout ) 57 | void saveEditorState(Map panelStates, double pixels) { 58 | jsSet(_panelsKey, json.encode(panelStates)); 59 | saveScrollPosition(pixels); 60 | } 61 | 62 | /// saves editor scrollposition ( mobile layout ) 63 | void saveScrollPosition(double pixels) { 64 | jsSet(_positionKey, pixels); 65 | } 66 | } 67 | 68 | void clearPersisted() { 69 | jsSet(_positionKey, null); 70 | jsSet(_panelsKey, null); 71 | } 72 | -------------------------------------------------------------------------------- /panache_web/lib/src/web_persistence_bridge.dart: -------------------------------------------------------------------------------- 1 | @JS() 2 | library persistence_bridge; 3 | 4 | import 'package:js/js.dart'; 5 | 6 | @JS('setProp') 7 | external void jsSet(String propertyName, dynamic value); 8 | 9 | @JS('getProp') 10 | external dynamic jsGet(String propertyName); 11 | -------------------------------------------------------------------------------- /panache_web/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: panache_web 2 | description: panache for the web 3 | version: 1.0.0+1 4 | 5 | environment: 6 | sdk: ">=2.2.2<3.0.0" 7 | 8 | dependencies: 9 | flutter: 10 | sdk: flutter 11 | 12 | dev_dependencies: 13 | flutter_test: 14 | sdk: flutter 15 | 16 | scoped_model: ^1.0.1 17 | provider: ^3.1.0 18 | 19 | js: any 20 | 21 | panache_core: 22 | path: ../panache_core 23 | 24 | panache_ui: 25 | path: ../panache_ui 26 | 27 | flutter: 28 | uses-material-design: true 29 | -------------------------------------------------------------------------------- /panache_web/web/assets/.FontManifest.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "fonts": [ 4 | { 5 | "asset": "fonts/MaterialIcons-Regular.ttf" 6 | } 7 | ], 8 | "family": "MaterialIcons" 9 | }, 10 | { 11 | "family": "Roboto", 12 | "fonts": [ 13 | { 14 | "asset": "fonts/Roboto-Regular.ttf" 15 | } 16 | ] 17 | }, 18 | { 19 | "family": "RobotoMono", 20 | "fonts": [ 21 | { 22 | "asset": "fonts/RobotoMono-Regular.ttf" 23 | } 24 | ] 25 | } 26 | ] -------------------------------------------------------------------------------- /panache_web/web/assets/Roboto-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_web/web/assets/Roboto-Regular.ttf -------------------------------------------------------------------------------- /panache_web/web/assets/RobotoMono-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rxlabz/panache/6b2eb7e068e076634236654b97e376a88cee965f/panache_web/web/assets/RobotoMono-Regular.ttf -------------------------------------------------------------------------------- /panache_web/web/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | panache_web 6 | 8 | 31 | 32 | 33 | 34 | 35 | 36 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /tools/publish.sh: -------------------------------------------------------------------------------- 1 | cp -R panache_web/build/web/* ./docs/ 2 | cp -R panache_web/build/web/* ../017/panache_web/docs/ 3 | echo "COMPLETE !!!" --------------------------------------------------------------------------------