Commit Graph

312 Commits

Author SHA1 Message Date
dependabot-preview[bot] ac056e7f83 build(deps-dev): bump eslint-plugin-jsdoc from 31.6.1 to 32.1.0 in /web
Bumps [eslint-plugin-jsdoc](https://github.com/gajus/eslint-plugin-jsdoc) from 31.6.1 to 32.1.0.
- [Release notes](https://github.com/gajus/eslint-plugin-jsdoc/releases)
- [Commits](https://github.com/gajus/eslint-plugin-jsdoc/compare/v31.6.1...v32.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-02-25 14:36:42 -08:00
relrelb d62c3c0500 web: Fix CSS variables in shadow-template.ts
Apparently CSS variables need to be defined in :host rather than in
:root when it comes to shadow DOM.
2021-02-25 14:34:40 -08:00
relrelb 1b41f8fad1 web: Fix panic message alignment 2021-02-25 14:34:40 -08:00
Mike Welsh eb173f06ca web: Strip query params from URL in GitHub issue titles 2021-02-20 14:12:07 -08:00
relrelb 73b5916b2a
web: Fix player positioning 2021-02-19 17:40:43 -08:00
relrelb d3a006f62a web: Cleanup JSON files
Change indentation to 4 spaces and put newline at EOF.
2021-02-19 16:28:09 -08:00
relrelb 6a710fa1f3 web: Remove stale globals definitions
They were removed in 3e084963c6.
2021-02-19 16:28:09 -08:00
relrelb 524fb30acb chore: Cleanup .gitignore
And split it across multiple files.
2021-02-19 16:28:09 -08:00
Mike Welsh 836b631237 web: Revert style changes in #3239 2021-02-18 04:11:04 -08:00
relrelb 1c21856980
web: General refactoring
* web: Don't load a random SWF Instead, show a prompt to select or drag an SWF.
* web: Refactor webpack.config.js
* demo: Refactor index.js
* demo: Cleanup CSS
2021-02-16 20:39:46 -08:00
Ben Lubar 1c620b2c9b add TypeScript documentation for maxExecutionDuration 2021-02-16 20:31:40 -08:00
Adrian Wielgosik f787cffe54
web: Minimal polyfill of window.Reflect 2021-02-09 19:10:47 -08:00
TÖRÖK Attila 4ea1d9e33c web/build: Make successful wasm-opt invocation mandatory on GitHub Actions 2021-02-05 10:38:47 -08:00
Toad06 b5749ee228
web: Fix some context menu and warning message issues 2021-02-04 15:10:04 -08:00
Mads Marquart 1990e51639 avm2: Add UiBackend::display_unsupported_message
To allow displaying rich content when unsupported ActionScript 3 content is encountered.
2021-01-31 23:04:20 -08:00
Brian Gontowski 31dd2729e2 web: Add an onFSCommand callback into JavaScript 2021-01-31 18:03:31 -08:00
Toad06 b62ca3d589
web: Move `allowScriptAccess` to `BaseLoadOptions` 2021-01-30 16:59:58 -08:00
Omar Shehata 218f1f1da5 web: Pause player when tab is inactive (close #347) 2021-01-26 22:34:43 -08:00
Adrian Wielgosik 9195491f1b web: Redesign the context menu 2021-01-26 17:12:43 -08:00
relrelb aeda974143 web: Rename contextMenu to contextMenuElement
Firefox has a read-only "contextMenu" property, so avoid
shadowing it.
2021-01-25 03:51:50 -08:00
relrelb b07eb07afb web: Revert config removal 2021-01-25 03:51:50 -08:00
relrelb 5827801b03 web: Rename config.showContextMenu to config.contextMenu 2021-01-25 03:51:50 -08:00
relrelb 70326108b9 web: Rename "right click menu" to "context menu" 2021-01-25 03:51:50 -08:00
relrelb 21b0128bca web: Add option to disable the context menu 2021-01-25 03:51:50 -08:00
Toad06 dc2b4fcc42 web: Use enum instead of arbitrary values 2021-01-20 15:03:52 -08:00
Toad06 bc47bfb9e9 web: Display appropriate errors when Ruffle fails to initialize 2021-01-20 15:03:52 -08:00
Adrian Wielgosik b69e17bf35
web: Allow customizing log level 2021-01-19 18:10:35 -08:00
Mike Welsh c2b768c453 web: Fallback to instantiate with improper MIME type
Use --target web in wasm-bindgen and file-loader for WASM files,
allowing wasm-bindgen's built-in fallback from
WebAssembly.instantiateStreaming to instantiate.

file-loader spits out the WASM file directly in the output folder,
and imports will resolve to the URL, so that we can load the file
directly, avoiding webpack's built-in wasm loaders.

This allows Ruffle to function on web servers even if they serve
WASM files with the incorrect MIME type, fixing one of our biggest
support requests (#400, #1458). There is some performance impact
on loading with the fallback, but this is preferable to not
working at all.
2021-01-16 15:30:11 -08:00
TÖRÖK Attila 2858faaaf2
web: Drop wasm-pack, invoke wasm-bindgen and wasm-opt directly from npm (#2482) 2021-01-15 12:59:25 -08:00
Mike Welsh 9bb36885bb web: Add backgroundColor option and support bgcolor attribute
Add `backgroundColor` setting to the config options, allowing
a user to override the background color of an SWF. The polyfill
will now look for the `bgcolor` HTML attribute on the embed
and fill in this setting appropriately.
2021-01-13 11:57:19 -08:00
dependabot-preview[bot] 4dbc4e55cc build(deps-dev): bump eslint-plugin-jsdoc from 30.7.13 to 31.0.3 in /web
Bumps [eslint-plugin-jsdoc](https://github.com/gajus/eslint-plugin-jsdoc) from 30.7.13 to 31.0.3.
- [Release notes](https://github.com/gajus/eslint-plugin-jsdoc/releases)
- [Commits](https://github.com/gajus/eslint-plugin-jsdoc/compare/v30.7.13...v31.0.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-11 12:04:14 -08:00
TÖRÖK Attila cce3a8199d web: Add a config option to disable the message about unsupported content 2021-01-10 16:02:23 -08:00
relrelb 828d8b7339
demo: General refactor
General cleanup and refactoring of the web demo
2021-01-09 19:36:05 -08:00
Toad06 b81fb64be9 web: Prevent "414 URI Too Long" error on Github when reporting bugs 2021-01-07 11:51:00 -08:00
Mike Welsh 01aca9f861 web: Remove upgrade_to_https param from Ruffle::new
Grab it from the `config` directly instead of using an extra param.
2021-01-07 11:46:07 -08:00
Mike Welsh 8728804f28 web: Add letterbox config option 2021-01-07 11:46:07 -08:00
Toad06 24362d72e3
web: Fix minor issues in `ruffle-player.ts` 2021-01-06 12:04:03 -08:00
Toad06 201d014edb web: Read the `allowScriptAccess` property from `embed` tags 2021-01-04 13:08:02 -08:00
dependabot-preview[bot] 338e43888a build(deps-dev): bump typescript from 4.0.5 to 4.1.3 in /web
Bumps [typescript](https://github.com/Microsoft/TypeScript) from 4.0.5 to 4.1.3.
- [Release notes](https://github.com/Microsoft/TypeScript/releases)
- [Commits](https://github.com/Microsoft/TypeScript/compare/v4.0.5...v4.1.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2021-01-03 02:01:54 -08:00
Toad06 3ae9ad57fc web: Prevent crashes when native `Window` is overridden 2020-12-30 13:18:13 -08:00
Mike Welsh 3ea8c2fc7e chore: Fix typedoc config for typedoc 0.20 2020-12-29 17:27:48 -08:00
dependabot-preview[bot] 268ed44d6d build(deps-dev): bump typedoc from 0.19.2 to 0.20.0 in /web
Bumps [typedoc](https://github.com/TypeStrong/TypeDoc) from 0.19.2 to 0.20.0.
- [Release notes](https://github.com/TypeStrong/TypeDoc/releases)
- [Commits](https://github.com/TypeStrong/TypeDoc/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-12-28 12:53:16 -08:00
Sam Morrow 38bdb8b39a web/desktop: Add basic dialog handling (closes #1978) 2020-12-23 19:08:18 -08:00
Toad06 777734f6ba web: Maintain compatibility with prototype.js 2020-12-21 16:26:14 -08:00
Toad06 a6b7474a6b web: Prevent crashes with external libraries 2020-12-20 15:28:52 -08:00
dependabot-preview[bot] 5503399545 build(deps-dev): bump @wdio/cli from 6.10.5 to 6.10.11 in /web
Bumps [@wdio/cli](https://github.com/webdriverio/webdriverio) from 6.10.5 to 6.10.11.
- [Release notes](https://github.com/webdriverio/webdriverio/releases)
- [Changelog](https://github.com/webdriverio/webdriverio/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webdriverio/webdriverio/compare/v6.10.5...v6.10.11)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-12-19 13:19:11 -08:00
Toad06 d6a857803a web: Fix extension and self-hosted builds conflicting with each other 2020-12-17 12:48:32 -08:00
JMcKiern 63be0455a8
web: Add query string to `Report Bug` link
* web: Add query string to the Report Bug link (closes #1753)
2020-12-14 11:25:10 -08:00
Sam Morrow c4d7b24629 web: Fix cors issues with http (close ruffle-rs#1486) 2020-12-14 05:51:28 -08:00
Toad06 d55f3959b9 web: Detect file extension using the `URL()` constructor 2020-12-13 15:38:18 -08:00
Toad06 5d55a60924
web: Avoid double polyfilling object-inside-object
* web: Avoid double polyfilling object-inside-object
* tests: Add polyfill test for object inside object
2020-12-10 13:36:40 -08:00
Toad06 07d3e7d81b web: Use nullish coalescing operator 2020-12-09 17:01:20 -08:00
Toad06 4ed2470068 web: Fix possible issue with iframe elements no longer existing in the DOM 2020-12-09 17:01:20 -08:00
Toad06 1e61093e32 web: Fix issues with iframe polyfill 2020-12-09 17:01:20 -08:00
techboyg5 021194875a Open shadow DOM 2020-12-07 17:57:15 -08:00
Toad06 3ca08c881f docs: Update `streamSwfUrl` to `load` 2020-12-07 15:22:51 -08:00
Toad06 fc565e2cd6 web: Don't polyfill an object tag if it already contains a ruffle-embed 2020-11-28 14:43:39 -08:00
IWumboYouWumbo b6c0809224 web: Explicitly define font size of context menu 2020-11-27 15:44:24 -08:00
Mike Welsh e66fc6f6a1 web: Avoid double polyfilling embed-inside-object 2020-11-26 18:19:57 -08:00
IWumboYouWumbo 9501ff06b0
web: Refinements to meta user interface (attempt 2)
- Fonts are no longer inherited, Arial is used instead
- Play button is smaller and shares same styling as unmute button
- Context menu text is always aligned to the left
- Panic screen text displays in white instead of black (it's much easier to read this way)
- CSS is cleaner and less redundant
I'm iffy on the changes to the play button aesthetic (it ranges from translucent -> opaque instead of opaque -> brighter opaque) so opinions are welcome.
- Fixed context menu hover issue, added drop shadow
- More redundancy fixes
2020-11-25 20:49:38 -08:00
Nathan Adams c13d5e349b web: Move autoplay/unmuteOverlay from Config to BaseLoadOptions - and made config default the load options 2020-11-25 11:33:51 -08:00
Nathan Adams 797dd83766 web: Merge streamSwfUrl and streamSwfData into load 2020-11-25 11:33:51 -08:00
Nathan Adams a02a81f80f web: Fixed extension & local not detecting eachother correctly 2020-11-24 16:36:33 -08:00
Nathan Adams bcfe59c351 web: Rename Config.public_paths to Config.publicPaths 2020-11-24 16:36:33 -08:00
Nathan Adams 707788218d web: Rename Config.public_path to Config.publicPath 2020-11-24 16:36:33 -08:00
Nathan Adams 103f0d69e8 web: Default autoplay to 'auto' 2020-11-24 16:36:33 -08:00
Nathan Adams cc81122fd8 web: Make sure player config takes priority over global config 2020-11-24 16:36:33 -08:00
Nathan Adams 799c0955b3 web: Add options for autoplay
This is a rewritten version of PR #1161 by Toad06
2020-11-24 16:36:33 -08:00
Nathan Adams a03b2fdea6 web: Add mute overlay
Original code by Toad06 as part of PR #1161
2020-11-24 16:36:33 -08:00
Nathan Adams 3e084963c6 web: Embed build/version info inside the js 2020-11-24 16:36:33 -08:00
Nathan Adams 7a3273a269 web: Add 'docs' command to generate jsdocs 2020-11-24 16:36:33 -08:00
Nathan Adams f5667fc987 web: Fix up documentation to reflect the new state of core vs selfhosted (basically npm vs manual) 2020-11-24 16:36:33 -08:00
Nathan Adams 40bcd3f835 web: Remove no longer needed webpack config in core 2020-11-24 16:36:33 -08:00
Nathan Adams 10db305988 web: Enforce (sensible) documentation 2020-11-24 16:36:33 -08:00
Nathan Adams f1eabe1594 web: Rename install_plugin to installPlugin 2020-11-24 16:36:33 -08:00
Nathan Adams 6a9d0f64e9 web: Rename load_ruffle to loadRuffle 2020-11-24 16:36:33 -08:00
Nathan Adams 8c36e02dc5 web: Rename fetch_ruffle to fetchRuffle 2020-11-24 16:36:33 -08:00
Nathan Adams 41bf30efc8 web: Rename public_path to publicPath 2020-11-24 16:36:33 -08:00
Nathan Adams bccdaf77d4 web: Enforce camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 1519642a9a web: Fix documentation and warnings inside plugin-polyfill 2020-11-24 16:36:33 -08:00
Nathan Adams 48aa26460d web: Rename methods/variables inside polyfills to be camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 1bf4f5c4e4 web: Rename plugin_polyfill to pluginPolyfill 2020-11-24 16:36:33 -08:00
Nathan Adams dcf2b712b2 web: Fix documentation and warnings in polyfills 2020-11-24 16:36:33 -08:00
Nathan Adams d2d8bc6f01 web: Properly document and define window.RufflePlayer 2020-11-24 16:36:33 -08:00
Nathan Adams 2c952e954d web: Renamed fields and variables inside PublicAPI to camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 950d19d1c5 web: Allow taking in "conflict" APIs 2020-11-24 16:36:33 -08:00
Nathan Adams af01621484 web: Rename PublicAPI.local_compatible to PublicAPI.localCompatible 2020-11-24 16:36:33 -08:00
Nathan Adams 980590cf96 web: Rename PublicAPI.newest_source_name to PublicAPI.newestSourceName 2020-11-24 16:36:33 -08:00
Nathan Adams d6afe2edd3 web: Rename PublicAPI.register_source to PublicAPI.registerSource 2020-11-24 16:36:33 -08:00
Nathan Adams f4a710c806 web: Make PublicAPI use Config 2020-11-24 16:36:33 -08:00
Nathan Adams 96d3c30b5e web: Move Config to its own file 2020-11-24 16:36:33 -08:00
Nathan Adams 456557ec20 web: Fix documentation and warnings in PublicAPI 2020-11-24 16:36:33 -08:00
Nathan Adams 5f02ee3ab8 web: Fixed documentation and warnings inside public-path 2020-11-24 16:36:33 -08:00
Nathan Adams ca96553cf0 web: Rename register_element to registerElement 2020-11-24 16:36:33 -08:00
Nathan Adams 32abd35642 web: Changed variables inside RuffleEmbled to be camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 5a1fb5fba1 web: Rename RuffleEmbed.from_native_embed_element to
RuffleEmbed.fromNativeEmbedElement
2020-11-24 16:36:33 -08:00
Nathan Adams f1b05716dd web: Rename RuffleEmbed.is_interdictable to RuffleEmbed.isInterdictable 2020-11-24 16:36:33 -08:00
Nathan Adams 868548ddc6 web: Fixed documentation and warnings inside RuffleEmbed 2020-11-24 16:36:33 -08:00
Nathan Adams 976ef86da7 web: Rename variables in RuffleObject to camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 9f8dd465ae web: Rename RuffleObject.from_native_object_element to
RuffleObject.fromNativeObjectElement
2020-11-24 16:36:33 -08:00
Nathan Adams 9633073c1f web: Rename RuffleObject.is_interdictable to
RuffleObject.isInterdictable
2020-11-24 16:36:33 -08:00
Nathan Adams 879fa53417 web: Ignore ruffle-imports, it's not an API 2020-11-24 16:36:33 -08:00
Nathan Adams 5b5091b4b9 web: Rename copy_to_audio_buffer to copyToAudioBuffer 2020-11-24 16:36:33 -08:00
Nathan Adams 68ffc95348 web: Move RuffleObject.params_of to paramsOf (no longer a static member) 2020-11-24 16:36:33 -08:00
Nathan Adams 3faf09696d web: Move RuffleObject.find_case_insensitive to findCaseInsensitive (no
longer a static member)
2020-11-24 16:36:33 -08:00
Nathan Adams f44f2ea9db web: Fix documentation and warnings in RuffleObject 2020-11-24 16:36:33 -08:00
Nathan Adams 7bd4308c22 web: Renamed variables inside register-element to be camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams eaa6dc70f4 web: Rename Registration.internal_name to Registration.internalName 2020-11-24 16:36:33 -08:00
Nathan Adams 87d3bf57bd web: Fixed documentation and warnings inside register_element 2020-11-24 16:36:33 -08:00
Nathan Adams 62ddc7c9cd web: Rename lookup_element to lookupElement 2020-11-24 16:36:33 -08:00
Nathan Adams 5c1a8ecd94 web: Rename private_registry to privateRegistry 2020-11-24 16:36:33 -08:00
Nathan Adams f8486f00f3 web: Rename RufflePlayer.sanitize_parameters to
RufflePlayer.sanitizeParameters
2020-11-24 16:36:33 -08:00
Nathan Adams 8b5f1eee2f web: Rename all variables inside RufflePlayer to be camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 6e191f2893 web: Rename RufflePlayer.allow_script_access to
RufflePlayer.allowScriptAccess
2020-11-24 16:36:33 -08:00
Nathan Adams 1371a89d1a web: Rename RufflePlayer.is_swf_filename to RufflePlayer.isSwfFilename 2020-11-24 16:36:33 -08:00
Nathan Adams 2e83dad798 web: Rename RufflePlayer.debug_player_info to
RufflePlayer.debugPlayerInfo
2020-11-24 16:36:33 -08:00
Nathan Adams d21cb8473b web: Rename RufflePlayer.trace_observer to RufflePlayer.traceObserver 2020-11-24 16:36:33 -08:00
Nathan Adams 3ad4c0f392 web: Rename RufflePlayer.on_callback_available to
RufflePlayer.onCallbackAvailable
2020-11-24 16:36:33 -08:00
Nathan Adams 8c7f728215 web: Rename RufflePlayer.html_dimension_to_css_dimension to
RufflePlayer.htmlDimensionToCssDimension
2020-11-24 16:36:33 -08:00
Nathan Adams 95a22c486d web: Rename RufflePlayer.copy_element to RufflePlayer.copyElement 2020-11-24 16:36:33 -08:00
Nathan Adams abb311670f web: Rename RufflePlayer.play_swf_data to RufflePlayer.playSwfData 2020-11-24 16:36:33 -08:00
Nathan Adams 2e8e89c52b web: Rename RufflePlayer.hide_right_click_menu to
RufflePlayer.hideRightClickMenu
2020-11-24 16:36:33 -08:00
Nathan Adams 85735d3a45 web: Rename RufflePlayer.open_right_click_menu to
RufflePlayer.openRightClickMenu
2020-11-24 16:36:33 -08:00
Nathan Adams 37ef9c15b4 web: Rename RufflePlayer.play_button_clicked to
RufflePlayer.playButtonClicked
2020-11-24 16:36:33 -08:00
Nathan Adams 4f297948d0 web: Rename RufflePlayer.stream_swf_url to RufflePlayer.streamSwfUrl 2020-11-24 16:36:33 -08:00
Nathan Adams f692ee36a5 web: Rename RufflePlayer.ensure_fresh_instance to
RufflePlayer.ensureFreshInstance
2020-11-24 16:36:33 -08:00
Nathan Adams 4540b73d68 web: Rename RufflePlayer.is_unused_fallback_object to
RufflePlayer.isUnusedFallbackObject
2020-11-24 16:36:33 -08:00
Nathan Adams d0030e6ea7 web: Rename RufflePlayer.update_styles to RufflePlayer.updateStyles 2020-11-24 16:36:33 -08:00
Nathan Adams a25a298277 web: Fixed up documentation and return types inside RufflePlayer 2020-11-24 16:36:33 -08:00
Nathan Adams 96acde5445 web: Rename ShadowTemplate.ruffle_shadow_template to
ShadowTemplate.ruffleShadowTemplate
2020-11-24 16:36:33 -08:00
Nathan Adams f869812464 web: Fixed up documentation and return types inside SourceAPI 2020-11-24 16:36:33 -08:00
Nathan Adams bc3b6ade4e web: Rename SourceAPI.create_player to SourceAPI.createPlayer 2020-11-24 16:36:33 -08:00
Nathan Adams d6478c7d6a web: Rename SourceAPI.plugin_polyfill to SourceAPI.pluginPolyfill 2020-11-24 16:36:33 -08:00
Nathan Adams 3a470b02cc web: Fixed up documentation and return types inside SourceAPI 2020-11-24 16:36:33 -08:00
Nathan Adams 442e3f4f51 web: Renamed local variables inside VersionRange to be camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams 8fab9e25b1 web: Rename VersionRange.from_requirement_string to
VersionRange.fromRequirementString
2020-11-24 16:36:33 -08:00
Nathan Adams 376aeef1af web: Rename VersionRange.satisfied_by to VersionRange.satisfiedBy 2020-11-24 16:36:33 -08:00
Nathan Adams 77f7518cda web: Fixed up documentation and return types inside VersionRange 2020-11-24 16:36:33 -08:00
Nathan Adams cf8686a0b5 web: Renamed local variables inside Version to be camelCase 2020-11-24 16:36:33 -08:00
Nathan Adams a0817e48b0 web: Rename Version.is_stable_or_compatible_prerelease to
Version.isStableOrCompatiblePrerelease
2020-11-24 16:36:33 -08:00
Nathan Adams 6952197004 web: Rename Version.is_equal to Version.isEqual 2020-11-24 16:36:33 -08:00
Nathan Adams f3efc5c80a web: Rename Version.has_precedence_over to Version.hasPrecedenceOver 2020-11-24 16:36:33 -08:00
Nathan Adams ce6288fda8 web: Rename Version.is_compatible_with to Version.isCompatibleWith 2020-11-24 16:36:33 -08:00
Nathan Adams d2e6ae50a9 web: Rename Version.from_semver to Version.fromSemver 2020-11-24 16:36:33 -08:00
Nathan Adams 548fe6d172 web: Rename Version.build_ident to Version.buildIdent 2020-11-24 16:36:33 -08:00
Nathan Adams e5cd299009 web: Rename Version.pr_ident to Version.prIdent 2020-11-24 16:36:33 -08:00
Nathan Adams 022881f9c6 web: Fix up documentation in Version, resolved warnings 2020-11-24 16:36:33 -08:00
Nathan Adams 8abb8df299 web: core no longer uses webpack, but selfhosted still does 2020-11-24 16:36:33 -08:00
Nathan Adams 7701ef9c26 web: Make tests in core use typescript 2020-11-24 16:36:33 -08:00
Nathan Adams 5ff7168fe9 web: Switched core package from javascript to typescript 2020-11-24 16:36:33 -08:00