summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAliaksandr Kalenik <kalenik.aliaksandr@gmail.com>2023-04-05 09:14:42 +0300
committerAndreas Kling <kling@serenityos.org>2023-05-03 09:39:49 +0200
commit8be3de665b8909974d464c5f42757bfce47bc4c9 (patch)
treed6a66142eef4b2fc9bd081ddd078caa1160499ec
parent2adcf85d9dce3263cb9290eef9c7d42d1d5033a7 (diff)
downloadserenity-8be3de665b8909974d464c5f42757bfce47bc4c9.zip
LibWeb: Introduce SourceSnapshotParams
-rw-r--r--Userland/Libraries/LibWeb/HTML/SourceSnapshotParams.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/HTML/SourceSnapshotParams.h b/Userland/Libraries/LibWeb/HTML/SourceSnapshotParams.h
new file mode 100644
index 0000000000..8dc3e974dc
--- /dev/null
+++ b/Userland/Libraries/LibWeb/HTML/SourceSnapshotParams.h
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2023, Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
+ *
+ * SPDX-License-Identifier: BSD-2-Clause
+ */
+
+#pragma once
+
+#include <LibWeb/HTML/PolicyContainers.h>
+#include <LibWeb/HTML/SandboxingFlagSet.h>
+
+namespace Web::HTML {
+
+// https://html.spec.whatwg.org/multipage/browsing-the-web.html#source-snapshot-params
+struct SourceSnapshotParams {
+ // a boolean
+ bool has_transient_activation;
+
+ // a sandboxing flag set
+ SandboxingFlagSet sandboxing_flags;
+
+ // a boolean
+ bool allows_downloading;
+
+ // an environment settings object, only to be used as a request client
+ JS::GCPtr<EnvironmentSettingsObject> fetch_client;
+
+ // a policy container
+ PolicyContainer source_policy_container;
+};
+
+}