conflict_resolution
stringlengths 27
16k
|
---|
<<<<<<<
if (cache.concept) {
setPreviewsForVertex(cache, this.workspaceId);
} else console.error('Unable to attach concept to vertex', cache.properties._conceptType);
=======
if (cache.concept) {
setPreviewsForVertex(cache);
} else console.error('Unable to attach concept to vertex', cache.properties._conceptType);
cache.resolvedSource = this.resolvedSourceForProperties(cache.properties);
>>>>>>>
if (cache.concept) {
setPreviewsForVertex(cache, this.workspaceId);
} else console.error('Unable to attach concept to vertex', cache.properties._conceptType);
cache.resolvedSource = this.resolvedSourceForProperties(cache.properties);
<<<<<<<
function setPreviewsForVertex(vertex, currentWorkspace) {
var workspaceParameter = '?workspaceId=' + encodeURIComponent(currentWorkspace),
vId = encodeURIComponent(vertex.id),
artifactUrl = _.template("/artifact/" + vId + "/<%= type %>" + workspaceParameter);
vertex.imageSrcIsFromConcept = false;
if (vertex.properties._glyphIcon) {
vertex.imageSrc = vertex.properties._glyphIcon.value + workspaceParameter;
} else {
switch (vertex.concept.displayType) {
case 'image':
vertex.imageSrc = artifactUrl({ type: 'thumbnail' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
break;
case 'video':
vertex.imageSrc = artifactUrl({ type: 'poster-frame' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageFramesSrc = artifactUrl({ type: 'video-preview' });
break;
default:
vertex.imageSrc = vertex.concept.glyphIconHref;
vertex.imageSrcIsFromConcept = true;
}
}
}
=======
function setPreviewsForVertex(vertex) {
var vId = encodeURIComponent(vertex.id),
artifactUrl = _.template("/artifact/" + vId + "/{ type }");
vertex.imageSrcIsFromConcept = false;
if (vertex.properties._glyphIcon) {
vertex.imageSrc = vertex.properties._glyphIcon.value;
} else {
switch (vertex.concept.displayType) {
case 'image':
vertex.imageSrc = artifactUrl({ type: 'thumbnail' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
break;
case 'video':
vertex.imageSrc = artifactUrl({ type: 'poster-frame' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageFramesSrc = artifactUrl({ type: 'video-preview' });
break;
default:
vertex.imageSrc = vertex.concept.glyphIconHref;
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageSrcIsFromConcept = true;
}
}
}
this.resolvedSourceForProperties = function(p) {
var source = p.source && p.source.value,
author = p.author && p.author.value;
return source ?
author ? ([source,author].join(' / ')) : source :
author ? author : '';
}
>>>>>>>
function setPreviewsForVertex(vertex, currentWorkspace) {
var workspaceParameter = '?workspaceId=' + encodeURIComponent(currentWorkspace),
vId = encodeURIComponent(vertex.id),
artifactUrl = _.template("/artifact/" + vId + "/<%= type %>" + workspaceParameter);
vertex.imageSrcIsFromConcept = false;
if (vertex.properties._glyphIcon) {
vertex.imageSrc = vertex.properties._glyphIcon.value + workspaceParameter;
} else {
switch (vertex.concept.displayType) {
case 'image':
vertex.imageSrc = artifactUrl({ type: 'thumbnail' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
break;
case 'video':
vertex.imageSrc = artifactUrl({ type: 'poster-frame' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageFramesSrc = artifactUrl({ type: 'video-preview' });
break;
default:
vertex.imageSrc = vertex.concept.glyphIconHref;
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageSrcIsFromConcept = true;
}
}
}
this.resolvedSourceForProperties = function(p) {
var source = p.source && p.source.value,
author = p.author && p.author.value;
return source ?
author ? ([source,author].join(' / ')) : source :
author ? author : '';
} |
<<<<<<<
import logger from 'logger'
=======
import { Observable } from 'rxjs'
>>>>>>>
import logger from 'logger'
import { Observable } from 'rxjs' |
<<<<<<<
const AdvancedOptions = ({ onChange, account, transaction, status }: Props) => {
invariant(transaction.family === 'ethereum', 'AdvancedOptions: ethereum family expected')
const onGasLimitChange = useCallback(
(str: string) => {
const bridge = getAccountBridge(account)
let userGasLimit = BigNumber(str || 0)
if (userGasLimit.isNaN() || !userGasLimit.isFinite()) {
userGasLimit = BigNumber(0x5208)
}
onChange(bridge.updateTransaction(transaction, { userGasLimit }))
},
[account, transaction, onChange],
)
const gasLimit = getGasLimit(transaction)
const { gasLimit: gasLimitError } = status.errors
const { gasLimit: gasLimitWarning } = status.warnings
return (
<Box horizontal align="center" flow={5}>
<Box style={{ width: 200 }}>
<Label>
<span>
<Trans i18nKey="send.steps.amount.ethereumGasLimit" />
</span>
</Label>
</Box>
<Box grow>
<Input
ff="Rubik"
warning={gasLimitWarning}
error={gasLimitError}
value={gasLimit.toString()}
onChange={onGasLimitChange}
loading={!transaction.networkInfo && !transaction.userGasLimit}
/>
=======
class AdvancedOptions extends PureComponent<Props, *> {
state = { isValid: false }
componentDidMount() {
this.resync()
}
componentDidUpdate(nextProps: Props) {
if (nextProps.transaction !== this.props.transaction) {
this.resync()
}
}
componentWillUnmount() {
this.syncId++
this.isUnmounted = true
}
isUnmounted = false
syncId = 0
async resync() {
const syncId = ++this.syncId
const { account, transaction } = this.props
const bridge = getAccountBridge(account)
const recipient = bridge.getTransactionRecipient(account, transaction)
const isValid = await bridge
.checkValidRecipient(account, recipient)
.then(() => true, () => false)
if (syncId !== this.syncId) return
if (this.isUnmounted) return
this.setState(s => (s.isValid !== isValid ? { isValid } : null))
if (isValid) {
const t = await bridge.prepareTransaction(account, transaction)
if (syncId !== this.syncId) return
if (t !== transaction) this.props.onChange(t)
}
}
onChange = (str: string) => {
const { account, transaction, onChange } = this.props
const bridge = getAccountBridge(account)
let gasLimit = BigNumber(str || 0)
if (gasLimit.isNaN() || !gasLimit.isFinite()) {
gasLimit = BigNumber(0x5208)
}
onChange(bridge.editTransactionExtra(account, transaction, 'gasLimit', gasLimit))
}
render() {
const { account, transaction, t } = this.props
const { isValid } = this.state
const bridge = getAccountBridge(account)
const gasLimit = bridge.getTransactionExtra(account, transaction, 'gasLimit')
return (
<Box horizontal align="center" flow={5}>
<Box style={{ width: 200 }}>
<Label>
<span>{t('send.steps.amount.ethereumGasLimit')}</span>
</Label>
</Box>
<Box grow>
<Input
ff="Inter"
value={gasLimit ? gasLimit.toString() : ''}
onChange={this.onChange}
loading={isValid && !gasLimit}
/>
</Box>
>>>>>>>
const AdvancedOptions = ({ onChange, account, transaction, status }: Props) => {
invariant(transaction.family === 'ethereum', 'AdvancedOptions: ethereum family expected')
const onGasLimitChange = useCallback(
(str: string) => {
const bridge = getAccountBridge(account)
let userGasLimit = BigNumber(str || 0)
if (userGasLimit.isNaN() || !userGasLimit.isFinite()) {
userGasLimit = BigNumber(0x5208)
}
onChange(bridge.updateTransaction(transaction, { userGasLimit }))
},
[account, transaction, onChange],
)
const gasLimit = getGasLimit(transaction)
const { gasLimit: gasLimitError } = status.errors
const { gasLimit: gasLimitWarning } = status.warnings
return (
<Box horizontal align="center" flow={5}>
<Box style={{ width: 200 }}>
<Label>
<span>
<Trans i18nKey="send.steps.amount.ethereumGasLimit" />
</span>
</Label>
</Box>
<Box grow>
<Input
ff="Inter"
warning={gasLimitWarning}
error={gasLimitError}
value={gasLimit.toString()}
onChange={onGasLimitChange}
loading={!transaction.networkInfo && !transaction.userGasLimit}
/> |
<<<<<<<
const logCmds = !__DEV__ || process.env.DEBUG_COMMANDS
const logDb = !__DEV__ || process.env.DEBUG_DB
const logClicks = !__DEV__ || process.env.DEBUG_CLICK_ELEMENT
=======
>>>>>>>
const logCmds = !__DEV__ || process.env.DEBUG_COMMANDS
const logDb = !__DEV__ || process.env.DEBUG_DB
<<<<<<<
// tracks the user interactions (click, input focus/blur, what else?)
onClickElement: (role: string, roleData: ?Object) => {
const label = `👆 ${role}`
if (roleData) {
if (logClicks) {
console.log(label, roleData)
}
addLog('click', label, roleData)
} else {
if (logClicks) {
console.log(label)
}
addLog('click', label, roleData)
}
},
onCmd: (type: string, id: string, spentTime: number, data?: any) => {
if (logCmds) {
switch (type) {
case 'cmd.START':
console.log(`CMD ${id}.send(`, data, ')')
break
case 'cmd.NEXT':
console.log(`● CMD ${id}`, data)
break
case 'cmd.COMPLETE':
console.log(`✔ CMD ${id} finished in ${spentTime.toFixed(0)}ms`)
break
case 'cmd.ERROR':
console.warn(`✖ CMD ${id} error`, data)
break
default:
}
}
addLog('cmd', type, id, spentTime, data)
},
onDB: (way: 'read' | 'write' | 'clear', name: string, obj: ?Object) => {
const msg = `📁 ${way} ${name}:`
if (logDb) {
console.log(msg, obj)
}
addLog('db', msg)
},
=======
>>>>>>>
onCmd: (type: string, id: string, spentTime: number, data?: any) => {
if (logCmds) {
switch (type) {
case 'cmd.START':
console.log(`CMD ${id}.send(`, data, ')')
break
case 'cmd.NEXT':
console.log(`● CMD ${id}`, data)
break
case 'cmd.COMPLETE':
console.log(`✔ CMD ${id} finished in ${spentTime.toFixed(0)}ms`)
break
case 'cmd.ERROR':
console.warn(`✖ CMD ${id} error`, data)
break
default:
}
}
addLog('cmd', type, id, spentTime, data)
},
onDB: (way: 'read' | 'write' | 'clear', name: string, obj: ?Object) => {
const msg = `📁 ${way} ${name}:`
if (logDb) {
console.log(msg, obj)
}
addLog('db', msg)
}, |
<<<<<<<
<Price
withEquality
withActivityColor="wallet"
from={from}
to={to}
color="graphite"
fontSize={3}
placeholder={<NoData />}
/>
=======
<Ellipsis>
<Price
withEquality
from={from}
to={to}
color="graphite"
fontSize={3}
placeholder={<PlaceholderLine width={16} height={2} />}
/>
</Ellipsis>
>>>>>>>
<Price
withEquality
from={from}
to={to}
color="graphite"
fontSize={3}
placeholder={<NoData />}
/> |
<<<<<<<
libcoreScanAccounts,
libcoreSignAndBroadcast,
=======
listenDevices,
uninstallApp,
installOsuFirmware,
installFinalFirmware,
installMcu,
>>>>>>>
libcoreScanAccounts,
libcoreSignAndBroadcast,
listenDevices,
uninstallApp,
installOsuFirmware,
installFinalFirmware,
installMcu, |
<<<<<<<
if (isStandard) {
if (balanceZerosCount === 0) {
// first zero account will emit one account as opportunity to create a new account..
const currentBlock = await lazyCurrentBlock()
const accountId = `${currency.id}_${address}`
const account: Account = {
id: accountId,
xpub: '',
path,
walletPath: String(index),
name: 'New Account',
isSegwit: false,
address,
addresses: [address],
balance,
blockHeight: currentBlock.height,
archived: true,
index,
currency,
operations: [],
unit: currency.units[0],
lastSyncDate: new Date(),
}
return { account, complete: true }
=======
if (balanceZerosCount === 0) {
// first zero account will emit one account as opportunity to create a new account..
const currentBlock = await lazyCurrentBlock()
const accountId = `${currency.id}_${address}`
const account: Account = {
id: accountId,
xpub: '',
path, // FIXME we probably not want the address path in the account.path
walletPath: String(index),
name: 'New Account',
isSegwit: false,
address,
addresses: [{ str: address, path, }],
balance,
blockHeight: currentBlock.height,
archived: true,
index,
currency,
operations: [],
unit: currency.units[0],
lastSyncDate: new Date(),
>>>>>>>
if (isStandard) {
if (balanceZerosCount === 0) {
// first zero account will emit one account as opportunity to create a new account..
const currentBlock = await lazyCurrentBlock()
const accountId = `${currency.id}_${address}`
const account: Account = {
id: accountId,
xpub: '',
path, // FIXME we probably not want the address path in the account.path
walletPath: String(index),
name: 'New Account',
isSegwit: false,
address,
addresses: [{ str: address, path, }],
balance,
blockHeight: currentBlock.height,
archived: true,
index,
currency,
operations: [],
unit: currency.units[0],
lastSyncDate: new Date(),
}
return { account, complete: true } |
<<<<<<<
accounts: flattenAccounts(accountsSelector(state), {
enforceHideEmptySubAccounts: true,
}).filter(a => getAccountCurrency(a) === findCurrencyByTicker(props.match.params.assetTicker)),
=======
accounts: flattenSortAccountsEnforceHideEmptyTokenSelector(state).filter(
a =>
(a.type === 'Account' ? a.currency : a.token) ===
findCurrencyByTicker(props.match.params.assetTicker),
),
>>>>>>>
accounts: flattenSortAccountsEnforceHideEmptyTokenSelector(state).filter(
a => getAccountCurrency(a) === findCurrencyByTicker(props.match.params.assetTicker),
), |
<<<<<<<
import { getCurrencyColor } from 'helpers/getCurrencyColor'
import { findCurrencyByTicker } from '@ledgerhq/live-common/lib/currencies'
=======
import { getCurrencyColor } from '@ledgerhq/live-common/lib/currencies'
>>>>>>>
import { getCurrencyColor } from 'helpers/getCurrencyColor' |
<<<<<<<
error: ?Error,
appsList: LedgerScriptParams[],
appsLoaded: boolean,
=======
error: ?Error,
appsList: LedgerScriptParams[] | Array<*>,
>>>>>>>
error: ?Error,
appsList: LedgerScriptParams[],
appsLoaded: boolean,
<<<<<<<
this.setState({ status: 'error', error: err, mode: 'home' })
=======
this.setState({ status: 'error', error: err, app: '', mode: 'home' })
>>>>>>>
this.setState({ status: 'error', error: err, mode: 'home' })
<<<<<<<
=======
console.log('what is error?? : ', error)
>>>>>>>
<<<<<<<
<Box align="center" justify="center" flow={3}>
<TranslatedError error={error} />
<Button primary onClick={this.handleCloseModal}>
close
</Button>
</Box>
=======
<Fragment>
<ModalContent grow align="center" justify="center" mt={3}>
<Box color="alertRed">
<ExclamationCircleThin size={44} />
</Box>
<Box
color="black"
mt={4}
fontSize={6}
ff="Museo Sans|Regular"
textAlign="center"
style={{ maxWidth: 350 }}
>
<TranslatedError error={error} />
</Box>
</ModalContent>
<ModalFooter horizontal justifyContent="flex-end" style={{ width: '100%' }}>
<Button primary padded onClick={this.handleCloseModal}>
{t('app:common.close')}
</Button>
</ModalFooter>
</Fragment>
>>>>>>>
<Fragment>
<ModalContent grow align="center" justify="center" mt={3}>
<Box color="alertRed">
<ExclamationCircleThin size={44} />
</Box>
<Box
color="black"
mt={4}
fontSize={6}
ff="Museo Sans|Regular"
textAlign="center"
style={{ maxWidth: 350 }}
>
<TranslatedError error={error} />
</Box>
</ModalContent>
<ModalFooter horizontal justifyContent="flex-end" style={{ width: '100%' }}>
<Button primary padded onClick={this.handleCloseModal}>
{t('app:common.close')}
</Button>
</ModalFooter>
</Fragment> |
<<<<<<<
accountDistribution: accounts.map(a => ({
account: a,
currency: getAccountCurrency(a),
distribution: a.balance.div(total).toFixed(2),
amount: a.balance,
countervalue: calculateCountervalueSelector(state)(getAccountCurrency(a), a.balance),
})),
=======
accountDistribution: accounts
.map(a => ({
account: a,
currency: a.type === 'Account' ? a.currency : a.token,
distribution: a.balance.div(total).toFixed(2),
amount: a.balance,
countervalue: calculateCountervalueSelector(state)(
a.type === 'Account' ? a.currency : a.token,
a.balance,
),
}))
.sort((a, b) => b.distribution - a.distribution),
>>>>>>>
accountDistribution: accounts
.map(a => ({
account: a,
currency: getAccountCurrency(a),
distribution: a.balance.div(total).toFixed(2),
amount: a.balance,
countervalue: calculateCountervalueSelector(state)(getAccountCurrency(a), a.balance),
}))
.sort((a, b) => b.distribution - a.distribution), |
<<<<<<<
<<<<<<< HEAD
/**
* @constructor
*/
window.fsLightboxObject = function () {
=======
"use strict";
=======
>>>>>>>
<<<<<<<
function fsLightboxObject() {
>>>>>>> animations
=======
window.fsLightboxObject = function () {
>>>>>>>
window.fsLightboxObject = function () {
<<<<<<<
<<<<<<< HEAD
rememberedSourcesDimensions: [],
=======
>>>>>>> animations
=======
rememberedSourcesDimensions: [],
>>>>>>>
rememberedSourcesDimensions: [],
<<<<<<<
<<<<<<< HEAD
let xd = require('./renderDom')(this, DOMObject);
=======
this.renderDOM();
>>>>>>> animations
=======
let xd = require('./renderDom')(this, DOMObject);
>>>>>>>
let xd = require('./renderDom')(this, DOMObject);
xd = '';
<<<<<<<
<<<<<<< HEAD
this.slide = function () {
this.previousSlideViaButton = function () {
if (self.data.slide > 1) {
self.data.slide -= 1;
} else {
self.data.slide = self.data.total_slides
}
//load source by index (array is indexed from 0 so we need to decrement index)
self.loadsource(self.data.urls[self.data.slide - 1]);
};
this.nextSlideViaButton = function () {
if (self.data.slide < self.data.total_slides) {
self.data.slide += 1;
} else {
self.data.slide = 1;
}
//load source by index (array is indexed from 0 so we need to decrement index)
self.loadsource(self.data.urls[self.data.slide - 1]);
};
};
/**
* Div that holds source elem
=======
/**
* Method that takes care of rendering whole dom of fsLightbox
*/
this.renderDOM = function () {
let privateMethods = {
renderNav: function (container) {
let nav = new DOMObject('div').addClassesAndCreate(['fslightbox-nav']);
let toolbar = new self.toolbar();
toolbar.renderToolbar(nav);
let slideCounter = new self.slideCounter();
slideCounter.renderSlideCounter(nav);
container.appendChild(nav);
},
renderSlideButtons: function (container) {
if (self.data.isRenderingSlideButtons === false) {
return false;
}
//render left btn
let left_btn_container = new DOMObject('div').addClassesAndCreate(['fslightbox-slide-btn-container']);
let btn = new DOMObject('div').addClassesAndCreate(['fslightbox-slide-btn', 'button-style']);
btn.appendChild(
new self.SVGIcon().getSVGIcon('M8.388,10.049l4.76-4.873c0.303-0.31,0.297-0.804-0.012-1.105c-0.309-0.304-0.803-0.293-1.105,0.012L6.726,9.516c-0.303,0.31-0.296,0.805,0.012,1.105l5.433,5.307c0.152,0.148,0.35,0.223,0.547,0.223c0.203,0,0.406-0.08,0.559-0.236c0.303-0.309,0.295-0.803-0.012-1.104L8.388,10.049z')
);
container.appendChild(left_btn_container);
//go to previous slide onclick
left_btn_container.onclick = function () {
if(self.data.slide > 1) {
self.data.slide -= 1;
} else {
self.data.slide = self.data.total_slides
}
//load source by index (array is indexed from 0 so we need to decrement index)
self.loadsource(self.data.urls[self.data.slide - 1]);
};
left_btn_container.appendChild(btn);
let right_btn_container = new DOMObject('div').addClassesAndCreate(['fslightbox-slide-btn-container', 'fslightbox-slide-btn-right-container']);
btn = new DOMObject('div').addClassesAndCreate(['fslightbox-slide-btn', 'button-style']);
btn.appendChild(
new self.SVGIcon().getSVGIcon('M11.611,10.049l-4.76-4.873c-0.303-0.31-0.297-0.804,0.012-1.105c0.309-0.304,0.803-0.293,1.105,0.012l5.306,5.433c0.304,0.31,0.296,0.805-0.012,1.105L7.83,15.928c-0.152,0.148-0.35,0.223-0.547,0.223c-0.203,0-0.406-0.08-0.559-0.236c-0.303-0.309-0.295-0.803,0.012-1.104L11.611,10.049z')
);
//go to next slide onclick
right_btn_container.onclick = function () {
if(self.data.slide < self.data.total_slides) {
self.data.slide += 1;
} else {
self.data.slide = 1;
}
=======
this.slide = function () {
>>>>>>>
this.slide = function () {
<<<<<<<
* @constructor
>>>>>>> animations
=======
* Div that holds source elem
>>>>>>>
* Div that holds source elem
<<<<<<<
<<<<<<< HEAD
=======
this.slideByDrag = function () {
};
>>>>>>> animations
=======
>>>>>>>
<<<<<<<
<<<<<<< HEAD
const indexOfSourceURL = self.data.urls.indexOf(url);
let sourceDimensions = function (sourceElem, sourceWidth, sourceHeight) {
if (typeof sourceWidth === "undefined") {
sourceWidth = self.data.onResizeEvent.rememberdWidth;
sourceHeight = self.data.onResizeEvent.rememberdHeight;
}
const coefficient = sourceWidth / sourceHeight;
const deviceWidth = window.innerWidth;
const deviceHeight = window.innerHeight;
let newHeight = deviceWidth / coefficient;
if (newHeight < deviceHeight - 60) {
sourceElem.style.height = newHeight + "px";
sourceElem.style.width = deviceWidth + "px";
} else {
newHeight = deviceHeight - 60;
sourceElem.style.height = newHeight + "px";
sourceElem.style.width = newHeight * coefficient + "px";
}
};
=======
>>>>>>> animations
=======
const indexOfSourceURL = self.data.urls.indexOf(url);
let sourceDimensions = function (sourceElem, sourceWidth, sourceHeight) {
if (typeof sourceWidth === "undefined") {
sourceWidth = self.data.onResizeEvent.rememberdWidth;
sourceHeight = self.data.onResizeEvent.rememberdHeight;
}
const coefficient = sourceWidth / sourceHeight;
const deviceWidth = window.innerWidth;
const deviceHeight = window.innerHeight;
let newHeight = deviceWidth / coefficient;
if (newHeight < deviceHeight - 60) {
sourceElem.style.height = newHeight + "px";
sourceElem.style.width = deviceWidth + "px";
} else {
newHeight = deviceHeight - 60;
sourceElem.style.height = newHeight + "px";
sourceElem.style.width = newHeight * coefficient + "px";
}
};
>>>>>>>
const indexOfSourceURL = self.data.urls.indexOf(url);
let sourceDimensions = function (sourceElem, sourceWidth, sourceHeight) {
if (typeof sourceWidth === "undefined") {
sourceWidth = self.data.onResizeEvent.rememberdWidth;
sourceHeight = self.data.onResizeEvent.rememberdHeight;
}
const coefficient = sourceWidth / sourceHeight;
const deviceWidth = window.innerWidth;
const deviceHeight = window.innerHeight;
let newHeight = deviceWidth / coefficient;
if (newHeight < deviceHeight - 60) {
sourceElem.style.height = newHeight + "px";
sourceElem.style.width = deviceWidth + "px";
} else {
newHeight = deviceHeight - 60;
sourceElem.style.height = newHeight + "px";
sourceElem.style.width = newHeight * coefficient + "px";
}
};
<<<<<<<
<<<<<<< HEAD
//normal source dimensions needs to be stored in array
//it will be needed when loading source from memory
self.data.rememberedSourcesDimensions.splice(indexOfSourceURL, 0, {
"width": sourceWidth,
"height": sourceHeight
});
//set dimension for the first time
self.data.onResizeEvent.sourceDimensions(sourceWidth, sourceHeight);
//append elem
self.data.mediaHolder.holder.innerHTML = '';
self.data.mediaHolder.holder.appendChild(sourceElem);
//add some fade in animation
sourceElem.classList.remove('fslightbox-fade-in');
void sourceElem.offsetWidth;
sourceElem.classList.add('fslightbox-fade-in');
//push elem to array from where it will be loaded again if needed
self.data.sources[indexOfSourceURL] = sourceElem;
=======
=======
//normal source dimensions needs to be stored in array
//it will be needed when loading source from memory
self.data.rememberedSourcesDimensions.splice(indexOfSourceURL, 0, {
"width": sourceWidth,
"height": sourceHeight
});
//set dimension for the first time
>>>>>>>
//normal source dimensions needs to be stored in array
//it will be needed when loading source from memory
self.data.rememberedSourcesDimensions.splice(indexOfSourceURL, 0, {
"width": sourceWidth,
"height": sourceHeight
});
//set dimension for the first time
<<<<<<<
self.data.sources.push(sourceElem);
>>>>>>> animations
=======
//push elem to array from where it will be loaded again if needed
self.data.sources[indexOfSourceURL] = sourceElem;
>>>>>>>
//push elem to array from where it will be loaded again if needed
self.data.sources[indexOfSourceURL] = sourceElem;
<<<<<<<
<<<<<<< HEAD
=======
xhr.dataType = 'json';
>>>>>>> animations
=======
>>>>>>>
<<<<<<<
<<<<<<< HEAD
if (typeof this.data.sources[indexOfSourceURL] === "undefined") {
this.createSourceElem();
} else {
const sourceElem = self.data.sources[indexOfSourceURL];
const rememberedSourceDimensions = self.data.rememberedSourcesDimensions[indexOfSourceURL];
console.log(rememberedSourceDimensions);
self.data.mediaHolder.holder.innerHTML = '';
self.data.mediaHolder.holder.appendChild(sourceElem);
self.data.onResizeEvent.sourceDimensions = function () {
sourceDimensions(
sourceElem,
rememberedSourceDimensions[indexOfSourceURL].width,
rememberedSourceDimensions[indexOfSourceURL].height
);
};
=======
if (typeof this.data.sources[this.data.urls.indexOf(url)] === "undefined") {
=======
if (typeof this.data.sources[indexOfSourceURL] === "undefined") {
>>>>>>>
if (typeof this.data.sources[indexOfSourceURL] === "undefined") {
<<<<<<<
_this.data.mediaHolder.holder.innerHTML = '';
_this.data.mediaHolder.holder.appendChild(
_this.data.sources[this.data.urls.indexOf(url)]
);
>>>>>>> animations
=======
const sourceElem = self.data.sources[indexOfSourceURL];
const rememberedSourceDimensions = self.data.rememberedSourcesDimensions[indexOfSourceURL];
console.log(rememberedSourceDimensions);
self.data.mediaHolder.holder.innerHTML = '';
self.data.mediaHolder.holder.appendChild(sourceElem);
self.data.onResizeEvent.sourceDimensions = function () {
sourceDimensions(
sourceElem,
rememberedSourceDimensions[indexOfSourceURL].width,
rememberedSourceDimensions[indexOfSourceURL].height
);
};
>>>>>>>
const sourceElem = self.data.sources[indexOfSourceURL];
const rememberedSourceDimensions = self.data.rememberedSourcesDimensions[indexOfSourceURL];
console.log(rememberedSourceDimensions);
self.data.mediaHolder.holder.innerHTML = '';
self.data.mediaHolder.holder.appendChild(sourceElem);
self.data.onResizeEvent.sourceDimensions = function () {
sourceDimensions(
sourceElem,
rememberedSourceDimensions[indexOfSourceURL].width,
rememberedSourceDimensions[indexOfSourceURL].height
);
}; |
<<<<<<<
client.v[vId] = {
directory: msg.data
=======
if (!isPathSane(msg.data, true)) return log.log(log.socket(remoteIP, remotePort), " Invalid update request: " + msg.data);
clients[cookie] = {
directory: msg.data,
ws: ws
>>>>>>>
if (!isPathSane(msg.data, true)) return log.log(log.socket(remoteIP, remotePort), " Invalid update request: " + msg.data);
client.v[vId] = {
directory: msg.data
<<<<<<<
if (!/^\//.test(msg.data) || /^(\.+)$/.test(msg.data)) return;
client.v[vId].directory = msg.data;
=======
if (!isPathSane(msg.data, true)) return log.log(log.socket(remoteIP, remotePort), " Invalid directory switch request: " + msg.data);
clients[cookie].directory = msg.data;
>>>>>>>
if (!isPathSane(msg.data, true)) return log.log(log.socket(remoteIP, remotePort), " Invalid directory switch request: " + msg.data);
client.v[vId].directory = msg.data;
<<<<<<<
var p = addFilePath(client.v[vId].directory === "/" ? "/" : client.v[vId].directory + "/") + decodeURIComponent(file);
=======
if (!isPathSane(file)) return log.log(log.socket(remoteIP, remotePort), " Invalid empty file creation request: " + file);
var p = addFilePath(clients[cookie].directory === "/" ? "/" : clients[cookie].directory + "/") + decodeURIComponent(file);
>>>>>>>
if (!isPathSane(file)) return log.log(log.socket(remoteIP, remotePort), " Invalid empty file creation request: " + file);
var p = addFilePath(client.v[vId].directory === "/" ? "/" : client.v[vId].directory + "/") + decodeURIComponent(file); |
<<<<<<<
if (enter && el.attr("data-type") === "folder") {
=======
var dropZone = el.parents(".view").find(".dropzone");
if (enter && el.parents(".data-row").attr("data-type") === "folder") {
>>>>>>>
var dropZone = el.parents(".view").find(".dropzone");
if (enter && el.attr("data-type") === "folder") {
<<<<<<<
row.register("drop", function (event) {
row.removeClass("drop-hover");
=======
row.children("a").register("drop", function (event) {
$(".drop-hover").removeClass("drop-hover");
$(".dropzone").removeClass("in");
>>>>>>>
row.register("drop", function (event) {
$(".drop-hover").removeClass("drop-hover");
$(".dropzone").removeClass("in");
<<<<<<<
$(document.documentElement).register("drop", function () {
$(".drop-hover").removeClass("drop-hover");
});
=======
>>>>>>> |
<<<<<<<
hasServer = null,
ready = false,
=======
>>>>>>>
<<<<<<<
filepath = URI.match(/\?([\$~_])\/([\s\S]+)$/);
if (filepath[1] === "$") {
shortLink = true;
filepath = addFilePath(db.shortlinks[filepath[2]]);
} else if (filepath[1] === "~" || filepath[1] === "_") {
filepath = addFilePath("/" + filepath[2]);
}
=======
filepath = URI.match(/\?([\$~_])\/([\s\S]+)$/)
if (filepath[1] === "$") {
filepath = addFilePath(db.shortlinks[filepath[2]]);
} else if (filepath[1] === "~"
|| filepath[1] === "_") {
filepath = addFilePath("/" + filepath[2]);
}
>>>>>>>
filepath = URI.match(/\?([\$~_])\/([\s\S]+)$/);
if (filepath[1] === "$") {
shortLink = true;
filepath = addFilePath(db.shortlinks[filepath[2]]);
} else if (filepath[1] === "~" || filepath[1] === "_") {
filepath = addFilePath("/" + filepath[2]);
} |
<<<<<<<
view.find("#content").replaceClass(navRegex, (nav === "forward") ? "back" : "forward");
view.find("#newcontent").setTransitionClass(navRegex, "center");
=======
view.find("#content").attr("class", (droppy.animDirection === "forward") ? "back" : "forward");
view.find("#newcontent").setTransitionClass(isEditor ? "editor center" : "center");
>>>>>>>
view.find("#content").replaceClass(navRegex, (droppy.animDirection === "forward") ? "back" : "forward");
view.find("#newcontent").setTransitionClass(navRegex, "center"); |
<<<<<<<
// auto height visualizer
if(new Date().getSeconds() % 1 == 0){ // refreshing every 1 sec
// jquery iframe auto height plugin does not work in this place
// jQuery('#visualizationContainer > iframe').iframeAutoHeight();
$('#visualizationContainer > iframe').each(function(idx, el){
if(!el.contentWindow.document.body) return;
var height = el.contentWindow.document.body.scrollHeight;
$(el).height(height);
});
}
} else if(session.status=="RUNNING"){
if(new Date().getSeconds() % 1 == 0){ // refreshing every 1 sec
controller.send('loadSession', session.id);
}
} else if(session.status=="FINISHED"){
// change
} else if(session.status=="ERROR"){
} else if(session.status=="ABORT"){
}
}
}
=======
} else if(job.status=="RUNNING"){
if(new Date().getSeconds() % 1 == 0){ // refreshing every 1 sec
controller.send('loadJob', job.id);
}
} else if(job.status=="FINISHED"){
// historyis made when job finishes. update history list
controller.send('updateHistory');
} else if(job.status=="ERROR"){
} else if(job.status=="ABORT"){
}
}
}
>>>>>>>
// auto height visualizer
if(new Date().getSeconds() % 1 == 0){ // refreshing every 1 sec
// jquery iframe auto height plugin does not work in this place
// jQuery('#visualizationContainer > iframe').iframeAutoHeight();
$('#visualizationContainer > iframe').each(function(idx, el){
if(!el.contentWindow.document.body) return;
var height = el.contentWindow.document.body.scrollHeight;
$(el).height(height);
});
}
} else if(job.status=="RUNNING"){
if(new Date().getSeconds() % 1 == 0){ // refreshing every 1 sec
controller.send('loadJob', job.id);
}
} else if(job.status=="FINISHED"){
// historyis made when job finishes. update history list
controller.send('updateHistory');
} else if(job.status=="ERROR"){
} else if(job.status=="ABORT"){
}
}
} |
<<<<<<<
console.error(error);
res.json({ code: 500, message: "An error has occurred in the authorization process", error: error.message });
=======
res.status(500).json({ message: "An error has occurred in the authorization process", error });
>>>>>>>
res.status(500).json({ message: "An error has occurred in the authorization process", error: error.message }); |
<<<<<<<
triggerReady,
initElements
=======
triggerLifecycle,
triggerCreated,
triggerDetached
>>>>>>>
triggerCreated,
initElements
<<<<<<<
import version from './version';
=======
// The observer listening to document changes.
var documentObserver;
/**
* Initialises a set of elements.
*
* @param {DOMNodeList | Array} elements A traversable set of elements.
*
* @returns {undefined}
*/
function initElements (elements) {
var elementsLen = elements.length;
for (var a = 0; a < elementsLen; a++) {
var element = elements[a];
if (element.nodeType !== 1 || element.attributes[ATTR_IGNORE]) {
continue;
}
var currentNodeDefinitions = registry.getForElement(element);
var currentNodeDefinitionsLength = currentNodeDefinitions.length;
for (var b = 0; b < currentNodeDefinitionsLength; b++) {
triggerLifecycle(element, currentNodeDefinitions[b]);
}
var elementChildNodes = element.childNodes;
var elementChildNodesLen = elementChildNodes.length;
if (elementChildNodesLen) {
initElements(elementChildNodes);
}
}
}
/**
* Triggers the detached lifecycle callback on all of the elements.
*
* @param {DOMNodeList} elements The elements to trigger the remove lifecycle
* callback on.
*
* @returns {undefined}
*/
function removeElements (elements) {
var len = elements.length;
for (var a = 0; a < len; a++) {
var element = elements[a];
if (element.nodeType !== 1) {
continue;
}
removeElements(element.childNodes);
var definitions = registry.getForElement(element);
var definitionsLen = definitions.length;
for (var b = 0; b < definitionsLen; b++) {
triggerDetached(element, definitions[b]);
}
}
}
>>>>>>>
import version from './version';
<<<<<<<
=======
// IE has issues with reporting removedNodes correctly. See the polyfill for
// details. If we fix IE, we must also re-define the documentObserver.
if (definition.detached && !MutationObserver.isFixingIe) {
MutationObserver.fixIe();
destroyDocumentObserver();
}
>>>>>>> |
<<<<<<<
const propData = getNamespacedPropData(elem, name);
const attributeName = opts.attribute;
=======
const propData = data(elem, `api/property/${name}`);
const attributeName = opts.attribute === true ? dashCase(name) : opts.attribute;
>>>>>>>
const propData = getNamespacedPropData(elem, name);
const attributeName = opts.attribute === true ? dashCase(name) : opts.attribute; |
<<<<<<<
import dashCase from './util/dash-case';
import debounce from './util/debounce';
=======
import dashCase from './utils/dash-case';
import debounce from './utils/debounce';
import defaults from './defaults';
>>>>>>>
import dashCase from './util/dash-case';
import debounce from './util/debounce';
import defaults from './defaults';
<<<<<<<
=======
import skateInit from './api/init';
import skateNoConflict from './api/no-conflict';
import skateType from './api/type';
import skateVersion from './api/version';
>>>>>>>
<<<<<<<
var options = assign({}, apiDefaults);
=======
var options = assign({}, defaults);
>>>>>>>
var options = assign({}, defaults);
<<<<<<<
for (let name in apiDefaults) {
=======
for (let name in defaults) {
>>>>>>>
for (let name in defaults) {
<<<<<<<
skate.create = apiCreate;
skate.defaults = apiDefaults;
skate.init = apiInit;
skate.noConflict = apiNoConflict;
skate.type = apiType;
skate.version = apiVersion;
=======
skate.init = skateInit;
skate.noConflict = skateNoConflict;
skate.type = skateType;
skate.version = skateVersion;
>>>>>>>
skate.create = apiCreate;
skate.init = apiInit;
skate.noConflict = apiNoConflict;
skate.type = apiType;
skate.version = apiVersion; |
<<<<<<<
import {createNativePropertyDescriptor} from '../lifecycle/props-init';
=======
import initProps from '../lifecycle/props-init';
import { isFunction } from '../util/isType';
>>>>>>>
import { createNativePropertyDescriptor } from '../lifecycle/props-init';
import { isFunction } from '../util/isType';
<<<<<<<
function createNativePropertyDescriptors (Ctor) {
const propDefs = getPropsMap(Ctor);
return getAllKeys(propDefs).reduce((propDescriptors, propName) => {
propDescriptors[propName] = createNativePropertyDescriptor(propDefs[propName]);
return propDescriptors;
=======
// Ensures that definitions passed as part of the constructor are functions
// that return property definitions used on the element.
function ensurePropertyFunctions (Ctor) {
const props = getPropsMap(Ctor);
return getAllKeys(props).reduce((descriptors, descriptorName) => {
descriptors[descriptorName] = props[descriptorName];
if (!isFunction(descriptors[descriptorName])) {
descriptors[descriptorName] = initProps(descriptors[descriptorName]);
}
return descriptors;
}, {});
}
// TODO remove when not catering to Safari < 10.
//
// This can probably be simplified into createInitProps().
function ensurePropertyDefinitions (Ctor) {
const props = ensurePropertyFunctions(Ctor);
return getAllKeys(props).reduce((descriptors, descriptorName) => {
descriptors[descriptorName] = props[descriptorName](descriptorName);
return descriptors;
>>>>>>>
function createNativePropertyDescriptors (Ctor) {
const propDefs = getPropsMap(Ctor);
return getAllKeys(propDefs).reduce((propDescriptors, propName) => {
propDescriptors[propName] = createNativePropertyDescriptor(propDefs[propName]);
return propDescriptors;
<<<<<<<
const propNameOrSymbol = data(this, 'attributeLinks')[name];
=======
const propertyName = data(this, 'attributeLinks')[name];
>>>>>>>
const propNameOrSymbol = data(this, 'attributeLinks')[name];
<<<<<<<
// DEPRECATED
//
const { attributeChanged } = this.constructor;
if (attributeChanged) {
=======
// DEPRECATED
//
// static attributeChanged()
const { attributeChanged } = this.constructor;
if (isFunction(attributeChanged)) {
>>>>>>>
// DEPRECATED
//
// static attributeChanged()
const { attributeChanged } = this.constructor;
if (isFunction(attributeChanged)) {
<<<<<<<
static updated (elem, prev) {
if (!prev) {
return true;
}
// use get all keys so that we check Symbols as well as regular props
// using a for loop so we can break early
const allKeys = getAllKeys(prev);
for (let i = 0; i < allKeys.length; i += 1) {
// Object.is (NaN is equal NaN)
if (!Object.is(prev[allKeys[i]], elem[allKeys[i]])) {
return true;
}
}
return false;
}
// Skate
//
// DEPRECATED
//
// Move this to rendererCallback() before removing.
static rendered () {}
// Skate
//
// DEPRECATED
//
// Move this to rendererCallback() before removing.
=======
>>>>>>> |
<<<<<<<
function syncPropsToAttrs (elem) {
const props = elem.constructor.props;
Object.keys(props).forEach((propName) => {
const prop = props[propName];
syncPropToAttr(elem, prop, propName, true);
});
}
// Ensures that definitions passed as part of the constructor are functions
// that return property definitions used on the element.
function ensurePropertyFunctions (Ctor) {
const props = Ctor.props;
return getAllKeys(props).reduce((descriptors, descriptorName) => {
descriptors[descriptorName] = props[descriptorName];
if (typeof descriptors[descriptorName] !== 'function') {
descriptors[descriptorName] = initProps(descriptors[descriptorName]);
}
return descriptors;
}, {});
}
// Ensures the property definitions are transformed to objects that can be used
// to create properties on the element.
function ensurePropertyDefinitions (Ctor) {
const props = ensurePropertyFunctions(Ctor);
return getAllKeys(props).reduce((descriptors, descriptorName) => {
descriptors[descriptorName] = props[descriptorName](descriptorName);
return descriptors;
}, {});
}
function createInitProps (Ctor) {
const props = ensurePropertyDefinitions(Ctor);
return (elem) => {
if (!props) {
return;
}
getAllKeys(props).forEach((name) => {
const prop = props[name];
prop.created(elem);
// We check here before defining to see if the prop was specified prior
// to upgrading.
const hasPropBeforeUpgrading = name in elem;
// This is saved prior to defining so that we can set it after it it was
// defined prior to upgrading. We don't want to invoke the getter if we
// don't need to, so we only get the value if we need to re-sync.
const valueBeforeUpgrading = hasPropBeforeUpgrading && elem[name];
// https://bugs.webkit.org/show_bug.cgi?id=49739
//
// When Webkit fixes that bug so that native property accessors can be
// retrieved, we can move defining the property to the prototype and away
// from having to do if for every instance as all other browsers support
// this.
Object.defineProperty(elem, name, prop);
// We re-set the prop if it was specified prior to upgrading because we
// need to ensure set() is triggered both in polyfilled environments and
// in native where the definition may be registerd after elements it
// represents have already been created.
if (hasPropBeforeUpgrading) {
elem[name] = valueBeforeUpgrading;
}
});
};
}
function Component (...args) {
const elem = typeof Reflect === 'object'
? Reflect.construct(HTMLElement, args, this.constructor)
: HTMLElement.call(this, args[0]);
=======
// Prevent double-calling with polyfill.
const $prevName = createSymbol('name');
const $prevOldValue = createSymbol('oldValue');
const $prevNewValue = createSymbol('newValue');
function preventDoubleCalling (elem, name, oldValue, newValue) {
return name === elem[$prevName] &&
oldValue === elem[$prevOldValue] &&
newValue === elem[$prevNewValue];
}
function callConstructor (elem) {
>>>>>>>
// Prevent double-calling with polyfill.
const $prevName = createSymbol('name');
const $prevOldValue = createSymbol('oldValue');
const $prevNewValue = createSymbol('newValue');
function preventDoubleCalling (elem, name, oldValue, newValue) {
return name === elem[$prevName] &&
oldValue === elem[$prevOldValue] &&
newValue === elem[$prevNewValue];
}
function syncPropsToAttrs (elem) {
const props = elem.constructor.props;
Object.keys(props).forEach((propName) => {
const prop = props[propName];
syncPropToAttr(elem, prop, propName, true);
});
}
// Ensures that definitions passed as part of the constructor are functions
// that return property definitions used on the element.
function ensurePropertyFunctions (Ctor) {
const props = Ctor.props;
return getAllKeys(props).reduce((descriptors, descriptorName) => {
descriptors[descriptorName] = props[descriptorName];
if (typeof descriptors[descriptorName] !== 'function') {
descriptors[descriptorName] = initProps(descriptors[descriptorName]);
}
return descriptors;
}, {});
}
// Ensures the property definitions are transformed to objects that can be used
// to create properties on the element.
function ensurePropertyDefinitions (Ctor) {
const props = ensurePropertyFunctions(Ctor);
return getAllKeys(props).reduce((descriptors, descriptorName) => {
descriptors[descriptorName] = props[descriptorName](descriptorName);
return descriptors;
}, {});
}
function createInitProps (Ctor) {
const props = ensurePropertyDefinitions(Ctor);
return (elem) => {
if (!props) {
return;
}
getAllKeys(props).forEach((name) => {
const prop = props[name];
prop.created(elem);
// We check here before defining to see if the prop was specified prior
// to upgrading.
const hasPropBeforeUpgrading = name in elem;
// This is saved prior to defining so that we can set it after it it was
// defined prior to upgrading. We don't want to invoke the getter if we
// don't need to, so we only get the value if we need to re-sync.
const valueBeforeUpgrading = hasPropBeforeUpgrading && elem[name];
// https://bugs.webkit.org/show_bug.cgi?id=49739
//
// When Webkit fixes that bug so that native property accessors can be
// retrieved, we can move defining the property to the prototype and away
// from having to do if for every instance as all other browsers support
// this.
Object.defineProperty(elem, name, prop);
// We re-set the prop if it was specified prior to upgrading because we
// need to ensure set() is triggered both in polyfilled environments and
// in native where the definition may be registerd after elements it
// represents have already been created.
if (hasPropBeforeUpgrading) {
elem[name] = valueBeforeUpgrading;
}
});
};
}
function Component (...args) {
const elem = typeof Reflect === 'object'
? Reflect.construct(HTMLElement, args, this.constructor)
: HTMLElement.call(this, args[0]); |
<<<<<<<
=======
// Custom Elements v1
function Component (...args) {
const elem = typeof Reflect === 'object'
? Reflect.construct(HTMLElement, args, this.constructor)
: HTMLElement.call(this, args[0]);
callConstructor(elem);
>>>>>>>
<<<<<<<
Object.defineProperties(Component, {
// Skate
id: prop({ value: null }),
// Spec
observedAttributes: prop({
get () {
const { props } = this;
return Object.keys(props).map(key => {
const { attribute } = props[key];
return attribute === true ? dashCase(key) : attribute;
}).filter(Boolean);
},
override: 'observedAttributes'
}),
// Skate
props: prop({ value: {} })
});
=======
// Custom Elements v1
Component.observedAttributes = [];
// Skate
Component.props = {};
>>>>>>>
Object.defineProperties(Component, {
// Skate
id: prop({ value: null }),
// Custom Elements v1
observedAttributes: prop({
get () {
const { props } = this;
return Object.keys(props).map(key => {
const { attribute } = props[key];
return attribute === true ? dashCase(key) : attribute;
}).filter(Boolean);
},
override: 'observedAttributes'
}),
// Skate
props: prop({ value: {} })
}); |
<<<<<<<
import './unit/api/render';
=======
import './unit/api/state';
import './unit/attributes';
>>>>>>>
import './unit/api/state'; |
<<<<<<<
args.forEach(function (arg) {
const isInDom = elementContains(document, arg);
walkTree(arg, function (descendant) {
const component = findElementInRegistry(descendant);
if (component) {
component[created](descendant);
if (isInDom) {
component[attached](descendant);
}
=======
const isInDom = !checkIfIsInDom || elementContains(document, elem);
walkTree(elem, function (descendant) {
const component = findElementInRegistry(descendant);
if (component) {
if (component.prototype.createdCallback) {
component.prototype.createdCallback.call(descendant);
}
if (isInDom && component.prototype.attachedCallback) {
isInDom && component.prototype.attachedCallback.call(descendant);
>>>>>>>
const isInDom = !checkIfIsInDom || elementContains(document, elem);
walkTree(elem, function (descendant) {
const component = findElementInRegistry(descendant);
if (component) {
component[created](descendant);
if (isInDom) {
component[attached](descendant); |
<<<<<<<
if (cache.concept) {
setPreviewsForVertex(cache, this.workspaceId);
} else console.error('Unable to attach concept to vertex', cache.properties._conceptType);
=======
if (cache.concept) {
setPreviewsForVertex(cache);
} else console.error('Unable to attach concept to vertex', cache.properties._conceptType);
cache.resolvedSource = this.resolvedSourceForProperties(cache.properties);
>>>>>>>
if (cache.concept) {
setPreviewsForVertex(cache, this.workspaceId);
} else console.error('Unable to attach concept to vertex', cache.properties._conceptType);
cache.resolvedSource = this.resolvedSourceForProperties(cache.properties);
<<<<<<<
function setPreviewsForVertex(vertex, currentWorkspace) {
var workspaceParameter = '?workspaceId=' + encodeURIComponent(currentWorkspace),
vId = encodeURIComponent(vertex.id),
artifactUrl = _.template("/artifact/" + vId + "/<%= type %>" + workspaceParameter);
vertex.imageSrcIsFromConcept = false;
if (vertex.properties._glyphIcon) {
vertex.imageSrc = vertex.properties._glyphIcon.value + workspaceParameter;
} else {
switch (vertex.concept.displayType) {
case 'image':
vertex.imageSrc = artifactUrl({ type: 'thumbnail' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
break;
case 'video':
vertex.imageSrc = artifactUrl({ type: 'poster-frame' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageFramesSrc = artifactUrl({ type: 'video-preview' });
break;
default:
vertex.imageSrc = vertex.concept.glyphIconHref;
vertex.imageSrcIsFromConcept = true;
}
}
}
=======
function setPreviewsForVertex(vertex) {
var vId = encodeURIComponent(vertex.id),
artifactUrl = _.template("/artifact/" + vId + "/{ type }");
vertex.imageSrcIsFromConcept = false;
if (vertex.properties._glyphIcon) {
vertex.imageSrc = vertex.properties._glyphIcon.value;
} else {
switch (vertex.concept.displayType) {
case 'image':
vertex.imageSrc = artifactUrl({ type: 'thumbnail' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
break;
case 'video':
vertex.imageSrc = artifactUrl({ type: 'poster-frame' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageFramesSrc = artifactUrl({ type: 'video-preview' });
break;
default:
vertex.imageSrc = vertex.concept.glyphIconHref;
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageSrcIsFromConcept = true;
}
}
}
this.resolvedSourceForProperties = function(p) {
var source = p.source && p.source.value,
author = p.author && p.author.value;
return source ?
author ? ([source,author].join(' / ')) : source :
author ? author : '';
}
>>>>>>>
function setPreviewsForVertex(vertex, currentWorkspace) {
var workspaceParameter = '?workspaceId=' + encodeURIComponent(currentWorkspace),
vId = encodeURIComponent(vertex.id),
artifactUrl = _.template("/artifact/" + vId + "/<%= type %>" + workspaceParameter);
vertex.imageSrcIsFromConcept = false;
if (vertex.properties._glyphIcon) {
vertex.imageSrc = vertex.properties._glyphIcon.value + workspaceParameter;
} else {
switch (vertex.concept.displayType) {
case 'image':
vertex.imageSrc = artifactUrl({ type: 'thumbnail' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
break;
case 'video':
vertex.imageSrc = artifactUrl({ type: 'poster-frame' });
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageFramesSrc = artifactUrl({ type: 'video-preview' });
break;
default:
vertex.imageSrc = vertex.concept.glyphIconHref;
vertex.imageRawSrc = artifactUrl({ type: 'raw' });
vertex.imageSrcIsFromConcept = true;
}
}
}
this.resolvedSourceForProperties = function(p) {
var source = p.source && p.source.value,
author = p.author && p.author.value;
return source ?
author ? ([source,author].join(' / ')) : source :
author ? author : '';
} |
<<<<<<<
const { definedAttribute, events, created, observedAttributes, props } = Ctor;
=======
const { definedAttribute, created, observedAttributes, props, ready, renderedAttribute } = Ctor;
const renderer = Ctor[$renderer];
>>>>>>>
const { definedAttribute, created, observedAttributes, props } = Ctor; |
<<<<<<<
function isEmpty (value) {
return value == null;
}
function normaliseProp (prop) {
if (typeof prop === 'object') {
prop = assignSafe({}, prop);
} else {
prop = { type: prop };
}
return prop;
}
function normaliseAttr (prop, name) {
var attr = prop.attr;
return attr === true ? dashCase(name) : attr;
}
=======
function property (name, prop) {
var internalValue;
let isBoolean = prop.type === Boolean;
>>>>>>>
function isEmpty (value) {
return value == null;
}
function property (name, prop) {
var internalValue;
let isBoolean = prop.type === Boolean; |
<<<<<<<
=======
>>>>>>>
<<<<<<<
// _bytecode,
=======
// _bytecode,
>>>>>>>
// _bytecode,
<<<<<<<
"V1", [], [], name, symbol,
{
=======
"V1",
[accounts[0]], [100], name, symbol,
{
>>>>>>>
"V1",
[accounts[0]], [100], name, symbol,
{
<<<<<<<
getItems2(entryCore, 'getEntriesIDs', 'readEntry', mapFn)
=======
getItems2(entryCore, 'entriesAmount', 'entryInfo', mapFn)
>>>>>>>
getItems2(entryCore, 'getEntriesIDs', 'readEntry', mapFn)
<<<<<<<
// debugger
});
=======
debugger
});
>>>>>>>
// debugger
}); |
<<<<<<<
// !json templates.index
// !code vendor/mustache.js/mustache.js
=======
//!code vendor/date/date.js
>>>>>>>
// !json templates.index
// !code vendor/mustache.js/mustache.js
//!code vendor/date/date.js
<<<<<<<
return [doc, templates.index.head + "http://localhost:5984/io/_design/io/_show/long/" + shortened + templates.index.tail];
=======
doc.date = (new Date()).rfc3339();
return [doc, "http://jan.io/" + shortened + "\n"];
>>>>>>>
doc.date = (new Date()).rfc3339();
return [doc, templates.index.head + "http://localhost:5984/io/_design/io/_show/long/" + shortened + templates.index.tail]; |
<<<<<<<
["setDocs","setChrome","setElectron"],
=======
"serviceWorker",
["setDocs","setChrome"],
>>>>>>>
"serviceWorker",
["setDocs","setChrome","setElectron"], |
<<<<<<<
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', 'none')
=======
.classed('cr_' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none')
>>>>>>>
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none')
<<<<<<<
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', 'none')
=======
.classed('cr_' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none')
>>>>>>>
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none') |
<<<<<<<
state = self.frame.select('g.cge_' + uv.util.formatClassName(category)).style('display'),
=======
state = self.frame.select('g.cge-' + category.replace(' ','_', 'gim')).style('display'),
>>>>>>>
state = self.frame.select('g.cge-' + uv.util.formatClassName(category)).style('display'),
<<<<<<<
self.frame.selectAll('g.cge_' + uv.util.formatClassName(category)).style('display', (state === 'none')? null : 'none');
=======
self.frame.selectAll('g.cge-' + category.replace(' ', '_', 'gim')).style('display', (state === 'none')? null : 'none');
>>>>>>>
self.frame.selectAll('g.cge-' + uv.util.formatClassName(category)).style('display', (state === 'none')? null : 'none'); |
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).select('path.area_'+ uv.util.formatClassName(category))
=======
graph.frame.selectAll('.cge-' + category).select('path.' + uv.constants.classes.area + category)
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).select('path.' + uv.constants.classes.area + uv.util.formatClassName(category))
<<<<<<<
graph.frame.selectAll('.cge_'+ uv.util.formatClassName(category)).select('path.area_'+ uv.util.formatClassName(category))
=======
graph.frame.selectAll('.cge-'+category).select('path.' + uv.constants.classes.area +category)
>>>>>>>
graph.frame.selectAll('.cge-'+ uv.util.formatClassName(category)).select('path.'+ uv.constants.classes.area + uv.util.formatClassName(category))
graph.frame.selectAll('.cge-'+category).select('path.' + uv.constants.classes.area +category)
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).selectAll('circle')
=======
graph.frame.selectAll('.cge-' + category).selectAll('circle')
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).selectAll('circle')
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).select('path')
=======
graph.frame.selectAll('.cge-' + category).select('path')
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).select('path')
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).selectAll('text')
=======
graph.frame.selectAll('.cge-' + category).selectAll('text')
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).selectAll('text')
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).selectAll('circle')
=======
graph.frame.selectAll('.cge-' + category).selectAll('circle')
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).selectAll('circle')
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).select('path')
=======
graph.frame.selectAll('.cge-' + category).select('path')
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).select('path')
<<<<<<<
graph.frame.selectAll('.cge_' + uv.util.formatClassName(category)).selectAll('text')
=======
graph.frame.selectAll('.cge-' + category).selectAll('text')
>>>>>>>
graph.frame.selectAll('.cge-' + uv.util.formatClassName(category)).selectAll('text') |
<<<<<<<
'data/withServiceHandlers',
=======
'data/withPendingChanges',
>>>>>>>
'data/withServiceHandlers',
'data/withPendingChanges',
<<<<<<<
withVertexCache, withAjaxFilters, withServiceHandlers, withAsyncQueue,
=======
withVertexCache, withAjaxFilters, withPendingChanges, withAsyncQueue, withDocumentUnloadHandlers,
>>>>>>>
withVertexCache, withAjaxFilters, withServiceHandlers, withPendingChanges, withAsyncQueue,
<<<<<<<
DataComponent = defineComponent(Data,
withAsyncQueue,
withVertexCache,
withAjaxFilters,
withServiceHandlers);
=======
DataComponent = defineComponent(Data,
withAsyncQueue,
withVertexCache,
withAjaxFilters,
withDocumentUnloadHandlers,
withPendingChanges);
>>>>>>>
DataComponent = defineComponent(Data,
withAsyncQueue,
withVertexCache,
withAjaxFilters,
withServiceHandlers,
withDocumentUnloadHandlers,
withPendingChanges); |
<<<<<<<
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', 'none')
=======
.classed('cr_' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none')
>>>>>>>
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none')
<<<<<<<
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', 'none')
=======
.classed('cr_' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none')
>>>>>>>
.classed('cr-' + uv.util.formatClassName(self.categories[idx]), true)
.style('fill', self.config.label.showlabel ? uv.util.getColorBand(self.config, idx) : 'none') |
<<<<<<<
category = graph.categories[idx],
color = defColor || uv.util.getColorBand(graph.config, idx);
=======
category = graph.categories[idx],
barColor = uv.util.getColorBand(graph.config, idx),
textColor = color || uv.util.getColorBand(graph.config, idx);
>>>>>>>
category = graph.categories[idx],
barColor = uv.util.getColorBand(graph.config, idx),
textColor = defColor || uv.util.getColorBand(graph.config, idx); |
<<<<<<<
return USER_INPUT_QUESTIONS_LIST.findIndex( ( question ) => userInputSettings?.[ question ]?.values?.length === 0 );
=======
return {
isSavingSettings: select( CORE_USER ).isSavingUserInputSettings( userInputSettings ),
error: select( CORE_USER ).getErrorForAction( 'saveUserInputSettings', [] ),
answeredUntilIndex: USER_INPUT_QUESTIONS_LIST.findIndex( ( question ) => userInputSettings[ question ].values.length === 0 ),
};
>>>>>>>
return {
isSavingSettings: select( CORE_USER ).isSavingUserInputSettings( userInputSettings ),
error: select( CORE_USER ).getErrorForAction( 'saveUserInputSettings', [] ),
answeredUntilIndex: USER_INPUT_QUESTIONS_LIST.findIndex( ( question ) => userInputSettings?.[ question ]?.values?.length === 0 ),
}; |
<<<<<<<
ErrorNotice,
ExistingGTMPropertyNotice,
ExistingGTMPropertyError,
=======
>>>>>>>
ExistingGTMPropertyNotice,
ExistingGTMPropertyError, |
<<<<<<<
widgetSlug="urlSearchWidget"
header={ () => (
=======
slug="urlSearchWidget"
Header={ () => (
>>>>>>>
widgetSlug="urlSearchWidget"
Header={ () => ( |
<<<<<<<
if ( selectedAccount && ! responseData.accounts.find( account => account.accountId === selectedAccount ) ) {
data.deleteCache( 'tagmanager::list-accounts' );
=======
if ( selectedAccount && ! responseData.accounts.find( ( account ) => account.accountId === selectedAccount ) ) {
data.deleteCache( 'tagmanager', 'list-accounts' );
>>>>>>>
if ( selectedAccount && ! responseData.accounts.find( ( account ) => account.accountId === selectedAccount ) ) {
data.deleteCache( 'tagmanager::list-accounts' ); |
<<<<<<<
import { changeToPercent, getModulesData } from 'GoogleUtil';
=======
>>>>>>> |
<<<<<<<
SettingsViewComponent: SettingsView,
=======
settingsViewComponent: SettingsView,
icon: PageSpeedInsightsIcon,
>>>>>>>
SettingsViewComponent: SettingsView,
icon: PageSpeedInsightsIcon, |
<<<<<<<
import ReportError from '../../../../components/ReportError';
import { generateDateRangeArgs } from '../../util/report-date-range-args';
=======
>>>>>>>
import { generateDateRangeArgs } from '../../util/report-date-range-args'; |
<<<<<<<
import DashboardPopularPagesWidget from '../assets/js/modules/analytics/components/dashboard/DashboardPopularPagesWidget';
=======
import DashboardBounceRateWidget from '../assets/js/modules/analytics/components/dashboard/DashboardBounceRateWidget';
import DashboardGoalsWidget from '../assets/js/modules/analytics/components/dashboard/DashboardGoalsWidget';
import DashboardUniqueVisitorsWidget from '../assets/js/modules/analytics/components/dashboard/DashboardUniqueVisitorsWidget';
>>>>>>>
import DashboardPopularPagesWidget from '../assets/js/modules/analytics/components/dashboard/DashboardPopularPagesWidget';
import DashboardBounceRateWidget from '../assets/js/modules/analytics/components/dashboard/DashboardBounceRateWidget';
import DashboardGoalsWidget from '../assets/js/modules/analytics/components/dashboard/DashboardGoalsWidget';
import DashboardUniqueVisitorsWidget from '../assets/js/modules/analytics/components/dashboard/DashboardUniqueVisitorsWidget';
<<<<<<<
pageDashboardPopularPagesArgs,
pageDashboardPopularPagesData,
=======
pageDashboardBounceRateWidgetArgs,
pageDashboardBounceRateWidgetData,
pageDashboardUniqueVisitorsSparkArgs,
pageDashboardUniqueVisitorsSparkData,
pageDashboardUniqueVisitorsVisitorArgs,
pageDashboardUniqueVisitorsVisitorData,
dashboardBounceRateWidgetArgs,
dashboardBounceRateWidgetData,
dashboardGoalsWidgetArgs,
dashboardGoalsWidgetData,
dashboardUniqueVisitorsSparkArgs,
dashboardUniqueVisitorsVisitorArgs,
dashboardUniqueVisitorsSparkData,
dashboardUniqueVisitorsVisitorData,
>>>>>>>
pageDashboardPopularPagesArgs,
pageDashboardPopularPagesData,
pageDashboardBounceRateWidgetArgs,
pageDashboardBounceRateWidgetData,
pageDashboardUniqueVisitorsSparkArgs,
pageDashboardUniqueVisitorsSparkData,
pageDashboardUniqueVisitorsVisitorArgs,
pageDashboardUniqueVisitorsVisitorData,
dashboardBounceRateWidgetArgs,
dashboardBounceRateWidgetData,
dashboardGoalsWidgetArgs,
dashboardGoalsWidgetData,
dashboardUniqueVisitorsSparkArgs,
dashboardUniqueVisitorsVisitorArgs,
dashboardUniqueVisitorsSparkData,
dashboardUniqueVisitorsVisitorData,
<<<<<<<
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Popular Pages Widget',
data: pageDashboardPopularPagesData,
options: pageDashboardPopularPagesArgs,
component: DashboardPopularPagesWidget,
wrapWidget: false,
=======
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Bounce Rate Widget',
data: dashboardBounceRateWidgetData,
options: dashboardBounceRateWidgetArgs,
component: DashboardBounceRateWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Page Dashboard/Bounce Rate Widget',
data: pageDashboardBounceRateWidgetData,
options: pageDashboardBounceRateWidgetArgs,
component: DashboardBounceRateWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Goals Widget',
data: dashboardGoalsWidgetData,
options: dashboardGoalsWidgetArgs,
component: DashboardGoalsWidget,
additionalVariantCallbacks: {
Loaded: ( dispatch ) => {
dispatch( STORE_NAME ).receiveGetGoals( goals );
},
'Data Unavailable': ( dispatch ) => {
dispatch( STORE_NAME ).receiveGetGoals( goals );
},
},
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Unique Visitors Widget',
data: [
dashboardUniqueVisitorsVisitorData,
dashboardUniqueVisitorsSparkData,
],
options: [
dashboardUniqueVisitorsVisitorArgs,
dashboardUniqueVisitorsSparkArgs,
],
component: DashboardUniqueVisitorsWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Page Dashboard/Unique Visitors Widget',
data: [
pageDashboardUniqueVisitorsVisitorData,
pageDashboardUniqueVisitorsSparkData,
],
options: [
pageDashboardUniqueVisitorsVisitorArgs,
pageDashboardUniqueVisitorsSparkArgs,
],
component: DashboardUniqueVisitorsWidget,
>>>>>>>
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Bounce Rate Widget',
data: dashboardBounceRateWidgetData,
options: dashboardBounceRateWidgetArgs,
component: DashboardBounceRateWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Page Dashboard/Bounce Rate Widget',
data: pageDashboardBounceRateWidgetData,
options: pageDashboardBounceRateWidgetArgs,
component: DashboardBounceRateWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Goals Widget',
data: dashboardGoalsWidgetData,
options: dashboardGoalsWidgetArgs,
component: DashboardGoalsWidget,
additionalVariantCallbacks: {
Loaded: ( dispatch ) => {
dispatch( STORE_NAME ).receiveGetGoals( goals );
},
'Data Unavailable': ( dispatch ) => {
dispatch( STORE_NAME ).receiveGetGoals( goals );
},
},
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Unique Visitors Widget',
data: [
dashboardUniqueVisitorsVisitorData,
dashboardUniqueVisitorsSparkData,
],
options: [
dashboardUniqueVisitorsVisitorArgs,
dashboardUniqueVisitorsSparkArgs,
],
component: DashboardUniqueVisitorsWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Page Dashboard/Unique Visitors Widget',
data: [
pageDashboardUniqueVisitorsVisitorData,
pageDashboardUniqueVisitorsSparkData,
],
options: [
pageDashboardUniqueVisitorsVisitorArgs,
pageDashboardUniqueVisitorsSparkArgs,
],
component: DashboardUniqueVisitorsWidget,
} );
generateReportBasedWidgetStories( {
moduleSlug: 'analytics',
datastore: STORE_NAME,
group: 'Analytics Module/Components/Dashboard/Popular Pages Widget',
data: pageDashboardPopularPagesData,
options: pageDashboardPopularPagesArgs,
component: DashboardPopularPagesWidget,
wrapWidget: false, |
<<<<<<<
if ( ! loading && isZeroReport( data ) ) {
return getNoDataComponent( _x( 'Analytics', 'Service name', 'google-site-kit' ) );
=======
if ( ! data || ! data.length ) {
return <ReportZero moduleSlug="analytics" />;
>>>>>>>
if ( ! loading && isZeroReport( data ) ) {
return <ReportZero moduleSlug="analytics" />; |
<<<<<<<
error.INITIAL_STATE,
notifications.INITIAL_STATE,
=======
userInfo.INITIAL_STATE,
error.INITIAL_STATE
>>>>>>>
userInfo.INITIAL_STATE,
notifications.INITIAL_STATE,
error.INITIAL_STATE
<<<<<<<
error.actions,
notifications.actions,
=======
userInfo.actions,
error.actions
>>>>>>>
userInfo.actions,
notifications.actions,
error.actions
<<<<<<<
error.controls,
notifications.controls,
=======
userInfo.controls,
error.controls
>>>>>>>
userInfo.controls,
notifications.controls,
error.controls
<<<<<<<
error.reducer,
notifications.reducer,
=======
userInfo.reducer,
error.reducer
>>>>>>>
userInfo.reducer,
notifications.reducer,
error.reducer
<<<<<<<
error.resolvers,
notifications.resolvers,
=======
userInfo.resolvers,
error.resolvers
>>>>>>>
userInfo.resolvers,
notifications.resolvers,
error.resolvers
<<<<<<<
error.selectors,
notifications.selectors,
=======
userInfo.selectors,
error.selectors
>>>>>>>
userInfo.selectors,
notifications.selectors,
error.selectors |
<<<<<<<
import { useCallback } from '@wordpress/element';
import { __ } from '@wordpress/i18n';
=======
import { __, _x } from '@wordpress/i18n';
>>>>>>>
import { useCallback } from '@wordpress/element';
import { __, _x } from '@wordpress/i18n'; |
<<<<<<<
diff.id = outputItem.id = vertexId;
if (outputItem.vertex) {
outputItem.title = F.vertex.title(outputItem.vertex);
} else if (diff.title) {
outputItem.title = diff.title;
}
outputItem.action = diff.deleted ? actionTypes.DELETE : actionTypes.CREATE;
self.diffsForVertexId[vertexId] = diff;
self.diffsById[vertexId] = diff;
addDiffDependency(diff.id);
=======
diff.id = elementId;
outputItem.action = actionTypes.CREATE;
self.diffsForElementId[elementId] = diff;
self.diffsById[elementId] = diff;
>>>>>>>
diff.id = elementId;
outputItem.action = actionTypes.CREATE;
outputItem.title = F.vertex.title(outputItem.vertex);
} else if (diff.title) {
outputItem.title = diff.title;
}
outputItem.action = diff.deleted ? actionTypes.DELETE : actionTypes.CREATE;
self.diffsForElementId[elementId] = diff;
self.diffsById[elementId] = diff;
addDiffDependency(diff.id);
<<<<<<<
if (!state || diff.deleted) {
var deps = this.diffDependencies[diff.id];
deps.forEach(function(diffId) {
self.trigger('markPublishDiffItem', { diffId: diffId, state: state });
=======
if (!state) {
// Unpublish all dependents
this.diffDependencies[diff.id].forEach(function(diffId) {
self.trigger('markPublishDiffItem', { diffId: diffId, state: false });
>>>>>>>
if (!state || diff.deleted) {
// Unpublish all dependents
this.diffDependencies[diff.id].forEach(function(diffId) {
self.trigger('markPublishDiffItem', { diffId: diffId, state: state });
<<<<<<<
var vertexDiff = this.diffsForVertexId[diff.elementId];
if (vertexDiff && !diff.deleted) {
=======
var vertexDiff = this.diffsForElementId[diff.elementId];
if (vertexDiff) {
>>>>>>>
var vertexDiff = this.diffsForElementId[diff.elementId];
if (vertexDiff && !diff.deleted) { |
<<<<<<<
* @param {string} moduleSlug Module slug.
* @param {string|null} url Current entity URL.
* @param {Function} cb Callback for additional setup.
=======
* @param {(string|Array)} moduleSlug Module slug or slugs to activate.
* @param {string|null} url Current entity URL.
* @param {Function} [cb] Callback for additional setup. Default is no-op.
>>>>>>>
* @param {(string|Array)} moduleSlug Module slug or slugs to activate.
* @param {string|null} url Current entity URL.
* @param {Function} [cb] Callback for additional setup. Default is no-op.
<<<<<<<
* @param {Object} args Widget arguments.
* @param {string} args.moduleSlug Module slug.
* @param {string} args.datastore Module datastore name.
* @param {string} args.group Stories group name.
* @param {Array} args.data Widget data.
* @param {Object} args.options Arguments for report requests.
* @param {Object} args.additionalVariantCallbacks Additional custom callbacks to be run for each of the variants.
* @param {Component} args.component Widget component.
* @param {boolean} args.wrapWidget Whether to wrap in default <Widget> component. Default true.
=======
* @param {Object} args Widget arguments.
* @param {string} args.moduleSlug Module slug.
* @param {string} args.datastore Module datastore name.
* @param {string} args.group Stories group name.
* @param {Array} args.data Widget data.
* @param {Object} args.options Arguments for report requests.
* @param {Component} args.component Widget component.
* @param {boolean} [args.wrapWidget] Whether to wrap in default <Widget> component. Default true.
* @param {Array} [args.additionalVariants] Optional. Additional story variants.
* @param {Array} [args.additionalVariantCallbacks] Optional. Additional custom callbacks to be run for each of the variants
>>>>>>>
* @param {Object} args Widget arguments.
* @param {string} args.moduleSlug Module slug.
* @param {string} args.datastore Module datastore name.
* @param {string} args.group Stories group name.
* @param {Array} args.data Widget data.
* @param {Object} args.options Arguments for report requests.
* @param {Component} args.component Widget component.
* @param {boolean} [args.wrapWidget] Whether to wrap in default <Widget> component. Default true.
* @param {Array} [args.additionalVariants] Optional. Additional story variants.
* @param {Array} [args.additionalVariantCallbacks] Optional. Additional custom callbacks to be run for each of the variants.
<<<<<<<
if ( Array.isArray( options ) ) {
// If options is an array, so must data.
if ( ! Array.isArray( data ) ) {
throw new Error( 'options is an array, data must be one too' );
}
// Both must have the same length
if ( options.length !== data.length ) {
throw new Error( 'options and data must have the same number of items' );
}
}
const {
Loaded: additionalLoadingCallback,
'Data Unavailable': additionalDataUnavailableCallback,
Error: additionalErrorCallback,
} = additionalVariantCallbacks;
const variants = {
=======
if ( Array.isArray( options ) ) {
// If options is an array, so must data.
if ( ! Array.isArray( data ) ) {
throw new Error( 'options is an array, data must be one too' );
}
// Both must have the same length.
if ( options.length !== data.length ) {
throw new Error( 'options and data must have the same number of items' );
}
}
const {
Loaded: additionalLoadingCallback,
'Data Unavailable': additionalDataUnavailableCallback,
Error: additionalErrorCallback,
} = additionalVariantCallbacks;
// Existing default variants.
const defaultVariants = {
>>>>>>>
if ( Array.isArray( options ) ) {
// If options is an array, so must data.
if ( ! Array.isArray( data ) ) {
throw new Error( 'options is an array, data must be one too' );
}
// Both must have the same length.
if ( options.length !== data.length ) {
throw new Error( 'options and data must have the same number of items' );
}
}
const {
Loaded: additionalLoadingCallback,
'Data Unavailable': additionalDataUnavailableCallback,
Error: additionalErrorCallback,
} = additionalVariantCallbacks;
// Existing default variants.
const defaultVariants = {
<<<<<<<
if ( Array.isArray( options ) ) {
options.forEach( ( option, index ) => {
const returnType = Array.isArray( data[ index ] ) ? [] : {};
dispatch( datastore ).receiveGetReport( returnType, { options: option } );
} );
} else {
dispatch( datastore ).receiveGetReport( [], { options } );
}
// Run additional callback if it exists.
if ( additionalDataUnavailableCallback ) {
additionalDataUnavailableCallback( dispatch, data, options );
}
=======
if ( Array.isArray( options ) ) {
options.forEach( ( option, index ) => {
const returnType = Array.isArray( data[ index ] ) ? [] : {};
dispatch( datastore ).receiveGetReport( returnType, { options: option } );
} );
} else {
dispatch( datastore ).receiveGetReport( [], { options } );
}
// Run additional callback if it exists.
if ( additionalDataUnavailableCallback ) {
additionalDataUnavailableCallback( dispatch, data, options );
}
>>>>>>>
if ( Array.isArray( options ) ) {
options.forEach( ( option, index ) => {
const returnType = Array.isArray( data[ index ] ) ? [] : {};
dispatch( datastore ).receiveGetReport( returnType, { options: option } );
} );
} else {
dispatch( datastore ).receiveGetReport( [], { options } );
}
// Run additional callback if it exists.
if ( additionalDataUnavailableCallback ) {
additionalDataUnavailableCallback( dispatch, data, options );
}
<<<<<<<
if ( Array.isArray( options ) ) {
dispatch( datastore ).receiveError( error, 'getReport', [ options[ 0 ] ] );
dispatch( datastore ).finishResolution( 'getReport', [ options[ 0 ] ] );
} else {
dispatch( datastore ).receiveError( error, 'getReport', [ options ] );
dispatch( datastore ).finishResolution( 'getReport', [ options ] );
}
=======
if ( Array.isArray( options ) ) {
options.forEach( ( option ) => {
dispatch( datastore ).receiveError( error, 'getReport', [ option ] );
dispatch( datastore ).finishResolution( 'getReport', [ option ] );
} );
} else {
dispatch( datastore ).receiveError( error, 'getReport', [ options ] );
dispatch( datastore ).finishResolution( 'getReport', [ options ] );
}
>>>>>>>
if ( Array.isArray( options ) ) {
options.forEach( ( option ) => {
dispatch( datastore ).receiveError( error, 'getReport', [ option ] );
dispatch( datastore ).finishResolution( 'getReport', [ option ] );
} );
} else {
dispatch( datastore ).receiveError( error, 'getReport', [ options ] );
dispatch( datastore ).finishResolution( 'getReport', [ options ] );
} |
<<<<<<<
this._coalescedHandlers.push({ element, eventName, callback, _callback });
=======
this._getOrAllocateArray('_coalescedHandlers').push({ element, eventName, callback });
>>>>>>>
this._getOrAllocateArray('_coalescedHandlers').push({ element, eventName, callback, _callback });
<<<<<<<
_removeCoalescedEventListener(element, eventName, _callback) {
=======
_removeCoalescedEventListener(element, eventName, callback) {
if (!this._coalescedHandlers) {
return;
}
>>>>>>>
_removeCoalescedEventListener(element, eventName, _callback) {
if (!this._coalescedHandlers) {
return;
} |
<<<<<<<
=======
* External dependencies
*/
import SettingsApp from 'GoogleComponents/settings/settings-app';
import Notification from 'GoogleComponents/notifications/notification';
import 'GoogleComponents/notifications';
import { loadTranslations } from 'GoogleUtil';
import 'GoogleModules';
/**
>>>>>>>
* External dependencies
*/
import 'GoogleComponents/notifications';
import { loadTranslations } from 'GoogleUtil';
import 'GoogleModules';
/**
<<<<<<<
return (
<ErrorHandler>
<SettingsApp />
</ErrorHandler>
);
=======
const {
hasError,
error,
info,
} = this.state;
if ( hasError ) {
return <Notification
id={ 'googlesitekit-error' }
key={ 'googlesitekit-error' }
title={ error.message }
description={ info.componentStack }
dismiss={ '' }
isDismissable={ false }
format="small"
type="win-error"
/>;
}
return <SettingsApp />;
>>>>>>>
return (
<ErrorHandler>
<SettingsApp />
</ErrorHandler>
); |
<<<<<<<
/**
* Checks reauthentication status for this user.
*
* Returns true if any required scopes are not satisfied or undefined
* if reauthentication info is not available/loaded.
*
* @since 1.9.0
*
* @param {Object} state Data store's state.
* @return {(boolean|undefined)} User reauthentication status.
*/
needsReauthentication: createRegistrySelector( ( select ) => () => {
const { needsReauthentication } = select( STORE_NAME ).getAuthentication() || {};
return needsReauthentication;
} ),
=======
/**
* Gets the unsatisfied scopes for the user.
*
* Returns an array of unsatisfied scopes (required but not granted)
* or undefined if authentication info is not available/loaded.
*
* @since 1.9.0
*
* @param {Object} state Data store's state.
* @return {(Array|undefined)} Array of scopes
*/
getUnsatisfiedScopes: createRegistrySelector( ( select ) => () => {
const { unsatisfiedScopes } = select( STORE_NAME ).getAuthentication() || {};
return unsatisfiedScopes;
} ),
>>>>>>>
/**
* Gets the unsatisfied scopes for the user.
*
* Returns an array of unsatisfied scopes (required but not granted)
* or undefined if authentication info is not available/loaded.
*
* @since 1.9.0
*
* @param {Object} state Data store's state.
* @return {(Array|undefined)} Array of scopes
*/
getUnsatisfiedScopes: createRegistrySelector( ( select ) => () => {
const { unsatisfiedScopes } = select( STORE_NAME ).getAuthentication() || {};
return unsatisfiedScopes;
} ),
/**
* Checks reauthentication status for this user.
*
* Returns true if any required scopes are not satisfied or undefined
* if reauthentication info is not available/loaded.
*
* @since 1.9.0
*
* @param {Object} state Data store's state.
* @return {(boolean|undefined)} User reauthentication status.
*/
needsReauthentication: createRegistrySelector( ( select ) => () => {
const { needsReauthentication } = select( STORE_NAME ).getAuthentication() || {};
return needsReauthentication;
} ), |
<<<<<<<
<PageHeader
title={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
icon
iconWidth="24"
iconHeight="26"
iconID="analytics"
status="connected"
statusText={ sprintf(
/* translators: %s: module name. */
__( '%s is connected', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
/>
{ loading && <ProgressBar /> }
</div>
{ /* Data issue: on error display a notification. On missing data: display a CTA. */ }
{ ! receivingData && (
error ? getDataErrorComponent( 'analytics', error, true, true, true, errorObj ) : getNoDataComponent( _x( 'Analytics', 'Service name', 'google-site-kit' ), true, true, true )
) }
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
/* translators: %s: date range */
title={ sprintf( __( 'Audience overview for the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
headerCtaLink={ visitorsOverview }
>
<AnalyticsDashboardWidgetOverview
selectedStats={ selectedStats }
handleStatSelection={ handleStatSelection }
handleDataError={ handleDataError }
handleDataSuccess={ handleDataSuccess }
/>
<AnalyticsDashboardWidgetSiteStats
selectedStats={ selectedStats }
series={ series }
vAxes={ vAxes }
dateRangeSlug={ dateRange }
/>
</Layout>
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
footer
/* translators: %s: date range */
title={ sprintf( __( 'Top content over the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLink={ topContentServiceURL }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
footerCtaLabel={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
footerCtaLink={ topContentServiceURL }
>
<AnalyticsDashboardWidgetTopPagesTable />
</Layout>
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
footer
/* translators: %s: date range */
title={ sprintf( __( 'Top acquisition channels over the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLink={ topAcquisitionServiceURL }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
footerCtaLabel={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
footerCtaLink={ topAcquisitionServiceURL }
>
<div className="mdc-layout-grid">
<div className="mdc-layout-grid__inner">
<div className="
=======
<PageHeader
title={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
icon={
<AnalyticsIcon
className="googlesitekit-page-header__icon"
height="26"
width="24"
/>
}
status="connected"
statusText={ sprintf(
/* translators: %s: module name. */
__( '%s is connected', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
>
<PageHeaderDateRange />
</PageHeader>
{ loading && <ProgressBar /> }
</div>
{ /* Data issue: on error display a notification. On missing data: display a CTA. */ }
{ ! receivingData && (
error ? getDataErrorComponent( 'analytics', error, true, true, true, errorObj ) : getNoDataComponent( _x( 'Analytics', 'Service name', 'google-site-kit' ), true, true, true )
) }
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
/* translators: %s: date range */
title={ sprintf( __( 'Audience overview for the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
headerCtaLink="http://analytics.google.com"
>
<AnalyticsDashboardWidgetOverview
selectedStats={ selectedStats }
handleStatSelection={ this.handleStatSelection }
handleDataError={ this.handleDataError }
handleDataSuccess={ this.handleDataSuccess }
/>
<AnalyticsDashboardWidgetSiteStats
selectedStats={ selectedStats }
series={ series }
vAxes={ vAxes }
dateRangeSlug={ dateRange }
/>
</Layout>
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
footer
/* translators: %s: date range */
title={ sprintf( __( 'Top content over the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLink="https://analytics.google.com"
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
footerCtaLabel={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
footerCtaLink="https://analytics.google.com"
>
<AnalyticsDashboardWidgetTopPagesTable />
</Layout>
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
footer
/* translators: %s: date range */
title={ sprintf( __( 'Top acquisition channels over the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLink="https://analytics.google.com"
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
footerCtaLabel={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
footerCtaLink="https://analytics.google.com"
>
<div className="mdc-layout-grid">
<div className="mdc-layout-grid__inner">
<div className="
>>>>>>>
<PageHeader
title={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
icon={
<AnalyticsIcon
className="googlesitekit-page-header__icon"
height="26"
width="24"
/>
}
status="connected"
statusText={ sprintf(
/* translators: %s: module name. */
__( '%s is connected', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
>
<PageHeaderDateRange />
</PageHeader>
{ loading && <ProgressBar /> }
</div>
{ /* Data issue: on error display a notification. On missing data: display a CTA. */ }
{ ! receivingData && (
error ? getDataErrorComponent( 'analytics', error, true, true, true, errorObj ) : getNoDataComponent( _x( 'Analytics', 'Service name', 'google-site-kit' ), true, true, true )
) }
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
/* translators: %s: date range */
title={ sprintf( __( 'Audience overview for the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
headerCtaLink={ visitorsOverview }
>
<AnalyticsDashboardWidgetOverview
selectedStats={ selectedStats }
handleStatSelection={ handleStatSelection }
handleDataError={ handleDataError }
handleDataSuccess={ handleDataSuccess }
/>
<AnalyticsDashboardWidgetSiteStats
selectedStats={ selectedStats }
series={ series }
vAxes={ vAxes }
dateRangeSlug={ dateRange }
/>
</Layout>
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
footer
/* translators: %s: date range */
title={ sprintf( __( 'Top content over the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLink={ topContentServiceURL }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
footerCtaLabel={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
footerCtaLink={ topContentServiceURL }
>
<AnalyticsDashboardWidgetTopPagesTable />
</Layout>
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<Layout
header
footer
/* translators: %s: date range */
title={ sprintf( __( 'Top acquisition channels over the last %s', 'google-site-kit' ), currentDateRange ) }
headerCtaLink={ topAcquisitionServiceURL }
headerCtaLabel={ sprintf(
/* translators: %s: module name. */
__( 'See full stats in %s', 'google-site-kit' ),
_x( 'Analytics', 'Service name', 'google-site-kit' )
) }
footerCtaLabel={ _x( 'Analytics', 'Service name', 'google-site-kit' ) }
footerCtaLink={ topAcquisitionServiceURL }
>
<div className="mdc-layout-grid">
<div className="mdc-layout-grid__inner">
<div className=" |
<<<<<<<
=======
* Internal dependencies
*/
import PostSearcher from '../../components/PostSearcher';
import GoogleSitekitSearchConsoleDashboardWidget from './components/dashboard/GoogleSitekitSearchConsoleDashboardWidget';
import GoogleSitekitSearchConsoleAdminbarWidget from './components/adminbar/GoogleSitekitSearchConsoleAdminbarWidget';
import WPSearchConsoleDashboardWidget from './components/wp-dashboard/WPSearchConsoleDashboardWidget';
import DashboardSearchFunnel from './components/dashboard/DashboardSearchFunnel.js';
import SearchConsoleDashboardWidgetTopLevel from './components/dashboard/SearchConsoleDashboardWidgetTopLevel';
import DashboardDetailsWidgetKeywordsTable from './components/dashboard-details/DashboardDetailsWidgetKeywordsTable';
import DashboardWidgetPopularKeywordsTable from './components/dashboard/DashboardWidgetPopularKeywordsTable';
import DashboardDetailsWidgetSearchFunnel from './components/dashboard-details/DashboardDetailsSearchFunnel';
import DashboardPopularity from './components/dashboard/DashboardPopularity';
/**
>>>>>>> |
<<<<<<<
import DashboardDetailsApp from '../assets/js/components/dashboard-details/dashboard-details-app';
=======
import DashboardDetailsApp from '../assets/js/components/dashboard-details/DashboardDetailsApp';
import { enableFeature } from './utils/features';
>>>>>>>
import DashboardDetailsApp from '../assets/js/components/dashboard-details/DashboardDetailsApp'; |
<<<<<<<
import { changeToPercent } from '../../../util';
=======
import { changeToPercent, getModulesData } from 'GoogleUtil';
>>>>>>>
import { changeToPercent, getModulesData } from '../../../util'; |
<<<<<<<
import { changeToPercent } from '../../../../util';
=======
import { calculateChange } from '../../../../util';
import applyEntityToReportPath from '../../util/applyEntityToReportPath';
>>>>>>>
import { calculateChange } from '../../../../util';
<<<<<<<
=======
const accountID = store.getAccountID();
const profileID = store.getProfileID();
const internalWebPropertyID = store.getInternalWebPropertyID();
const {
compareStartDate,
compareEndDate,
startDate,
endDate,
} = select( CORE_USER ).getDateRangeDates( {
offsetDays: DATE_RANGE_OFFSET,
compare: true,
weekdayAlign: true,
} );
>>>>>>>
const {
compareStartDate,
compareEndDate,
startDate,
endDate,
} = select( CORE_USER ).getDateRangeDates( {
offsetDays: DATE_RANGE_OFFSET,
compare: true,
weekdayAlign: true,
} ); |
<<<<<<<
import { WithTestRegistry } from '../tests/js/utils';
import { generateGtmPropertyStory } from './utils/analytics';
function filterAnalyticsSettings() {
// set( global, 'googlesitekit.modules.analytics.setupComplete', true );
removeAllFilters( 'googlesitekit.ModuleSettingsDetails-analytics' );
addFilter(
'googlesitekit.ModuleSettingsDetails-analytics',
'googlesitekit.AnalyticsModuleSettings',
fillFilterWithComponent( AnalyticsSettings )
);
}
const completeModuleData = {
...global._googlesitekitLegacyData.modules.analytics,
active: true,
setupComplete: true,
=======
import { createTestRegistry, provideModules } from '../tests/js/utils';
import createLegacySettingsWrapper from './utils/create-legacy-settings-wrapper';
const defaultSettings = {
ownerID: 0,
accountID: '',
adsenseLinked: false,
anonymizeIP: true,
internalWebPropertyID: '',
profileID: '',
propertyID: '',
trackingDisabled: [ 'loggedinUsers' ],
useSnippet: true,
>>>>>>>
import { createTestRegistry, provideModules } from '../tests/js/utils';
import { generateGtmPropertyStory } from './utils/analytics';
import createLegacySettingsWrapper from './utils/create-legacy-settings-wrapper';
function filterAnalyticsSettings() {
// set( global, 'googlesitekit.modules.analytics.setupComplete', true );
removeAllFilters( 'googlesitekit.ModuleSettingsDetails-analytics' );
addFilter(
'googlesitekit.ModuleSettingsDetails-analytics',
'googlesitekit.AnalyticsModuleSettings',
fillFilterWithComponent( AnalyticsSettings )
);
}
const completeModuleData = {
...global._googlesitekitLegacyData.modules.analytics,
active: true,
setupComplete: true,
};
const defaultSettings = {
ownerID: 0,
accountID: '',
adsenseLinked: false,
anonymizeIP: true,
internalWebPropertyID: '',
profileID: '',
propertyID: '',
trackingDisabled: [ 'loggedinUsers' ],
useSnippet: true,
<<<<<<<
.add( 'Edit, with existing tag w/ access', () => {
filterAnalyticsSettings();
=======
.add( 'Edit, with existing tag (with access)', ( registry ) => {
>>>>>>>
.add( 'Edit, with existing tag w/ access', ( registry ) => {
filterAnalyticsSettings();
<<<<<<<
.add( 'Edit, with existing tag w/o access', () => {
filterAnalyticsSettings();
=======
.add( 'Edit, with existing tag (no access)', ( registry ) => {
const { accounts, properties, profiles } = fixtures.accountsPropertiesProfiles;
>>>>>>>
.add( 'Edit, with existing tag w/o access', ( registry ) => {
filterAnalyticsSettings();
const { accounts, properties, profiles } = fixtures.accountsPropertiesProfiles; |
<<<<<<<
/**
* Internal dependencies
*/
import { getPreviousDate, getDateString, getPreviousWeekDate } from './utils';
export const INITIAL_STATE = {
=======
export const initialState = {
>>>>>>>
/**
* Internal dependencies
*/
import { getPreviousDate, getDateString, getPreviousWeekDate } from './utils';
export const initialState = { |
<<<<<<<
import Notification from '../assets/js/components/notifications/notification';
import { provideModuleRegistrations, WithTestRegistry } from '../tests/js/utils';
=======
>>>>>>>
import { provideModuleRegistrations, WithTestRegistry } from '../tests/js/utils';
<<<<<<<
=======
import { provideModules, WithTestRegistry } from '../tests/js/utils';
import Notification from '../assets/js/components/legacy-notifications/notification';
>>>>>>>
import Notification from '../assets/js/components/legacy-notifications/notification'; |
<<<<<<<
import { sendAnalyticsTrackingEvent } from 'GoogleUtil';
=======
import {
getSiteKitAdminURL,
getReAuthURL,
sendAnalyticsTrackingEvent,
} from 'GoogleUtil';
import { each, find, filter } from 'lodash';
/**
* WordPress dependencies
*/
import { __, sprintf } from '@wordpress/i18n';
>>>>>>>
import { sendAnalyticsTrackingEvent } from 'GoogleUtil';
import { each, find, filter } from 'lodash';
/**
* WordPress dependencies
*/
import { __, sprintf } from '@wordpress/i18n'; |
<<<<<<<
WinImageSVG,
=======
SmallImageSVG,
>>>>>>>
WinImageSVG,
SmallImageSVG, |
<<<<<<<
export { default as DashboardPopularPagesWidget } from './DashboardPopularPagesWidget';
=======
export { default as DashboardBounceRateWidget } from './DashboardBounceRateWidget';
export { default as DashboardGoalsWidget } from './DashboardGoalsWidget';
export { default as DashboardUniqueVisitorsWidget } from './DashboardUniqueVisitorsWidget';
>>>>>>>
export { default as DashboardPopularPagesWidget } from './DashboardPopularPagesWidget';
export { default as DashboardBounceRateWidget } from './DashboardBounceRateWidget';
export { default as DashboardGoalsWidget } from './DashboardGoalsWidget';
export { default as DashboardUniqueVisitorsWidget } from './DashboardUniqueVisitorsWidget'; |
<<<<<<<
'googlesitekit-modules': './assets/js/googlesitekit-modules.js',
'googlesitekit-modules-adsense': './assets/js/googlesitekit-modules-adsense.js',
=======
'googlesitekit-modules-analytics': './assets/js/googlesitekit-modules-analytics.js',
'googlesitekit-modules': './assets/js/googlesitekit-modules.js', // TODO: Add external following 1162.
>>>>>>>
'googlesitekit-modules': './assets/js/googlesitekit-modules.js',
'googlesitekit-modules-adsense': './assets/js/googlesitekit-modules-adsense.js',
'googlesitekit-modules-analytics': './assets/js/googlesitekit-modules-analytics.js', |
<<<<<<<
=======
const { Component, Fragment } = wp.element;
const { __, _x, sprintf } = wp.i18n;
>>>>>>> |
<<<<<<<
=======
dashboardAllTrafficArgs,
dashboardAllTrafficData,
pageDashboardAllTrafficArgs,
pageDashboardAllTrafficData,
dashboardPopularPagesArgs,
dashboardPopularPagesData,
pageDashboardBounceRateWidgetArgs,
pageDashboardBounceRateWidgetData,
pageDashboardUniqueVisitorsSparkArgs,
pageDashboardUniqueVisitorsSparkData,
pageDashboardUniqueVisitorsVisitorArgs,
pageDashboardUniqueVisitorsVisitorData,
dashboardBounceRateWidgetArgs,
dashboardBounceRateWidgetData,
dashboardGoalsWidgetArgs,
dashboardGoalsWidgetData,
dashboardUniqueVisitorsSparkArgs,
dashboardUniqueVisitorsVisitorArgs,
dashboardUniqueVisitorsSparkData,
dashboardUniqueVisitorsVisitorData,
dashboardUserDimensionsArgs,
dashboardUserDimensionsData,
>>>>>>>
dashboardUserDimensionsArgs,
dashboardUserDimensionsData, |
<<<<<<<
export { default as pageDashboardAllTrafficData } from './page-dashboard-all-traffic-widget-data.json';
export { default as pageDashboardPopularPagesArgs } from './dashboard-popular-pages-widget-args.json';
export { default as pageDashboardPopularPagesData } from './dashboard-popular-pages-widget-data.json';
=======
export { default as pageDashboardAllTrafficData } from './page-dashboard-all-traffic-widget-data.json';
export { default as pageDashboardBounceRateWidgetArgs } from './page-dashboard-bounce-rate-widget-args.json';
export { default as pageDashboardBounceRateWidgetData } from './page-dashboard-bounce-rate-widget-data.json';
export { default as dashboardBounceRateWidgetData } from './dashboard-bounce-rate-widget-data.json';
export { default as dashboardBounceRateWidgetArgs } from './dashboard-bounce-rate-widget-args.json';
export { default as dashboardGoalsWidgetData } from './dashboard-goals-widget-data.json';
export { default as dashboardGoalsWidgetArgs } from './dashboard-goals-widget-args.json';
export * from './dashboard-unique-visitors-data';
export * from './dashboard-unique-visitors-args';
export { pageDashboardUniqueVisitorsSparkData, pageDashboardUniqueVisitorsVisitorData } from './page-dashboard-unique-visitors-data';
export { pageDashboardUniqueVisitorsSparkArgs, pageDashboardUniqueVisitorsVisitorArgs } from './page-dashboard-unique-visitors-args';
>>>>>>>
export { default as pageDashboardAllTrafficData } from './page-dashboard-all-traffic-widget-data.json';
export { default as pageDashboardPopularPagesArgs } from './dashboard-popular-pages-widget-args.json';
export { default as pageDashboardPopularPagesData } from './dashboard-popular-pages-widget-data.json';
export { default as pageDashboardBounceRateWidgetArgs } from './page-dashboard-bounce-rate-widget-args.json';
export { default as pageDashboardBounceRateWidgetData } from './page-dashboard-bounce-rate-widget-data.json';
export { default as dashboardBounceRateWidgetData } from './dashboard-bounce-rate-widget-data.json';
export { default as dashboardBounceRateWidgetArgs } from './dashboard-bounce-rate-widget-args.json';
export { default as dashboardGoalsWidgetData } from './dashboard-goals-widget-data.json';
export { default as dashboardGoalsWidgetArgs } from './dashboard-goals-widget-args.json';
export * from './dashboard-unique-visitors-data';
export * from './dashboard-unique-visitors-args';
export { pageDashboardUniqueVisitorsSparkData, pageDashboardUniqueVisitorsVisitorData } from './page-dashboard-unique-visitors-data';
export { pageDashboardUniqueVisitorsSparkArgs, pageDashboardUniqueVisitorsVisitorArgs } from './page-dashboard-unique-visitors-args'; |
<<<<<<<
=======
const accountID = store.getAccountID();
const profileID = store.getProfileID();
const internalWebPropertyID = store.getInternalWebPropertyID();
const {
compareStartDate,
compareEndDate,
startDate,
endDate,
} = select( CORE_USER ).getDateRangeDates( {
offsetDays: DATE_RANGE_OFFSET,
compare: true,
} );
>>>>>>>
const {
compareStartDate,
compareEndDate,
startDate,
endDate,
} = select( CORE_USER ).getDateRangeDates( {
offsetDays: DATE_RANGE_OFFSET,
compare: true,
} ); |
<<<<<<<
'googlesitekit-modules-tagmanager': './assets/js/googlesitekit-modules-tagmanager.js',
=======
'googlesitekit-modules-search-console': './assets/js/googlesitekit-modules-search-console.js',
>>>>>>>
'googlesitekit-modules-search-console': './assets/js/googlesitekit-modules-search-console.js',
'googlesitekit-modules-tagmanager': './assets/js/googlesitekit-modules-tagmanager.js', |
<<<<<<<
<Cell className={ wrapperClass } size={ 12 }>
<ModuleSettingsWarning slug="adsense" context="module-dashboard" />
</Cell>
<Cell className={ wrapperClass } size={ 12 }>
=======
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
<ModuleSettingsWarning slug="adsense" />
</div>
<div className={ classnames(
'mdc-layout-grid__cell',
'mdc-layout-grid__cell--span-12',
wrapperClass
) }>
>>>>>>>
<Cell className={ wrapperClass } size={ 12 }>
<ModuleSettingsWarning slug="adsense" />
</Cell>
<Cell className={ wrapperClass } size={ 12 }> |
<<<<<<<
import { getTimeInSeconds, numberFormat, untrailingslashit } from '../../../../util';
import withData from '../../../../components/higherorder/withData';
=======
import {
getTimeInSeconds,
numFmt,
untrailingslashit,
} from '../../../../util';
import withData from '../../../../components/higherorder/withdata';
>>>>>>>
import {
getTimeInSeconds,
numFmt,
untrailingslashit,
} from '../../../../util';
import withData from '../../../../components/higherorder/withData'; |
<<<<<<<
import { STORE_NAME } from './constants';
=======
import notifications from './notifications';
>>>>>>>
import { STORE_NAME } from './constants';
import notifications from './notifications';
<<<<<<<
=======
import { STORE_NAME } from './constants';
export { STORE_NAME };
>>>>>>>
export { STORE_NAME }; |
<<<<<<<
import { STORE_NAME as CORE_SITE } from '../../googlesitekit/datastore/site/constants';
import { STORE_NAME as CORE_USER, DISCONNECTED_REASON_CONNECTED_URL_MISMATCH } from '../../googlesitekit/datastore/user/constants';
import { useFeature } from '../../hooks/useFeature';
=======
import { CORE_SITE } from '../../googlesitekit/datastore/site/constants';
import { CORE_USER, DISCONNECTED_REASON_CONNECTED_URL_MISMATCH } from '../../googlesitekit/datastore/user/constants';
>>>>>>>
import { CORE_SITE } from '../../googlesitekit/datastore/site/constants';
import { CORE_USER, DISCONNECTED_REASON_CONNECTED_URL_MISMATCH } from '../../googlesitekit/datastore/user/constants';
import { useFeature } from '../../hooks/useFeature'; |
<<<<<<<
this.props.lose_focus();
if (Map.tiff) {
=======
if (force || Map.tiff) {
>>>>>>>
this.props.lose_focus();
if (force || Map.tiff) { |
<<<<<<<
name: 'Tag Manager',
settingsEditComponent: SettingsEdit,
settingsViewComponent: SettingsView,
setupComponent: SetupMain,
=======
SettingsEditComponent: SettingsEdit,
SettingsViewComponent: SettingsView,
SetupComponent: SetupMain,
Icon: TagManagerIcon,
>>>>>>>
name: 'Tag Manager',
settingsEditComponent: SettingsEdit,
settingsViewComponent: SettingsView,
setupComponent: SetupMain,
Icon: TagManagerIcon, |
<<<<<<<
import { getCurrentDateRange } from '../../../../util/date-range';
import { Cell, Grid, Row } from '../../../../material-components';
=======
import { getCurrentDateRangeDayCount } from '../../../../util/date-range';
>>>>>>>
import { Cell, Grid, Row } from '../../../../material-components';
import { getCurrentDateRangeDayCount } from '../../../../util/date-range';
<<<<<<<
const wrapperClass = ( ! receivingData || zeroData ) ? 'googlesitekit-nodata' : '';
const currentDateRange = getCurrentDateRange( dateRange );
=======
const wrapperClass = ( loading || ! receivingData || zeroData ) ? 'googlesitekit-nodata' : '';
const currentDayCount = getCurrentDateRangeDayCount( dateRange );
>>>>>>>
const wrapperClass = ( ! receivingData || zeroData ) ? 'googlesitekit-nodata' : '';
const currentDayCount = getCurrentDateRangeDayCount( dateRange ); |
<<<<<<<
import AdSenseIcon from '../../../svg/adsense.svg';
=======
import { STORE_NAME } from './datastore/constants';
import { ERROR_CODE_ADBLOCKER_ACTIVE } from './constants';
>>>>>>>
import AdSenseIcon from '../../../svg/adsense.svg';
import { STORE_NAME } from './datastore/constants';
import { ERROR_CODE_ADBLOCKER_ACTIVE } from './constants';
<<<<<<<
icon: AdSenseIcon,
=======
checkRequirements: () => {
const isAdBlockerActive = select( STORE_NAME ).isAdBlockerActive();
if ( ! isAdBlockerActive ) {
return;
}
throw {
code: ERROR_CODE_ADBLOCKER_ACTIVE,
message: __( 'Ad blocker detected, you need to disable it in order to set up AdSense.', 'google-site-kit' ),
data: null,
};
},
>>>>>>>
icon: AdSenseIcon,
checkRequirements: () => {
const isAdBlockerActive = select( STORE_NAME ).isAdBlockerActive();
if ( ! isAdBlockerActive ) {
return;
}
throw {
code: ERROR_CODE_ADBLOCKER_ACTIVE,
message: __( 'Ad blocker detected, you need to disable it in order to set up AdSense.', 'google-site-kit' ),
data: null,
};
}, |
<<<<<<<
if (modal) {
modal.classList.toggle('active');
event.preventDefault(); // prevents rewriting url (apps can still use hash values in url)
}
=======
if (modal && modal.classList.contains('modal')) modal.classList.toggle('active');
>>>>>>>
if (modal) {
if (modal && modal.classList.contains('modal')) modal.classList.toggle('active');
event.preventDefault(); // prevents rewriting url (apps can still use hash values in url)
} |
<<<<<<<
if ( ! reportMobile || ! reportDesktop || ! dataSrc ) {
return (
<Layout className="googlesitekit-pagespeed-widget">
<div className="mdc-layout-grid">
<div className="mdc-layout-grid__inner">
<div className=" mdc-layout-grid__cell mdc-layout-grid__cell--span-12">
<ProgressBar />
<p className="googlesitekit-text-align-center">
{ __( 'PageSpeed Insights is preparing data…', 'google-site-kit' ) }
</p>
</div>
</div>
</div>
</Layout>
);
=======
if ( ! referenceURL || ! reportMobile || ! reportDesktop || ! dataSrc ) {
return <ProgressBar />;
>>>>>>>
if ( ! reportMobile || ! reportDesktop || ! dataSrc ) {
return (
<Layout className="googlesitekit-pagespeed-widget">
<div className="mdc-layout-grid">
<div className="mdc-layout-grid__inner">
<div className=" mdc-layout-grid__cell mdc-layout-grid__cell--span-12">
<ProgressBar />
<p className="googlesitekit-text-align-center">
{ __( 'PageSpeed Insights is preparing data…', 'google-site-kit' ) }
</p>
</div>
</div>
</div>
</Layout>
);
<<<<<<<
=======
const footerLinkHTML = sprintf(
/* translators: 1: link attributes, 2: translated service name */
__( 'View details at <a %1$s>%2$s</a>', 'google-site-kit' ),
`href="${ addQueryArgs( 'https://developers.google.com/speed/pagespeed/insights/', { url: referenceURL } ) }" class="googlesitekit-cta-link googlesitekit-cta-link--external" target="_blank"`,
_x( 'PageSpeed Insights', 'Service name', 'google-site-kit' )
);
>>>>>>> |
<<<<<<<
import Link from 'GoogleComponents/link';
import Button from 'GoogleComponents/button';
import data, { TYPE_MODULES } from 'GoogleComponents/data';
import SvgIcon from 'GoogleUtil/svg-icon';
import SetupModule from 'GoogleComponents/setup-module';
import Dialog from 'GoogleComponents/dialog';
import ModuleSettingsDetails from 'GoogleComponents/settings/module-settings-details';
import ModuleSetupIncomplete from 'GoogleComponents/settings/module-setup-incomplete';
import {
activateOrDeactivateModule,
refreshAuthentication,
getReAuthURL,
moduleIcon,
showErrorNotification,
getModulesData,
} from 'GoogleUtil';
import Spinner from 'GoogleComponents/spinner';
import SettingsOverlay from 'GoogleComponents/settings/settings-overlay';
import GenericError from 'GoogleComponents/notifications/generic-error';
=======
>>>>>>> |
<<<<<<<
* External dependencies
*/
import { fillFilterWithComponent, getModulesData } from 'GoogleUtil';
import OptimizeSetup from 'GoogleModules/optimize/setup';
/**
=======
>>>>>>> |
<<<<<<<
=======
* External dependencies
*/
import { clearWebStorage, loadTranslations } from 'GoogleUtil';
import Notification from 'GoogleComponents/notifications/notification';
import 'GoogleComponents/notifications';
/**
>>>>>>>
* External dependencies
*/
import { clearWebStorage, loadTranslations } from 'GoogleUtil';
import 'GoogleComponents/notifications';
/**
<<<<<<<
import { setLocaleData } from '@wordpress/i18n';
import { Component, render } from '@wordpress/element';
=======
import { Component, render, Fragment } from '@wordpress/element';
>>>>>>>
import { Component, render } from '@wordpress/element';
<<<<<<<
=======
const {
hasError,
error,
info,
} = this.state;
if ( hasError ) {
return <Notification
id={ 'googlesitekit-error' }
key={ 'googlesitekit-error' }
title={ error.message }
description={ info.componentStack }
dismiss={ '' }
isDismissable={ false }
format="small"
type="win-error"
/>;
}
>>>>>>> |
<<<<<<<
import { getModulesData } from '../../../util';
import Layout from '../../../components//layout/layout';
import DashboardModuleHeader from '../../../components//dashboard/dashboard-module-header';
import AnalyticsInactiveCTA from '../../../components//analytics-inactive-cta';
=======
import Layout from '../../../components/layout/layout';
import DashboardModuleHeader from '../../../components/dashboard/dashboard-module-header';
import AnalyticsInactiveCTA from '../../../components/analytics-inactive-cta';
>>>>>>>
import { getModulesData } from '../../../util';
import Layout from '../../../components/layout/layout';
import DashboardModuleHeader from '../../../components/dashboard/dashboard-module-header';
import AnalyticsInactiveCTA from '../../../components/analytics-inactive-cta'; |
<<<<<<<
=======
import { fillFilterWithComponent } from '../assets/js/util';
import AnalyticsSetup from '../assets/js/modules/analytics/setup';
import SearchConsoleSettingStatus from '../assets/js/modules/search-console/settings/search-console-settings-status';
import AdSenseSettings from '../assets/js/modules/adsense/settings/adsense-settings';
>>>>>>>
<<<<<<<
=======
global.googlesitekit.modules.adsense.setupComplete = true;
global.googlesitekit.modules.adsense.active = true;
global.googlesitekit.modules.adsense.settings.accountID = 'pub-XXXXXXXXXXXXXXXX';
// Load the datacache with data.
setTimeout( () => {
setupSettings();
addFilter( 'googlesitekit.ModuleSettingsDetails-analytics',
'googlesitekit.AnalyticsModuleSettingsDetails',
fillFilterWithComponent( AnalyticsSetup, {
onSettingsPage: true,
} ) );
addFilter( 'googlesitekit.ModuleSettingsDetails-search-console',
'googlesitekit.SearchConsoleModuleSettingsDetails',
fillFilterWithComponent( SearchConsoleSettingStatus, {
onSettingsPage: true,
} ) );
addFilter( 'googlesitekit.ModuleSettingsDetails-adsense',
'googlesitekit.AdSenseModuleSettingsDetails',
fillFilterWithComponent( AdSenseSettings, {
onSettingsPage: true,
} ) );
}, 2500 );
>>>>>>>
global.googlesitekit.modules.adsense.setupComplete = true;
global.googlesitekit.modules.adsense.active = true;
global.googlesitekit.modules.adsense.settings.accountID = 'pub-XXXXXXXXXXXXXXXX'; |
<<<<<<<
import { STORE_NAME as MODULES_ANALYTICS, FORM_ALL_TRAFFIC_WIDGET } from '../../../datastore/constants';
import { STORE_NAME as CORE_FORMS } from '../../../../../googlesitekit/datastore/forms/constants';
import { STORE_NAME as CORE_SITE } from '../../../../../googlesitekit/datastore/site/constants';
=======
import Widgets from 'googlesitekit-widgets';
import { MODULES_ANALYTICS, FORM_ALL_TRAFFIC_WIDGET } from '../../../datastore/constants';
import { CORE_FORMS } from '../../../../../googlesitekit/datastore/forms/constants';
import { CORE_SITE } from '../../../../../googlesitekit/datastore/site/constants';
>>>>>>>
import { MODULES_ANALYTICS, FORM_ALL_TRAFFIC_WIDGET } from '../../../datastore/constants';
import { CORE_FORMS } from '../../../../../googlesitekit/datastore/forms/constants';
import { CORE_SITE } from '../../../../../googlesitekit/datastore/site/constants';
<<<<<<<
=======
import { getURLPath } from '../../../../../util/getURLPath';
const { Widget } = Widgets.components;
>>>>>>>
import { getURLPath } from '../../../../../util/getURLPath'; |
<<<<<<<
import Widgets from 'googlesitekit-widgets';
import {
DIMENSION_NAME_ALL_TRAFFIC_WIDGET,
DIMENSION_VALUE_ALL_TRAFFIC_WIDGET,
DATE_RANGE_OFFSET,
MODULES_ANALYTICS,
} from '../../../datastore/constants';
=======
import { FORM_ALL_TRAFFIC_WIDGET, DATE_RANGE_OFFSET, MODULES_ANALYTICS } from '../../../datastore/constants';
import { CORE_FORMS } from '../../../../../googlesitekit/datastore/forms/constants';
>>>>>>>
import {
DIMENSION_NAME_ALL_TRAFFIC_WIDGET,
DIMENSION_VALUE_ALL_TRAFFIC_WIDGET,
DATE_RANGE_OFFSET,
MODULES_ANALYTICS,
} from '../../../datastore/constants'; |
<<<<<<<
// '@wordpress/api-fetch$': path.resolve( __dirname, 'wp-api-fetch-mock.js' ),
'googlesitekit-data': path.resolve( __dirname, '../assets/js/googlesitekit-data.js' ),
'googlesitekit-api': path.resolve( __dirname, '../assets/js/googlesitekit-api.js' ),
SiteKitCore: path.resolve( __dirname, '../assets/js/' ),
GoogleComponents: path.resolve( __dirname, '../assets/js/components/' ),
GoogleUtil: path.resolve( __dirname, '../assets/js/util/' ),
GoogleModules: path.resolve( __dirname, '../assets/js/modules/' ),
=======
'@wordpress/api-fetch$': path.resolve( __dirname, 'wp-api-fetch-mock.js' ),
>>>>>>>
// '@wordpress/api-fetch$': path.resolve( __dirname, 'wp-api-fetch-mock.js' ), |
<<<<<<<
registry.dispatch( STORE_NAME ).receiveExistingTag( null );
fetchMock.getOnce(
/^\/google-site-kit\/v1\/modules\/analytics\/data\/accounts-properties-profiles/,
{ body: fixtures.accountsPropertiesProfiles, status: 200 }
);
=======
registry.dispatch( STORE_NAME ).receiveGetExistingTag( null );
fetch
.doMockOnceIf(
/^\/google-site-kit\/v1\/modules\/analytics\/data\/accounts-properties-profiles/
)
.mockResponseOnce(
JSON.stringify( fixtures.accountsPropertiesProfiles ),
{ status: 200 }
);
>>>>>>>
registry.dispatch( STORE_NAME ).receiveGetExistingTag( null );
fetchMock.getOnce(
/^\/google-site-kit\/v1\/modules\/analytics\/data\/accounts-properties-profiles/,
{ body: fixtures.accountsPropertiesProfiles, status: 200 }
); |
<<<<<<<
name: 'Analytics',
settingsEditComponent: SettingsEdit,
settingsViewComponent: SettingsView,
setupComponent: SetupMain,
=======
SettingsEditComponent: SettingsEdit,
SettingsViewComponent: SettingsView,
SetupComponent: SetupMain,
Icon: AnalyticsIcon,
>>>>>>>
name: 'Analytics',
SettingsEditComponent: SettingsEdit,
SettingsViewComponent: SettingsView,
SetupComponent: SetupMain,
Icon: AnalyticsIcon, |
<<<<<<<
export { default as DashboardZeroData } from './DashboardZeroData';
export { default as DashboardSummaryWidget } from './DashboardSummaryWidget';
=======
export { default as AdSenseDashboardMainSummary } from './AdSenseDashboardMainSummary';
export { default as AdSenseDashboardWidget } from './AdSenseDashboardWidget';
export { default as AdSenseEstimateEarningsWidget } from './AdSenseEstimateEarningsWidget';
export { default as AdSensePerformanceWidget } from './AdSensePerformanceWidget';
export { default as DashboardAdSenseTopEarningPagesSmall } from './DashboardAdSenseTopEarningPagesSmall';
export { default as DashboardAdSenseTopPages } from './DashboardAdSenseTopPages';
export { default as DashboardEarnings } from './DashboardEarnings';
export { default as DashboardZeroData } from './DashboardZeroData';
>>>>>>>
export { default as AdSenseDashboardMainSummary } from './AdSenseDashboardMainSummary';
export { default as AdSenseDashboardWidget } from './AdSenseDashboardWidget';
export { default as AdSenseEstimateEarningsWidget } from './AdSenseEstimateEarningsWidget';
export { default as AdSensePerformanceWidget } from './AdSensePerformanceWidget';
export { default as DashboardAdSenseTopEarningPagesSmall } from './DashboardAdSenseTopEarningPagesSmall';
export { default as DashboardAdSenseTopPages } from './DashboardAdSenseTopPages';
export { default as DashboardEarnings } from './DashboardEarnings';
export { default as DashboardZeroData } from './DashboardZeroData';
export { default as DashboardSummaryWidget } from './DashboardSummaryWidget'; |
<<<<<<<
name: 'AdSense',
settingsEditComponent: SettingsEdit,
settingsViewComponent: SettingsView,
setupComponent: SetupMain,
=======
SettingsEditComponent: SettingsEdit,
SettingsViewComponent: SettingsView,
SetupComponent: SetupMain,
Icon: AdSenseIcon,
>>>>>>>
name: 'AdSense',
SettingsEditComponent: SettingsEdit,
SettingsViewComponent: SettingsView,
SetupComponent: SetupMain,
Icon: AdSenseIcon, |
<<<<<<<
import { STORE_NAME as CORE_SITE } from '../googlesitekit/datastore/site/constants';
import { STORE_NAME as CORE_LOCATION } from '../googlesitekit/datastore/location/constants';
=======
import { CORE_SITE } from '../googlesitekit/datastore/site/constants';
>>>>>>>
import { CORE_SITE } from '../googlesitekit/datastore/site/constants';
import { CORE_LOCATION } from '../googlesitekit/datastore/location/constants'; |
<<<<<<<
argsToParams: ( objParam, aParam ) => {
return {
objParam,
aParam,
};
},
validateParams: ( { objParam, aParam } = {} ) => {
invariant( isPlainObject( objParam ), 'objParam is required.' );
invariant( aParam !== undefined, 'aParam is required.' );
},
=======
storeName: STORE_NAME,
>>>>>>>
storeName: STORE_NAME,
argsToParams: ( objParam, aParam ) => {
return {
objParam,
aParam,
};
},
validateParams: ( { objParam, aParam } = {} ) => {
invariant( isPlainObject( objParam ), 'objParam is required.' );
invariant( aParam !== undefined, 'aParam is required.' );
}, |
<<<<<<<
=======
'googlesitekit-modules-pagespeed-insights': 'assets/js/googlesitekit-modules-pagespeed-insights.js',
'googlesitekit-modules-search-console': './assets/js/googlesitekit-modules-search-console.js',
'googlesitekit-modules': './assets/js/googlesitekit-modules.js', // TODO: Add external following 1162.
>>>>>>>
'googlesitekit-modules-pagespeed-insights': 'assets/js/googlesitekit-modules-pagespeed-insights.js',
'googlesitekit-modules-search-console': './assets/js/googlesitekit-modules-search-console.js', |
<<<<<<<
const { accountID, properties, hasResolvedProperties } = useSelect( ( select ) => {
const data = {
accountID: select( STORE_NAME ).getAccountID(),
properties: [],
hasResolvedProperties: false,
};
if ( data.accountID ) {
data.properties = select( STORE_NAME ).getProperties( data.accountID );
data.hasResolvedProperties = select( STORE_NAME ).hasFinishedResolution( 'getProperties', [ data.accountID ] );
}
return data;
} );
const propertyID = useSelect( ( select ) => select( STORE_NAME ).getPropertyID() );
const hasResolvedAccounts = useSelect( ( select ) => select( STORE_NAME ).hasFinishedResolution( 'getAccounts' ) );
=======
const { accountID, properties, hasResolvedProperties } = useSelect( ( select ) => {
const data = {
accountID: select( STORE_NAME ).getAccountID(),
properties: [],
hasResolvedProperties: false,
};
if ( data.accountID ) {
data.properties = select( STORE_NAME ).getProperties( data.accountID );
data.hasResolvedProperties = select( STORE_NAME ).hasFinishedResolution( 'getProperties', [ data.accountID ] );
}
return data;
} );
>>>>>>>
const { accountID, properties, hasResolvedProperties } = useSelect( ( select ) => {
const data = {
accountID: select( STORE_NAME ).getAccountID(),
properties: [],
hasResolvedProperties: false,
};
if ( data.accountID ) {
data.properties = select( STORE_NAME ).getProperties( data.accountID );
data.hasResolvedProperties = select( STORE_NAME ).hasFinishedResolution( 'getProperties', [ data.accountID ] );
}
return data;
} );
const propertyID = useSelect( ( select ) => select( STORE_NAME ).getPropertyID() );
const hasResolvedAccounts = useSelect( ( select ) => select( STORE_NAME ).hasFinishedResolution( 'getAccounts' ) );
<<<<<<<
=======
const hasGTMPropertyID = useSelect( ( select ) => !! select( MODULES_TAGMANAGER ).getSingleAnalyticsPropertyID() );
const propertyID = useSelect( ( select ) => select( STORE_NAME ).getPropertyID() );
const hasResolvedAccounts = useSelect( ( select ) => select( STORE_NAME ).hasFinishedResolution( 'getAccounts' ) );
>>>>>>>
const hasGTMPropertyID = useSelect( ( select ) => !! select( MODULES_TAGMANAGER ).getSingleAnalyticsPropertyID() ); |
<<<<<<<
import modulesTagManagerStore, { STORE_NAME as modulesTagManagerStoreName } from '../../assets/js/modules/tagmanager/datastore';
=======
import modulesSearchConsoleStore, { STORE_NAME as modulesSearchConsoleStoreName } from '../../assets/js/modules/search-console/datastore';
>>>>>>>
import modulesSearchConsoleStore, { STORE_NAME as modulesSearchConsoleStoreName } from '../../assets/js/modules/search-console/datastore';
import modulesTagManagerStore, { STORE_NAME as modulesTagManagerStoreName } from '../../assets/js/modules/tagmanager/datastore';
<<<<<<<
registry.registerStore( modulesTagManagerStoreName, modulesTagManagerStore );
=======
registry.registerStore( modulesSearchConsoleStoreName, modulesSearchConsoleStore );
>>>>>>>
registry.registerStore( modulesSearchConsoleStoreName, modulesSearchConsoleStore );
registry.registerStore( modulesTagManagerStoreName, modulesTagManagerStore ); |
<<<<<<<
import './datastore';
import Modules from 'googlesitekit-modules';
=======
import Modules from 'googlesitekit-modules';
>>>>>>>
import Modules from 'googlesitekit-modules';
<<<<<<<
'googlesitekit.ModuleSettingsDetails-adsense',
'googlesitekit.AdSenseModuleSettings',
fillFilterWithComponent( SettingsMain )
);
addFilter(
=======
'googlesitekit.ModuleSetup-adsense',
'googlesitekit.AdSenseModuleSetup',
fillFilterWithComponent( SetupMain )
);
addFilter(
>>>>>>>
<<<<<<<
Modules.registerModule(
'adsense',
{
setupComponent: SetupMain,
},
);
=======
Modules.registerModule(
'adsense',
{
settingsEditComponent: SettingsEdit,
settingsViewComponent: SettingsView,
}
);
>>>>>>>
Modules.registerModule(
'adsense',
{
settingsEditComponent: SettingsEdit,
settingsViewComponent: SettingsView,
setupComponent: SetupMain,
}
); |
<<<<<<<
=======
import error from './error';
import service from './service';
>>>>>>>
import service from './service';
<<<<<<<
=======
error,
service
>>>>>>>
service |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.