Added onProgress, onLoad, onError callback in ModelViewer#64
Open
ahmadhassan-dev wants to merge 49 commits into
Open
Added onProgress, onLoad, onError callback in ModelViewer#64ahmadhassan-dev wants to merge 49 commits into
ahmadhassan-dev wants to merge 49 commits into
Conversation
Make the `ModelViewerState` of Web and Mobile share the same `ModelViewer`.
- Replace the js file - Update readme - Add CircularProgressIndicator while mobile platform loading
Tried to add Web support
Added: - `/lib/src/shim/` with `dart_html_fake.dart` and `dart_ui_fake.dart`. Fixing `ERROR: The name platformViewRegistry' is being referenced through the prefix 'ui', but it isn't defined in any of the libraries imported using that prefix.` and `INFO: Avoid using web-only libraries outside Flutter web plugin` to improve the [score on pub.dev](https://pub.dev/packages/model_viewer_plus/score). Changed: - example's `/etc/assets` -> `/assets`
Improve the score on pub.dev
According to omchiii#12 's need, - ModelViewer's background defaults to Colors.transparent - Also, set Webview's background to Colors.transparent on Android / iOS By doing this, users can use Stack to add a image to ModelViewer's lower layer.
_proxy null check and setState() for it
for v1.1.3 - fix omchiii#10 and omchiii#12
### Changed - `/lib/src/model_viewer_plus_mobile.dart`, update according to the [newest document](https://developers.google.com/ar/develop/scene-viewer#3d-or-ar). Fix [omchiii#9](omchiii#9). - Insted of `com.google.ar.core`, now we use `com.google.android.googlequicksearchbox`. This should support the widest possible range of devices. - Mode defaults to `ar_preferred`. Scene Viewer launches in AR native mode as the entry mode. If Google Play Services for AR isn't present, Scene Viewer gracefully falls back to 3D mode as the entry mode. - Update `example\android\app\build.gradle` `compileSdkVersion` to 31 - Update `android_intent_plus` to `3.1.1` - Update `android_intent_plus to` `3.0.1` ### Removed - `/lib/src/http_proxy.dart`: empty file
Fix omchiii#11 and a less elegant solution of omchiii#8
…elds implementation animation-name & animation-crossfade-duration
### Added - More examples in `example/lib` ### Changed - `lib\html_builder.dart`, `lib\model_viewer_plus_mobile.dart`, `lib\model_viewer_plus_web.dart`, `lib\model_viewer_plus.dart`: implement all the attributes of `<model-viewer>` v1.11.1. - ModelViewer.arSacle from `final String? arScale` to `final ArScale? arScale`, which may be a breaking change. - Update `assets/model-viewer.min.js` to v1.11.1 - Update example dir's gradle version to 7.0.2
Implement all the missing attributes of `<model-viewer>` v1.11.1
### Changed - `README.md`: `import 'package:model_viewer_plus/model_viewer.dart';` -> `import 'package:model_viewer_plus/model_viewer_plus.dart';` - `lib\html_builder.dart`: fix typos and uncomment `debugPrint` for more debug info - `lib\model_viewer_plus_mobile.dart`: uncomment `debugPrint` for more debug info - `lib\model_viewer_plus_web.dart`: unique viewType to fix [omchiii#29](omchiii#29) - Update `assets/model-viewer.min.js` to v1.20.0
Upgrade dependencies, maybe related with omchiii#34
Fix omchiii#40 ### Changed - Update `html_builder.dart`: - Fix `min-camera-orbit`, `max-field-of-view`, `min-field-of-view`
Update html_builder.dart, Fix omchiii#40
…ent]` ### Changed - Fix: `Removing disallowed element <SCRIPT> from [object DocumentFragment]`, in `lib\src\model_viewer_plus_web.dart` - Update `example\lib\loading\display_poster.dart` - Update `README.md`, due to `<model-viewer>` upgrades to 2.0.0 and we have not keep up with it's latest version. So, Flutter Web users should replace `src="https://unpkg.com/@google/model-viewer/dist/model-viewer.min.js"` with `src="./assets/packages/model_viewer_plus/assets/model-viewer.min.js"` to use the js file in our package. ### Added - Add a new example: `example\lib\loading\render_scale.dart`
Fix: `Removing disallowed element <SCRIPT> from [object DocumentFragment]`
[web] Add button with hotspot attributes to allowed elements
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I have added the functionality of onProgress, onLoad, onError callbacks in ModelViewer Packages,
onProgresscallbackonLoadcallbackonErrorcallback