@firebolt-js/manage-sdk
Version:
The Firebolt Manage JS SDK
300 lines (298 loc) • 6.56 kB
JavaScript
/*
* Copyright 2021 Comcast Cable Communications Management, LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* SPDX-License-Identifier: Apache-2.0
*/
import MockProps from '../Prop/MockProps.mjs'
export default {
allowResumePoints: function (params) {
return MockProps.mock(
'Privacy',
'allowResumePoints',
params,
undefined,
0,
true,
)
},
allowUnentitledResumePoints: function (params) {
return MockProps.mock(
'Privacy',
'allowUnentitledResumePoints',
params,
undefined,
0,
true,
)
},
allowWatchHistory: function (params) {
return MockProps.mock(
'Privacy',
'allowWatchHistory',
params,
undefined,
0,
true,
)
},
allowProductAnalytics: function (params) {
return MockProps.mock(
'Privacy',
'allowProductAnalytics',
params,
undefined,
0,
true,
)
},
allowPersonalization: function (params) {
return MockProps.mock(
'Privacy',
'allowPersonalization',
params,
undefined,
0,
true,
)
},
allowUnentitledPersonalization: function (params) {
return MockProps.mock(
'Privacy',
'allowUnentitledPersonalization',
params,
undefined,
0,
true,
)
},
allowRemoteDiagnostics: function (params) {
return MockProps.mock(
'Privacy',
'allowRemoteDiagnostics',
params,
undefined,
0,
true,
)
},
allowPrimaryContentAdTargeting: function (params) {
return MockProps.mock(
'Privacy',
'allowPrimaryContentAdTargeting',
params,
undefined,
0,
true,
)
},
allowPrimaryBrowseAdTargeting: function (params) {
return MockProps.mock(
'Privacy',
'allowPrimaryBrowseAdTargeting',
params,
undefined,
0,
true,
)
},
allowAppContentAdTargeting: function (params) {
return MockProps.mock(
'Privacy',
'allowAppContentAdTargeting',
params,
undefined,
0,
true,
)
},
allowACRCollection: function (params) {
return MockProps.mock(
'Privacy',
'allowACRCollection',
params,
undefined,
0,
true,
)
},
allowCameraAnalytics: function (params) {
return MockProps.mock(
'Privacy',
'allowCameraAnalytics',
params,
undefined,
0,
true,
)
},
settings: {
allowACRCollection: true,
allowResumePoints: false,
allowAppContentAdTargeting: false,
allowCameraAnalytics: true,
allowPersonalization: true,
allowPrimaryBrowseAdTargeting: false,
allowPrimaryContentAdTargeting: false,
allowProductAnalytics: true,
allowRemoteDiagnostics: true,
allowUnentitledPersonalization: true,
allowUnentitledResumePoints: false,
allowWatchHistory: true,
},
setAllowResumePoints: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowResumePoints',
params,
callbackOrValue,
0,
null,
)
},
setAllowUnentitledResumePoints: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowUnentitledResumePoints',
params,
callbackOrValue,
0,
null,
)
},
setAllowWatchHistory: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowWatchHistory',
params,
callbackOrValue,
0,
null,
)
},
setAllowProductAnalytics: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowProductAnalytics',
params,
callbackOrValue,
0,
null,
)
},
setAllowPersonalization: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowPersonalization',
params,
callbackOrValue,
0,
null,
)
},
setAllowUnentitledPersonalization: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowUnentitledPersonalization',
params,
callbackOrValue,
0,
null,
)
},
setAllowRemoteDiagnostics: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowRemoteDiagnostics',
params,
callbackOrValue,
0,
null,
)
},
setAllowPrimaryContentAdTargeting: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowPrimaryContentAdTargeting',
params,
callbackOrValue,
0,
null,
)
},
setAllowPrimaryBrowseAdTargeting: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowPrimaryBrowseAdTargeting',
params,
callbackOrValue,
0,
null,
)
},
setAllowAppContentAdTargeting: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowAppContentAdTargeting',
params,
callbackOrValue,
0,
null,
)
},
setAllowACRCollection: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowACRCollection',
params,
callbackOrValue,
0,
null,
)
},
setAllowCameraAnalytics: function (params) {
const callbackOrValue = params.value
delete params.value
return MockProps.mock(
'Privacy',
'allowCameraAnalytics',
params,
callbackOrValue,
0,
null,
)
},
}