From 3b91202423c71f5b249c5f316db42749d102c0f3 Mon Sep 17 00:00:00 2001 From: RunDevelopment Date: Fri, 29 Nov 2024 21:27:18 +0100 Subject: [PATCH 1/3] Add support for `no_export` for string enums --- crates/backend/src/ast.rs | 4 ++++ crates/backend/src/encode.rs | 2 ++ crates/cli-support/src/js/mod.rs | 13 ++++++++----- crates/cli-support/src/wit/mod.rs | 2 ++ crates/cli-support/src/wit/nonstandard.rs | 4 ++++ crates/cli/tests/reference/enums.d.ts | 8 +++++++- crates/cli/tests/reference/enums.js | 10 ++++++++++ crates/cli/tests/reference/enums.rs | 12 ++++++++++++ crates/cli/tests/reference/enums.wat | 15 +++++++++------ crates/macro-support/src/parser.rs | 17 ++++++++++++++++- crates/shared/src/lib.rs | 2 ++ crates/web-sys/src/features/gen_AlignSetting.rs | 2 +- crates/web-sys/src/features/gen_AlphaOption.rs | 2 +- .../src/features/gen_AnimationPlayState.rs | 2 +- .../gen_AttestationConveyancePreference.rs | 2 +- .../features/gen_AudioContextLatencyCategory.rs | 2 +- .../src/features/gen_AudioContextState.rs | 2 +- .../src/features/gen_AudioSampleFormat.rs | 2 +- .../web-sys/src/features/gen_AudioSinkType.rs | 2 +- .../src/features/gen_AuthenticatorAttachment.rs | 2 +- .../src/features/gen_AuthenticatorTransport.rs | 2 +- crates/web-sys/src/features/gen_AutoKeyword.rs | 2 +- .../web-sys/src/features/gen_BasicCardType.rs | 2 +- crates/web-sys/src/features/gen_BinaryType.rs | 2 +- .../src/features/gen_BiquadFilterType.rs | 2 +- .../features/gen_BrowserFindCaseSensitivity.rs | 2 +- .../src/features/gen_BrowserFindDirection.rs | 2 +- .../src/features/gen_CacheStorageNamespace.rs | 2 +- .../src/features/gen_CanvasWindingRule.rs | 2 +- .../src/features/gen_CaretChangedReason.rs | 2 +- .../src/features/gen_ChannelCountMode.rs | 2 +- .../src/features/gen_ChannelInterpretation.rs | 2 +- .../src/features/gen_CheckerboardReason.rs | 2 +- crates/web-sys/src/features/gen_ClientType.rs | 2 +- crates/web-sys/src/features/gen_CodecState.rs | 2 +- .../src/features/gen_ColorSpaceConversion.rs | 2 +- .../src/features/gen_CompositeOperation.rs | 2 +- .../src/features/gen_CompressionFormat.rs | 2 +- .../web-sys/src/features/gen_ConnectionType.rs | 2 +- crates/web-sys/src/features/gen_ConsoleLevel.rs | 2 +- .../web-sys/src/features/gen_ConsoleLogLevel.rs | 2 +- crates/web-sys/src/features/gen_CssBoxType.rs | 2 +- .../features/gen_CssStyleSheetParsingMode.rs | 2 +- .../gen_DecoderDoctorNotificationType.rs | 2 +- .../src/features/gen_DirectionSetting.rs | 2 +- .../src/features/gen_DistanceModelType.rs | 2 +- .../src/features/gen_DomRequestReadyState.rs | 2 +- .../src/features/gen_EncodedAudioChunkType.rs | 2 +- .../src/features/gen_EncodedVideoChunkType.rs | 2 +- crates/web-sys/src/features/gen_EndingTypes.rs | 2 +- crates/web-sys/src/features/gen_FetchState.rs | 2 +- .../src/features/gen_FileSystemHandleKind.rs | 2 +- .../features/gen_FileSystemPermissionMode.rs | 2 +- crates/web-sys/src/features/gen_FillMode.rs | 2 +- .../src/features/gen_FlashClassification.rs | 2 +- .../web-sys/src/features/gen_FlowControlType.rs | 2 +- .../src/features/gen_FontFaceLoadStatus.rs | 2 +- .../src/features/gen_FontFaceSetLoadStatus.rs | 2 +- crates/web-sys/src/features/gen_FrameType.rs | 2 +- crates/web-sys/src/features/gen_GamepadHand.rs | 2 +- .../features/gen_GamepadHapticActuatorType.rs | 2 +- .../src/features/gen_GamepadHapticEffectType.rs | 2 +- .../src/features/gen_GamepadHapticsResult.rs | 2 +- .../src/features/gen_GamepadMappingType.rs | 2 +- .../web-sys/src/features/gen_GpuAddressMode.rs | 2 +- .../src/features/gen_GpuAutoLayoutMode.rs | 2 +- .../web-sys/src/features/gen_GpuBlendFactor.rs | 2 +- .../src/features/gen_GpuBlendOperation.rs | 2 +- .../src/features/gen_GpuBufferBindingType.rs | 2 +- .../src/features/gen_GpuBufferMapState.rs | 2 +- .../src/features/gen_GpuCanvasAlphaMode.rs | 2 +- .../features/gen_GpuCanvasToneMappingMode.rs | 2 +- .../src/features/gen_GpuCompareFunction.rs | 2 +- .../features/gen_GpuCompilationMessageType.rs | 2 +- crates/web-sys/src/features/gen_GpuCullMode.rs | 2 +- .../src/features/gen_GpuDeviceLostReason.rs | 2 +- .../web-sys/src/features/gen_GpuErrorFilter.rs | 2 +- .../web-sys/src/features/gen_GpuFeatureName.rs | 2 +- .../web-sys/src/features/gen_GpuFilterMode.rs | 2 +- crates/web-sys/src/features/gen_GpuFrontFace.rs | 2 +- .../web-sys/src/features/gen_GpuIndexFormat.rs | 2 +- crates/web-sys/src/features/gen_GpuLoadOp.rs | 2 +- .../src/features/gen_GpuMipmapFilterMode.rs | 2 +- .../src/features/gen_GpuPipelineErrorReason.rs | 2 +- .../src/features/gen_GpuPowerPreference.rs | 2 +- .../src/features/gen_GpuPrimitiveTopology.rs | 2 +- crates/web-sys/src/features/gen_GpuQueryType.rs | 2 +- .../src/features/gen_GpuSamplerBindingType.rs | 2 +- .../src/features/gen_GpuStencilOperation.rs | 2 +- .../src/features/gen_GpuStorageTextureAccess.rs | 2 +- crates/web-sys/src/features/gen_GpuStoreOp.rs | 2 +- .../src/features/gen_GpuTextureAspect.rs | 2 +- .../src/features/gen_GpuTextureDimension.rs | 2 +- .../src/features/gen_GpuTextureFormat.rs | 2 +- .../src/features/gen_GpuTextureSampleType.rs | 2 +- .../src/features/gen_GpuTextureViewDimension.rs | 2 +- .../web-sys/src/features/gen_GpuVertexFormat.rs | 2 +- .../src/features/gen_GpuVertexStepMode.rs | 2 +- .../src/features/gen_HardwareAcceleration.rs | 2 +- .../src/features/gen_HeadersGuardEnum.rs | 2 +- .../web-sys/src/features/gen_HidUnitSystem.rs | 2 +- .../src/features/gen_IdbCursorDirection.rs | 2 +- .../src/features/gen_IdbRequestReadyState.rs | 2 +- .../features/gen_IdbTransactionDurability.rs | 2 +- .../src/features/gen_IdbTransactionMode.rs | 2 +- .../src/features/gen_ImageOrientation.rs | 2 +- .../features/gen_IterationCompositeOperation.rs | 2 +- .../src/features/gen_LargeBlobSupport.rs | 2 +- crates/web-sys/src/features/gen_LatencyMode.rs | 2 +- .../src/features/gen_LineAlignSetting.rs | 2 +- crates/web-sys/src/features/gen_LockMode.rs | 2 +- .../src/features/gen_MediaDecodingType.rs | 2 +- .../web-sys/src/features/gen_MediaDeviceKind.rs | 2 +- .../src/features/gen_MediaEncodingType.rs | 2 +- .../src/features/gen_MediaKeyMessageType.rs | 2 +- .../src/features/gen_MediaKeySessionType.rs | 2 +- .../web-sys/src/features/gen_MediaKeyStatus.rs | 2 +- .../src/features/gen_MediaKeySystemStatus.rs | 2 +- .../src/features/gen_MediaKeysRequirement.rs | 2 +- .../src/features/gen_MediaSessionAction.rs | 2 +- .../features/gen_MediaSessionPlaybackState.rs | 2 +- .../features/gen_MediaSourceEndOfStreamError.rs | 2 +- .../web-sys/src/features/gen_MediaSourceEnum.rs | 2 +- .../src/features/gen_MediaSourceReadyState.rs | 2 +- .../src/features/gen_MediaStreamTrackState.rs | 2 +- .../src/features/gen_MidiPortConnectionState.rs | 2 +- .../src/features/gen_MidiPortDeviceState.rs | 2 +- crates/web-sys/src/features/gen_MidiPortType.rs | 2 +- .../web-sys/src/features/gen_NavigationType.rs | 2 +- .../src/features/gen_NotificationDirection.rs | 2 +- .../src/features/gen_NotificationPermission.rs | 2 +- .../src/features/gen_OrientationLockType.rs | 2 +- .../web-sys/src/features/gen_OrientationType.rs | 2 +- .../web-sys/src/features/gen_OscillatorType.rs | 2 +- .../web-sys/src/features/gen_OverSampleType.rs | 2 +- .../src/features/gen_PanningModelType.rs | 2 +- crates/web-sys/src/features/gen_ParityType.rs | 2 +- .../web-sys/src/features/gen_PaymentComplete.rs | 2 +- .../features/gen_PcImplIceConnectionState.rs | 2 +- .../src/features/gen_PcImplIceGatheringState.rs | 2 +- .../src/features/gen_PcImplSignalingState.rs | 2 +- .../src/features/gen_PcObserverStateType.rs | 2 +- .../web-sys/src/features/gen_PermissionName.rs | 2 +- .../web-sys/src/features/gen_PermissionState.rs | 2 +- .../src/features/gen_PlaybackDirection.rs | 2 +- .../src/features/gen_PositionAlignSetting.rs | 2 +- .../src/features/gen_PremultiplyAlpha.rs | 2 +- .../gen_PresentationConnectionBinaryType.rs | 2 +- .../gen_PresentationConnectionClosedReason.rs | 2 +- .../features/gen_PresentationConnectionState.rs | 2 +- .../src/features/gen_PresentationStyle.rs | 2 +- ...n_ProfileTimelineMessagePortOperationType.rs | 2 +- .../gen_ProfileTimelineWorkerOperationType.rs | 2 +- .../features/gen_PublicKeyCredentialHints.rs | 2 +- .../src/features/gen_PublicKeyCredentialType.rs | 2 +- .../src/features/gen_PushEncryptionKeyName.rs | 2 +- .../src/features/gen_PushPermissionState.rs | 2 +- .../features/gen_ReadableStreamReaderMode.rs | 2 +- .../src/features/gen_ReadableStreamType.rs | 2 +- .../web-sys/src/features/gen_RecordingState.rs | 2 +- .../web-sys/src/features/gen_ReferrerPolicy.rs | 2 +- crates/web-sys/src/features/gen_RequestCache.rs | 2 +- .../src/features/gen_RequestCredentials.rs | 2 +- .../src/features/gen_RequestDestination.rs | 2 +- crates/web-sys/src/features/gen_RequestMode.rs | 2 +- .../web-sys/src/features/gen_RequestRedirect.rs | 2 +- .../src/features/gen_ResidentKeyRequirement.rs | 2 +- .../features/gen_ResizeObserverBoxOptions.rs | 2 +- .../web-sys/src/features/gen_ResizeQuality.rs | 2 +- crates/web-sys/src/features/gen_ResponseType.rs | 2 +- .../web-sys/src/features/gen_RtcBundlePolicy.rs | 2 +- .../src/features/gen_RtcDataChannelState.rs | 2 +- .../src/features/gen_RtcDataChannelType.rs | 2 +- .../features/gen_RtcDegradationPreference.rs | 2 +- .../features/gen_RtcEncodedVideoFrameType.rs | 2 +- .../src/features/gen_RtcIceConnectionState.rs | 2 +- .../src/features/gen_RtcIceCredentialType.rs | 2 +- .../src/features/gen_RtcIceGatheringState.rs | 2 +- .../src/features/gen_RtcIceTransportPolicy.rs | 2 +- .../src/features/gen_RtcPeerConnectionState.rs | 2 +- .../web-sys/src/features/gen_RtcPriorityType.rs | 2 +- .../src/features/gen_RtcRtpSourceEntryType.rs | 2 +- .../features/gen_RtcRtpTransceiverDirection.rs | 2 +- crates/web-sys/src/features/gen_RtcSdpType.rs | 2 +- .../src/features/gen_RtcSignalingState.rs | 2 +- .../gen_RtcStatsIceCandidatePairState.rs | 2 +- .../features/gen_RtcStatsIceCandidateType.rs | 2 +- crates/web-sys/src/features/gen_RtcStatsType.rs | 2 +- .../gen_SFrameTransformErrorEventType.rs | 2 +- .../src/features/gen_SFrameTransformRole.rs | 2 +- .../src/features/gen_ScreenColorGamut.rs | 2 +- .../web-sys/src/features/gen_ScrollBehavior.rs | 2 +- .../src/features/gen_ScrollLogicalPosition.rs | 2 +- .../src/features/gen_ScrollRestoration.rs | 2 +- .../web-sys/src/features/gen_ScrollSetting.rs | 2 +- crates/web-sys/src/features/gen_ScrollState.rs | 2 +- ...n_SecurityPolicyViolationEventDisposition.rs | 2 +- .../web-sys/src/features/gen_SelectionMode.rs | 2 +- .../src/features/gen_ServiceWorkerState.rs | 2 +- .../features/gen_ServiceWorkerUpdateViaCache.rs | 2 +- .../web-sys/src/features/gen_ShadowRootMode.rs | 2 +- .../src/features/gen_SocketReadyState.rs | 2 +- .../src/features/gen_SourceBufferAppendMode.rs | 2 +- .../features/gen_SpeechRecognitionErrorCode.rs | 2 +- .../features/gen_SpeechSynthesisErrorCode.rs | 2 +- crates/web-sys/src/features/gen_StorageType.rs | 2 +- .../web-sys/src/features/gen_SupportedType.rs | 2 +- crates/web-sys/src/features/gen_TaskPriority.rs | 2 +- .../web-sys/src/features/gen_TcpReadyState.rs | 2 +- .../src/features/gen_TcpSocketBinaryType.rs | 2 +- .../web-sys/src/features/gen_TextTrackKind.rs | 2 +- .../web-sys/src/features/gen_TextTrackMode.rs | 2 +- .../src/features/gen_TokenBindingStatus.rs | 2 +- crates/web-sys/src/features/gen_Transport.rs | 2 +- crates/web-sys/src/features/gen_UsbDirection.rs | 2 +- .../web-sys/src/features/gen_UsbEndpointType.rs | 2 +- crates/web-sys/src/features/gen_UsbRecipient.rs | 2 +- .../web-sys/src/features/gen_UsbRequestType.rs | 2 +- .../src/features/gen_UsbTransferStatus.rs | 2 +- .../features/gen_UserVerificationRequirement.rs | 2 +- .../src/features/gen_VideoColorPrimaries.rs | 2 +- .../src/features/gen_VideoFacingModeEnum.rs | 2 +- .../src/features/gen_VideoMatrixCoefficients.rs | 2 +- .../src/features/gen_VideoPixelFormat.rs | 2 +- .../gen_VideoTransferCharacteristics.rs | 2 +- .../web-sys/src/features/gen_VisibilityState.rs | 2 +- crates/web-sys/src/features/gen_VrEye.rs | 2 +- crates/web-sys/src/features/gen_WakeLockType.rs | 2 +- .../src/features/gen_WebGlPowerPreference.rs | 2 +- .../gen_WebTransportCongestionControl.rs | 2 +- .../src/features/gen_WebTransportErrorSource.rs | 2 +- .../features/gen_WebTransportReliabilityMode.rs | 2 +- .../src/features/gen_WellKnownDirectory.rs | 2 +- crates/web-sys/src/features/gen_WorkerType.rs | 2 +- .../src/features/gen_WriteCommandType.rs | 2 +- .../features/gen_XmlHttpRequestResponseType.rs | 2 +- crates/web-sys/src/features/gen_XrEye.rs | 2 +- crates/web-sys/src/features/gen_XrHandJoint.rs | 2 +- crates/web-sys/src/features/gen_XrHandedness.rs | 2 +- .../src/features/gen_XrReferenceSpaceType.rs | 2 +- .../web-sys/src/features/gen_XrSessionMode.rs | 2 +- .../web-sys/src/features/gen_XrTargetRayMode.rs | 2 +- .../src/features/gen_XrVisibilityState.rs | 2 +- crates/webidl/src/generator.rs | 2 +- 244 files changed, 309 insertions(+), 246 deletions(-) diff --git a/crates/backend/src/ast.rs b/crates/backend/src/ast.rs index 0507f055306..9bbba9647d3 100644 --- a/crates/backend/src/ast.rs +++ b/crates/backend/src/ast.rs @@ -360,6 +360,8 @@ pub struct StringEnum { pub rust_attrs: Vec, /// Whether to generate a typescript definition for this enum pub generate_typescript: bool, + /// Whether the type should not be exported in JS/TS. + pub no_export: bool, /// Path to wasm_bindgen pub wasm_bindgen: Path, } @@ -467,6 +469,8 @@ pub struct Enum { pub hole: u32, /// Whether to generate a typescript definition for this enum pub generate_typescript: bool, + /// Whether the type should not be exported in JS/TS. + pub no_export: bool, /// Path to wasm_bindgen pub wasm_bindgen: Path, } diff --git a/crates/backend/src/encode.rs b/crates/backend/src/encode.rs index d98fe628450..fd898ac2932 100644 --- a/crates/backend/src/encode.rs +++ b/crates/backend/src/encode.rs @@ -247,6 +247,7 @@ fn shared_enum<'a>(e: &'a ast::Enum, intern: &'a Interner) -> Enum<'a> { .collect(), comments: e.comments.iter().map(|s| &**s).collect(), generate_typescript: e.generate_typescript, + no_export: e.no_export, } } @@ -364,6 +365,7 @@ fn shared_import_enum<'a>(i: &'a ast::StringEnum, _intern: &'a Interner) -> Stri StringEnum { name: &i.js_name, generate_typescript: i.generate_typescript, + no_export: i.no_export, variant_values: i.variant_values.iter().map(|x| &**x).collect(), comments: i.comments.iter().map(|s| &**s).collect(), } diff --git a/crates/cli-support/src/js/mod.rs b/crates/cli-support/src/js/mod.rs index 72b0273d71f..555f721697a 100644 --- a/crates/cli-support/src/js/mod.rs +++ b/crates/cli-support/src/js/mod.rs @@ -3973,11 +3973,11 @@ __wbg_set_wasm(wasm);" .map(|v| format!("\"{v}\"")) .collect(); - if string_enum.generate_typescript - && self - .typescript_refs - .contains(&TsReference::StringEnum(string_enum.name.clone())) - { + let is_used_in_typescript = self + .typescript_refs + .contains(&TsReference::StringEnum(string_enum.name.clone())); + + if string_enum.generate_typescript && (!string_enum.no_export || is_used_in_typescript) { let docs = format_doc_comments(&string_enum.comments, None); let type_expr = if variants.is_empty() { "never".to_string() @@ -3986,6 +3986,9 @@ __wbg_set_wasm(wasm);" }; self.typescript.push_str(&docs); + if !string_enum.no_export { + self.typescript.push_str("export "); + } self.typescript.push_str("type "); self.typescript.push_str(&string_enum.name); self.typescript.push_str(" = "); diff --git a/crates/cli-support/src/wit/mod.rs b/crates/cli-support/src/wit/mod.rs index 2f1d7f52691..2d4cb5ae532 100644 --- a/crates/cli-support/src/wit/mod.rs +++ b/crates/cli-support/src/wit/mod.rs @@ -875,6 +875,7 @@ impl<'a> Context<'a> { .map(|v| v.to_string()) .collect(), generate_typescript: string_enum.generate_typescript, + no_export: string_enum.no_export, }; let mut result = Ok(()); self.aux @@ -909,6 +910,7 @@ impl<'a> Context<'a> { }) .collect(), generate_typescript: enum_.generate_typescript, + no_export: enum_.no_export, }; let mut result = Ok(()); self.aux diff --git a/crates/cli-support/src/wit/nonstandard.rs b/crates/cli-support/src/wit/nonstandard.rs index 35f30a74497..8863b88682f 100644 --- a/crates/cli-support/src/wit/nonstandard.rs +++ b/crates/cli-support/src/wit/nonstandard.rs @@ -173,6 +173,8 @@ pub struct AuxEnum { pub variants: Vec<(String, i64, String)>, /// Whether typescript bindings should be generated for this enum. pub generate_typescript: bool, + /// Whether the type should not be exported in JS/TS. + pub no_export: bool, } #[derive(Debug)] @@ -185,6 +187,8 @@ pub struct AuxStringEnum { pub variant_values: Vec, /// Whether typescript bindings should be generated for this enum. pub generate_typescript: bool, + /// Whether the type should not be exported in JS/TS. + pub no_export: bool, } #[derive(Debug)] diff --git a/crates/cli/tests/reference/enums.d.ts b/crates/cli/tests/reference/enums.d.ts index da84bbb7740..daebc58f510 100644 --- a/crates/cli/tests/reference/enums.d.ts +++ b/crates/cli/tests/reference/enums.d.ts @@ -4,6 +4,7 @@ export function enum_echo(color: Color): Color; export function option_enum_echo(color?: Color): Color | undefined; export function get_name(color: Color): ColorName; export function option_string_enum_echo(color?: ColorName): ColorName | undefined; +export function use_private_enum(): PrivateStringEnum; export function option_order(order?: Ordering): Ordering | undefined; /** * A color. @@ -39,4 +40,9 @@ export enum Ordering { /** * The name of a color. */ -type ColorName = "green" | "yellow" | "red"; +export type ColorName = "green" | "yellow" | "red"; +/** + * An unused string enum. + */ +export type FooBar = "foo" | "bar"; +type PrivateStringEnum = "foo" | "bar"; diff --git a/crates/cli/tests/reference/enums.js b/crates/cli/tests/reference/enums.js index 13459b9c77e..54d2d100bbc 100644 --- a/crates/cli/tests/reference/enums.js +++ b/crates/cli/tests/reference/enums.js @@ -62,6 +62,14 @@ export function option_string_enum_echo(color) { return __wbindgen_enum_ColorName[ret]; } +/** + * @returns {PrivateStringEnum} + */ +export function use_private_enum() { + const ret = wasm.use_private_enum(); + return __wbindgen_enum_PrivateStringEnum[ret]; +} + /** * @param {Ordering | undefined} [order] * @returns {Ordering | undefined} @@ -110,6 +118,8 @@ export const Ordering = Object.freeze({ const __wbindgen_enum_ColorName = ["green", "yellow", "red"]; +const __wbindgen_enum_PrivateStringEnum = ["foo", "bar"]; + export function __wbindgen_init_externref_table() { const table = wasm.__wbindgen_export_0; const offset = table.grow(4); diff --git a/crates/cli/tests/reference/enums.rs b/crates/cli/tests/reference/enums.rs index 553d63d9a4d..b8a92762a80 100644 --- a/crates/cli/tests/reference/enums.rs +++ b/crates/cli/tests/reference/enums.rs @@ -52,12 +52,24 @@ pub enum UnusedStringEnum { Bar = "bar", } +/// An unused string enum. +#[wasm_bindgen(js_name = "FooBarNoExport", no_export)] +pub enum UnusedStringEnumNoExport { + Foo = "foo", + Bar = "bar", +} + #[wasm_bindgen] enum PrivateStringEnum { Foo = "foo", Bar = "bar", } +#[wasm_bindgen] +pub fn use_private_enum() -> PrivateStringEnum { + PrivateStringEnum::Foo +} + #[wasm_bindgen] pub enum ImplicitDiscriminant { A, diff --git a/crates/cli/tests/reference/enums.wat b/crates/cli/tests/reference/enums.wat index 3688c671785..6cc28e43977 100644 --- a/crates/cli/tests/reference/enums.wat +++ b/crates/cli/tests/reference/enums.wat @@ -1,12 +1,14 @@ (module $reference_test.wasm (type (;0;) (func)) - (type (;1;) (func (param i32) (result i32))) + (type (;1;) (func (result i32))) + (type (;2;) (func (param i32) (result i32))) (import "./reference_test_bg.js" "__wbindgen_init_externref_table" (func (;0;) (type 0))) - (func $enum_echo (;1;) (type 1) (param i32) (result i32)) - (func $option_enum_echo (;2;) (type 1) (param i32) (result i32)) - (func $get_name (;3;) (type 1) (param i32) (result i32)) - (func $option_string_enum_echo (;4;) (type 1) (param i32) (result i32)) - (func $option_order (;5;) (type 1) (param i32) (result i32)) + (func $enum_echo (;1;) (type 2) (param i32) (result i32)) + (func $option_enum_echo (;2;) (type 2) (param i32) (result i32)) + (func $get_name (;3;) (type 2) (param i32) (result i32)) + (func $option_string_enum_echo (;4;) (type 2) (param i32) (result i32)) + (func $option_order (;5;) (type 2) (param i32) (result i32)) + (func $use_private_enum (;6;) (type 1) (result i32)) (table (;0;) 128 externref) (memory (;0;) 17) (export "memory" (memory 0)) @@ -14,6 +16,7 @@ (export "option_enum_echo" (func $option_enum_echo)) (export "get_name" (func $get_name)) (export "option_string_enum_echo" (func $option_string_enum_echo)) + (export "use_private_enum" (func $use_private_enum)) (export "option_order" (func $option_order)) (export "__wbindgen_export_0" (table 0)) (export "__wbindgen_start" (func 0)) diff --git a/crates/macro-support/src/parser.rs b/crates/macro-support/src/parser.rs index 9d7ad85a00c..19f02b3c2ca 100644 --- a/crates/macro-support/src/parser.rs +++ b/crates/macro-support/src/parser.rs @@ -92,6 +92,7 @@ macro_rules! attrgen { (js_sys, JsSys(Span, syn::Path)), (wasm_bindgen_futures, WasmBindgenFutures(Span, syn::Path)), (skip, Skip(Span)), + (no_export, NoExport(Span)), (typescript_type, TypeScriptType(Span, String, Span)), (getter_with_clone, GetterWithClone(Span)), (static_string, StaticString(Span)), @@ -1375,6 +1376,7 @@ fn string_enum( program: &mut ast::Program, js_name: String, generate_typescript: bool, + no_export: bool, comments: Vec, ) -> Result<(), Diagnostic> { let mut variants = vec![]; @@ -1414,6 +1416,7 @@ fn string_enum( comments, rust_attrs: enum_.attrs, generate_typescript, + no_export, wasm_bindgen: program.wasm_bindgen.clone(), }), }); @@ -1487,6 +1490,10 @@ impl<'a> MacroParse<(&'a mut TokenStream, BindgenAttrs)> for syn::ItemEnum { .map_or_else(|| self.ident.to_string(), |s| s.to_string()); let comments = extract_doc_comments(&self.attrs); + // don't export private enums and if explicitly requested + let no_export = + opts.no_export().is_some() || !matches!(self.vis, syn::Visibility::Public(_)); + opts.check_used(); // Check if the enum is a string enum, by checking whether any variant has a string discriminant. @@ -1503,7 +1510,14 @@ impl<'a> MacroParse<(&'a mut TokenStream, BindgenAttrs)> for syn::ItemEnum { false }); if is_string_enum { - return string_enum(self, program, js_name, generate_typescript, comments); + return string_enum( + self, + program, + js_name, + generate_typescript, + no_export, + comments, + ); } match self.vis { @@ -1613,6 +1627,7 @@ impl<'a> MacroParse<(&'a mut TokenStream, BindgenAttrs)> for syn::ItemEnum { comments, hole, generate_typescript, + no_export, wasm_bindgen: program.wasm_bindgen.clone(), }); Ok(()) diff --git a/crates/shared/src/lib.rs b/crates/shared/src/lib.rs index cee843079d0..e3280ed66d3 100644 --- a/crates/shared/src/lib.rs +++ b/crates/shared/src/lib.rs @@ -109,6 +109,7 @@ macro_rules! shared_api { variant_values: Vec<&'a str>, comments: Vec<&'a str>, generate_typescript: bool, + no_export: bool, } struct Export<'a> { @@ -126,6 +127,7 @@ macro_rules! shared_api { variants: Vec>, comments: Vec<&'a str>, generate_typescript: bool, + no_export: bool, } struct EnumVariant<'a> { diff --git a/crates/web-sys/src/features/gen_AlignSetting.rs b/crates/web-sys/src/features/gen_AlignSetting.rs index e47fce5f02f..e32df057d2e 100644 --- a/crates/web-sys/src/features/gen_AlignSetting.rs +++ b/crates/web-sys/src/features/gen_AlignSetting.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AlignSetting` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AlignSetting`*"] diff --git a/crates/web-sys/src/features/gen_AlphaOption.rs b/crates/web-sys/src/features/gen_AlphaOption.rs index 82dbef2c1c1..4651cfc6d7d 100644 --- a/crates/web-sys/src/features/gen_AlphaOption.rs +++ b/crates/web-sys/src/features/gen_AlphaOption.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AlphaOption` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AlphaOption`*"] diff --git a/crates/web-sys/src/features/gen_AnimationPlayState.rs b/crates/web-sys/src/features/gen_AnimationPlayState.rs index 70fc25c40cf..24ecc31ea76 100644 --- a/crates/web-sys/src/features/gen_AnimationPlayState.rs +++ b/crates/web-sys/src/features/gen_AnimationPlayState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AnimationPlayState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AnimationPlayState`*"] diff --git a/crates/web-sys/src/features/gen_AttestationConveyancePreference.rs b/crates/web-sys/src/features/gen_AttestationConveyancePreference.rs index c98cb125c86..e6726cbc53b 100644 --- a/crates/web-sys/src/features/gen_AttestationConveyancePreference.rs +++ b/crates/web-sys/src/features/gen_AttestationConveyancePreference.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AttestationConveyancePreference` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AttestationConveyancePreference`*"] diff --git a/crates/web-sys/src/features/gen_AudioContextLatencyCategory.rs b/crates/web-sys/src/features/gen_AudioContextLatencyCategory.rs index c0842efa94a..562b39cf12b 100644 --- a/crates/web-sys/src/features/gen_AudioContextLatencyCategory.rs +++ b/crates/web-sys/src/features/gen_AudioContextLatencyCategory.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AudioContextLatencyCategory` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AudioContextLatencyCategory`*"] diff --git a/crates/web-sys/src/features/gen_AudioContextState.rs b/crates/web-sys/src/features/gen_AudioContextState.rs index 4d15fd86aec..a4e6c79689e 100644 --- a/crates/web-sys/src/features/gen_AudioContextState.rs +++ b/crates/web-sys/src/features/gen_AudioContextState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AudioContextState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AudioContextState`*"] diff --git a/crates/web-sys/src/features/gen_AudioSampleFormat.rs b/crates/web-sys/src/features/gen_AudioSampleFormat.rs index 6c9c0d34ff8..a75a939fc47 100644 --- a/crates/web-sys/src/features/gen_AudioSampleFormat.rs +++ b/crates/web-sys/src/features/gen_AudioSampleFormat.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AudioSampleFormat` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AudioSampleFormat`*"] diff --git a/crates/web-sys/src/features/gen_AudioSinkType.rs b/crates/web-sys/src/features/gen_AudioSinkType.rs index 5e1abf9562c..81e756a1a0a 100644 --- a/crates/web-sys/src/features/gen_AudioSinkType.rs +++ b/crates/web-sys/src/features/gen_AudioSinkType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AudioSinkType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AudioSinkType`*"] diff --git a/crates/web-sys/src/features/gen_AuthenticatorAttachment.rs b/crates/web-sys/src/features/gen_AuthenticatorAttachment.rs index 1ba36251e4a..5fe579061ca 100644 --- a/crates/web-sys/src/features/gen_AuthenticatorAttachment.rs +++ b/crates/web-sys/src/features/gen_AuthenticatorAttachment.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AuthenticatorAttachment` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AuthenticatorAttachment`*"] diff --git a/crates/web-sys/src/features/gen_AuthenticatorTransport.rs b/crates/web-sys/src/features/gen_AuthenticatorTransport.rs index 9b43b08b139..d80d78b4b5e 100644 --- a/crates/web-sys/src/features/gen_AuthenticatorTransport.rs +++ b/crates/web-sys/src/features/gen_AuthenticatorTransport.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AuthenticatorTransport` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AuthenticatorTransport`*"] diff --git a/crates/web-sys/src/features/gen_AutoKeyword.rs b/crates/web-sys/src/features/gen_AutoKeyword.rs index 3ee39ad3351..f1f61b1c526 100644 --- a/crates/web-sys/src/features/gen_AutoKeyword.rs +++ b/crates/web-sys/src/features/gen_AutoKeyword.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `AutoKeyword` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `AutoKeyword`*"] diff --git a/crates/web-sys/src/features/gen_BasicCardType.rs b/crates/web-sys/src/features/gen_BasicCardType.rs index 87d45224e9c..3ac61912f49 100644 --- a/crates/web-sys/src/features/gen_BasicCardType.rs +++ b/crates/web-sys/src/features/gen_BasicCardType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `BasicCardType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `BasicCardType`*"] diff --git a/crates/web-sys/src/features/gen_BinaryType.rs b/crates/web-sys/src/features/gen_BinaryType.rs index aa7ab231dc5..ceb3eb3ad36 100644 --- a/crates/web-sys/src/features/gen_BinaryType.rs +++ b/crates/web-sys/src/features/gen_BinaryType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `BinaryType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `BinaryType`*"] diff --git a/crates/web-sys/src/features/gen_BiquadFilterType.rs b/crates/web-sys/src/features/gen_BiquadFilterType.rs index fbd455d2619..cd5b7a1afed 100644 --- a/crates/web-sys/src/features/gen_BiquadFilterType.rs +++ b/crates/web-sys/src/features/gen_BiquadFilterType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `BiquadFilterType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `BiquadFilterType`*"] diff --git a/crates/web-sys/src/features/gen_BrowserFindCaseSensitivity.rs b/crates/web-sys/src/features/gen_BrowserFindCaseSensitivity.rs index 7e5ad4fddf1..5b887976d36 100644 --- a/crates/web-sys/src/features/gen_BrowserFindCaseSensitivity.rs +++ b/crates/web-sys/src/features/gen_BrowserFindCaseSensitivity.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `BrowserFindCaseSensitivity` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `BrowserFindCaseSensitivity`*"] diff --git a/crates/web-sys/src/features/gen_BrowserFindDirection.rs b/crates/web-sys/src/features/gen_BrowserFindDirection.rs index a45e63cbb91..97e2e8f3d0c 100644 --- a/crates/web-sys/src/features/gen_BrowserFindDirection.rs +++ b/crates/web-sys/src/features/gen_BrowserFindDirection.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `BrowserFindDirection` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `BrowserFindDirection`*"] diff --git a/crates/web-sys/src/features/gen_CacheStorageNamespace.rs b/crates/web-sys/src/features/gen_CacheStorageNamespace.rs index fd3ee287435..50df06179b7 100644 --- a/crates/web-sys/src/features/gen_CacheStorageNamespace.rs +++ b/crates/web-sys/src/features/gen_CacheStorageNamespace.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CacheStorageNamespace` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CacheStorageNamespace`*"] diff --git a/crates/web-sys/src/features/gen_CanvasWindingRule.rs b/crates/web-sys/src/features/gen_CanvasWindingRule.rs index 1ee94c14b7e..d6da6e7931d 100644 --- a/crates/web-sys/src/features/gen_CanvasWindingRule.rs +++ b/crates/web-sys/src/features/gen_CanvasWindingRule.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CanvasWindingRule` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CanvasWindingRule`*"] diff --git a/crates/web-sys/src/features/gen_CaretChangedReason.rs b/crates/web-sys/src/features/gen_CaretChangedReason.rs index 1782320d029..4536810310b 100644 --- a/crates/web-sys/src/features/gen_CaretChangedReason.rs +++ b/crates/web-sys/src/features/gen_CaretChangedReason.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CaretChangedReason` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CaretChangedReason`*"] diff --git a/crates/web-sys/src/features/gen_ChannelCountMode.rs b/crates/web-sys/src/features/gen_ChannelCountMode.rs index d801074006d..9867377c932 100644 --- a/crates/web-sys/src/features/gen_ChannelCountMode.rs +++ b/crates/web-sys/src/features/gen_ChannelCountMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ChannelCountMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ChannelCountMode`*"] diff --git a/crates/web-sys/src/features/gen_ChannelInterpretation.rs b/crates/web-sys/src/features/gen_ChannelInterpretation.rs index a45eeca2736..b88e5847363 100644 --- a/crates/web-sys/src/features/gen_ChannelInterpretation.rs +++ b/crates/web-sys/src/features/gen_ChannelInterpretation.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ChannelInterpretation` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ChannelInterpretation`*"] diff --git a/crates/web-sys/src/features/gen_CheckerboardReason.rs b/crates/web-sys/src/features/gen_CheckerboardReason.rs index d8cbc534e4b..d9a3b2adead 100644 --- a/crates/web-sys/src/features/gen_CheckerboardReason.rs +++ b/crates/web-sys/src/features/gen_CheckerboardReason.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CheckerboardReason` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CheckerboardReason`*"] diff --git a/crates/web-sys/src/features/gen_ClientType.rs b/crates/web-sys/src/features/gen_ClientType.rs index 43ea6b93093..49d8c29b7b0 100644 --- a/crates/web-sys/src/features/gen_ClientType.rs +++ b/crates/web-sys/src/features/gen_ClientType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ClientType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ClientType`*"] diff --git a/crates/web-sys/src/features/gen_CodecState.rs b/crates/web-sys/src/features/gen_CodecState.rs index 7648d53d1aa..532315d4f92 100644 --- a/crates/web-sys/src/features/gen_CodecState.rs +++ b/crates/web-sys/src/features/gen_CodecState.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CodecState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CodecState`*"] diff --git a/crates/web-sys/src/features/gen_ColorSpaceConversion.rs b/crates/web-sys/src/features/gen_ColorSpaceConversion.rs index 91409cd3cc6..4ee04068707 100644 --- a/crates/web-sys/src/features/gen_ColorSpaceConversion.rs +++ b/crates/web-sys/src/features/gen_ColorSpaceConversion.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ColorSpaceConversion` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ColorSpaceConversion`*"] diff --git a/crates/web-sys/src/features/gen_CompositeOperation.rs b/crates/web-sys/src/features/gen_CompositeOperation.rs index 246fc95ce9b..18d16a1f156 100644 --- a/crates/web-sys/src/features/gen_CompositeOperation.rs +++ b/crates/web-sys/src/features/gen_CompositeOperation.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CompositeOperation` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CompositeOperation`*"] diff --git a/crates/web-sys/src/features/gen_CompressionFormat.rs b/crates/web-sys/src/features/gen_CompressionFormat.rs index 1ee2070cd19..3c5896b1238 100644 --- a/crates/web-sys/src/features/gen_CompressionFormat.rs +++ b/crates/web-sys/src/features/gen_CompressionFormat.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CompressionFormat` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CompressionFormat`*"] diff --git a/crates/web-sys/src/features/gen_ConnectionType.rs b/crates/web-sys/src/features/gen_ConnectionType.rs index 55973494731..417c609205c 100644 --- a/crates/web-sys/src/features/gen_ConnectionType.rs +++ b/crates/web-sys/src/features/gen_ConnectionType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ConnectionType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ConnectionType`*"] diff --git a/crates/web-sys/src/features/gen_ConsoleLevel.rs b/crates/web-sys/src/features/gen_ConsoleLevel.rs index fb7f6971ca5..85ae3f9a5aa 100644 --- a/crates/web-sys/src/features/gen_ConsoleLevel.rs +++ b/crates/web-sys/src/features/gen_ConsoleLevel.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ConsoleLevel` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ConsoleLevel`*"] diff --git a/crates/web-sys/src/features/gen_ConsoleLogLevel.rs b/crates/web-sys/src/features/gen_ConsoleLogLevel.rs index 6946606d6c0..c10fe514f01 100644 --- a/crates/web-sys/src/features/gen_ConsoleLogLevel.rs +++ b/crates/web-sys/src/features/gen_ConsoleLogLevel.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ConsoleLogLevel` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ConsoleLogLevel`*"] diff --git a/crates/web-sys/src/features/gen_CssBoxType.rs b/crates/web-sys/src/features/gen_CssBoxType.rs index 68b285f886f..00ce7427a41 100644 --- a/crates/web-sys/src/features/gen_CssBoxType.rs +++ b/crates/web-sys/src/features/gen_CssBoxType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CssBoxType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CssBoxType`*"] diff --git a/crates/web-sys/src/features/gen_CssStyleSheetParsingMode.rs b/crates/web-sys/src/features/gen_CssStyleSheetParsingMode.rs index 8c721650b66..b40ee165680 100644 --- a/crates/web-sys/src/features/gen_CssStyleSheetParsingMode.rs +++ b/crates/web-sys/src/features/gen_CssStyleSheetParsingMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `CssStyleSheetParsingMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `CssStyleSheetParsingMode`*"] diff --git a/crates/web-sys/src/features/gen_DecoderDoctorNotificationType.rs b/crates/web-sys/src/features/gen_DecoderDoctorNotificationType.rs index 2c742b090cb..6e0392067a5 100644 --- a/crates/web-sys/src/features/gen_DecoderDoctorNotificationType.rs +++ b/crates/web-sys/src/features/gen_DecoderDoctorNotificationType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `DecoderDoctorNotificationType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `DecoderDoctorNotificationType`*"] diff --git a/crates/web-sys/src/features/gen_DirectionSetting.rs b/crates/web-sys/src/features/gen_DirectionSetting.rs index d6c9a5dd394..92063803dbd 100644 --- a/crates/web-sys/src/features/gen_DirectionSetting.rs +++ b/crates/web-sys/src/features/gen_DirectionSetting.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `DirectionSetting` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `DirectionSetting`*"] diff --git a/crates/web-sys/src/features/gen_DistanceModelType.rs b/crates/web-sys/src/features/gen_DistanceModelType.rs index a622e7a38b0..f0604e09eb2 100644 --- a/crates/web-sys/src/features/gen_DistanceModelType.rs +++ b/crates/web-sys/src/features/gen_DistanceModelType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `DistanceModelType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `DistanceModelType`*"] diff --git a/crates/web-sys/src/features/gen_DomRequestReadyState.rs b/crates/web-sys/src/features/gen_DomRequestReadyState.rs index c8a8ac4f337..680c9c46786 100644 --- a/crates/web-sys/src/features/gen_DomRequestReadyState.rs +++ b/crates/web-sys/src/features/gen_DomRequestReadyState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `DomRequestReadyState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `DomRequestReadyState`*"] diff --git a/crates/web-sys/src/features/gen_EncodedAudioChunkType.rs b/crates/web-sys/src/features/gen_EncodedAudioChunkType.rs index 42f4dcc55d0..c726b83d7c6 100644 --- a/crates/web-sys/src/features/gen_EncodedAudioChunkType.rs +++ b/crates/web-sys/src/features/gen_EncodedAudioChunkType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `EncodedAudioChunkType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `EncodedAudioChunkType`*"] diff --git a/crates/web-sys/src/features/gen_EncodedVideoChunkType.rs b/crates/web-sys/src/features/gen_EncodedVideoChunkType.rs index 64ce2b89ee3..be6481dedc1 100644 --- a/crates/web-sys/src/features/gen_EncodedVideoChunkType.rs +++ b/crates/web-sys/src/features/gen_EncodedVideoChunkType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `EncodedVideoChunkType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `EncodedVideoChunkType`*"] diff --git a/crates/web-sys/src/features/gen_EndingTypes.rs b/crates/web-sys/src/features/gen_EndingTypes.rs index 0898d8f99a6..98da1ecc776 100644 --- a/crates/web-sys/src/features/gen_EndingTypes.rs +++ b/crates/web-sys/src/features/gen_EndingTypes.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `EndingTypes` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `EndingTypes`*"] diff --git a/crates/web-sys/src/features/gen_FetchState.rs b/crates/web-sys/src/features/gen_FetchState.rs index e3adc4aed2d..a97c61c6d72 100644 --- a/crates/web-sys/src/features/gen_FetchState.rs +++ b/crates/web-sys/src/features/gen_FetchState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FetchState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FetchState`*"] diff --git a/crates/web-sys/src/features/gen_FileSystemHandleKind.rs b/crates/web-sys/src/features/gen_FileSystemHandleKind.rs index 4cb6fdb6fe6..5815cef6748 100644 --- a/crates/web-sys/src/features/gen_FileSystemHandleKind.rs +++ b/crates/web-sys/src/features/gen_FileSystemHandleKind.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FileSystemHandleKind` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FileSystemHandleKind`*"] diff --git a/crates/web-sys/src/features/gen_FileSystemPermissionMode.rs b/crates/web-sys/src/features/gen_FileSystemPermissionMode.rs index 11636456c13..d54c0af4b3f 100644 --- a/crates/web-sys/src/features/gen_FileSystemPermissionMode.rs +++ b/crates/web-sys/src/features/gen_FileSystemPermissionMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FileSystemPermissionMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FileSystemPermissionMode`*"] diff --git a/crates/web-sys/src/features/gen_FillMode.rs b/crates/web-sys/src/features/gen_FillMode.rs index 8897bde8524..22f53a92ce6 100644 --- a/crates/web-sys/src/features/gen_FillMode.rs +++ b/crates/web-sys/src/features/gen_FillMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FillMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FillMode`*"] diff --git a/crates/web-sys/src/features/gen_FlashClassification.rs b/crates/web-sys/src/features/gen_FlashClassification.rs index 08e526915ff..111b37d54f5 100644 --- a/crates/web-sys/src/features/gen_FlashClassification.rs +++ b/crates/web-sys/src/features/gen_FlashClassification.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FlashClassification` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FlashClassification`*"] diff --git a/crates/web-sys/src/features/gen_FlowControlType.rs b/crates/web-sys/src/features/gen_FlowControlType.rs index 0b9f4c5e999..7cb9c716427 100644 --- a/crates/web-sys/src/features/gen_FlowControlType.rs +++ b/crates/web-sys/src/features/gen_FlowControlType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FlowControlType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FlowControlType`*"] diff --git a/crates/web-sys/src/features/gen_FontFaceLoadStatus.rs b/crates/web-sys/src/features/gen_FontFaceLoadStatus.rs index 2d86cda84cb..eb1dc60e004 100644 --- a/crates/web-sys/src/features/gen_FontFaceLoadStatus.rs +++ b/crates/web-sys/src/features/gen_FontFaceLoadStatus.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FontFaceLoadStatus` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FontFaceLoadStatus`*"] diff --git a/crates/web-sys/src/features/gen_FontFaceSetLoadStatus.rs b/crates/web-sys/src/features/gen_FontFaceSetLoadStatus.rs index ab61481eafb..efa7003682f 100644 --- a/crates/web-sys/src/features/gen_FontFaceSetLoadStatus.rs +++ b/crates/web-sys/src/features/gen_FontFaceSetLoadStatus.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FontFaceSetLoadStatus` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FontFaceSetLoadStatus`*"] diff --git a/crates/web-sys/src/features/gen_FrameType.rs b/crates/web-sys/src/features/gen_FrameType.rs index fd18caca04e..0d43dcc1420 100644 --- a/crates/web-sys/src/features/gen_FrameType.rs +++ b/crates/web-sys/src/features/gen_FrameType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `FrameType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `FrameType`*"] diff --git a/crates/web-sys/src/features/gen_GamepadHand.rs b/crates/web-sys/src/features/gen_GamepadHand.rs index 191aff88eff..19906694ed4 100644 --- a/crates/web-sys/src/features/gen_GamepadHand.rs +++ b/crates/web-sys/src/features/gen_GamepadHand.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GamepadHand` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GamepadHand`*"] diff --git a/crates/web-sys/src/features/gen_GamepadHapticActuatorType.rs b/crates/web-sys/src/features/gen_GamepadHapticActuatorType.rs index 7fb9239ed94..42d16fc7924 100644 --- a/crates/web-sys/src/features/gen_GamepadHapticActuatorType.rs +++ b/crates/web-sys/src/features/gen_GamepadHapticActuatorType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GamepadHapticActuatorType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GamepadHapticActuatorType`*"] diff --git a/crates/web-sys/src/features/gen_GamepadHapticEffectType.rs b/crates/web-sys/src/features/gen_GamepadHapticEffectType.rs index f78269698f8..e2b3f3f5bce 100644 --- a/crates/web-sys/src/features/gen_GamepadHapticEffectType.rs +++ b/crates/web-sys/src/features/gen_GamepadHapticEffectType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GamepadHapticEffectType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GamepadHapticEffectType`*"] diff --git a/crates/web-sys/src/features/gen_GamepadHapticsResult.rs b/crates/web-sys/src/features/gen_GamepadHapticsResult.rs index 14a59728c18..a716d6d4ee5 100644 --- a/crates/web-sys/src/features/gen_GamepadHapticsResult.rs +++ b/crates/web-sys/src/features/gen_GamepadHapticsResult.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GamepadHapticsResult` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GamepadHapticsResult`*"] diff --git a/crates/web-sys/src/features/gen_GamepadMappingType.rs b/crates/web-sys/src/features/gen_GamepadMappingType.rs index 00873cf87d2..5814f4aa48c 100644 --- a/crates/web-sys/src/features/gen_GamepadMappingType.rs +++ b/crates/web-sys/src/features/gen_GamepadMappingType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GamepadMappingType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GamepadMappingType`*"] diff --git a/crates/web-sys/src/features/gen_GpuAddressMode.rs b/crates/web-sys/src/features/gen_GpuAddressMode.rs index c0710da06cf..64e60fb3391 100644 --- a/crates/web-sys/src/features/gen_GpuAddressMode.rs +++ b/crates/web-sys/src/features/gen_GpuAddressMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuAddressMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuAddressMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuAutoLayoutMode.rs b/crates/web-sys/src/features/gen_GpuAutoLayoutMode.rs index 8b56987a9ac..3aa7e24c041 100644 --- a/crates/web-sys/src/features/gen_GpuAutoLayoutMode.rs +++ b/crates/web-sys/src/features/gen_GpuAutoLayoutMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuAutoLayoutMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuAutoLayoutMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuBlendFactor.rs b/crates/web-sys/src/features/gen_GpuBlendFactor.rs index 6ae84672461..902c6e647e6 100644 --- a/crates/web-sys/src/features/gen_GpuBlendFactor.rs +++ b/crates/web-sys/src/features/gen_GpuBlendFactor.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuBlendFactor` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuBlendFactor`*"] diff --git a/crates/web-sys/src/features/gen_GpuBlendOperation.rs b/crates/web-sys/src/features/gen_GpuBlendOperation.rs index ad66d0a51f5..04e60499f83 100644 --- a/crates/web-sys/src/features/gen_GpuBlendOperation.rs +++ b/crates/web-sys/src/features/gen_GpuBlendOperation.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuBlendOperation` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuBlendOperation`*"] diff --git a/crates/web-sys/src/features/gen_GpuBufferBindingType.rs b/crates/web-sys/src/features/gen_GpuBufferBindingType.rs index d297f54b43b..16753bbaddd 100644 --- a/crates/web-sys/src/features/gen_GpuBufferBindingType.rs +++ b/crates/web-sys/src/features/gen_GpuBufferBindingType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuBufferBindingType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuBufferBindingType`*"] diff --git a/crates/web-sys/src/features/gen_GpuBufferMapState.rs b/crates/web-sys/src/features/gen_GpuBufferMapState.rs index 3e6049ffdd5..faedcc05e5a 100644 --- a/crates/web-sys/src/features/gen_GpuBufferMapState.rs +++ b/crates/web-sys/src/features/gen_GpuBufferMapState.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuBufferMapState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuBufferMapState`*"] diff --git a/crates/web-sys/src/features/gen_GpuCanvasAlphaMode.rs b/crates/web-sys/src/features/gen_GpuCanvasAlphaMode.rs index 96d11c720b7..d65ca20da97 100644 --- a/crates/web-sys/src/features/gen_GpuCanvasAlphaMode.rs +++ b/crates/web-sys/src/features/gen_GpuCanvasAlphaMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuCanvasAlphaMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuCanvasAlphaMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuCanvasToneMappingMode.rs b/crates/web-sys/src/features/gen_GpuCanvasToneMappingMode.rs index 106664a51ad..f12c517142c 100644 --- a/crates/web-sys/src/features/gen_GpuCanvasToneMappingMode.rs +++ b/crates/web-sys/src/features/gen_GpuCanvasToneMappingMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuCanvasToneMappingMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuCanvasToneMappingMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuCompareFunction.rs b/crates/web-sys/src/features/gen_GpuCompareFunction.rs index 8e01e1903dc..f6da2bbe47e 100644 --- a/crates/web-sys/src/features/gen_GpuCompareFunction.rs +++ b/crates/web-sys/src/features/gen_GpuCompareFunction.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuCompareFunction` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuCompareFunction`*"] diff --git a/crates/web-sys/src/features/gen_GpuCompilationMessageType.rs b/crates/web-sys/src/features/gen_GpuCompilationMessageType.rs index 74780e3d56a..46ea90c50de 100644 --- a/crates/web-sys/src/features/gen_GpuCompilationMessageType.rs +++ b/crates/web-sys/src/features/gen_GpuCompilationMessageType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuCompilationMessageType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuCompilationMessageType`*"] diff --git a/crates/web-sys/src/features/gen_GpuCullMode.rs b/crates/web-sys/src/features/gen_GpuCullMode.rs index f17ba15111e..aca98c38c06 100644 --- a/crates/web-sys/src/features/gen_GpuCullMode.rs +++ b/crates/web-sys/src/features/gen_GpuCullMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuCullMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuCullMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuDeviceLostReason.rs b/crates/web-sys/src/features/gen_GpuDeviceLostReason.rs index 554f1473303..b75ff717d68 100644 --- a/crates/web-sys/src/features/gen_GpuDeviceLostReason.rs +++ b/crates/web-sys/src/features/gen_GpuDeviceLostReason.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuDeviceLostReason` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuDeviceLostReason`*"] diff --git a/crates/web-sys/src/features/gen_GpuErrorFilter.rs b/crates/web-sys/src/features/gen_GpuErrorFilter.rs index 070f8e98499..93cd23140dd 100644 --- a/crates/web-sys/src/features/gen_GpuErrorFilter.rs +++ b/crates/web-sys/src/features/gen_GpuErrorFilter.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuErrorFilter` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuErrorFilter`*"] diff --git a/crates/web-sys/src/features/gen_GpuFeatureName.rs b/crates/web-sys/src/features/gen_GpuFeatureName.rs index b4bbf30a2b3..71c3c3e56fe 100644 --- a/crates/web-sys/src/features/gen_GpuFeatureName.rs +++ b/crates/web-sys/src/features/gen_GpuFeatureName.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuFeatureName` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuFeatureName`*"] diff --git a/crates/web-sys/src/features/gen_GpuFilterMode.rs b/crates/web-sys/src/features/gen_GpuFilterMode.rs index 7edd76b6c06..9ef0f3a4d5f 100644 --- a/crates/web-sys/src/features/gen_GpuFilterMode.rs +++ b/crates/web-sys/src/features/gen_GpuFilterMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuFilterMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuFilterMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuFrontFace.rs b/crates/web-sys/src/features/gen_GpuFrontFace.rs index af1f79c3e12..1e7ca1837c0 100644 --- a/crates/web-sys/src/features/gen_GpuFrontFace.rs +++ b/crates/web-sys/src/features/gen_GpuFrontFace.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuFrontFace` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuFrontFace`*"] diff --git a/crates/web-sys/src/features/gen_GpuIndexFormat.rs b/crates/web-sys/src/features/gen_GpuIndexFormat.rs index 6812c5c52cd..043ef20568f 100644 --- a/crates/web-sys/src/features/gen_GpuIndexFormat.rs +++ b/crates/web-sys/src/features/gen_GpuIndexFormat.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuIndexFormat` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuIndexFormat`*"] diff --git a/crates/web-sys/src/features/gen_GpuLoadOp.rs b/crates/web-sys/src/features/gen_GpuLoadOp.rs index e7baab63bab..1466f545075 100644 --- a/crates/web-sys/src/features/gen_GpuLoadOp.rs +++ b/crates/web-sys/src/features/gen_GpuLoadOp.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuLoadOp` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuLoadOp`*"] diff --git a/crates/web-sys/src/features/gen_GpuMipmapFilterMode.rs b/crates/web-sys/src/features/gen_GpuMipmapFilterMode.rs index ec34e9a6d6b..64da15b4810 100644 --- a/crates/web-sys/src/features/gen_GpuMipmapFilterMode.rs +++ b/crates/web-sys/src/features/gen_GpuMipmapFilterMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuMipmapFilterMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuMipmapFilterMode`*"] diff --git a/crates/web-sys/src/features/gen_GpuPipelineErrorReason.rs b/crates/web-sys/src/features/gen_GpuPipelineErrorReason.rs index 3d2fd0bf194..9d5e4de6d70 100644 --- a/crates/web-sys/src/features/gen_GpuPipelineErrorReason.rs +++ b/crates/web-sys/src/features/gen_GpuPipelineErrorReason.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuPipelineErrorReason` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuPipelineErrorReason`*"] diff --git a/crates/web-sys/src/features/gen_GpuPowerPreference.rs b/crates/web-sys/src/features/gen_GpuPowerPreference.rs index 41c15a84d88..e8b2df72c1b 100644 --- a/crates/web-sys/src/features/gen_GpuPowerPreference.rs +++ b/crates/web-sys/src/features/gen_GpuPowerPreference.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuPowerPreference` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuPowerPreference`*"] diff --git a/crates/web-sys/src/features/gen_GpuPrimitiveTopology.rs b/crates/web-sys/src/features/gen_GpuPrimitiveTopology.rs index 848b4c3e18c..1f466642b28 100644 --- a/crates/web-sys/src/features/gen_GpuPrimitiveTopology.rs +++ b/crates/web-sys/src/features/gen_GpuPrimitiveTopology.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuPrimitiveTopology` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuPrimitiveTopology`*"] diff --git a/crates/web-sys/src/features/gen_GpuQueryType.rs b/crates/web-sys/src/features/gen_GpuQueryType.rs index 4e115a98709..ccb393e7046 100644 --- a/crates/web-sys/src/features/gen_GpuQueryType.rs +++ b/crates/web-sys/src/features/gen_GpuQueryType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuQueryType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuQueryType`*"] diff --git a/crates/web-sys/src/features/gen_GpuSamplerBindingType.rs b/crates/web-sys/src/features/gen_GpuSamplerBindingType.rs index 0b406c0d30e..14de556c3be 100644 --- a/crates/web-sys/src/features/gen_GpuSamplerBindingType.rs +++ b/crates/web-sys/src/features/gen_GpuSamplerBindingType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuSamplerBindingType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuSamplerBindingType`*"] diff --git a/crates/web-sys/src/features/gen_GpuStencilOperation.rs b/crates/web-sys/src/features/gen_GpuStencilOperation.rs index 6206b66c55d..c37f99ccbc8 100644 --- a/crates/web-sys/src/features/gen_GpuStencilOperation.rs +++ b/crates/web-sys/src/features/gen_GpuStencilOperation.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuStencilOperation` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuStencilOperation`*"] diff --git a/crates/web-sys/src/features/gen_GpuStorageTextureAccess.rs b/crates/web-sys/src/features/gen_GpuStorageTextureAccess.rs index e0069d0992f..6e5bedf2570 100644 --- a/crates/web-sys/src/features/gen_GpuStorageTextureAccess.rs +++ b/crates/web-sys/src/features/gen_GpuStorageTextureAccess.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuStorageTextureAccess` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuStorageTextureAccess`*"] diff --git a/crates/web-sys/src/features/gen_GpuStoreOp.rs b/crates/web-sys/src/features/gen_GpuStoreOp.rs index fc01989a1e6..d92e984a462 100644 --- a/crates/web-sys/src/features/gen_GpuStoreOp.rs +++ b/crates/web-sys/src/features/gen_GpuStoreOp.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuStoreOp` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuStoreOp`*"] diff --git a/crates/web-sys/src/features/gen_GpuTextureAspect.rs b/crates/web-sys/src/features/gen_GpuTextureAspect.rs index 21216c326f6..1ca17fa064f 100644 --- a/crates/web-sys/src/features/gen_GpuTextureAspect.rs +++ b/crates/web-sys/src/features/gen_GpuTextureAspect.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuTextureAspect` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuTextureAspect`*"] diff --git a/crates/web-sys/src/features/gen_GpuTextureDimension.rs b/crates/web-sys/src/features/gen_GpuTextureDimension.rs index a9676ac30fc..b6f714bbbb5 100644 --- a/crates/web-sys/src/features/gen_GpuTextureDimension.rs +++ b/crates/web-sys/src/features/gen_GpuTextureDimension.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuTextureDimension` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuTextureDimension`*"] diff --git a/crates/web-sys/src/features/gen_GpuTextureFormat.rs b/crates/web-sys/src/features/gen_GpuTextureFormat.rs index 5b67dce2fdf..f0eb53e8939 100644 --- a/crates/web-sys/src/features/gen_GpuTextureFormat.rs +++ b/crates/web-sys/src/features/gen_GpuTextureFormat.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuTextureFormat` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuTextureFormat`*"] diff --git a/crates/web-sys/src/features/gen_GpuTextureSampleType.rs b/crates/web-sys/src/features/gen_GpuTextureSampleType.rs index 8c5a8f963cc..c92b535776f 100644 --- a/crates/web-sys/src/features/gen_GpuTextureSampleType.rs +++ b/crates/web-sys/src/features/gen_GpuTextureSampleType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuTextureSampleType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuTextureSampleType`*"] diff --git a/crates/web-sys/src/features/gen_GpuTextureViewDimension.rs b/crates/web-sys/src/features/gen_GpuTextureViewDimension.rs index 8e341635f75..13f31059e4e 100644 --- a/crates/web-sys/src/features/gen_GpuTextureViewDimension.rs +++ b/crates/web-sys/src/features/gen_GpuTextureViewDimension.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuTextureViewDimension` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuTextureViewDimension`*"] diff --git a/crates/web-sys/src/features/gen_GpuVertexFormat.rs b/crates/web-sys/src/features/gen_GpuVertexFormat.rs index 9c380d45895..491a741ebab 100644 --- a/crates/web-sys/src/features/gen_GpuVertexFormat.rs +++ b/crates/web-sys/src/features/gen_GpuVertexFormat.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuVertexFormat` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuVertexFormat`*"] diff --git a/crates/web-sys/src/features/gen_GpuVertexStepMode.rs b/crates/web-sys/src/features/gen_GpuVertexStepMode.rs index 16552bbabea..2d6324feee5 100644 --- a/crates/web-sys/src/features/gen_GpuVertexStepMode.rs +++ b/crates/web-sys/src/features/gen_GpuVertexStepMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `GpuVertexStepMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `GpuVertexStepMode`*"] diff --git a/crates/web-sys/src/features/gen_HardwareAcceleration.rs b/crates/web-sys/src/features/gen_HardwareAcceleration.rs index 35320b3609a..36733ca0202 100644 --- a/crates/web-sys/src/features/gen_HardwareAcceleration.rs +++ b/crates/web-sys/src/features/gen_HardwareAcceleration.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `HardwareAcceleration` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `HardwareAcceleration`*"] diff --git a/crates/web-sys/src/features/gen_HeadersGuardEnum.rs b/crates/web-sys/src/features/gen_HeadersGuardEnum.rs index 130118979ec..619a90363c8 100644 --- a/crates/web-sys/src/features/gen_HeadersGuardEnum.rs +++ b/crates/web-sys/src/features/gen_HeadersGuardEnum.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `HeadersGuardEnum` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `HeadersGuardEnum`*"] diff --git a/crates/web-sys/src/features/gen_HidUnitSystem.rs b/crates/web-sys/src/features/gen_HidUnitSystem.rs index 4f9e39c5c5e..9fbea17b402 100644 --- a/crates/web-sys/src/features/gen_HidUnitSystem.rs +++ b/crates/web-sys/src/features/gen_HidUnitSystem.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `HidUnitSystem` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `HidUnitSystem`*"] diff --git a/crates/web-sys/src/features/gen_IdbCursorDirection.rs b/crates/web-sys/src/features/gen_IdbCursorDirection.rs index 1013cf5db2d..cabea805500 100644 --- a/crates/web-sys/src/features/gen_IdbCursorDirection.rs +++ b/crates/web-sys/src/features/gen_IdbCursorDirection.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `IdbCursorDirection` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `IdbCursorDirection`*"] diff --git a/crates/web-sys/src/features/gen_IdbRequestReadyState.rs b/crates/web-sys/src/features/gen_IdbRequestReadyState.rs index 49644e6e6ba..2933c55b54b 100644 --- a/crates/web-sys/src/features/gen_IdbRequestReadyState.rs +++ b/crates/web-sys/src/features/gen_IdbRequestReadyState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `IdbRequestReadyState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `IdbRequestReadyState`*"] diff --git a/crates/web-sys/src/features/gen_IdbTransactionDurability.rs b/crates/web-sys/src/features/gen_IdbTransactionDurability.rs index 756fac38578..172e079d9aa 100644 --- a/crates/web-sys/src/features/gen_IdbTransactionDurability.rs +++ b/crates/web-sys/src/features/gen_IdbTransactionDurability.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `IdbTransactionDurability` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `IdbTransactionDurability`*"] diff --git a/crates/web-sys/src/features/gen_IdbTransactionMode.rs b/crates/web-sys/src/features/gen_IdbTransactionMode.rs index e0886c5284e..de30091d978 100644 --- a/crates/web-sys/src/features/gen_IdbTransactionMode.rs +++ b/crates/web-sys/src/features/gen_IdbTransactionMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `IdbTransactionMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `IdbTransactionMode`*"] diff --git a/crates/web-sys/src/features/gen_ImageOrientation.rs b/crates/web-sys/src/features/gen_ImageOrientation.rs index 1fe8d731f7f..27136927b5b 100644 --- a/crates/web-sys/src/features/gen_ImageOrientation.rs +++ b/crates/web-sys/src/features/gen_ImageOrientation.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ImageOrientation` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ImageOrientation`*"] diff --git a/crates/web-sys/src/features/gen_IterationCompositeOperation.rs b/crates/web-sys/src/features/gen_IterationCompositeOperation.rs index d87ccf88585..94b175555c6 100644 --- a/crates/web-sys/src/features/gen_IterationCompositeOperation.rs +++ b/crates/web-sys/src/features/gen_IterationCompositeOperation.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `IterationCompositeOperation` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `IterationCompositeOperation`*"] diff --git a/crates/web-sys/src/features/gen_LargeBlobSupport.rs b/crates/web-sys/src/features/gen_LargeBlobSupport.rs index 508b901fe8f..9add590f557 100644 --- a/crates/web-sys/src/features/gen_LargeBlobSupport.rs +++ b/crates/web-sys/src/features/gen_LargeBlobSupport.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `LargeBlobSupport` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `LargeBlobSupport`*"] diff --git a/crates/web-sys/src/features/gen_LatencyMode.rs b/crates/web-sys/src/features/gen_LatencyMode.rs index aa53e603fba..81a0c75de51 100644 --- a/crates/web-sys/src/features/gen_LatencyMode.rs +++ b/crates/web-sys/src/features/gen_LatencyMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `LatencyMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `LatencyMode`*"] diff --git a/crates/web-sys/src/features/gen_LineAlignSetting.rs b/crates/web-sys/src/features/gen_LineAlignSetting.rs index eb1cf3d6057..6ac8a04b803 100644 --- a/crates/web-sys/src/features/gen_LineAlignSetting.rs +++ b/crates/web-sys/src/features/gen_LineAlignSetting.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `LineAlignSetting` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `LineAlignSetting`*"] diff --git a/crates/web-sys/src/features/gen_LockMode.rs b/crates/web-sys/src/features/gen_LockMode.rs index 18459e67ec1..c9f517620fb 100644 --- a/crates/web-sys/src/features/gen_LockMode.rs +++ b/crates/web-sys/src/features/gen_LockMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `LockMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `LockMode`*"] diff --git a/crates/web-sys/src/features/gen_MediaDecodingType.rs b/crates/web-sys/src/features/gen_MediaDecodingType.rs index 865462b8a51..fb2a372e1b1 100644 --- a/crates/web-sys/src/features/gen_MediaDecodingType.rs +++ b/crates/web-sys/src/features/gen_MediaDecodingType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaDecodingType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaDecodingType`*"] diff --git a/crates/web-sys/src/features/gen_MediaDeviceKind.rs b/crates/web-sys/src/features/gen_MediaDeviceKind.rs index 69c6ed8ce9b..f555e2c7663 100644 --- a/crates/web-sys/src/features/gen_MediaDeviceKind.rs +++ b/crates/web-sys/src/features/gen_MediaDeviceKind.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaDeviceKind` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaDeviceKind`*"] diff --git a/crates/web-sys/src/features/gen_MediaEncodingType.rs b/crates/web-sys/src/features/gen_MediaEncodingType.rs index 84d8bba8c8f..6eff2c58b12 100644 --- a/crates/web-sys/src/features/gen_MediaEncodingType.rs +++ b/crates/web-sys/src/features/gen_MediaEncodingType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaEncodingType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaEncodingType`*"] diff --git a/crates/web-sys/src/features/gen_MediaKeyMessageType.rs b/crates/web-sys/src/features/gen_MediaKeyMessageType.rs index c4251b25a7a..a49fe83f655 100644 --- a/crates/web-sys/src/features/gen_MediaKeyMessageType.rs +++ b/crates/web-sys/src/features/gen_MediaKeyMessageType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaKeyMessageType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaKeyMessageType`*"] diff --git a/crates/web-sys/src/features/gen_MediaKeySessionType.rs b/crates/web-sys/src/features/gen_MediaKeySessionType.rs index 0f131bcccb9..e0db6001e01 100644 --- a/crates/web-sys/src/features/gen_MediaKeySessionType.rs +++ b/crates/web-sys/src/features/gen_MediaKeySessionType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaKeySessionType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaKeySessionType`*"] diff --git a/crates/web-sys/src/features/gen_MediaKeyStatus.rs b/crates/web-sys/src/features/gen_MediaKeyStatus.rs index 8016cdeb2ff..d0746f9f57b 100644 --- a/crates/web-sys/src/features/gen_MediaKeyStatus.rs +++ b/crates/web-sys/src/features/gen_MediaKeyStatus.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaKeyStatus` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaKeyStatus`*"] diff --git a/crates/web-sys/src/features/gen_MediaKeySystemStatus.rs b/crates/web-sys/src/features/gen_MediaKeySystemStatus.rs index fee902ec516..7f0ded20850 100644 --- a/crates/web-sys/src/features/gen_MediaKeySystemStatus.rs +++ b/crates/web-sys/src/features/gen_MediaKeySystemStatus.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaKeySystemStatus` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaKeySystemStatus`*"] diff --git a/crates/web-sys/src/features/gen_MediaKeysRequirement.rs b/crates/web-sys/src/features/gen_MediaKeysRequirement.rs index e1f3bb08cec..d7d6f605fa1 100644 --- a/crates/web-sys/src/features/gen_MediaKeysRequirement.rs +++ b/crates/web-sys/src/features/gen_MediaKeysRequirement.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaKeysRequirement` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaKeysRequirement`*"] diff --git a/crates/web-sys/src/features/gen_MediaSessionAction.rs b/crates/web-sys/src/features/gen_MediaSessionAction.rs index 20f74a59aa7..1c6b1f29285 100644 --- a/crates/web-sys/src/features/gen_MediaSessionAction.rs +++ b/crates/web-sys/src/features/gen_MediaSessionAction.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaSessionAction` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaSessionAction`*"] diff --git a/crates/web-sys/src/features/gen_MediaSessionPlaybackState.rs b/crates/web-sys/src/features/gen_MediaSessionPlaybackState.rs index a1e12dc79a3..72202386e55 100644 --- a/crates/web-sys/src/features/gen_MediaSessionPlaybackState.rs +++ b/crates/web-sys/src/features/gen_MediaSessionPlaybackState.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaSessionPlaybackState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaSessionPlaybackState`*"] diff --git a/crates/web-sys/src/features/gen_MediaSourceEndOfStreamError.rs b/crates/web-sys/src/features/gen_MediaSourceEndOfStreamError.rs index ca6827210fe..0357f0fe504 100644 --- a/crates/web-sys/src/features/gen_MediaSourceEndOfStreamError.rs +++ b/crates/web-sys/src/features/gen_MediaSourceEndOfStreamError.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaSourceEndOfStreamError` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaSourceEndOfStreamError`*"] diff --git a/crates/web-sys/src/features/gen_MediaSourceEnum.rs b/crates/web-sys/src/features/gen_MediaSourceEnum.rs index b10fe7e1b4a..815272e36db 100644 --- a/crates/web-sys/src/features/gen_MediaSourceEnum.rs +++ b/crates/web-sys/src/features/gen_MediaSourceEnum.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaSourceEnum` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaSourceEnum`*"] diff --git a/crates/web-sys/src/features/gen_MediaSourceReadyState.rs b/crates/web-sys/src/features/gen_MediaSourceReadyState.rs index 1b8e06a0965..18d20c168c5 100644 --- a/crates/web-sys/src/features/gen_MediaSourceReadyState.rs +++ b/crates/web-sys/src/features/gen_MediaSourceReadyState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaSourceReadyState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaSourceReadyState`*"] diff --git a/crates/web-sys/src/features/gen_MediaStreamTrackState.rs b/crates/web-sys/src/features/gen_MediaStreamTrackState.rs index 854efb46141..9a308d37268 100644 --- a/crates/web-sys/src/features/gen_MediaStreamTrackState.rs +++ b/crates/web-sys/src/features/gen_MediaStreamTrackState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MediaStreamTrackState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MediaStreamTrackState`*"] diff --git a/crates/web-sys/src/features/gen_MidiPortConnectionState.rs b/crates/web-sys/src/features/gen_MidiPortConnectionState.rs index e0389280ebc..9c9ddb0a1c7 100644 --- a/crates/web-sys/src/features/gen_MidiPortConnectionState.rs +++ b/crates/web-sys/src/features/gen_MidiPortConnectionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MidiPortConnectionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MidiPortConnectionState`*"] diff --git a/crates/web-sys/src/features/gen_MidiPortDeviceState.rs b/crates/web-sys/src/features/gen_MidiPortDeviceState.rs index f1bd843f5f1..f03ac5b2efc 100644 --- a/crates/web-sys/src/features/gen_MidiPortDeviceState.rs +++ b/crates/web-sys/src/features/gen_MidiPortDeviceState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MidiPortDeviceState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MidiPortDeviceState`*"] diff --git a/crates/web-sys/src/features/gen_MidiPortType.rs b/crates/web-sys/src/features/gen_MidiPortType.rs index 507c37d92ff..92c7d81ee66 100644 --- a/crates/web-sys/src/features/gen_MidiPortType.rs +++ b/crates/web-sys/src/features/gen_MidiPortType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `MidiPortType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `MidiPortType`*"] diff --git a/crates/web-sys/src/features/gen_NavigationType.rs b/crates/web-sys/src/features/gen_NavigationType.rs index 8f82bdd2866..4ac63aa6a22 100644 --- a/crates/web-sys/src/features/gen_NavigationType.rs +++ b/crates/web-sys/src/features/gen_NavigationType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `NavigationType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `NavigationType`*"] diff --git a/crates/web-sys/src/features/gen_NotificationDirection.rs b/crates/web-sys/src/features/gen_NotificationDirection.rs index 861eadfe8fe..70aa99aacdc 100644 --- a/crates/web-sys/src/features/gen_NotificationDirection.rs +++ b/crates/web-sys/src/features/gen_NotificationDirection.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `NotificationDirection` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `NotificationDirection`*"] diff --git a/crates/web-sys/src/features/gen_NotificationPermission.rs b/crates/web-sys/src/features/gen_NotificationPermission.rs index 35a4b8a59c5..1b516bdec76 100644 --- a/crates/web-sys/src/features/gen_NotificationPermission.rs +++ b/crates/web-sys/src/features/gen_NotificationPermission.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `NotificationPermission` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `NotificationPermission`*"] diff --git a/crates/web-sys/src/features/gen_OrientationLockType.rs b/crates/web-sys/src/features/gen_OrientationLockType.rs index a87f9e7aaf7..d824deed2d7 100644 --- a/crates/web-sys/src/features/gen_OrientationLockType.rs +++ b/crates/web-sys/src/features/gen_OrientationLockType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `OrientationLockType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `OrientationLockType`*"] diff --git a/crates/web-sys/src/features/gen_OrientationType.rs b/crates/web-sys/src/features/gen_OrientationType.rs index 21b96131a8c..4fb69e01e1c 100644 --- a/crates/web-sys/src/features/gen_OrientationType.rs +++ b/crates/web-sys/src/features/gen_OrientationType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `OrientationType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `OrientationType`*"] diff --git a/crates/web-sys/src/features/gen_OscillatorType.rs b/crates/web-sys/src/features/gen_OscillatorType.rs index af4f43180fe..990e45c4771 100644 --- a/crates/web-sys/src/features/gen_OscillatorType.rs +++ b/crates/web-sys/src/features/gen_OscillatorType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `OscillatorType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `OscillatorType`*"] diff --git a/crates/web-sys/src/features/gen_OverSampleType.rs b/crates/web-sys/src/features/gen_OverSampleType.rs index 3f36eea4ca8..f80b3df2a5a 100644 --- a/crates/web-sys/src/features/gen_OverSampleType.rs +++ b/crates/web-sys/src/features/gen_OverSampleType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `OverSampleType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `OverSampleType`*"] diff --git a/crates/web-sys/src/features/gen_PanningModelType.rs b/crates/web-sys/src/features/gen_PanningModelType.rs index e6a7ca2c8c0..9a5b24e42dd 100644 --- a/crates/web-sys/src/features/gen_PanningModelType.rs +++ b/crates/web-sys/src/features/gen_PanningModelType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PanningModelType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PanningModelType`*"] diff --git a/crates/web-sys/src/features/gen_ParityType.rs b/crates/web-sys/src/features/gen_ParityType.rs index f1a4a28c367..da35551eed7 100644 --- a/crates/web-sys/src/features/gen_ParityType.rs +++ b/crates/web-sys/src/features/gen_ParityType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ParityType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ParityType`*"] diff --git a/crates/web-sys/src/features/gen_PaymentComplete.rs b/crates/web-sys/src/features/gen_PaymentComplete.rs index e090f091de2..9e140fbcceb 100644 --- a/crates/web-sys/src/features/gen_PaymentComplete.rs +++ b/crates/web-sys/src/features/gen_PaymentComplete.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PaymentComplete` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PaymentComplete`*"] diff --git a/crates/web-sys/src/features/gen_PcImplIceConnectionState.rs b/crates/web-sys/src/features/gen_PcImplIceConnectionState.rs index a9b2b351165..67b8f098e68 100644 --- a/crates/web-sys/src/features/gen_PcImplIceConnectionState.rs +++ b/crates/web-sys/src/features/gen_PcImplIceConnectionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PcImplIceConnectionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PcImplIceConnectionState`*"] diff --git a/crates/web-sys/src/features/gen_PcImplIceGatheringState.rs b/crates/web-sys/src/features/gen_PcImplIceGatheringState.rs index d52a7eae0e9..ec961d26dd6 100644 --- a/crates/web-sys/src/features/gen_PcImplIceGatheringState.rs +++ b/crates/web-sys/src/features/gen_PcImplIceGatheringState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PcImplIceGatheringState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PcImplIceGatheringState`*"] diff --git a/crates/web-sys/src/features/gen_PcImplSignalingState.rs b/crates/web-sys/src/features/gen_PcImplSignalingState.rs index 06cb051820b..3e516f68362 100644 --- a/crates/web-sys/src/features/gen_PcImplSignalingState.rs +++ b/crates/web-sys/src/features/gen_PcImplSignalingState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PcImplSignalingState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PcImplSignalingState`*"] diff --git a/crates/web-sys/src/features/gen_PcObserverStateType.rs b/crates/web-sys/src/features/gen_PcObserverStateType.rs index 75f4b1be15a..0b675abffcd 100644 --- a/crates/web-sys/src/features/gen_PcObserverStateType.rs +++ b/crates/web-sys/src/features/gen_PcObserverStateType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PcObserverStateType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PcObserverStateType`*"] diff --git a/crates/web-sys/src/features/gen_PermissionName.rs b/crates/web-sys/src/features/gen_PermissionName.rs index 57887063a10..25afc99ebbe 100644 --- a/crates/web-sys/src/features/gen_PermissionName.rs +++ b/crates/web-sys/src/features/gen_PermissionName.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PermissionName` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PermissionName`*"] diff --git a/crates/web-sys/src/features/gen_PermissionState.rs b/crates/web-sys/src/features/gen_PermissionState.rs index ad4dfe78af6..94d63b800e8 100644 --- a/crates/web-sys/src/features/gen_PermissionState.rs +++ b/crates/web-sys/src/features/gen_PermissionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PermissionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PermissionState`*"] diff --git a/crates/web-sys/src/features/gen_PlaybackDirection.rs b/crates/web-sys/src/features/gen_PlaybackDirection.rs index 5e3caabfad0..f42f32036f6 100644 --- a/crates/web-sys/src/features/gen_PlaybackDirection.rs +++ b/crates/web-sys/src/features/gen_PlaybackDirection.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PlaybackDirection` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PlaybackDirection`*"] diff --git a/crates/web-sys/src/features/gen_PositionAlignSetting.rs b/crates/web-sys/src/features/gen_PositionAlignSetting.rs index 929f80840c9..c888157011f 100644 --- a/crates/web-sys/src/features/gen_PositionAlignSetting.rs +++ b/crates/web-sys/src/features/gen_PositionAlignSetting.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PositionAlignSetting` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PositionAlignSetting`*"] diff --git a/crates/web-sys/src/features/gen_PremultiplyAlpha.rs b/crates/web-sys/src/features/gen_PremultiplyAlpha.rs index 603d77abef8..ae739cebe8c 100644 --- a/crates/web-sys/src/features/gen_PremultiplyAlpha.rs +++ b/crates/web-sys/src/features/gen_PremultiplyAlpha.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PremultiplyAlpha` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PremultiplyAlpha`*"] diff --git a/crates/web-sys/src/features/gen_PresentationConnectionBinaryType.rs b/crates/web-sys/src/features/gen_PresentationConnectionBinaryType.rs index 1170ee14ba9..3cff6b0668d 100644 --- a/crates/web-sys/src/features/gen_PresentationConnectionBinaryType.rs +++ b/crates/web-sys/src/features/gen_PresentationConnectionBinaryType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PresentationConnectionBinaryType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionBinaryType`*"] diff --git a/crates/web-sys/src/features/gen_PresentationConnectionClosedReason.rs b/crates/web-sys/src/features/gen_PresentationConnectionClosedReason.rs index 254175d5833..5ff183ebbad 100644 --- a/crates/web-sys/src/features/gen_PresentationConnectionClosedReason.rs +++ b/crates/web-sys/src/features/gen_PresentationConnectionClosedReason.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PresentationConnectionClosedReason` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionClosedReason`*"] diff --git a/crates/web-sys/src/features/gen_PresentationConnectionState.rs b/crates/web-sys/src/features/gen_PresentationConnectionState.rs index 4aa059497d7..01ab7ff076f 100644 --- a/crates/web-sys/src/features/gen_PresentationConnectionState.rs +++ b/crates/web-sys/src/features/gen_PresentationConnectionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PresentationConnectionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PresentationConnectionState`*"] diff --git a/crates/web-sys/src/features/gen_PresentationStyle.rs b/crates/web-sys/src/features/gen_PresentationStyle.rs index 2c0573d8553..64964e49f6e 100644 --- a/crates/web-sys/src/features/gen_PresentationStyle.rs +++ b/crates/web-sys/src/features/gen_PresentationStyle.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PresentationStyle` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PresentationStyle`*"] diff --git a/crates/web-sys/src/features/gen_ProfileTimelineMessagePortOperationType.rs b/crates/web-sys/src/features/gen_ProfileTimelineMessagePortOperationType.rs index 95620b06492..b1fa4fc62e8 100644 --- a/crates/web-sys/src/features/gen_ProfileTimelineMessagePortOperationType.rs +++ b/crates/web-sys/src/features/gen_ProfileTimelineMessagePortOperationType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ProfileTimelineMessagePortOperationType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ProfileTimelineMessagePortOperationType`*"] diff --git a/crates/web-sys/src/features/gen_ProfileTimelineWorkerOperationType.rs b/crates/web-sys/src/features/gen_ProfileTimelineWorkerOperationType.rs index 25a50bfb973..9678165282c 100644 --- a/crates/web-sys/src/features/gen_ProfileTimelineWorkerOperationType.rs +++ b/crates/web-sys/src/features/gen_ProfileTimelineWorkerOperationType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ProfileTimelineWorkerOperationType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ProfileTimelineWorkerOperationType`*"] diff --git a/crates/web-sys/src/features/gen_PublicKeyCredentialHints.rs b/crates/web-sys/src/features/gen_PublicKeyCredentialHints.rs index a5aa405e64f..104e2c4f6eb 100644 --- a/crates/web-sys/src/features/gen_PublicKeyCredentialHints.rs +++ b/crates/web-sys/src/features/gen_PublicKeyCredentialHints.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PublicKeyCredentialHints` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PublicKeyCredentialHints`*"] diff --git a/crates/web-sys/src/features/gen_PublicKeyCredentialType.rs b/crates/web-sys/src/features/gen_PublicKeyCredentialType.rs index 2ba8cffe3b4..25f5205d01f 100644 --- a/crates/web-sys/src/features/gen_PublicKeyCredentialType.rs +++ b/crates/web-sys/src/features/gen_PublicKeyCredentialType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PublicKeyCredentialType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PublicKeyCredentialType`*"] diff --git a/crates/web-sys/src/features/gen_PushEncryptionKeyName.rs b/crates/web-sys/src/features/gen_PushEncryptionKeyName.rs index 328a69c6f0b..9d1e431fbc6 100644 --- a/crates/web-sys/src/features/gen_PushEncryptionKeyName.rs +++ b/crates/web-sys/src/features/gen_PushEncryptionKeyName.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PushEncryptionKeyName` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PushEncryptionKeyName`*"] diff --git a/crates/web-sys/src/features/gen_PushPermissionState.rs b/crates/web-sys/src/features/gen_PushPermissionState.rs index 2053fb078f6..9700579b5b2 100644 --- a/crates/web-sys/src/features/gen_PushPermissionState.rs +++ b/crates/web-sys/src/features/gen_PushPermissionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `PushPermissionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `PushPermissionState`*"] diff --git a/crates/web-sys/src/features/gen_ReadableStreamReaderMode.rs b/crates/web-sys/src/features/gen_ReadableStreamReaderMode.rs index ed940741702..737f9c719d1 100644 --- a/crates/web-sys/src/features/gen_ReadableStreamReaderMode.rs +++ b/crates/web-sys/src/features/gen_ReadableStreamReaderMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ReadableStreamReaderMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ReadableStreamReaderMode`*"] diff --git a/crates/web-sys/src/features/gen_ReadableStreamType.rs b/crates/web-sys/src/features/gen_ReadableStreamType.rs index 298c3eef697..ea755ce7254 100644 --- a/crates/web-sys/src/features/gen_ReadableStreamType.rs +++ b/crates/web-sys/src/features/gen_ReadableStreamType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ReadableStreamType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ReadableStreamType`*"] diff --git a/crates/web-sys/src/features/gen_RecordingState.rs b/crates/web-sys/src/features/gen_RecordingState.rs index 6aee4d1366e..5e31e929d6d 100644 --- a/crates/web-sys/src/features/gen_RecordingState.rs +++ b/crates/web-sys/src/features/gen_RecordingState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RecordingState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RecordingState`*"] diff --git a/crates/web-sys/src/features/gen_ReferrerPolicy.rs b/crates/web-sys/src/features/gen_ReferrerPolicy.rs index 467695b2ef6..bc08278cf16 100644 --- a/crates/web-sys/src/features/gen_ReferrerPolicy.rs +++ b/crates/web-sys/src/features/gen_ReferrerPolicy.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ReferrerPolicy` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ReferrerPolicy`*"] diff --git a/crates/web-sys/src/features/gen_RequestCache.rs b/crates/web-sys/src/features/gen_RequestCache.rs index e464cdfc201..3484b79f22a 100644 --- a/crates/web-sys/src/features/gen_RequestCache.rs +++ b/crates/web-sys/src/features/gen_RequestCache.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RequestCache` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RequestCache`*"] diff --git a/crates/web-sys/src/features/gen_RequestCredentials.rs b/crates/web-sys/src/features/gen_RequestCredentials.rs index 00f7a753385..06fa2048bcf 100644 --- a/crates/web-sys/src/features/gen_RequestCredentials.rs +++ b/crates/web-sys/src/features/gen_RequestCredentials.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RequestCredentials` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RequestCredentials`*"] diff --git a/crates/web-sys/src/features/gen_RequestDestination.rs b/crates/web-sys/src/features/gen_RequestDestination.rs index 143fadff1a4..e8e71401abf 100644 --- a/crates/web-sys/src/features/gen_RequestDestination.rs +++ b/crates/web-sys/src/features/gen_RequestDestination.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RequestDestination` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RequestDestination`*"] diff --git a/crates/web-sys/src/features/gen_RequestMode.rs b/crates/web-sys/src/features/gen_RequestMode.rs index 82842b5e082..361eeea606b 100644 --- a/crates/web-sys/src/features/gen_RequestMode.rs +++ b/crates/web-sys/src/features/gen_RequestMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RequestMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RequestMode`*"] diff --git a/crates/web-sys/src/features/gen_RequestRedirect.rs b/crates/web-sys/src/features/gen_RequestRedirect.rs index 528d777d651..de80bfe723a 100644 --- a/crates/web-sys/src/features/gen_RequestRedirect.rs +++ b/crates/web-sys/src/features/gen_RequestRedirect.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RequestRedirect` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RequestRedirect`*"] diff --git a/crates/web-sys/src/features/gen_ResidentKeyRequirement.rs b/crates/web-sys/src/features/gen_ResidentKeyRequirement.rs index 453e8363b21..b9bb33a8ffe 100644 --- a/crates/web-sys/src/features/gen_ResidentKeyRequirement.rs +++ b/crates/web-sys/src/features/gen_ResidentKeyRequirement.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ResidentKeyRequirement` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ResidentKeyRequirement`*"] diff --git a/crates/web-sys/src/features/gen_ResizeObserverBoxOptions.rs b/crates/web-sys/src/features/gen_ResizeObserverBoxOptions.rs index 827b3d99d84..d908806837e 100644 --- a/crates/web-sys/src/features/gen_ResizeObserverBoxOptions.rs +++ b/crates/web-sys/src/features/gen_ResizeObserverBoxOptions.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ResizeObserverBoxOptions` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ResizeObserverBoxOptions`*"] diff --git a/crates/web-sys/src/features/gen_ResizeQuality.rs b/crates/web-sys/src/features/gen_ResizeQuality.rs index 606867badca..ac746eb3397 100644 --- a/crates/web-sys/src/features/gen_ResizeQuality.rs +++ b/crates/web-sys/src/features/gen_ResizeQuality.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ResizeQuality` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ResizeQuality`*"] diff --git a/crates/web-sys/src/features/gen_ResponseType.rs b/crates/web-sys/src/features/gen_ResponseType.rs index 7f123fb915c..1d2c5cdb7b9 100644 --- a/crates/web-sys/src/features/gen_ResponseType.rs +++ b/crates/web-sys/src/features/gen_ResponseType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ResponseType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ResponseType`*"] diff --git a/crates/web-sys/src/features/gen_RtcBundlePolicy.rs b/crates/web-sys/src/features/gen_RtcBundlePolicy.rs index e4a5a7a3359..5cfc1f45752 100644 --- a/crates/web-sys/src/features/gen_RtcBundlePolicy.rs +++ b/crates/web-sys/src/features/gen_RtcBundlePolicy.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcBundlePolicy` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcBundlePolicy`*"] diff --git a/crates/web-sys/src/features/gen_RtcDataChannelState.rs b/crates/web-sys/src/features/gen_RtcDataChannelState.rs index 3acc26cfa3b..36bd0ce11cb 100644 --- a/crates/web-sys/src/features/gen_RtcDataChannelState.rs +++ b/crates/web-sys/src/features/gen_RtcDataChannelState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcDataChannelState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcDataChannelState`*"] diff --git a/crates/web-sys/src/features/gen_RtcDataChannelType.rs b/crates/web-sys/src/features/gen_RtcDataChannelType.rs index 018743abbbf..d6184b55f0e 100644 --- a/crates/web-sys/src/features/gen_RtcDataChannelType.rs +++ b/crates/web-sys/src/features/gen_RtcDataChannelType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcDataChannelType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcDataChannelType`*"] diff --git a/crates/web-sys/src/features/gen_RtcDegradationPreference.rs b/crates/web-sys/src/features/gen_RtcDegradationPreference.rs index 5886bb9ff00..a0747cb41be 100644 --- a/crates/web-sys/src/features/gen_RtcDegradationPreference.rs +++ b/crates/web-sys/src/features/gen_RtcDegradationPreference.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcDegradationPreference` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcDegradationPreference`*"] diff --git a/crates/web-sys/src/features/gen_RtcEncodedVideoFrameType.rs b/crates/web-sys/src/features/gen_RtcEncodedVideoFrameType.rs index 3874a7f483f..b5e2c2cab76 100644 --- a/crates/web-sys/src/features/gen_RtcEncodedVideoFrameType.rs +++ b/crates/web-sys/src/features/gen_RtcEncodedVideoFrameType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcEncodedVideoFrameType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcEncodedVideoFrameType`*"] diff --git a/crates/web-sys/src/features/gen_RtcIceConnectionState.rs b/crates/web-sys/src/features/gen_RtcIceConnectionState.rs index d7d9004b7c7..731e3e79556 100644 --- a/crates/web-sys/src/features/gen_RtcIceConnectionState.rs +++ b/crates/web-sys/src/features/gen_RtcIceConnectionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcIceConnectionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcIceConnectionState`*"] diff --git a/crates/web-sys/src/features/gen_RtcIceCredentialType.rs b/crates/web-sys/src/features/gen_RtcIceCredentialType.rs index 1b51f1c5c04..dcb0acab1a3 100644 --- a/crates/web-sys/src/features/gen_RtcIceCredentialType.rs +++ b/crates/web-sys/src/features/gen_RtcIceCredentialType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcIceCredentialType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcIceCredentialType`*"] diff --git a/crates/web-sys/src/features/gen_RtcIceGatheringState.rs b/crates/web-sys/src/features/gen_RtcIceGatheringState.rs index d3f83bfc5f6..3a207378b1d 100644 --- a/crates/web-sys/src/features/gen_RtcIceGatheringState.rs +++ b/crates/web-sys/src/features/gen_RtcIceGatheringState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcIceGatheringState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcIceGatheringState`*"] diff --git a/crates/web-sys/src/features/gen_RtcIceTransportPolicy.rs b/crates/web-sys/src/features/gen_RtcIceTransportPolicy.rs index 350c510aac8..08846deb263 100644 --- a/crates/web-sys/src/features/gen_RtcIceTransportPolicy.rs +++ b/crates/web-sys/src/features/gen_RtcIceTransportPolicy.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcIceTransportPolicy` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcIceTransportPolicy`*"] diff --git a/crates/web-sys/src/features/gen_RtcPeerConnectionState.rs b/crates/web-sys/src/features/gen_RtcPeerConnectionState.rs index 5647845cb42..5bf979425b9 100644 --- a/crates/web-sys/src/features/gen_RtcPeerConnectionState.rs +++ b/crates/web-sys/src/features/gen_RtcPeerConnectionState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcPeerConnectionState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcPeerConnectionState`*"] diff --git a/crates/web-sys/src/features/gen_RtcPriorityType.rs b/crates/web-sys/src/features/gen_RtcPriorityType.rs index 325b66c970b..58df3cee9f1 100644 --- a/crates/web-sys/src/features/gen_RtcPriorityType.rs +++ b/crates/web-sys/src/features/gen_RtcPriorityType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcPriorityType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcPriorityType`*"] diff --git a/crates/web-sys/src/features/gen_RtcRtpSourceEntryType.rs b/crates/web-sys/src/features/gen_RtcRtpSourceEntryType.rs index e1e26ef677c..2a8eb9f41bb 100644 --- a/crates/web-sys/src/features/gen_RtcRtpSourceEntryType.rs +++ b/crates/web-sys/src/features/gen_RtcRtpSourceEntryType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcRtpSourceEntryType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcRtpSourceEntryType`*"] diff --git a/crates/web-sys/src/features/gen_RtcRtpTransceiverDirection.rs b/crates/web-sys/src/features/gen_RtcRtpTransceiverDirection.rs index cdbbdd8c522..3414786d214 100644 --- a/crates/web-sys/src/features/gen_RtcRtpTransceiverDirection.rs +++ b/crates/web-sys/src/features/gen_RtcRtpTransceiverDirection.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcRtpTransceiverDirection` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcRtpTransceiverDirection`*"] diff --git a/crates/web-sys/src/features/gen_RtcSdpType.rs b/crates/web-sys/src/features/gen_RtcSdpType.rs index 4babb126b88..ce7de6ac2f8 100644 --- a/crates/web-sys/src/features/gen_RtcSdpType.rs +++ b/crates/web-sys/src/features/gen_RtcSdpType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcSdpType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcSdpType`*"] diff --git a/crates/web-sys/src/features/gen_RtcSignalingState.rs b/crates/web-sys/src/features/gen_RtcSignalingState.rs index a735f367086..30c94409b78 100644 --- a/crates/web-sys/src/features/gen_RtcSignalingState.rs +++ b/crates/web-sys/src/features/gen_RtcSignalingState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcSignalingState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcSignalingState`*"] diff --git a/crates/web-sys/src/features/gen_RtcStatsIceCandidatePairState.rs b/crates/web-sys/src/features/gen_RtcStatsIceCandidatePairState.rs index fe5b41e58a8..4cc7031916f 100644 --- a/crates/web-sys/src/features/gen_RtcStatsIceCandidatePairState.rs +++ b/crates/web-sys/src/features/gen_RtcStatsIceCandidatePairState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcStatsIceCandidatePairState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcStatsIceCandidatePairState`*"] diff --git a/crates/web-sys/src/features/gen_RtcStatsIceCandidateType.rs b/crates/web-sys/src/features/gen_RtcStatsIceCandidateType.rs index 3d6084246c0..746831efd01 100644 --- a/crates/web-sys/src/features/gen_RtcStatsIceCandidateType.rs +++ b/crates/web-sys/src/features/gen_RtcStatsIceCandidateType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcStatsIceCandidateType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcStatsIceCandidateType`*"] diff --git a/crates/web-sys/src/features/gen_RtcStatsType.rs b/crates/web-sys/src/features/gen_RtcStatsType.rs index 2670a3a879b..0f8610c5003 100644 --- a/crates/web-sys/src/features/gen_RtcStatsType.rs +++ b/crates/web-sys/src/features/gen_RtcStatsType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `RtcStatsType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `RtcStatsType`*"] diff --git a/crates/web-sys/src/features/gen_SFrameTransformErrorEventType.rs b/crates/web-sys/src/features/gen_SFrameTransformErrorEventType.rs index 9bd1e81e9f1..2baea5f4b6f 100644 --- a/crates/web-sys/src/features/gen_SFrameTransformErrorEventType.rs +++ b/crates/web-sys/src/features/gen_SFrameTransformErrorEventType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SFrameTransformErrorEventType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SFrameTransformErrorEventType`*"] diff --git a/crates/web-sys/src/features/gen_SFrameTransformRole.rs b/crates/web-sys/src/features/gen_SFrameTransformRole.rs index 7556496670e..178b96db534 100644 --- a/crates/web-sys/src/features/gen_SFrameTransformRole.rs +++ b/crates/web-sys/src/features/gen_SFrameTransformRole.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SFrameTransformRole` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SFrameTransformRole`*"] diff --git a/crates/web-sys/src/features/gen_ScreenColorGamut.rs b/crates/web-sys/src/features/gen_ScreenColorGamut.rs index d6e752fe5f3..c07c8c28e54 100644 --- a/crates/web-sys/src/features/gen_ScreenColorGamut.rs +++ b/crates/web-sys/src/features/gen_ScreenColorGamut.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ScreenColorGamut` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ScreenColorGamut`*"] diff --git a/crates/web-sys/src/features/gen_ScrollBehavior.rs b/crates/web-sys/src/features/gen_ScrollBehavior.rs index 9170db49c00..adddec4fa58 100644 --- a/crates/web-sys/src/features/gen_ScrollBehavior.rs +++ b/crates/web-sys/src/features/gen_ScrollBehavior.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ScrollBehavior` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ScrollBehavior`*"] diff --git a/crates/web-sys/src/features/gen_ScrollLogicalPosition.rs b/crates/web-sys/src/features/gen_ScrollLogicalPosition.rs index 5a3d088688d..f2530008bae 100644 --- a/crates/web-sys/src/features/gen_ScrollLogicalPosition.rs +++ b/crates/web-sys/src/features/gen_ScrollLogicalPosition.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ScrollLogicalPosition` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ScrollLogicalPosition`*"] diff --git a/crates/web-sys/src/features/gen_ScrollRestoration.rs b/crates/web-sys/src/features/gen_ScrollRestoration.rs index 62d6d116d74..86b69853406 100644 --- a/crates/web-sys/src/features/gen_ScrollRestoration.rs +++ b/crates/web-sys/src/features/gen_ScrollRestoration.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ScrollRestoration` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ScrollRestoration`*"] diff --git a/crates/web-sys/src/features/gen_ScrollSetting.rs b/crates/web-sys/src/features/gen_ScrollSetting.rs index 7f30f8a851f..64c04624a36 100644 --- a/crates/web-sys/src/features/gen_ScrollSetting.rs +++ b/crates/web-sys/src/features/gen_ScrollSetting.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ScrollSetting` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ScrollSetting`*"] diff --git a/crates/web-sys/src/features/gen_ScrollState.rs b/crates/web-sys/src/features/gen_ScrollState.rs index c06431714f8..34b8143fb11 100644 --- a/crates/web-sys/src/features/gen_ScrollState.rs +++ b/crates/web-sys/src/features/gen_ScrollState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ScrollState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ScrollState`*"] diff --git a/crates/web-sys/src/features/gen_SecurityPolicyViolationEventDisposition.rs b/crates/web-sys/src/features/gen_SecurityPolicyViolationEventDisposition.rs index 38f01f8c441..3895b80e948 100644 --- a/crates/web-sys/src/features/gen_SecurityPolicyViolationEventDisposition.rs +++ b/crates/web-sys/src/features/gen_SecurityPolicyViolationEventDisposition.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SecurityPolicyViolationEventDisposition` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SecurityPolicyViolationEventDisposition`*"] diff --git a/crates/web-sys/src/features/gen_SelectionMode.rs b/crates/web-sys/src/features/gen_SelectionMode.rs index 5d32722ab2c..68cd85b2fe1 100644 --- a/crates/web-sys/src/features/gen_SelectionMode.rs +++ b/crates/web-sys/src/features/gen_SelectionMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SelectionMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SelectionMode`*"] diff --git a/crates/web-sys/src/features/gen_ServiceWorkerState.rs b/crates/web-sys/src/features/gen_ServiceWorkerState.rs index cf37c476fb8..051caaf59fe 100644 --- a/crates/web-sys/src/features/gen_ServiceWorkerState.rs +++ b/crates/web-sys/src/features/gen_ServiceWorkerState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ServiceWorkerState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ServiceWorkerState`*"] diff --git a/crates/web-sys/src/features/gen_ServiceWorkerUpdateViaCache.rs b/crates/web-sys/src/features/gen_ServiceWorkerUpdateViaCache.rs index d667ab4ea9e..0391670864f 100644 --- a/crates/web-sys/src/features/gen_ServiceWorkerUpdateViaCache.rs +++ b/crates/web-sys/src/features/gen_ServiceWorkerUpdateViaCache.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ServiceWorkerUpdateViaCache` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ServiceWorkerUpdateViaCache`*"] diff --git a/crates/web-sys/src/features/gen_ShadowRootMode.rs b/crates/web-sys/src/features/gen_ShadowRootMode.rs index c6cfca62a0c..e24ea105262 100644 --- a/crates/web-sys/src/features/gen_ShadowRootMode.rs +++ b/crates/web-sys/src/features/gen_ShadowRootMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `ShadowRootMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `ShadowRootMode`*"] diff --git a/crates/web-sys/src/features/gen_SocketReadyState.rs b/crates/web-sys/src/features/gen_SocketReadyState.rs index 00092b00a70..3a05eeb7e9a 100644 --- a/crates/web-sys/src/features/gen_SocketReadyState.rs +++ b/crates/web-sys/src/features/gen_SocketReadyState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SocketReadyState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SocketReadyState`*"] diff --git a/crates/web-sys/src/features/gen_SourceBufferAppendMode.rs b/crates/web-sys/src/features/gen_SourceBufferAppendMode.rs index cdd97c94d55..5a7336ccfaf 100644 --- a/crates/web-sys/src/features/gen_SourceBufferAppendMode.rs +++ b/crates/web-sys/src/features/gen_SourceBufferAppendMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SourceBufferAppendMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SourceBufferAppendMode`*"] diff --git a/crates/web-sys/src/features/gen_SpeechRecognitionErrorCode.rs b/crates/web-sys/src/features/gen_SpeechRecognitionErrorCode.rs index 4bbf99e600c..e1d9bbc42d7 100644 --- a/crates/web-sys/src/features/gen_SpeechRecognitionErrorCode.rs +++ b/crates/web-sys/src/features/gen_SpeechRecognitionErrorCode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SpeechRecognitionErrorCode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SpeechRecognitionErrorCode`*"] diff --git a/crates/web-sys/src/features/gen_SpeechSynthesisErrorCode.rs b/crates/web-sys/src/features/gen_SpeechSynthesisErrorCode.rs index f024bf0695b..6b9c9e51b46 100644 --- a/crates/web-sys/src/features/gen_SpeechSynthesisErrorCode.rs +++ b/crates/web-sys/src/features/gen_SpeechSynthesisErrorCode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SpeechSynthesisErrorCode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SpeechSynthesisErrorCode`*"] diff --git a/crates/web-sys/src/features/gen_StorageType.rs b/crates/web-sys/src/features/gen_StorageType.rs index beb27040502..dcb737fdd19 100644 --- a/crates/web-sys/src/features/gen_StorageType.rs +++ b/crates/web-sys/src/features/gen_StorageType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `StorageType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `StorageType`*"] diff --git a/crates/web-sys/src/features/gen_SupportedType.rs b/crates/web-sys/src/features/gen_SupportedType.rs index 0d384a87aba..7708e2b564f 100644 --- a/crates/web-sys/src/features/gen_SupportedType.rs +++ b/crates/web-sys/src/features/gen_SupportedType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `SupportedType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `SupportedType`*"] diff --git a/crates/web-sys/src/features/gen_TaskPriority.rs b/crates/web-sys/src/features/gen_TaskPriority.rs index 4d04fe23c15..c6b15c6cb16 100644 --- a/crates/web-sys/src/features/gen_TaskPriority.rs +++ b/crates/web-sys/src/features/gen_TaskPriority.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `TaskPriority` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `TaskPriority`*"] diff --git a/crates/web-sys/src/features/gen_TcpReadyState.rs b/crates/web-sys/src/features/gen_TcpReadyState.rs index a4ff84a1047..20506c0f965 100644 --- a/crates/web-sys/src/features/gen_TcpReadyState.rs +++ b/crates/web-sys/src/features/gen_TcpReadyState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `TcpReadyState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `TcpReadyState`*"] diff --git a/crates/web-sys/src/features/gen_TcpSocketBinaryType.rs b/crates/web-sys/src/features/gen_TcpSocketBinaryType.rs index 7951276a0d6..b49aca009cc 100644 --- a/crates/web-sys/src/features/gen_TcpSocketBinaryType.rs +++ b/crates/web-sys/src/features/gen_TcpSocketBinaryType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `TcpSocketBinaryType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `TcpSocketBinaryType`*"] diff --git a/crates/web-sys/src/features/gen_TextTrackKind.rs b/crates/web-sys/src/features/gen_TextTrackKind.rs index 5f81e64e533..76614c152df 100644 --- a/crates/web-sys/src/features/gen_TextTrackKind.rs +++ b/crates/web-sys/src/features/gen_TextTrackKind.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `TextTrackKind` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `TextTrackKind`*"] diff --git a/crates/web-sys/src/features/gen_TextTrackMode.rs b/crates/web-sys/src/features/gen_TextTrackMode.rs index 95b9455b1e9..b1e21bfe14c 100644 --- a/crates/web-sys/src/features/gen_TextTrackMode.rs +++ b/crates/web-sys/src/features/gen_TextTrackMode.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `TextTrackMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `TextTrackMode`*"] diff --git a/crates/web-sys/src/features/gen_TokenBindingStatus.rs b/crates/web-sys/src/features/gen_TokenBindingStatus.rs index a9afc68ae1f..83cc1627ec3 100644 --- a/crates/web-sys/src/features/gen_TokenBindingStatus.rs +++ b/crates/web-sys/src/features/gen_TokenBindingStatus.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `TokenBindingStatus` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `TokenBindingStatus`*"] diff --git a/crates/web-sys/src/features/gen_Transport.rs b/crates/web-sys/src/features/gen_Transport.rs index ae35abf5230..a93e9f5a3b8 100644 --- a/crates/web-sys/src/features/gen_Transport.rs +++ b/crates/web-sys/src/features/gen_Transport.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `Transport` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `Transport`*"] diff --git a/crates/web-sys/src/features/gen_UsbDirection.rs b/crates/web-sys/src/features/gen_UsbDirection.rs index f2abfbd1c6f..0c4f8efa355 100644 --- a/crates/web-sys/src/features/gen_UsbDirection.rs +++ b/crates/web-sys/src/features/gen_UsbDirection.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `UsbDirection` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `UsbDirection`*"] diff --git a/crates/web-sys/src/features/gen_UsbEndpointType.rs b/crates/web-sys/src/features/gen_UsbEndpointType.rs index 73a52f710e4..5c0c4ed57c4 100644 --- a/crates/web-sys/src/features/gen_UsbEndpointType.rs +++ b/crates/web-sys/src/features/gen_UsbEndpointType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `UsbEndpointType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `UsbEndpointType`*"] diff --git a/crates/web-sys/src/features/gen_UsbRecipient.rs b/crates/web-sys/src/features/gen_UsbRecipient.rs index fb486f9531d..3f6d0a4dfe4 100644 --- a/crates/web-sys/src/features/gen_UsbRecipient.rs +++ b/crates/web-sys/src/features/gen_UsbRecipient.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `UsbRecipient` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `UsbRecipient`*"] diff --git a/crates/web-sys/src/features/gen_UsbRequestType.rs b/crates/web-sys/src/features/gen_UsbRequestType.rs index e47b7b4af41..026461ec268 100644 --- a/crates/web-sys/src/features/gen_UsbRequestType.rs +++ b/crates/web-sys/src/features/gen_UsbRequestType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `UsbRequestType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `UsbRequestType`*"] diff --git a/crates/web-sys/src/features/gen_UsbTransferStatus.rs b/crates/web-sys/src/features/gen_UsbTransferStatus.rs index 3a23a5156d2..b6b4a18513d 100644 --- a/crates/web-sys/src/features/gen_UsbTransferStatus.rs +++ b/crates/web-sys/src/features/gen_UsbTransferStatus.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `UsbTransferStatus` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `UsbTransferStatus`*"] diff --git a/crates/web-sys/src/features/gen_UserVerificationRequirement.rs b/crates/web-sys/src/features/gen_UserVerificationRequirement.rs index 674372b5bf4..1e6775d6b8e 100644 --- a/crates/web-sys/src/features/gen_UserVerificationRequirement.rs +++ b/crates/web-sys/src/features/gen_UserVerificationRequirement.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `UserVerificationRequirement` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `UserVerificationRequirement`*"] diff --git a/crates/web-sys/src/features/gen_VideoColorPrimaries.rs b/crates/web-sys/src/features/gen_VideoColorPrimaries.rs index 31c6f0e739e..71ba38ebbb9 100644 --- a/crates/web-sys/src/features/gen_VideoColorPrimaries.rs +++ b/crates/web-sys/src/features/gen_VideoColorPrimaries.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VideoColorPrimaries` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VideoColorPrimaries`*"] diff --git a/crates/web-sys/src/features/gen_VideoFacingModeEnum.rs b/crates/web-sys/src/features/gen_VideoFacingModeEnum.rs index 81fd3839ae9..e04151ffc3c 100644 --- a/crates/web-sys/src/features/gen_VideoFacingModeEnum.rs +++ b/crates/web-sys/src/features/gen_VideoFacingModeEnum.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VideoFacingModeEnum` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VideoFacingModeEnum`*"] diff --git a/crates/web-sys/src/features/gen_VideoMatrixCoefficients.rs b/crates/web-sys/src/features/gen_VideoMatrixCoefficients.rs index 196688d6add..8f2ee099138 100644 --- a/crates/web-sys/src/features/gen_VideoMatrixCoefficients.rs +++ b/crates/web-sys/src/features/gen_VideoMatrixCoefficients.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VideoMatrixCoefficients` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VideoMatrixCoefficients`*"] diff --git a/crates/web-sys/src/features/gen_VideoPixelFormat.rs b/crates/web-sys/src/features/gen_VideoPixelFormat.rs index e2348ed9495..bf68ffefbc6 100644 --- a/crates/web-sys/src/features/gen_VideoPixelFormat.rs +++ b/crates/web-sys/src/features/gen_VideoPixelFormat.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VideoPixelFormat` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VideoPixelFormat`*"] diff --git a/crates/web-sys/src/features/gen_VideoTransferCharacteristics.rs b/crates/web-sys/src/features/gen_VideoTransferCharacteristics.rs index dbb6684f5a5..deef8b59c9e 100644 --- a/crates/web-sys/src/features/gen_VideoTransferCharacteristics.rs +++ b/crates/web-sys/src/features/gen_VideoTransferCharacteristics.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VideoTransferCharacteristics` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VideoTransferCharacteristics`*"] diff --git a/crates/web-sys/src/features/gen_VisibilityState.rs b/crates/web-sys/src/features/gen_VisibilityState.rs index 7e4dd56b15f..c5287751221 100644 --- a/crates/web-sys/src/features/gen_VisibilityState.rs +++ b/crates/web-sys/src/features/gen_VisibilityState.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VisibilityState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VisibilityState`*"] diff --git a/crates/web-sys/src/features/gen_VrEye.rs b/crates/web-sys/src/features/gen_VrEye.rs index 690ae13d9f4..520be78c8dd 100644 --- a/crates/web-sys/src/features/gen_VrEye.rs +++ b/crates/web-sys/src/features/gen_VrEye.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `VrEye` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `VrEye`*"] diff --git a/crates/web-sys/src/features/gen_WakeLockType.rs b/crates/web-sys/src/features/gen_WakeLockType.rs index 280eda4a122..82c1b091cc7 100644 --- a/crates/web-sys/src/features/gen_WakeLockType.rs +++ b/crates/web-sys/src/features/gen_WakeLockType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WakeLockType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WakeLockType`*"] diff --git a/crates/web-sys/src/features/gen_WebGlPowerPreference.rs b/crates/web-sys/src/features/gen_WebGlPowerPreference.rs index d346fe056a1..ac1eee873e2 100644 --- a/crates/web-sys/src/features/gen_WebGlPowerPreference.rs +++ b/crates/web-sys/src/features/gen_WebGlPowerPreference.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WebGlPowerPreference` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WebGlPowerPreference`*"] diff --git a/crates/web-sys/src/features/gen_WebTransportCongestionControl.rs b/crates/web-sys/src/features/gen_WebTransportCongestionControl.rs index 5838a3f944e..052332c1615 100644 --- a/crates/web-sys/src/features/gen_WebTransportCongestionControl.rs +++ b/crates/web-sys/src/features/gen_WebTransportCongestionControl.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WebTransportCongestionControl` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WebTransportCongestionControl`*"] diff --git a/crates/web-sys/src/features/gen_WebTransportErrorSource.rs b/crates/web-sys/src/features/gen_WebTransportErrorSource.rs index 1e49ce89253..ad94b2e0879 100644 --- a/crates/web-sys/src/features/gen_WebTransportErrorSource.rs +++ b/crates/web-sys/src/features/gen_WebTransportErrorSource.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WebTransportErrorSource` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WebTransportErrorSource`*"] diff --git a/crates/web-sys/src/features/gen_WebTransportReliabilityMode.rs b/crates/web-sys/src/features/gen_WebTransportReliabilityMode.rs index 5bdba27c6eb..f6efd0e112c 100644 --- a/crates/web-sys/src/features/gen_WebTransportReliabilityMode.rs +++ b/crates/web-sys/src/features/gen_WebTransportReliabilityMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WebTransportReliabilityMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WebTransportReliabilityMode`*"] diff --git a/crates/web-sys/src/features/gen_WellKnownDirectory.rs b/crates/web-sys/src/features/gen_WellKnownDirectory.rs index a99a80592e5..3512f631d83 100644 --- a/crates/web-sys/src/features/gen_WellKnownDirectory.rs +++ b/crates/web-sys/src/features/gen_WellKnownDirectory.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WellKnownDirectory` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WellKnownDirectory`*"] diff --git a/crates/web-sys/src/features/gen_WorkerType.rs b/crates/web-sys/src/features/gen_WorkerType.rs index d67706b41cb..a338b1646c5 100644 --- a/crates/web-sys/src/features/gen_WorkerType.rs +++ b/crates/web-sys/src/features/gen_WorkerType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WorkerType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WorkerType`*"] diff --git a/crates/web-sys/src/features/gen_WriteCommandType.rs b/crates/web-sys/src/features/gen_WriteCommandType.rs index eb962259d79..a1f4aff9ec6 100644 --- a/crates/web-sys/src/features/gen_WriteCommandType.rs +++ b/crates/web-sys/src/features/gen_WriteCommandType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `WriteCommandType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `WriteCommandType`*"] diff --git a/crates/web-sys/src/features/gen_XmlHttpRequestResponseType.rs b/crates/web-sys/src/features/gen_XmlHttpRequestResponseType.rs index f1c4feb6d1e..f62d0ca443c 100644 --- a/crates/web-sys/src/features/gen_XmlHttpRequestResponseType.rs +++ b/crates/web-sys/src/features/gen_XmlHttpRequestResponseType.rs @@ -1,7 +1,7 @@ #![allow(unused_imports)] #![allow(clippy::all)] use wasm_bindgen::prelude::*; -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XmlHttpRequestResponseType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XmlHttpRequestResponseType`*"] diff --git a/crates/web-sys/src/features/gen_XrEye.rs b/crates/web-sys/src/features/gen_XrEye.rs index 079c1ed2eef..547ec5ebdd1 100644 --- a/crates/web-sys/src/features/gen_XrEye.rs +++ b/crates/web-sys/src/features/gen_XrEye.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrEye` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrEye`*"] diff --git a/crates/web-sys/src/features/gen_XrHandJoint.rs b/crates/web-sys/src/features/gen_XrHandJoint.rs index 8edc7345284..46198e84af6 100644 --- a/crates/web-sys/src/features/gen_XrHandJoint.rs +++ b/crates/web-sys/src/features/gen_XrHandJoint.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrHandJoint` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrHandJoint`*"] diff --git a/crates/web-sys/src/features/gen_XrHandedness.rs b/crates/web-sys/src/features/gen_XrHandedness.rs index faadaa848f3..a85f5006163 100644 --- a/crates/web-sys/src/features/gen_XrHandedness.rs +++ b/crates/web-sys/src/features/gen_XrHandedness.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrHandedness` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrHandedness`*"] diff --git a/crates/web-sys/src/features/gen_XrReferenceSpaceType.rs b/crates/web-sys/src/features/gen_XrReferenceSpaceType.rs index 3ee66e27206..22ca1bdc560 100644 --- a/crates/web-sys/src/features/gen_XrReferenceSpaceType.rs +++ b/crates/web-sys/src/features/gen_XrReferenceSpaceType.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrReferenceSpaceType` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrReferenceSpaceType`*"] diff --git a/crates/web-sys/src/features/gen_XrSessionMode.rs b/crates/web-sys/src/features/gen_XrSessionMode.rs index becf96ed22c..0ec51a13c61 100644 --- a/crates/web-sys/src/features/gen_XrSessionMode.rs +++ b/crates/web-sys/src/features/gen_XrSessionMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrSessionMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrSessionMode`*"] diff --git a/crates/web-sys/src/features/gen_XrTargetRayMode.rs b/crates/web-sys/src/features/gen_XrTargetRayMode.rs index d4248fb8da4..7dc0fce295f 100644 --- a/crates/web-sys/src/features/gen_XrTargetRayMode.rs +++ b/crates/web-sys/src/features/gen_XrTargetRayMode.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrTargetRayMode` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrTargetRayMode`*"] diff --git a/crates/web-sys/src/features/gen_XrVisibilityState.rs b/crates/web-sys/src/features/gen_XrVisibilityState.rs index 9b826370a4d..a4b372a9862 100644 --- a/crates/web-sys/src/features/gen_XrVisibilityState.rs +++ b/crates/web-sys/src/features/gen_XrVisibilityState.rs @@ -2,7 +2,7 @@ #![allow(clippy::all)] use wasm_bindgen::prelude::*; #[cfg(web_sys_unstable_apis)] -#[wasm_bindgen] +#[wasm_bindgen(no_export)] #[doc = "The `XrVisibilityState` enum."] #[doc = ""] #[doc = "*This API requires the following crate features to be activated: `XrVisibilityState`*"] diff --git a/crates/webidl/src/generator.rs b/crates/webidl/src/generator.rs index 0122807bb8a..97ac5abc345 100644 --- a/crates/webidl/src/generator.rs +++ b/crates/webidl/src/generator.rs @@ -135,7 +135,7 @@ impl Enum { use wasm_bindgen::prelude::*; #unstable_attr - #[wasm_bindgen] + #[wasm_bindgen(no_export)] #doc_comment #unstable_docs #[derive(Debug, Clone, Copy, PartialEq, Eq)] From c0f475b78cb09edffa571cfc89e00387e02b53da Mon Sep 17 00:00:00 2001 From: RunDevelopment Date: Fri, 29 Nov 2024 23:11:44 +0100 Subject: [PATCH 2/3] Add support for numeric enums and changed private enums --- crates/cli-support/src/js/binding.rs | 9 ++++- crates/cli-support/src/js/mod.rs | 49 ++++++++++++++++----------- crates/cli/tests/reference/enums.d.ts | 13 +++++-- crates/cli/tests/reference/enums.js | 17 +++++++--- crates/cli/tests/reference/enums.rs | 34 ++++++++++++++----- crates/cli/tests/reference/enums.wat | 18 +++++----- crates/macro-support/src/parser.rs | 10 +----- 7 files changed, 97 insertions(+), 53 deletions(-) diff --git a/crates/cli-support/src/js/binding.rs b/crates/cli-support/src/js/binding.rs index d5ed01363ad..e7d945f2de8 100644 --- a/crates/cli-support/src/js/binding.rs +++ b/crates/cli-support/src/js/binding.rs @@ -87,6 +87,7 @@ pub struct JsFunction { #[derive(Debug, Clone, PartialEq, Eq, Hash)] pub enum TsReference { StringEnum(String), + Enum(String), } impl<'a, 'b> Builder<'a, 'b> { @@ -1570,7 +1571,13 @@ fn adapter2ts(ty: &AdapterType, dst: &mut String, refs: Option<&mut HashSet dst.push_str(name), AdapterType::Struct(name) => dst.push_str(name), - AdapterType::Enum(name) => dst.push_str(name), + AdapterType::Enum(name) => { + if let Some(refs) = refs { + refs.insert(TsReference::Enum(name.clone())); + } + + dst.push_str(name) + } AdapterType::StringEnum(name) => { if let Some(refs) = refs { refs.insert(TsReference::StringEnum(name.clone())); diff --git a/crates/cli-support/src/js/mod.rs b/crates/cli-support/src/js/mod.rs index 555f721697a..88a463beefc 100644 --- a/crates/cli-support/src/js/mod.rs +++ b/crates/cli-support/src/js/mod.rs @@ -3915,12 +3915,21 @@ __wbg_set_wasm(wasm);" fn generate_enum(&mut self, enum_: &AuxEnum) -> Result<(), Error> { let mut variants = String::new(); - if enum_.generate_typescript { + let is_used_in_typescript = self + .typescript_refs + .contains(&TsReference::Enum(enum_.name.clone())); + + let ts = enum_.generate_typescript && (!enum_.no_export || is_used_in_typescript); + + if ts { self.typescript .push_str(&format_doc_comments(&enum_.comments, None)); - self.typescript - .push_str(&format!("export enum {} {{", enum_.name)); + if !enum_.no_export { + self.typescript.push_str("export "); + } + self.typescript.push_str(&format!("enum {} {{", enum_.name)); } + for (name, value, comments) in enum_.variants.iter() { let variant_docs = if comments.is_empty() { String::new() @@ -3930,7 +3939,7 @@ __wbg_set_wasm(wasm);" variants.push_str(&variant_docs); variants.push_str(&format!("{}: {}, ", name, value)); variants.push_str(&format!("\"{}\": \"{}\",\n", value, name)); - if enum_.generate_typescript { + if ts { self.typescript.push('\n'); if !variant_docs.is_empty() { for line in variant_docs.lines() { @@ -3942,26 +3951,28 @@ __wbg_set_wasm(wasm);" self.typescript.push_str(&format!(" {name} = {value},")); } } - if enum_.generate_typescript { + if ts { self.typescript.push_str("\n}\n"); } - // add an `@enum {1 | 2 | 3}` to ensure that enums type-check even without .d.ts - let mut at_enum = "@enum {".to_string(); - for (i, (_, value, _)) in enum_.variants.iter().enumerate() { - if i != 0 { - at_enum.push_str(" | "); + if !enum_.no_export { + // add an `@enum {1 | 2 | 3}` to ensure that enums type-check even without .d.ts + let mut at_enum = "@enum {".to_string(); + for (i, (_, value, _)) in enum_.variants.iter().enumerate() { + if i != 0 { + at_enum.push_str(" | "); + } + at_enum.push_str(&value.to_string()); } - at_enum.push_str(&value.to_string()); - } - at_enum.push('}'); - let docs = format_doc_comments(&enum_.comments, Some(at_enum)); + at_enum.push('}'); + let docs = format_doc_comments(&enum_.comments, Some(at_enum)); - self.export( - &enum_.name, - &format!("Object.freeze({{\n{}}})", variants), - Some(&docs), - )?; + self.export( + &enum_.name, + &format!("Object.freeze({{\n{}}})", variants), + Some(&docs), + )?; + } Ok(()) } diff --git a/crates/cli/tests/reference/enums.d.ts b/crates/cli/tests/reference/enums.d.ts index daebc58f510..d0112ad640c 100644 --- a/crates/cli/tests/reference/enums.d.ts +++ b/crates/cli/tests/reference/enums.d.ts @@ -4,7 +4,7 @@ export function enum_echo(color: Color): Color; export function option_enum_echo(color?: Color): Color | undefined; export function get_name(color: Color): ColorName; export function option_string_enum_echo(color?: ColorName): ColorName | undefined; -export function use_private_enum(): PrivateStringEnum; +export function use_used(arg0: NoExportButUsedStringEnum, arg1: NoExportButUsedEnum): void; export function option_order(order?: Ordering): Ordering | undefined; /** * A color. @@ -29,6 +29,10 @@ export enum ImplicitDiscriminant { C = 42, D = 43, } +enum NoExportButUsedEnum { + Foo = 0, + Bar = 1, +} /** * A C-style enum with negative discriminants. */ @@ -37,6 +41,10 @@ export enum Ordering { Equal = 0, Greater = 1, } +export enum PrivateEnum { + Foo = 0, + Bar = 1, +} /** * The name of a color. */ @@ -45,4 +53,5 @@ export type ColorName = "green" | "yellow" | "red"; * An unused string enum. */ export type FooBar = "foo" | "bar"; -type PrivateStringEnum = "foo" | "bar"; +type NoExportButUsedStringEnum = "foo" | "bar"; +export type PrivateStringEnum = "foo" | "bar"; diff --git a/crates/cli/tests/reference/enums.js b/crates/cli/tests/reference/enums.js index 54d2d100bbc..2d432f44261 100644 --- a/crates/cli/tests/reference/enums.js +++ b/crates/cli/tests/reference/enums.js @@ -63,11 +63,11 @@ export function option_string_enum_echo(color) { } /** - * @returns {PrivateStringEnum} + * @param {NoExportButUsedStringEnum} arg0 + * @param {NoExportButUsedEnum} arg1 */ -export function use_private_enum() { - const ret = wasm.use_private_enum(); - return __wbindgen_enum_PrivateStringEnum[ret]; +export function use_used(arg0, arg1) { + wasm.use_used((__wbindgen_enum_NoExportButUsedStringEnum.indexOf(arg0) + 1 || 3) - 1, arg1); } /** @@ -115,10 +115,17 @@ export const Ordering = Object.freeze({ Equal: 0, "0": "Equal", Greater: 1, "1": "Greater", }); +/** + * @enum {0 | 1} + */ +export const PrivateEnum = Object.freeze({ + Foo: 0, "0": "Foo", + Bar: 1, "1": "Bar", +}); const __wbindgen_enum_ColorName = ["green", "yellow", "red"]; -const __wbindgen_enum_PrivateStringEnum = ["foo", "bar"]; +const __wbindgen_enum_NoExportButUsedStringEnum = ["foo", "bar"]; export function __wbindgen_init_externref_table() { const table = wasm.__wbindgen_export_0; diff --git a/crates/cli/tests/reference/enums.rs b/crates/cli/tests/reference/enums.rs index b8a92762a80..83b05237566 100644 --- a/crates/cli/tests/reference/enums.rs +++ b/crates/cli/tests/reference/enums.rs @@ -52,23 +52,41 @@ pub enum UnusedStringEnum { Bar = "bar", } -/// An unused string enum. -#[wasm_bindgen(js_name = "FooBarNoExport", no_export)] -pub enum UnusedStringEnumNoExport { +#[wasm_bindgen] +enum PrivateStringEnum { Foo = "foo", Bar = "bar", } - #[wasm_bindgen] -enum PrivateStringEnum { +enum PrivateEnum { + Foo, + Bar, +} + +#[wasm_bindgen(no_export)] +pub enum NoExportStringEnum { Foo = "foo", Bar = "bar", } +#[wasm_bindgen(no_export)] +pub enum NoExportEnum { + Foo, + Bar, +} -#[wasm_bindgen] -pub fn use_private_enum() -> PrivateStringEnum { - PrivateStringEnum::Foo +#[wasm_bindgen(no_export)] +pub enum NoExportButUsedStringEnum { + Foo = "foo", + Bar = "bar", } +#[wasm_bindgen(no_export)] +pub enum NoExportButUsedEnum { + Foo, + Bar, +} + +#[wasm_bindgen] +pub fn use_used(arg0: NoExportButUsedStringEnum, arg1: NoExportButUsedEnum) {} #[wasm_bindgen] pub enum ImplicitDiscriminant { diff --git a/crates/cli/tests/reference/enums.wat b/crates/cli/tests/reference/enums.wat index 6cc28e43977..fbb61789cf0 100644 --- a/crates/cli/tests/reference/enums.wat +++ b/crates/cli/tests/reference/enums.wat @@ -1,14 +1,14 @@ (module $reference_test.wasm (type (;0;) (func)) - (type (;1;) (func (result i32))) - (type (;2;) (func (param i32) (result i32))) + (type (;1;) (func (param i32) (result i32))) + (type (;2;) (func (param i32 i32))) (import "./reference_test_bg.js" "__wbindgen_init_externref_table" (func (;0;) (type 0))) - (func $enum_echo (;1;) (type 2) (param i32) (result i32)) - (func $option_enum_echo (;2;) (type 2) (param i32) (result i32)) - (func $get_name (;3;) (type 2) (param i32) (result i32)) - (func $option_string_enum_echo (;4;) (type 2) (param i32) (result i32)) - (func $option_order (;5;) (type 2) (param i32) (result i32)) - (func $use_private_enum (;6;) (type 1) (result i32)) + (func $use_used (;1;) (type 2) (param i32 i32)) + (func $enum_echo (;2;) (type 1) (param i32) (result i32)) + (func $option_enum_echo (;3;) (type 1) (param i32) (result i32)) + (func $get_name (;4;) (type 1) (param i32) (result i32)) + (func $option_string_enum_echo (;5;) (type 1) (param i32) (result i32)) + (func $option_order (;6;) (type 1) (param i32) (result i32)) (table (;0;) 128 externref) (memory (;0;) 17) (export "memory" (memory 0)) @@ -16,7 +16,7 @@ (export "option_enum_echo" (func $option_enum_echo)) (export "get_name" (func $get_name)) (export "option_string_enum_echo" (func $option_string_enum_echo)) - (export "use_private_enum" (func $use_private_enum)) + (export "use_used" (func $use_used)) (export "option_order" (func $option_order)) (export "__wbindgen_export_0" (table 0)) (export "__wbindgen_start" (func 0)) diff --git a/crates/macro-support/src/parser.rs b/crates/macro-support/src/parser.rs index 19f02b3c2ca..9ce9cef233e 100644 --- a/crates/macro-support/src/parser.rs +++ b/crates/macro-support/src/parser.rs @@ -1484,16 +1484,13 @@ impl<'a> MacroParse<(&'a mut TokenStream, BindgenAttrs)> for syn::ItemEnum { } let generate_typescript = opts.skip_typescript().is_none(); + let no_export = opts.no_export().is_some(); let js_name = opts .js_name() .map(|s| s.0) .map_or_else(|| self.ident.to_string(), |s| s.to_string()); let comments = extract_doc_comments(&self.attrs); - // don't export private enums and if explicitly requested - let no_export = - opts.no_export().is_some() || !matches!(self.vis, syn::Visibility::Public(_)); - opts.check_used(); // Check if the enum is a string enum, by checking whether any variant has a string discriminant. @@ -1520,11 +1517,6 @@ impl<'a> MacroParse<(&'a mut TokenStream, BindgenAttrs)> for syn::ItemEnum { ); } - match self.vis { - syn::Visibility::Public(_) => {} - _ => bail_span!(self, "only public enums are allowed with #[wasm_bindgen]"), - } - // Go through all variants once first to determine whether the enum is // signed or unsigned. We don't need to actually parse the discriminant // values yet, we just need to know their sign. The actual parsing is From 665c1f4d99826579139e70e23d8aab3009409a15 Mon Sep 17 00:00:00 2001 From: RunDevelopment Date: Fri, 29 Nov 2024 23:34:08 +0100 Subject: [PATCH 3/3] Updated hash --- crates/shared/src/schema_hash_approval.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/shared/src/schema_hash_approval.rs b/crates/shared/src/schema_hash_approval.rs index fa086937c74..c511f898c41 100644 --- a/crates/shared/src/schema_hash_approval.rs +++ b/crates/shared/src/schema_hash_approval.rs @@ -8,7 +8,7 @@ // If the schema in this library has changed then: // 1. Bump the version in `crates/shared/Cargo.toml` // 2. Change the `SCHEMA_VERSION` in this library to this new Cargo.toml version -const APPROVED_SCHEMA_FILE_HASH: &str = "8234561557367848394"; +const APPROVED_SCHEMA_FILE_HASH: &str = "9911558308202795111"; #[test] fn schema_version() {