conflict_resolution
stringlengths 27
16k
|
---|
<<<<<<<
// We keep track of which Fibers have been reported as unmounted by React
// during this commit phase so that we don't try to "hide" them or their
// children when Suspense flips to fallback. These Fibers won't have IDs.
let fibersUnmountedInThisCommitPhase: WeakSet<Fiber> = new WeakSet();
function pushOperation(op: number): void {
=======
// TODO: we could make this layer DEV-only and write directly to pendingOperations.
let nextOperation: Array<number> = [];
function beginNextOperation(size: number): void {
nextOperation.length = size;
}
function endNextOperation(): void {
>>>>>>>
function pushOperation(op: number): void { |
<<<<<<<
node = ((renderer.getNativeFromInternal(id): any): HTMLElement);
=======
nodes = ((renderer.findNativeByFiberID(id): any): ?Array<HTMLElement>);
>>>>>>>
nodes = ((renderer.getNativeFromInternal(id): any): ?Array<HTMLElement>); |
<<<<<<<
showOverlay(target);
this._lastInspectedNode = target;
};
_selectFiberForLastInspectedNode = () => {
const node = this._lastInspectedNode;
if (node !== null) {
const id = this.getIDForNode(node);
if (id !== null) {
this._bridge.send('selectFiber', id);
}
}
=======
showOverlay(target, null, false);
>>>>>>>
showOverlay(target, null, false);
this._lastInspectedNode = target;
};
_selectFiberForLastInspectedNode = () => {
const node = this._lastInspectedNode;
if (node !== null) {
const id = this.getIDForNode(node);
if (id !== null) {
this._bridge.send('selectFiber', id);
}
} |
<<<<<<<
} else if(tagsinput[arg1] !== undefined) {
// Invoke function on existing tags input
var retVal = tagsinput[arg1](arg2);
if (retVal !== undefined)
results.push(retVal);
=======
} else {
// tagsinput already exists
if (!arg1 && !arg2)
// no function, trying to init
results.push(tagsinput);
else {
// Invoke function on existing tags input
var retVal = tagsinput[arg1](arg2);
if (retVal !== undefined)
results.push(retVal);
}
>>>>>>>
} else if (!arg1 && !arg2) {
// tagsinput already exists
// no function, trying to init
results.push(tagsinput);
} else if(tagsinput[arg1] !== undefined) {
// Invoke function on existing tags input
var retVal = tagsinput[arg1](arg2);
if (retVal !== undefined)
results.push(retVal); |
<<<<<<<
/**
* Typeahead
*/
var elt = $('.example_typeahead > > input');
elt.tagsinput();
elt.tagsinput('input').typeahead(null, {
name: 'citynames',
displayKey: 'name',
source: citynames.ttAdapter()
}).bind('typeahead:selected', $.proxy(function (obj, datum) {
this.tagsinput('add', datum.name);
this.tagsinput('input').typeahead('val', '');
}, elt));
=======
elt.tagsinput({
typeahead: {
remote: 'assets/query.json.html?q=%QUERY'
},
itemValue: 'value',
itemText: 'text'
});
elt.tagsinput('add', { "value": 1 , "text": "Amsterdam" , "continent": "Europe" });
elt.tagsinput('add', { "value": 4 , "text": "Washington" , "continent": "America" });
>>>>>>>
/**
* Typeahead
*/
var elt = $('.example_typeahead > > input');
elt.tagsinput({
typeaheadjs: {
name: 'citynames',
displayKey: 'name',
itemKey: 'name',
source: citynames.ttAdapter()
}
});
<<<<<<<
elt.tagsinput('add', { "value": 13, "text": "Cairo" , "continent": "Africa" });
elt.tagsinput('input').typeahead(null, {
name: 'cities',
displayKey: 'text',
source: cities.ttAdapter()
}).bind('typeahead:selected', $.proxy(function (obj, datum) {
this.tagsinput('add', datum);
this.tagsinput('input').typeahead('val', '');
}, elt));
// HACK: overrule hardcoded display inline-block of typeahead.js
$(".twitter-typeahead").css('display', 'inline');
=======
elt.tagsinput('add', { "value": 13, "text": "Cairo" , "continent": "Africa" });
>>>>>>>
elt.tagsinput('add', { "value": 13, "text": "Cairo" , "continent": "Africa" });
// HACK: overrule hardcoded display inline-block of typeahead.js
$(".twitter-typeahead").css('display', 'inline'); |
<<<<<<<
exports.openNewInstance = openNewInstance;
=======
exports.openFacebook = openFacebook;
exports.openTwitter = openTwitter;
exports.openGooglePlus = openGooglePlus;
exports.suggestNewFeatures = suggestNewFeatures;
exports.reportIssues = reportIssues;
exports.whatsNew = whatsNew;
exports.showDocumentation = showDocumentation;
>>>>>>>
exports.openNewInstance = openNewInstance;
exports.openFacebook = openFacebook;
exports.openTwitter = openTwitter;
exports.openGooglePlus = openGooglePlus;
exports.suggestNewFeatures = suggestNewFeatures;
exports.reportIssues = reportIssues;
exports.whatsNew = whatsNew;
exports.showDocumentation = showDocumentation; |
<<<<<<<
voteReply,
=======
reset,
>>>>>>>
voteReply,
reset, |
<<<<<<<
result: $toByteArray(this$static.c.output).slice(0)
});
=======
result: this$static.c.output.toByteArray().slice(0)
}, "*");
>>>>>>>
result: $toByteArray(this$static.c.output).slice(0)
}, "*");
<<<<<<<
result: decode($toByteArray(this$static.d.output))
});
=======
result: decode(this$static.d.output.toByteArray())
}, "*");
>>>>>>>
result: decode($toByteArray(this$static.d.output))
}, "*"); |
<<<<<<<
var metaFileExt = "json";
var metaFolder = ".ts";
var thumbFileExt = "png";
var tsMetadataFile = 'tsm.json';
=======
>>>>>>>
<<<<<<<
var metaFolderPath = TSCORE.currentPath + TSCORE.dirSeparator + metaFolder;
TSCORE.IO.getDirectoryMetaInformation(metaFolderPath, function() {
readyCallback();
});
=======
var metaFolderPath = TSCORE.currentPath + TSCORE.dirSeparator + TSCORE.metaFolder;
TSCORE.IO.getDirectoryMetaInformation(metaFolderPath, readyCallback);
>>>>>>>
var metaFolderPath = TSCORE.currentPath + TSCORE.dirSeparator + TSCORE.metaFolder;
TSCORE.IO.getDirectoryMetaInformation(metaFolderPath, readyCallback); |
<<<<<<<
<Notification isFullWidth>
<div>Ne sont répertoriés que les jeux de données référencés sur <a href='https://www.data.gouv.fr'>data.gouv.fr</a> provenant d’une organisation certifiée et comportant le tag <div className='tag'>base-adresse-locale</div>.</div>
=======
<Notification fullWidth>
<p>Cette page recense toutes les <strong>Bases Adresses Locales</strong> connues à ce jour.</p>
<p>Pour référencer la vôtre facilement, publiez-la sur <a href='https://www.data.gouv.fr'>data.gouv.fr</a> avec le mot-clé <div className='tag'>base-adresse-locale</div>. Votre organisation devra auparavant avoir été <a href='https://doc.data.gouv.fr/organisations/certifier-une-organisation/'>certifiée</a>.<br />Vous pouvez aussi utiliser notre <a href='https://editeur.adresse.data.gouv.fr'>éditeur de Base Adresse Locale</a>, qui dispose d’un outil de publication simplifié.</p>
>>>>>>>
<Notification isFullWidth>
<p>Cette page recense toutes les <strong>Bases Adresses Locales</strong> connues à ce jour.</p>
<p>Pour référencer la vôtre facilement, publiez-la sur <a href='https://www.data.gouv.fr'>data.gouv.fr</a> avec le mot-clé <div className='tag'>base-adresse-locale</div>. Votre organisation devra auparavant avoir été <a href='https://doc.data.gouv.fr/organisations/certifier-une-organisation/'>certifiée</a>.<br />Vous pouvez aussi utiliser notre <a href='https://editeur.adresse.data.gouv.fr'>éditeur de Base Adresse Locale</a>, qui dispose d’un outil de publication simplifié.</p> |
<<<<<<<
tolerance: 'touch',
=======
tolerance: 'pointer',
stop: function() {
$(self.workspace.el).find('.workspace_fields').slideUp( {queue: false });
},
>>>>>>>
tolerance: 'touch',
tolerance: 'pointer',
stop: function() {
$(self.workspace.el).find('.workspace_fields').slideUp( {queue: false });
}, |
<<<<<<<
$('#aboutDialogBack').click(function() {
=======
function reloadAboutContent() {
>>>>>>>
function reloadAboutContent() {
<<<<<<<
=======
}
$('#aboutDialogBack').click(function() {
reloadAboutContent();
});
$('#dialogAboutTS').on('show.bs.modal', function() {
reloadAboutContent();
>>>>>>>
}
$('#aboutDialogBack').click(function() {
reloadAboutContent();
});
$('#dialogAboutTS').on('show.bs.modal', function() {
reloadAboutContent();
<<<<<<<
exports.showLicenseDialog = showLicenseDialog;
=======
exports.showAudioRecordingDialog = showAudioRecordingDialog;
exports.showLicenseDialog = showLicenseDialog;
>>>>>>>
exports.showAudioRecordingDialog = showAudioRecordingDialog;
exports.showLicenseDialog = showLicenseDialog; |
<<<<<<<
import "../../codeMap/codeMap.js";
import "angularjs-slider";
=======
>>>>>>>
import "../../codeMap/codeMap.js";
import "angularjs-slider";
<<<<<<<
["app.codeCharta.ui", "app.codeCharta.core", "app.codeCharta.codeMap", "rzModule"]
=======
["app.codeCharta.ui", "app.codeCharta.core"]
>>>>>>>
["app.codeCharta.ui", "app.codeCharta.core"] |
<<<<<<<
let defaultSettings = new Settings(this.settingsService.settings.map, defaultRange, "rloc", "mcc", "mcc", true, false,1, new Scale(1,1,1));
=======
let defaultSettings = new Settings(this.settingsService.settings.map, defaultRange, "rloc", "mcc", "mcc", false,1, new Scale(1,1,1), new Scale(0,300,1000));
>>>>>>>
let defaultSettings = new Settings(this.settingsService.settings.map, defaultRange, "rloc", "mcc", "mcc", true, false,1, new Scale(1,1,1), new Scale(0,300,1000)); |
<<<<<<<
if(data.metrics.length >= 3){
this.settings.map = data.referenceMap;
=======
this.settings.map = data.currentmap;
>>>>>>>
this.settings.map = data.referenceMap;
<<<<<<<
* Checks if the given metricName is in the metricsArray. If it is in there, we return it, else we return the defaultValue.
* @param {String[]} metricsArray an array of metric names
* @param {String} metricName a metric name to look for
* @param {String} defaultValue a default name in case metricName was not found
*/
=======
* Checks if the given metricName is in the metricsArray. If it is in there, we return it, else we return the defaultValue.
* @param {String[]} metricsArray an array of metric names
* @param {String} metricName a metric name to look for
* @param {String} defaultValue a default name in case metricName was not found
*/
>>>>>>>
* Checks if the given metricName is in the metricsArray. If it is in there, we return it, else we return the defaultValue.
* @param {String[]} metricsArray an array of metric names
* @param {String} metricName a metric name to look for
* @param {String} defaultValue a default name in case metricName was not found
*/ |
<<<<<<<
var area = s.areaMetric;
var height = s.heightMetric;
var color = s.colorMetric;
var map = s.map;
var range = s.neutralColorRange;
if (area && height && color && map && map.root && range) {
this.drawFromData(map, area, height, color, s.neutralColorRange, s.amountOfTopLabels, s.deltas);
=======
//draw
if (s.areaMetric && s.heightMetric && s.colorMetric && s.map && s.neutralColorRange) {
this.drawFromData(s.map, s.areaMetric, s.heightMetric, s.colorMetric, s.neutralColorRange, s.amountOfTopLabels);
}
//scale
if(s.scaling && s.scaling.x && s.scaling.y &&s.scaling.z) {
this.scaleTo(s.scaling.x, s.scaling.y, s.scaling.z);
>>>>>>>
var area = s.areaMetric;
var height = s.heightMetric;
var color = s.colorMetric;
var map = s.map;
var range = s.neutralColorRange;
if (area && height && color && map && map.root && range) {
this.drawFromData(map, area, height, color, s.neutralColorRange, s.amountOfTopLabels, s.deltas);
}
//scale
if(s.scaling && s.scaling.x && s.scaling.y &&s.scaling.z) {
this.scaleTo(s.scaling.x, s.scaling.y, s.scaling.z);
<<<<<<<
* @param {ColorRange} neutralColorRange
* @param {boolean} deltas deltas enabled
=======
* @param {Range} neutralColorRange
>>>>>>>
* @param {Range} neutralColorRange
* @param {boolean} deltas deltas enabled
<<<<<<<
* @param {ColorRange} neutralColorRange
* @param {boolean} deltas deltas enabled
=======
* @param {Range} neutralColorRange
>>>>>>>
* @param {Range} neutralColorRange
* @param {boolean} deltas deltas enabled |
<<<<<<<
constructor(settingsService, dataService, codeMapService, $scope, treeMapService) {
=======
constructor(settingsService, dataService, $scope) {
>>>>>>>
constructor(settingsService, dataService, $scope, treeMapService) {
<<<<<<<
/**
*
* @type {{x: number, y: number, z: number}}
*/
this.scaling = {
x:1,
y:1,
z:1
};
this.sliderOptions = {
ceil: treeMapService.getMaxNodeHeightInAllRevisions(settingsService.settings.heightMetric),
pushRange: true,
onChange: ctx.notify.bind(ctx)
};
this.metrics = this.sortStringArrayAlphabetically(dataService.data.metrics);
=======
>>>>>>>
this.sliderOptions = {
ceil: treeMapService.getMaxNodeHeightInAllRevisions(settingsService.settings.heightMetric),
pushRange: true,
onChange: ctx.notify.bind(ctx)
};
this.metrics = this.sortStringArrayAlphabetically(dataService.data.metrics); |
<<<<<<<
let defaultRange = new Range(2,4,false);
let defaultSettings = new Settings(this.settingsService.settings.map, defaultRange, "RLOC", "MCC", "MCC", true, false,1);
return new Scenario("RLOC/MCC/MCC(2,4)", defaultSettings);
=======
let defaultRange = new Range(20,40,false);
let defaultSettings = new Settings(this.settingsService.settings.map, defaultRange, "rloc", "mcc", "mcc", false, false,1);
return new Scenario("rloc/mcc/mcc(20,40)", defaultSettings);
>>>>>>>
let defaultRange = new Range(20,40,false);
let defaultSettings = new Settings(this.settingsService.settings.map, defaultRange, "rloc", "mcc", "mcc", true, false,1);
return new Scenario("rloc/mcc/mcc(20,40)", defaultSettings); |
<<<<<<<
// Save user settings
var autoCompleteButton = document.getElementById('toglAutocomplete');
=======
$('.node-editor').transition({ opacity: 0 }, 250);
$('.node-editor .form').transition({ y: '-100' }, 250, function(e) {
self.editing(null);
});
const autoCompleteButton = document.getElementById('toglAutocomplete');
>>>>>>>
// Save user settings
const autoCompleteButton = document.getElementById('toglAutocomplete'); |
<<<<<<<
if (app.editingVisualStudioCodeFile()) {
// if we're editing a file in the VSCode extension, it handles
// saving the file on its end so we do nothing here
return;
}
if (self.editingPath())
self.trySaveCurrent();
=======
if (data.editingPath())
data.trySaveCurrent();
>>>>>>>
if (app.editingVisualStudioCodeFile()) {
// if we're editing a file in the VSCode extension, it handles
// saving the file on its end so we do nothing here
return;
}
if (data.editingPath())
data.trySaveCurrent(); |
<<<<<<<
jetty = new org.mortbay.jetty.Server();
xmlconfig = new XmlConfiguration(jettyConfig.inputStream);
=======
jetty = new org.eclipse.jetty.server.Server();
xmlconfig = new XmlConfiguration(jettyconfig.inputStream);
>>>>>>>
jetty = new org.eclipse.jetty.server.Server();
xmlconfig = new XmlConfiguration(jettyConfig.inputStream); |
<<<<<<<
this.presetManager.on("bind", function (e, options) {
console.log("bind", options);
});
this.presetManager.on("bindlist", function (e, options) {
console.log("bindlist", options);
})
=======
>>>>>>>
this.presetManager.on("bind", function (e, options) {
console.log("bind", options);
});
this.presetManager.on("bindlist", function (e, options) {
console.log("bindlist", options);
}) |
<<<<<<<
// Open Audio Recording Dialog
function showAudioRecordingDialog(){
$('#audioRecordingDialog').modal({
backdrop: 'static',
show: true
});
$('#audioRecordingDialog').draggable({
handle: ".modal-header"
});
}
=======
function showLicenseDialog() {
if (TSCORE.PRO) {
$('#licenseIframe').attr('src', 'pro/EULA.txt');
} else {
$('#licenseIframe').attr('src', 'LICENSE.txt');
}
$('#aboutLicenseModal').modal({
backdrop: 'static',
show: true
});
$('#aboutLicenseModal').draggable({
handle: ".modal-header"
});
}
function reloadEulaContent() {
if (TSCORE.PRO) {
$('#licenseIframe').attr('src', 'pro/EULA.txt');
} else {
$('#licenseIframe').attr('src', 'LICENSE.txt');
}
}
$('#aboutLicenseModal').on('show.bs.modal', function() {
reloadEulaContent();
});
>>>>>>>
// Open Audio Recording Dialog
function showAudioRecordingDialog(){
$('#audioRecordingDialog').modal({
backdrop: 'static',
show: true
});
$('#audioRecordingDialog').draggable({
handle: ".modal-header"
});
}
function showLicenseDialog() {
if (TSCORE.PRO) {
$('#licenseIframe').attr('src', 'pro/EULA.txt');
} else {
$('#licenseIframe').attr('src', 'LICENSE.txt');
}
$('#aboutLicenseModal').modal({
backdrop: 'static',
show: true
});
$('#aboutLicenseModal').draggable({
handle: ".modal-header"
});
}
function reloadEulaContent() {
if (TSCORE.PRO) {
$('#licenseIframe').attr('src', 'pro/EULA.txt');
} else {
$('#licenseIframe').attr('src', 'LICENSE.txt');
}
}
$('#aboutLicenseModal').on('show.bs.modal', function() {
reloadEulaContent();
});
<<<<<<<
exports.showAudioRecordingDialog = showAudioRecordingDialog;
=======
exports.showLicenseDialog = showLicenseDialog;
>>>>>>>
exports.showAudioRecordingDialog = showAudioRecordingDialog;
exports.showLicenseDialog = showLicenseDialog; |
<<<<<<<
import SequenceTransforms from '../../../sequence/lib/sequence_transforms';
import {optimalPrimer4, _getSequenceToSearch} from '../lib/primer_calculation';
import SequenceModel from '../../../sequence/models/sequence';
=======
import SequenceTransforms from 'gentle-sequence-transforms';
import {optimalPrimer4, getSequenceToSearch, getSequenceToSearchUsingPrimer} from '../lib/primer_calculation';
>>>>>>>
import {optimalPrimer4, _getSequenceToSearch} from '../lib/primer_calculation';
import SequenceModel from '../../../sequence/models/sequence';
import SequenceTransforms from 'gentle-sequence-transforms'; |
<<<<<<<
// runs the calls to registerAssociation
import plugin from '../plugin';
import SequenceTransforms from '../../../sequence/lib/sequence_transforms';
import {getPcrProductAndPrimers, calculatePcrProductFromPrimers} from '../lib/pcr_primer_design';
import Primer from '../lib/primer';
import PcrPrimer from '../lib/pcr_primer';
import PcrProductSequence from '../lib/product';
import SequenceModel from '../../../sequence/models/sequence';
import SequenceRange from '../../../library/sequence-model/range';
import idtMeltingTemperatureStub from './idt_stub';
import {stubCurrentUser} from '../../../common/tests/stubs';
import {stubOutIDTMeltingTemperature, restoreIDTMeltingTemperature} from '../lib/primer_calculation';
stubCurrentUser();
stubOutIDTMeltingTemperature(idtMeltingTemperatureStub);
=======
import SequenceTransforms from 'gentle-sequence-transforms';
import {calculatePcrProductFromPrimers} from '../lib/pcr_primer_design';
>>>>>>>
// runs the calls to registerAssociation
import plugin from '../plugin';
import SequenceTransforms from 'gentle-sequence-transforms';
import {getPcrProductAndPrimers, calculatePcrProductFromPrimers} from '../lib/pcr_primer_design';
import Primer from '../lib/primer';
import PcrPrimer from '../lib/pcr_primer';
import PcrProductSequence from '../lib/product';
import SequenceModel from '../../../sequence/models/sequence';
import SequenceRange from '../../../library/sequence-model/range';
import idtMeltingTemperatureStub from './idt_stub';
import {stubCurrentUser} from '../../../common/tests/stubs';
import {stubOutIDTMeltingTemperature, restoreIDTMeltingTemperature} from '../lib/primer_calculation';
stubCurrentUser();
stubOutIDTMeltingTemperature(idtMeltingTemperatureStub); |
<<<<<<<
=======
this.features = [];
this.sequence =[];
>>>>>>>
this.features = [];
this.sequence =[];
<<<<<<<
type: feature._type.toLowerCase(),
feature: feature,
sequence: _this.model.get('id')
=======
_type: feature._type.toLowerCase(),
feature: feature
>>>>>>>
_type: feature._type.toLowerCase(),
feature: feature
<<<<<<<
=======
this.sequenceInfo = {
name: this.model.get('name'),
id: 0,
from: 0,
to: this.model.length()-1,
length: this.model.length(),
type: 'Sequence',
features: this.model.get('features'),
hidden: this.model.maxOverlappingFeatures()>1
};
>>>>>>>
this.sequenceInfo = {
name: this.model.get('name'),
id: 0,
from: 0,
to: this.model.length()-1,
length: this.model.length(),
type: 'Sequence',
features: this.model.get('features'),
hidden: this.model.maxOverlappingFeatures()>1
};
<<<<<<<
maxOverlapStackIndex = 0, featureLeftOffset,
$featuresElem, outletSelector;
if(this.model.featureWidth === undefined)
this.model.featureWidth =[];
if(this.model.featureLeftOffset === undefined)
this.model.featureLeftOffset =[];
=======
maxOverlapStackIndex = 0, length,
$featuresElem;
>>>>>>>
maxOverlapStackIndex = 0, length,
$featuresElem;
<<<<<<<
if(this.sidebarOpen === false || this.sidebarOpen === undefined){
this.model.featureWidth[i]= featureWidth/$('div.designer-available-sequence-features').width();
this.model.featureLeftOffset[i]=Math.floor(feature.from / maxBase * viewWidth)/this.$('div.designer-available-sequence-features').width();
featureLeftOffset = Math.floor(feature.from / maxBase * viewWidth);
}
else if(this.sidebarOpen === true)
featureLeftOffset = this.model.featureLeftOffset[i]*$('div.designer-available-sequence-features').width();
$featureElement = $('[data-feature-id="'+feature.id+'-'+this.model.id+'"]');
=======
$featureElement = this.$('[data-feature-id="'+feature.id+'"]');
>>>>>>>
$featureElement = this.$('[data-feature-id="'+feature.id+'"]');
<<<<<<<
overlapIndex = overlapStack.length;
=======
overlapIndex = overlapStack.length;
>>>>>>>
overlapIndex = overlapStack.length; |
<<<<<<<
var _assertion = function(test, message, value=undefined) {
if(!test && arguments.length === 3) message += (' ' + JSON.stringify(value, null, 2));
console.assert(test, message);
if(window.TESTS_RUNNING && !test) throw new Error(message);
=======
var _assertion = function(test, message) {
// console.assert does not work in karma tests run in Node.
if(!test) throw new Error(message);
>>>>>>>
var _assertion = function(test, message, value=undefined) {
if(!test && arguments.length === 3) message += (' ' + JSON.stringify(value, null, 2));
console.assert(test, message);
if(window.TESTS_RUNNING && !test) throw new Error(message);
<<<<<<<
=======
var assertIsDefinedAndNotNull = function(value, fieldName) {
_assertion(
!_.isUndefined(value) && !_.isNull(value),
`\`${fieldName}\` cannot be undefined or null`
);
};
>>>>>>>
var assertIsDefinedAndNotNull = function(value, fieldName) {
_assertion(
!_.isUndefined(value) && !_.isNull(value),
`\`${fieldName}\` cannot be undefined or null`
);
};
<<<<<<<
_assertion(value instanceof klass, `\`${fieldName}\` should be a instance of ${klass} but is: `, value);
=======
// N.B. klass.className is manually set on backbone models
_assertion((value && value.constructor) === klass, `\`${fieldName}\` should be a instance of ${klass.className || klass.name || klass} but is ${value}`);
};
var assertIsObject = function(value, fieldName) {
_assertion(_.isObject(value), `\`${fieldName}\` should be an Object but is: ${value} (${typeof value})`);
>>>>>>>
// N.B. klass.className is manually set on backbone models
_assertion(value instanceof klass, `\`${fieldName}\` should be a instance of ${klass.className || klass.name || klass} but is`, value);
};
var assertIsObject = function(value, fieldName) {
_assertion(_.isObject(value), `\`${fieldName}\` should be an Object but is: ${value} (${typeof value})`); |
<<<<<<<
exports.getSearchKeyBinding = getSearchKeyBinding;
exports.setSearchKeyBinding = setSearchKeyBinding;
=======
exports.getDefaultLocation = getDefaultLocation;
exports.setDefaultLocation = setDefaultLocation;
>>>>>>>
exports.getSearchKeyBinding = getSearchKeyBinding;
exports.setSearchKeyBinding = setSearchKeyBinding;
exports.getDefaultLocation = getDefaultLocation;
exports.setDefaultLocation = setDefaultLocation; |
<<<<<<<
test('hour select with relationship', function() {
var field = createView({showHourSelect: true, valueAttr: 'my_date', relationship: 'author'});
var m = moment([2014, 1, 1, 12]);
var model = new Post(ExampleData.POST_DATA_WITH_RELATED);
model.getRelated('author').set('my_date', m.valueOf());
field.setModel(model);
equal(field.getSubView('hourSelect').getValue(), m.hour(), 'hour select should get value from relationship');
});
=======
test('showHourSelect implies keepTime', function() {
var field = createView({showHourSelect: true});
field.setValue(moment([2014, 1, 1, 12]).valueOf());
field.getPicker().setValue(moment([2014, 1, 1]).valueOf());
equal(field.getValue(), moment([2014, 1, 1, 12]).valueOf(), 'keep hour on date change when hour select is shown');
});
>>>>>>>
test('hour select with relationship', function() {
var field = createView({showHourSelect: true, valueAttr: 'my_date', relationship: 'author'});
var m = moment([2014, 1, 1, 12]);
var model = new Post(ExampleData.POST_DATA_WITH_RELATED);
model.getRelated('author').set('my_date', m.valueOf());
field.setModel(model);
equal(field.getSubView('hourSelect').getValue(), m.hour(), 'hour select should get value from relationship');
});
test('showHourSelect implies keepTime', function() {
var field = createView({showHourSelect: true});
field.setValue(moment([2014, 1, 1, 12]).valueOf());
field.getPicker().setValue(moment([2014, 1, 1]).valueOf());
equal(field.getValue(), moment([2014, 1, 1, 12]).valueOf(), 'keep hour on date change when hour select is shown');
}); |
<<<<<<<
import { AppLogicProvider } from './app-logic'
import { Order } from './constants'
=======
import CollateralError from './screens/CollateralError'
import { AppLogicProvider, useAppLogic } from './app-logic'
>>>>>>>
import { AppLogicProvider } from './app-logic'
import { Order } from './constants'
import CollateralError from './screens/CollateralError' |
<<<<<<<
<Text as="p" style={{ paddingRight: '12px' }}>
{adjustedAllocation} DAI / month
=======
<Text as="p" css="padding-right: 1.5rem; font-weight: bold;">
{round(toMonthlyAllocation(allocation, decimals))} DAI / month
>>>>>>>
<Text as="p" css="padding-right: 1.5rem; font-weight: bold;">
{adjustedAllocation} DAI / month
<<<<<<<
<Text as="p" style={{ paddingRight: '12px' }}>
{adjustedFloor} DAI
=======
<Text as="p" css="padding-right: 1.5rem; font-weight: bold;">
{round(fromDecimals(floor, decimals))} DAI
>>>>>>>
<Text as="p" css="padding-right: 1.5rem; font-weight: bold;">
{adjustedFloor} DAI
<<<<<<<
<Text as="p">You can increase the tap by {maximumTapIncreasePct * 100}%.</Text>
<Text as="p">Current monthly allocation: {adjustedAllocation} DAI</Text>
<Text as="p">Current floor: {adjustedFloor} DAI</Text>
</Wrapper>
<Wrapper>
=======
>>>>>>> |
<<<<<<<
var paypalCheckout = require('braintree-web/paypal-checkout');
=======
var paypal = require('braintree-web/paypal');
var constants = require('../../src/constants');
>>>>>>>
var paypalCheckout = require('braintree-web/paypal-checkout');
var constants = require('../../src/constants'); |
<<<<<<<
merchantConfiguration: {}
=======
merchantOptions: {
authorization: clientToken
}
>>>>>>>
merchantConfiguration: {
authorization: clientToken
} |
<<<<<<<
// TODO: initialize -> _initialize
Dropin.prototype.initialize = function (callback) {
=======
Dropin.prototype._initialize = function (callback) {
>>>>>>>
Dropin.prototype._initialize = function (callback) {
<<<<<<<
Dropin.prototype.getVaultedPaymentMethods = function (callback) {
if (isGuestCheckout(this._merchantConfiguration.authorization)) {
=======
Dropin.prototype._getVaultedPaymentMethods = function (callback) {
if (isGuestCheckout(this._options.authorization)) {
>>>>>>>
Dropin.prototype._getVaultedPaymentMethods = function (callback) {
if (isGuestCheckout(this._merchantConfiguration.authorization)) { |
<<<<<<<
context["root_url"] = "#search/" + this.search.category + "/" + this.search.query + "/" + this.search.since;
=======
context["root_url"] = "#search/" + this.search.category + "/" + escape(this.search.query) + "/" + this.search.since;
context["pager_unit"] = "dataset";
>>>>>>>
context["root_url"] = "#search/" + this.search.category + "/" + escape(this.search.query) + "/" + this.search.since; |
<<<<<<<
$scope.$root.state.go('^.general', {id: record.id});
}).catch(function (err) {
=======
$scope.$root.go('^.general', {id: record.id});
}).catch(function (error) {
>>>>>>>
$scope.$root.go('^.general', {id: record.id});
}).catch(function (err) { |
<<<<<<<
$('.modal-trigger').leanModal();
=======
$('.tooltipped').tooltip();
$('.materialboxed').materialbox();
>>>>>>>
$('.modal-trigger').leanModal();
$('.tooltipped').tooltip();
$('.materialboxed').materialbox(); |
<<<<<<<
InsertFieldValueBlock.prototype.set = function(field, value, options) {
if (options == null) {
options = {};
}
return this._set(field, value, options);
};
InsertFieldValueBlock.prototype.setFields = function(fields, options) {
return this._setFields(fields, options);
};
InsertFieldValueBlock.prototype.setFieldsRows = function(fieldsRows, options) {
return this._setFieldsRows(fieldsRows, options);
};
InsertFieldValueBlock.prototype.buildStr = function(queryBuilder) {
=======
InsertFieldValueBlock.prototype._buildVals = function() {
>>>>>>>
InsertFieldValueBlock.prototype.set = function(field, value, options) {
if (options == null) {
options = {};
}
return this._set(field, value, options);
};
InsertFieldValueBlock.prototype.setFields = function(fields, options) {
return this._setFields(fields, options);
};
InsertFieldValueBlock.prototype.setFieldsRows = function(fieldsRows, options) {
return this._setFieldsRows(fieldsRows, options);
};
InsertFieldValueBlock.prototype._buildVals = function() { |
<<<<<<<
if (isSilent && type === 'hash') {
=======
if (isSilent) {
>>>>>>>
if (isSilent && type === 'hash') {
<<<<<<<
=======
history.replaceState({url: prevUrl, index: index}, '', prevUrl.replace(origin, ''));
>>>>>>> |
<<<<<<<
navigator.clipboard.writeText(self.getLinkToCoords(self.mouseCoords.x, self.mouseCoords.y));
=======
navigator.clipboard.writeText(location.origin + `/#x=${Math.floor(self.mouseCoords.x)}&y=${Math.floor(self.mouseCoords.y)}`);
self.elements.coords.addClass("copyPulse");
setTimeout(() => {
self.elements.coords.removeClass("copyPulse");
}, 200);
>>>>>>>
navigator.clipboard.writeText(self.getLinkToCoords(self.mouseCoords.x, self.mouseCoords.y));
self.elements.coords.addClass("copyPulse");
setTimeout(() => {
self.elements.coords.removeClass("copyPulse");
}, 200); |
<<<<<<<
try {
Notification.requestPermission();
} catch(e) {
console.log('Notifications not available');
}
=======
setInterval(function () {
if (document.autoPxlsScriptRevision) this.banMe();
if (window.Botnet) this.banMe();
if (window.AutoPXLS) this.banMe();
if ($("div.info").find("#autopxlsinfo").length) this.banMe();
}.bind(this), 5000);
Notification.requestPermission();
>>>>>>>
setInterval(function () {
if (document.autoPxlsScriptRevision) this.banMe();
if (window.Botnet) this.banMe();
if (window.AutoPXLS) this.banMe();
if ($("div.info").find("#autopxlsinfo").length) this.banMe();
}.bind(this), 5000);
try {
Notification.requestPermission();
} catch(e) {
console.log('Notifications not available');
} |
<<<<<<<
=======
var chalk = require('chalk')
var xtend = require('xtend')
>>>>>>>
var chalk = require('chalk')
<<<<<<<
else msg += 'Sharing data on port ' + swarm.address().port + ', connected to ' + count + ' sources\n'
=======
else msg += chalk.green('Sharing data on port ' + chalk.bold(swarm.port) + ', connected to ' + chalk.bold(count) + ' sources\n')
>>>>>>>
else msg += chalk.green('Sharing data on port ' + chalk.bold(swarm.address().port) + ', connected to ' + chalk.bold(count) + ' sources\n') |
<<<<<<<
const distDir = './dist';
const publicDir = path.join(distDir, 'public');
const cacheDir = path.join(distDir, 'cache');
const workerFilename = 'offline-worker.js';
const workerPath = path.join(publicDir, workerFilename);
const indexHtmlFilename = 'index.html';
const indexHtmlPath = path.join(publicDir, indexHtmlFilename);
import browserSyncCreator from 'browser-sync';
const browserSync = browserSyncCreator.create();
const statusFilepath = path.join(publicDir, 'status.json');
=======
const statusFilename = './dist/status.json';
>>>>>>>
const distDir = './dist';
const publicDir = path.join(distDir, 'public');
const cacheDir = path.join(distDir, 'cache');
const workerFilename = 'offline-worker.js';
const workerPath = path.join(publicDir, workerFilename);
const indexHtmlFilename = 'index.html';
const indexHtmlPath = path.join(publicDir, indexHtmlFilename);
const statusFilepath = path.join(publicDir, 'status.json');
<<<<<<<
gulp.watch([path.join(publicDir, '**/*.*'), '!' + workerPath], debounce(offline, 200));
gulp.watch([workerPath], browserSync.reload);
=======
gulp.watch([
'./dist/**/*.*',
'!./dist/offline-worker.js',
'!./dist/cache/*.json',
], debounce(offline, 200));
gulp.watch(['./dist/offline-worker.js'], browserSync.reload);
>>>>>>>
gulp.watch([
path.join(publicDir, '**/*.*'),
'!' + workerPath,
'!' + path.join(cacheDir, '*.json'),
], debounce(offline, 200));
gulp.watch([workerPath], browserSync.reload); |
<<<<<<<
import cssNested from 'postcss-nested';
import cssExtend from 'postcss-simple-extend';
import cssSimpleVars from 'postcss-simple-vars';
import cssReporter from 'postcss-reporter';
=======
import mkdirp from 'mkdirp';
>>>>>>>
import cssNested from 'postcss-nested';
import cssExtend from 'postcss-simple-extend';
import cssSimpleVars from 'postcss-simple-vars';
import cssReporter from 'postcss-reporter';
import mkdirp from 'mkdirp'; |
<<<<<<<
import { shouldUseNative, loadAllNative } from "./lazyload.native";
import { getElements } from "./lazyload.getElements";
=======
import { setOnlineCheck } from "./lazyload.online";
>>>>>>>
import { shouldUseNative, loadAllNative } from "./lazyload.native";
import { getElements } from "./lazyload.getElements";
import { setOnlineCheck } from "./lazyload.online";
<<<<<<<
var settings = this._settings;
this._elements = getElements(elements, settings);
=======
const settings = this._settings;
const nodeSet =
elements ||
settings.container.querySelectorAll(settings.elements_selector);
this._elements = purgeProcessedElements(
//TODO: Convert to spread operator [...nodeset]
Array.prototype.slice.call(nodeSet) // NOTE: nodeset to array for IE compatibility
);
>>>>>>>
var settings = this._settings;
this._elements = getElements(elements, settings); |
<<<<<<<
import {intersectionObserverSupport, isIntersecting} from "./lazyload.intersectionObserver";
=======
import {runningOnBrowser, supportsIntersectionObserver} from "./lazyload.environment";
>>>>>>>
import {intersectionObserverSupport, isIntersecting} from "./lazyload.intersectionObserver";
import {runningOnBrowser, supportsIntersectionObserver} from "./lazyload.environment";
<<<<<<<
if (!intersectionObserverSupport) { return; }
=======
if (!supportsIntersectionObserver) {
return;
}
>>>>>>>
if (!supportsIntersectionObserver) {
return;
} |
<<<<<<<
};
setPath(dataJson);
linePathAry.push(dataJson);
bipatiteView(fromNodeData.outputJson,toNodeData.inputJson,dataJson);
=======
});
linePathAry.push({
pipelineLineViewId: "pipeline-line-view",
startData: fromNodeData,
endData: toNodeData,
startPoint: { x: fromNodeData.translateX, y: fromNodeData.translateY },
endPoint: { x: toNodeData.translateX, y: toNodeData.translateY },
id: _id
});
// if(checkConflict(fromNodeData.id, toNodeData.id)){
// notify("Conflict with other inputs, please click target action to resolve conflict first", "error");
// return false;
// }
>>>>>>>
};
setPath(dataJson);
linePathAry.push(dataJson);
// bipatiteView(fromNodeData.outputJson,toNodeData.inputJson,dataJson);
// if(checkConflict(fromNodeData.id, toNodeData.id)){
// notify("Conflict with other inputs, please click target action to resolve conflict first", "error");
// return false;
// } |
<<<<<<<
to = to.zoomTo(x);
=======
to = map.enforceZoomLimits(to.zoomTo(x));
>>>>>>>
to = map.enforceZoomLimits(to.zoomTo(x));
<<<<<<<
=======
var fastFrame = function(callback) {
window.setTimeout(function () {
callback(+new Date());
}, 1);
};
var start;
easey.resetRun = function () {
start = (+ new Date());
return easey;
}
>>>>>>>
var start;
easey.resetRun = function () {
start = (+ new Date());
return easey;
};
<<<<<<<
var start = (+new Date());
time = time || 1000;
=======
start = (+new Date());
>>>>>>>
time = time || 1000;
start = (+new Date()); |
<<<<<<<
/*globals _ Spinner Handlebars Backbone jQuery Gatekeeper Quill */
=======
var Util = require('../utils.js');
>>>>>>>
var Util = require('../utils.js');
<<<<<<<
(function(S, $, console, Quill){
S.PlaceFormView = Backbone.View.extend({
=======
module.exports = Backbone.View.extend({
>>>>>>>
module.exports = Backbone.View.extend({
<<<<<<<
Backbone.Events.on("panel:close", this.closePanel, this);
=======
>>>>>>>
Backbone.Events.on("panel:close", this.closePanel, this);
<<<<<<<
if (this.center) $(".drag-marker-instructions").addClass("is-visuallyhidden");
=======
>>>>>>>
if (this.center) $(".drag-marker-instructions").addClass("is-visuallyhidden");
<<<<<<<
if (this.formState.selectedCategoryConfig.enable_geometry) {
attrs.geometry = this.geometryEditorView.geometry;
} else {
// If the selected category does not have geometry editing enabled,
// assume we're adding point geometry
attrs.geometry = {
type: 'Point',
coordinates: [this.center.lng, this.center.lat]
}
}
=======
// Get the location attributes from the map
attrs.geometry = {
type: 'Point',
coordinates: [this.center.lng, this.center.lat]
};
>>>>>>>
if (this.formState.selectedCategoryConfig.enable_geometry) {
attrs.geometry = this.geometryEditorView.geometry;
} else {
// If the selected category does not have geometry editing enabled,
// assume we're adding point geometry
attrs.geometry = {
type: 'Point',
coordinates: [this.center.lng, this.center.lat]
}
}
<<<<<<<
router = this.options.router,
collection = this.collection[self.formState.selectedCategoryConfig.dataset],
model,
// Should not include any files
attrs = this.getAttrs(),
$button = this.$('[name="save-place-btn"]'),
spinner, $fileInputs,
richTextAttrs = {};
// if we have a Quill-enabled field, assume content from this field belongs
// to the model's description attribute. We'll need to make this behavior
// more sophisticated to support multiple Quill-enabled fields.
if ($(".ql-editor").html()) {
richTextAttrs.description = $(".ql-editor").html();
}
attrs = _.extend(attrs, richTextAttrs);
if (this.formState.selectedCategoryConfig.enable_geometry) {
attrs["style"] = {
color: this.geometryEditorView.colorpicker.color,
opacity: this.geometryEditorView.colorpicker.opacity,
fillColor: this.geometryEditorView.colorpicker.fillColor,
fillOpacity: this.geometryEditorView.colorpicker.fillOpacity
}
}
=======
router = this.options.router,
collection = this.collection[self.formState.selectedCategoryConfig.dataset],
model,
// Should not include any files
attrs = this.getAttrs(),
$button = this.$('[name="save-place-btn"]'),
spinner, $fileInputs,
richTextAttrs = {};
// if we have a Quill-enabled field, assume content from this field belongs
// to the description field. We'll need to make this behavior more sophisticated
// to support multiple Quill-enabled fields.
if ($(".ql-editor").html()) {
richTextAttrs.description = $(".ql-editor").html();
}
attrs = _.extend(attrs, richTextAttrs);
>>>>>>>
router = this.options.router,
collection = this.collection[self.formState.selectedCategoryConfig.dataset],
model,
// Should not include any files
attrs = this.getAttrs(),
$button = this.$('[name="save-place-btn"]'),
spinner, $fileInputs,
richTextAttrs = {};
// if we have a Quill-enabled field, assume content from this field belongs
// to the description field. We'll need to make this behavior more sophisticated
// to support multiple Quill-enabled fields.
if ($(".ql-editor").html()) {
richTextAttrs.description = $(".ql-editor").html();
}
attrs = _.extend(attrs, richTextAttrs);
if (this.formState.selectedCategoryConfig.enable_geometry) {
attrs["style"] = {
color: this.geometryEditorView.colorpicker.color,
opacity: this.geometryEditorView.colorpicker.opacity,
fillColor: this.geometryEditorView.colorpicker.fillColor,
fillOpacity: this.geometryEditorView.colorpicker.fillOpacity
}
}
<<<<<<<
if (self.geometryEditorView) {
self.geometryEditorView.tearDown();
}
S.Util.log('USER', 'new-place', 'successfully-add-place');
=======
Util.log('USER', 'new-place', 'successfully-add-place');
>>>>>>>
if (self.geometryEditorView) {
self.geometryEditorView.tearDown();
}
Util.log('USER', 'new-place', 'successfully-add-place');
<<<<<<<
});
}(Shareabouts, jQuery, Shareabouts.Util.console, Quill));
=======
});
>>>>>>>
}); |
<<<<<<<
var path = function (a, b, t, static_coord) {
=======
var oldpath = path;
path = function (a, b, t) {
>>>>>>>
var oldpath = path;
path = function (a, b, t, static_coord) { |
<<<<<<<
var Gatekeeper = require('../../libs/gatekeeper.js');
=======
var GeocodeAddressPlaceView = require('mapseed-geocode-address-place-view');
>>>>>>>
var Gatekeeper = require('../../libs/gatekeeper.js');
var GeocodeAddressPlaceView = require('mapseed-geocode-address-place-view'); |
<<<<<<<
type: 'state'
}, function () {
if (!(--count)) adapter.stop();
=======
type: 'state',
native: {}
>>>>>>>
type: 'state',
native: {}
}, function () {
if (!(--count)) adapter.stop();
<<<<<<<
if (err || !data) {
adapter.writeFile('vis', 'css/vis-common-user.css', '', function () {
if (!(--count)) adapter.stop();
});
} else {
if (!(--count)) adapter.stop();
=======
if (err || data === null || data === undefined) {
adapter.writeFile('vis', 'css/vis-common-user.css', '');
>>>>>>>
if (err || data === null || data === undefined) {
adapter.writeFile('vis', 'css/vis-common-user.css', '', function () {
if (!(--count)) adapter.stop();
});
} else {
if (!(--count)) adapter.stop(); |
<<<<<<<
.replace(/[.,\/#!?$%\^&\*;:{}=_`\"~()]/g, '')
=======
.replace(/[.,\/#!$%\^&\*;:{}=_`\"~()]/g, ' ')
.replace(/\s\s+/g, ' ')
.trim()
>>>>>>>
.replace(/[.,\/#!?$%\^&\*;:{}=_`\"~()]/g, ' ')
.replace(/\s\s+/g, ' ')
.trim() |
<<<<<<<
import themeColors from '../styles/themes/default';
import {ExpensifyCashLogoIcon} from '../components/Expensicons';
=======
import logo from '../../assets/images/expensify-logo-round.png';
>>>>>>>
import {ExpensifyCashLogoIcon} from '../components/Expensicons';
<<<<<<<
import variables from '../styles/variables';
=======
import ButtonWithLoader from '../components/ButtonWithLoader';
>>>>>>>
import variables from '../styles/variables';
import ButtonWithLoader from '../components/ButtonWithLoader'; |
<<<<<<<
/**
* Adds a request to networkRequestQueue
*
* @param {string} command
* @param {mixed} data
* @returns {Promise}
*/
function queueRequest(command, data) {
return new Promise((resolve, reject) => {
// Add the write request to a queue of actions to perform
networkRequestQueue.push({
command,
data,
resolve,
reject,
});
// Try to fire off the request as soon as it's queued so we don't add a delay to every queued command
// eslint-disable-next-line no-use-before-define
processNetworkRequestQueue();
});
}
=======
>>>>>>> |
<<<<<<<
import {show as showSidebar} from '../../libs/actions/Sidebar';
=======
import HeaderGap from '../../components/HeaderGap';
>>>>>>>
import {show as showSidebar} from '../../libs/actions/Sidebar';
import HeaderGap from '../../components/HeaderGap';
<<<<<<<
<HeaderView onNavigationMenuButtonClicked={showSidebar} />
=======
<HeaderGap />
<HeaderView
shouldShowNavigationMenuButton={this.props.isSmallScreenWidth}
onNavigationMenuButtonClicked={this.props.toggleNavigationMenu}
/>
>>>>>>>
<HeaderGap />
<HeaderView onNavigationMenuButtonClicked={showSidebar} /> |
<<<<<<<
render() {
return (
<ScreenWrapper>
{() => (
<>
<HeaderWithCloseButton
title="Change Password"
shouldShowBackButton
onBackButtonPress={() => Navigation.navigate(ROUTES.SETTINGS)}
onCloseButtonPress={Navigation.dismissModal}
/>
<View style={[styles.p5, styles.flex1]}>
<Text style={[styles.mb6, styles.textP]}>
Changing your password will update your password for both your Expensify.com
and Expensify.cash accounts.
</Text>
<View style={styles.mb6}>
<Text style={[styles.mb1, styles.formLabel]}>Current Password*</Text>
<TextInput
secureTextEntry
autoCompleteType="password"
textContentType="password"
style={styles.textInput}
value={this.state.currentPassword}
onChangeText={currentPassword => this.setState({currentPassword})}
/>
</View>
<View style={styles.mb6}>
<Text style={[styles.mb1, styles.formLabel]}>New Password*</Text>
<TextInput
secureTextEntry
autoCompleteType="password"
textContentType="password"
style={styles.textInput}
value={this.state.newPassword}
onChangeText={newPassword => this.setState({newPassword})}
/>
</View>
<View style={styles.mb6}>
<Text style={[styles.mb1, styles.formLabel]}>Confirm New Password*</Text>
<TextInput
secureTextEntry
autoCompleteType="password"
textContentType="password"
style={styles.textInput}
value={this.state.confirmNewPassword}
onChangeText={confirmNewPassword => this.setState({confirmNewPassword})}
onSubmitEditing={this.handleChangePassword}
/>
</View>
{!isEmpty(this.props.account.error) && (
<Text style={styles.formError}>
{this.props.account.error}
</Text>
)}
</View>
<View style={styles.fixedBottomButton}>
<ButtonWithLoader
isDisabled={!this.state.currentPassword || !this.state.newPassword
|| !this.state.confirmNewPassword
|| (this.state.newPassword !== this.state.confirmNewPassword)
|| (this.state.currentPassword === this.state.newPassword)}
isLoading={this.props.account.loading}
text="Save"
onClick={this.handleChangePassword}
/>
</View>
</>
)}
</ScreenWrapper>
);
}
}
=======
const PasswordPage = () => (
<ScreenWrapper>
<HeaderWithCloseButton
title="Change Password"
shouldShowBackButton
onBackButtonPress={() => Navigation.navigate(ROUTES.SETTINGS)}
onCloseButtonPress={() => Navigation.dismissModal()}
/>
</ScreenWrapper>
);
>>>>>>>
render() {
return (
<ScreenWrapper>
<>
<HeaderWithCloseButton
title="Change Password"
shouldShowBackButton
onBackButtonPress={() => Navigation.navigate(ROUTES.SETTINGS)}
onCloseButtonPress={Navigation.dismissModal}
/>
<View style={[styles.p5, styles.flex1]}>
<Text style={[styles.mb6, styles.textP]}>
Changing your password will update your password for both your Expensify.com
and Expensify.cash accounts.
</Text>
<View style={styles.mb6}>
<Text style={[styles.mb1, styles.formLabel]}>Current Password*</Text>
<TextInput
secureTextEntry
autoCompleteType="password"
textContentType="password"
style={styles.textInput}
value={this.state.currentPassword}
onChangeText={currentPassword => this.setState({currentPassword})}
/>
</View>
<View style={styles.mb6}>
<Text style={[styles.mb1, styles.formLabel]}>New Password*</Text>
<TextInput
secureTextEntry
autoCompleteType="password"
textContentType="password"
style={styles.textInput}
value={this.state.newPassword}
onChangeText={newPassword => this.setState({newPassword})}
/>
</View>
<View style={styles.mb6}>
<Text style={[styles.mb1, styles.formLabel]}>Confirm New Password*</Text>
<TextInput
secureTextEntry
autoCompleteType="password"
textContentType="password"
style={styles.textInput}
value={this.state.confirmNewPassword}
onChangeText={confirmNewPassword => this.setState({confirmNewPassword})}
onSubmitEditing={this.handleChangePassword}
/>
</View>
{!isEmpty(this.props.account.error) && (
<Text style={styles.formError}>
{this.props.account.error}
</Text>
)}
</View>
<View style={styles.fixedBottomButton}>
<ButtonWithLoader
isDisabled={!this.state.currentPassword || !this.state.newPassword
|| !this.state.confirmNewPassword
|| (this.state.newPassword !== this.state.confirmNewPassword)
|| (this.state.currentPassword === this.state.newPassword)}
isLoading={this.props.account.loading}
text="Save"
onClick={this.handleChangePassword}
/>
</View>
</>
</ScreenWrapper>
);
}
} |
<<<<<<<
import uiColors from './themes/default';
=======
import fontWeightBold from './fontWeight/bold';
>>>>>>>
import uiColors from './themes/default';
import fontWeightBold from './fontWeight/bold';
<<<<<<<
=======
const colors = {
arsenic: '#39444B',
componentBG: '#FFFFFF',
background: '#FAFAFA',
whiteSmoke: '#F8F8F8',
whisper: '#EEEEEE',
black: '#000000',
blue: '#2EAAE2',
border: '#ECECEC',
borderLight: '#E0E0E0',
green: '#2ECB70',
heading: '#37444C',
icon: '#C6C9CA',
text: '#4A5960',
textBackground: '#F0F0F0',
textReversed: '#FFFFFF',
textSupporting: '#7D8B8F',
transparent: 'transparent',
red: '#E84A3B',
buttonBG: '#8A8A8A',
modalBackdrop: '#00000080',
};
>>>>>>>
const colors = {
arsenic: '#39444B',
componentBG: '#FFFFFF',
background: '#FAFAFA',
whiteSmoke: '#F8F8F8',
whisper: '#EEEEEE',
black: '#000000',
blue: '#2EAAE2',
border: '#ECECEC',
borderLight: '#E0E0E0',
green: '#2ECB70',
heading: '#37444C',
icon: '#C6C9CA',
text: '#4A5960',
textBackground: '#F0F0F0',
textReversed: '#FFFFFF',
textSupporting: '#7D8B8F',
transparent: 'transparent',
red: '#E84A3B',
buttonBG: '#8A8A8A',
modalBackdrop: '#00000080',
};
<<<<<<<
=======
h4: {
fontFamily: fontFamily.GTA_BOLD,
fontWeight: fontWeightBold,
fontSize: 13,
},
>>>>>>>
<<<<<<<
fontWeight: '700',
=======
fontWeight: fontWeightBold,
>>>>>>>
fontWeight: fontWeightBold,
<<<<<<<
minHeight: 64,
paddingTop: 12,
flex: 1,
flexGrow: 0,
=======
minHeight: 72,
paddingTop: 16,
paddingRight: 12,
paddingBottom: 16,
paddingLeft: 12,
>>>>>>>
flexGrow: 0,
},
sidebarHeaderActive: {
flexGrow: 1,
height: '100%', |
<<<<<<<
return [major, minor, patch, Number.isInteger(Number(build)) ? Number(build) : 0];
=======
return [major, minor, patch, build ? Number(build) : 0];
>>>>>>>
return [major, minor, patch, Number.isInteger(Number(build)) ? Number(build) : 0];
<<<<<<<
if (minor < MAX_INCREMENTS) {
return getVersionStringFromNumber(major, minor + 1, 0);
}
return getVersionStringFromNumber(major + 1, 0, 0);
=======
if (minor < MAX_INCREMENTS) {
return getVersionStringFromNumber(major, minor + 1, 0, 0);
}
return getVersionStringFromNumber(major + 1, 0, 0, 0);
>>>>>>>
if (minor < MAX_INCREMENTS) {
return getVersionStringFromNumber(major, minor + 1, 0, 0);
}
return getVersionStringFromNumber(major + 1, 0, 0, 0);
<<<<<<<
if (patch < MAX_INCREMENTS) {
return getVersionStringFromNumber(major, minor, patch + 1);
}
=======
if (patch < MAX_INCREMENTS) {
return getVersionStringFromNumber(major, minor, patch + 1, 0);
}
>>>>>>>
if (patch < MAX_INCREMENTS) {
return getVersionStringFromNumber(major, minor, patch + 1, 0);
}
<<<<<<<
// Majors will always be incremented
if (level === SEMANTIC_VERSION_LEVELS.MAJOR) {
return getVersionStringFromNumber(major + 1, 0, 0);
}
=======
// majors will always be incremented
if (level === SEMANTIC_VERSION_LEVELS.MAJOR) {
return getVersionStringFromNumber(major + 1, 0, 0, 0);
}
>>>>>>>
// Majors will always be incremented
if (level === SEMANTIC_VERSION_LEVELS.MAJOR) {
return getVersionStringFromNumber(major + 1, 0, 0, 0);
}
<<<<<<<
=======
if (build === undefined || build === 0) {
return getVersionStringFromNumber(major, minor, patch, 1);
}
>>>>>>> |
<<<<<<<
Dimensions.addEventListener('change', this.onChange);
StatusBar.setBackgroundColor(styles.appContentStatusBar.color, styles.appContentStatusBar.animated);
=======
Dimensions.addEventListener('change', this.toggleHamburgerBasedOnDimensions);
>>>>>>>
Dimensions.addEventListener('change', this.toggleHamburgerBasedOnDimensions);
StatusBar.setBackgroundColor(styles.appContentStatusBar.color, styles.appContentStatusBar.animated); |
<<<<<<<
return new Promise((resolve, reject) => {
Network.post(command, parameters, type)
.then((response) => {
// Handle expired auth tokens properly by making sure to pass the resolve and reject down to the
// new promise created when calling handleExpiredAuthToken.
if (response.jsonCode === 407) {
// There are some API requests that should not be retried when there is an auth failure like
// creating and deleting logins. In those cases, they should handle the original response instead
// of the new response created by handleExpiredAuthToken.
if (parameters.doNotRetry) {
resolve(response);
return;
}
handleExpiredAuthToken(command, parameters, type)
.then(resolve)
.catch(reject);
return;
}
resolve(response);
})
.catch(reject);
=======
const networkPromise = mockCommands[command]
? mockCommands[command]()
: Network.post(command, parameters, type);
// Setup the default handlers to work with different response codes
networkPromise.then((response) => {
// Handle expired auth tokens properly
if (response.jsonCode === 407) {
handleExpiredAuthToken(response, command, parameters, type);
// Throw an error to prevent other handlers from being triggered on this promise
throw new Error('A default handler was used for this request');
}
return response;
>>>>>>>
return new Promise((resolve, reject) => {
const networkPromise = mockCommands[command]
? mockCommands[command]()
: Network.post(command, parameters, type);
networkPromise
.then((response) => {
// Handle expired auth tokens properly by making sure to pass the resolve and reject down to the
// new promise created when calling handleExpiredAuthToken.
if (response.jsonCode === 407) {
// There are some API requests that should not be retried when there is an auth failure like
// creating and deleting logins. In those cases, they should handle the original response instead
// of the new response created by handleExpiredAuthToken.
if (parameters.doNotRetry) {
resolve(response);
return;
}
handleExpiredAuthToken(command, parameters, type)
.then(resolve)
.catch(reject);
return;
}
resolve(response);
})
.catch(reject); |
<<<<<<<
import styles, {getSafeAreaPadding} from '../../styles/StyleSheet';
import variables from '../../styles/variables';
=======
import styles, {getSafeAreaPadding} from '../../styles/styles';
>>>>>>>
import styles, {getSafeAreaPadding} from '../../styles/styles';
import variables from '../../styles/variables'; |
<<<<<<<
// Setup the default handlers to work with different response codes
return Network.post(command, parameters, type)
.then((response) => {
// Handle expired auth tokens properly
if (response.jsonCode === 407) {
handleExpiredAuthToken(response, command, parameters, type);
// Throw an error to prevent other handlers from being triggered on this promise
throw new Error('A default handler was used for this request');
}
return response;
});
=======
return new Promise((resolve, reject) => {
const networkPromise = mockCommands[command]
? mockCommands[command]()
: Network.post(command, parameters, type);
networkPromise
.then((response) => {
// Handle expired auth tokens properly by making sure to pass the resolve and reject down to the
// new promise created when calling handleExpiredAuthToken.
if (response.jsonCode === 407) {
// There are some API requests that should not be retried when there is an auth failure like
// creating and deleting logins. In those cases, they should handle the original response instead
// of the new response created by handleExpiredAuthToken.
if (parameters.doNotRetry) {
resolve(response);
return;
}
handleExpiredAuthToken(command, parameters, type)
.then(resolve)
.catch(reject);
return;
}
resolve(response);
})
.catch(reject);
});
>>>>>>>
return new Promise((resolve, reject) => {
Network.post(command, parameters, type)
.then((response) => {
// Handle expired auth tokens properly by making sure to pass the resolve and reject down to the
// new promise created when calling handleExpiredAuthToken.
if (response.jsonCode === 407) {
// There are some API requests that should not be retried when there is an auth failure like
// creating and deleting logins. In those cases, they should handle the original response instead
// of the new response created by handleExpiredAuthToken.
if (parameters.doNotRetry) {
resolve(response);
return;
}
handleExpiredAuthToken(command, parameters, type)
.then(resolve)
.catch(reject);
return;
}
resolve(response);
})
.catch(reject);
}); |
<<<<<<<
body: '**Release Version:** `1.0.1-48`\r\n**Compare Changes:** https://github.com/Expensify/Expensify.cash/compare/1.0.1-0...1.0.1-48\r\n\r\n**This release contains changes from the following pull requests:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/21\r\n- [x] https://github.com/Expensify/Expensify.cash/pull/22\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/23\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/24\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/25\r\n\r\n**Deploy Blockers:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/issues/1\r\n- [x] https://github.com/Expensify/Expensify.cash/issues/2\r\n- [ ] https://github.com/Expensify/Expensify.cash/issues/3\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/1234\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/4321\r\n',
=======
body: '**Release Version:** `1.0.1-48`\r\n**Compare Changes:** https://github.com/Expensify/Expensify.cash/compare/1.0.1-0...1.0.1-48\r\n**This release contains changes from the following pull requests:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/21\r\n- [x] https://github.com/Expensify/Expensify.cash/pull/22\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/23\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/24\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/25\r\n\r\n**Deploy Blockers:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/issues/1\r\n- [x] https://github.com/Expensify/Expensify.cash/issues/2\r\n- [ ] https://github.com/Expensify/Expensify.cash/issues/3\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/1234\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/4321\r\n\r\ncc @Expensify/applauseleads\r\n',
>>>>>>>
body: '**Release Version:** `1.0.1-48`\r\n**Compare Changes:** https://github.com/Expensify/Expensify.cash/compare/1.0.1-0...1.0.1-48\r\n\r\n**This release contains changes from the following pull requests:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/21\r\n- [x] https://github.com/Expensify/Expensify.cash/pull/22\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/23\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/24\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/25\r\n\r\n**Deploy Blockers:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/issues/1\r\n- [x] https://github.com/Expensify/Expensify.cash/issues/2\r\n- [ ] https://github.com/Expensify/Expensify.cash/issues/3\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/1234\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/4321\r\n\r\ncc @Expensify/applauseleads\r\n',
<<<<<<<
body: `**Release Version:** \`${tag}\`\r\n**Compare Changes:** https://github.com/Expensify/Expensify.cash/compare/1.0.2-0...1.0.2-12\r\n\r\n**This release contains changes from the following pull requests:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/1\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/2\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/3\r\n`,
=======
body: `**Release Version:** \`${tag}\`\r\n**Compare Changes:** https://github.com/Expensify/Expensify.cash/compare/1.0.2...1.0.2-12\r\n**This release contains changes from the following pull requests:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/1\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/2\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/3\r\n\r\ncc @Expensify/applauseleads\r\n`,
>>>>>>>
body: `**Release Version:** \`${tag}\`\r\n**Compare Changes:** https://github.com/Expensify/Expensify.cash/compare/1.0.2-0...1.0.2-12\r\n\r\n**This release contains changes from the following pull requests:**\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/1\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/2\r\n- [ ] https://github.com/Expensify/Expensify.cash/pull/3\r\n\r\ncc @Expensify/applauseleads\r\n`, |
<<<<<<<
* Only store the minimal amount of data in Ion that needs to be stored
* because space is limited
*
* @param {object} report
* @param {number} report.reportID
* @param {string} report.reportName
* @param {object} report.reportNameValuePairs
* @param {string} accountID
* @returns {object}
*/
function getSimplifiedReportObject(report, accountID) {
return {
reportID: report.reportID,
reportName: report.reportName,
reportNameValuePairs: report.reportNameValuePairs,
hasUnread: hasUnreadHistoryItems(accountID, report),
};
}
/**
* Initialize our pusher subscriptions to listen for new report comments
=======
* Listen for new report comments via Pusher
>>>>>>>
* Only store the minimal amount of data in Ion that needs to be stored
* because space is limited
*
* @param {object} report
* @param {number} report.reportID
* @param {string} report.reportName
* @param {object} report.reportNameValuePairs
* @param {string} accountID
* @returns {object}
*/
function getSimplifiedReportObject(report, accountID) {
return {
reportID: report.reportID,
reportName: report.reportName,
reportNameValuePairs: report.reportNameValuePairs,
hasUnread: hasUnreadHistoryItems(accountID, report),
};
}
/**
* Initialize our pusher subscriptions to listen for new report comments
<<<<<<<
fetchChatReport,
=======
fetchChatReports,
>>>>>>>
fetchChatReport,
fetchChatReports, |
<<<<<<<
* @param {string} [mapping.path] a specific path of the store object to map to the state
* @param {mixed} [mapping.defaultValue] Used in conjunction with mapping.path to return if the there is
* nothing at mapping.path
* @param {boolean} [mapping.addAsCollection] rather than setting a single state value, this will add things
* to an array
* @param {string} [mapping.collectionID] the name of the ID property to use for the collection
* @param {mixed[]} [mapping.loaderParams] An array of params to be passed to the loader method
=======
* @param {string} statePropertyName the name of the state property that Ion will add the data to
* @param {string} [mapping.indexBy] the name of the ID property to use for the collection
* @param {string} [mapping.pathForProps] the statePropertyName can contain the string %DATAFROMPROPS% wich
* will be replaced with data from the props matching this path. That way, the component can connect to an
* Ion key that uses data from this.props.
*
* For example, if a component wants to connect to the Ion key "report_22" and
* "22" comes from this.props.match.params.reportID. The statePropertyName would be set to
* "report_%DATAFROMPROPS%" and pathForProps would be set to "match.params.reportID"
>>>>>>>
* @param {string} statePropertyName the name of the state property that Ion will add the data to
* @param {string} [mapping.indexBy] the name of the ID property to use for the collection
<<<<<<<
// Pre-fill the state with any data already in the store
if (mapping.initWithStoredValues !== false) {
Ion.getInitialStateFromConnectionID(connectionID)
.then(data => this.setState({[statePropertyName]: data}));
}
=======
>>>>>>> |
<<<<<<<
import Notification from '../Notification';
=======
import * as PersonalDetails from './PersonalDetails';
>>>>>>>
import Notification from '../Notification';
import * as PersonalDetails from './PersonalDetails'; |
<<<<<<<
import ROUTES from '../ROUTES';
import {registerSocketEventCallback} from './Pusher/pusher';
=======
import redirectToSignIn from './actions/ActionsSignInRedirect';
>>>>>>>
import ROUTES from '../ROUTES';
import {registerSocketEventCallback} from './Pusher/pusher';
import redirectToSignIn from './actions/ActionsSignInRedirect'; |
<<<<<<<
import Timing from '../../../libs/actions/Timing';
import CONST from '../../../CONST';
=======
import CONST from '../../../CONST';
import themeColors from '../../../styles/themes/default';
>>>>>>>
import Timing from '../../../libs/actions/Timing';
import CONST from '../../../CONST';
import themeColors from '../../../styles/themes/default';
<<<<<<<
shouldComponentUpdate(nextProps) {
if (nextProps.reportID !== this.props.reportID) {
=======
shouldComponentUpdate(nextProps, nextState) {
if (nextProps.isActiveReport !== this.props.isActiveReport) {
>>>>>>>
shouldComponentUpdate(nextProps, nextState) {
if (nextProps.reportID !== this.props.reportID) {
<<<<<<<
// The last sequenceNumber of the same report has changed.
const previousLastSequenceNumber = lodashGet(lastItem(prevProps.reportActions), 'sequenceNumber');
const currentLastSequenceNumber = lodashGet(lastItem(this.props.reportActions), 'sequenceNumber');
if (previousLastSequenceNumber !== currentLastSequenceNumber) {
=======
const previousLastItem = lastItem(prevProps.reportActions) || {};
const newLastItem = lastItem(this.props.reportActions) || {};
if (previousLastItem.sequenceNumber !== newLastItem.sequenceNumber) {
>>>>>>>
// The last sequenceNumber of the same report has changed.
const previousLastSequenceNumber = lodashGet(lastItem(prevProps.reportActions), 'sequenceNumber');
const currentLastSequenceNumber = lodashGet(lastItem(this.props.reportActions), 'sequenceNumber');
if (previousLastSequenceNumber !== currentLastSequenceNumber) {
<<<<<<<
* Actions to run when the report has been updated
* @param {Number} oldReportID
*/
reset(oldReportID) {
// Unsubscribe from previous report and resubscribe
unsubscribeFromReportChannel(oldReportID);
subscribeToReportTypingEvents(this.props.reportID);
Timing.end(CONST.TIMING.SWITCH_REPORT, CONST.TIMING.COLD);
// Fetch the new set of actions
fetchActions(this.props.reportID);
}
/**
=======
* Retrieves the next set of report actions for the chat once we are nearing the end of what we are currently
* displaying.
*/
loadMoreChats() {
const minSequenceNumber = _.chain(this.props.reportActions)
.pluck('sequenceNumber')
.min()
.value();
if (minSequenceNumber === 0) {
return;
}
this.setState({isLoadingMoreChats: true}, () => {
// Retrieve the next REPORT_ACTIONS_LIMIT sized page of comments, unless we're near the beginning, in which
// case just get everything starting from 0.
const offset = Math.max(minSequenceNumber - CONST.REPORT.REPORT_ACTIONS_LIMIT, 0);
fetchActions(this.props.reportID, offset)
.then(() => this.setState({isLoadingMoreChats: false}));
});
}
/**
>>>>>>>
* Actions to run when the report has been updated
* @param {Number} oldReportID
*/
reset(oldReportID) {
// Unsubscribe from previous report and resubscribe
unsubscribeFromReportChannel(oldReportID);
subscribeToReportTypingEvents(this.props.reportID);
Timing.end(CONST.TIMING.SWITCH_REPORT, CONST.TIMING.COLD);
// Fetch the new set of actions
fetchActions(this.props.reportID);
}
/**
* Retrieves the next set of report actions for the chat once we are nearing the end of what we are currently
* displaying.
*/
loadMoreChats() {
const minSequenceNumber = _.chain(this.props.reportActions)
.pluck('sequenceNumber')
.min()
.value();
if (minSequenceNumber === 0) {
return;
}
this.setState({isLoadingMoreChats: true}, () => {
// Retrieve the next REPORT_ACTIONS_LIMIT sized page of comments, unless we're near the beginning, in which
// case just get everything starting from 0.
const offset = Math.max(minSequenceNumber - CONST.REPORT.REPORT_ACTIONS_LIMIT, 0);
fetchActions(this.props.reportID, offset)
.then(() => this.setState({isLoadingMoreChats: false}));
});
}
/** |
<<<<<<<
import Activity from './Activity';
import PushNotification from './Notification/PushNotification';
// Holds all of the callbacks that need to be triggered when the network reconnects
const reconnectionCallbacks = [];
=======
>>>>>>>
import PushNotification from './Notification/PushNotification'; |
<<<<<<<
icons: report ? report.icons : [personalDetail.avatarURL],
tooltipText,
=======
icons: report ? report.icons : [personalDetail.avatar],
>>>>>>>
icons: report ? report.icons : [personalDetail.avatar],
tooltipText, |
<<<<<<<
import TrashIcon from './TrashIcon';
=======
import PlusIcon from './PlusIcon';
>>>>>>>
import PlusIcon from './PlusIcon';
import TrashIcon from './TrashIcon';
<<<<<<<
TrashIcon,
=======
PlusIcon,
>>>>>>>
PlusIcon,
TrashIcon, |
<<<<<<<
EXPENSIFY: {
PARTNER_NAME: IS_IN_PRODUCTION ? 'chat-expensify-com' : 'android',
PARTNER_PASSWORD: IS_IN_PRODUCTION ? 'e21965746fd75f82bb66' : 'c3a9ac418ea3f152aae2',
API_ROOT: IS_IN_PRODUCTION ? 'https://www.expensify.com/api?' : 'https://www.expensify.com.dev/api?',
},
REPORT_IDS: IS_IN_PRODUCTION ? '63212778,63212795,63212764,63212607,63699490' : devConfig.REPORT_IDS,
=======
SITE_TITLE: 'Chat',
>>>>>>>
REPORT_IDS: IS_IN_PRODUCTION ? '63212778,63212795,63212764,63212607,63699490' : devConfig.REPORT_IDS,
SITE_TITLE: 'Chat', |
<<<<<<<
this.toggleNavigationMenu = this.toggleNavigationMenu.bind(this);
this.dismissNavigationMenu = this.dismissNavigationMenu.bind(this);
this.showNavigationMenu = this.showNavigationMenu.bind(this);
this.toggleNavigationMenuBasedOnDimensions = this.toggleNavigationMenuBasedOnDimensions.bind(this);
this.recordTimerAndToggleNavigationMenu = this.recordTimerAndToggleNavigationMenu.bind(this);
const windowBarSize = isSmallScreenWidth
? -this.state.windowWidth
: -variables.sideBarWidth;
=======
this.toggleHamburger = this.toggleHamburger.bind(this);
this.dismissHamburger = this.dismissHamburger.bind(this);
this.showHamburger = this.showHamburger.bind(this);
this.toggleHamburgerBasedOnDimensions = this.toggleHamburgerBasedOnDimensions.bind(this);
this.recordTimerAndToggleHamburger = this.recordTimerAndToggleHamburger.bind(this);
this.navigateToSettings = this.navigateToSettings.bind(this);
>>>>>>>
this.toggleNavigationMenu = this.toggleNavigationMenu.bind(this);
this.dismissNavigationMenu = this.dismissNavigationMenu.bind(this);
this.showNavigationMenu = this.showNavigationMenu.bind(this);
this.toggleNavigationMenuBasedOnDimensions = this.toggleNavigationMenuBasedOnDimensions.bind(this);
this.recordTimerAndToggleNavigationMenu = this.recordTimerAndToggleNavigationMenu.bind(this);
this.navigateToSettings = this.navigateToSettings.bind(this);
const windowBarSize = isSmallScreenWidth
? -this.state.windowWidth
: -variables.sideBarWidth;
<<<<<<<
onLinkClick={this.recordTimerAndToggleNavigationMenu}
=======
onLinkClick={this.recordTimerAndToggleHamburger}
onAvatarClick={this.navigateToSettings}
>>>>>>>
onLinkClick={this.recordTimerAndToggleNavigationMenu}
onAvatarClick={this.navigateToSettings}
<<<<<<<
<HeaderView
shouldShowNavigationMenuButton={this.state.isSmallScreenWidth}
onNavigationMenuButtonClicked={this.toggleNavigationMenu}
/>
<Main />
</View>
=======
<View
style={[styles.appContent, styles.flex1, styles.flexColumn]}
>
<HeaderView
shouldShowHamburgerButton={this.state.isHamburgerEnabled}
onHamburgerButtonClicked={this.toggleHamburger}
/>
{this.props.currentURL === '/settings' && <SettingsPage />}
<Main />
</View>
</Pressable>
>>>>>>>
<HeaderView
shouldShowHamburgerButton={this.state.isHamburgerEnabled}
onHamburgerButtonClicked={this.toggleHamburger}
/>
{this.props.currentURL === '/settings' && <SettingsPage />}
<Main />
</View> |
<<<<<<<
iconSizeNormal: 20,
=======
iconSizeExtraSmall: 12,
iconSizeSmall: 16,
iconSizeNormal: 20,
iconSizeLarge: 24,
>>>>>>>
iconSizeSmall: 12,
iconSizeNormal: 20, |
<<<<<<<
// Callback method to handle pasting a file
onPasteFile: PropTypes.func,
=======
// A ref to forward to the text input
forwardedRef: PropTypes.func.isRequired,
// General styles to apply to the text input
// eslint-disable-next-line react/forbid-prop-types
style: PropTypes.any,
// If the input should clear, it actually gets intercepted instead of .clear()
shouldClear: PropTypes.bool,
// When the input has cleared whoever owns this input should know about it
onClear: PropTypes.func,
>>>>>>>
// Callback method to handle pasting a file
onPasteFile: PropTypes.func,
// A ref to forward to the text input
forwardedRef: PropTypes.func.isRequired,
// General styles to apply to the text input
// eslint-disable-next-line react/forbid-prop-types
style: PropTypes.any,
// If the input should clear, it actually gets intercepted instead of .clear()
shouldClear: PropTypes.bool,
// When the input has cleared whoever owns this input should know about it
onClear: PropTypes.func,
<<<<<<<
onPasteFile: () => {},
=======
shouldClear: false,
onClear: () => {},
style: null,
>>>>>>>
onPasteFile: () => {},
shouldClear: false,
onClear: () => {},
style: null, |
<<<<<<<
// When the URL is at the root of the site, go to sign-in, otherwise add the exitTo
const urlWithExitTo = currentURL === '/'
? ROUTES.SIGNIN
: `${ROUTES.SIGNIN}/exitTo${currentURL}`;
Ion.merge(IONKEYS.APP_REDIRECT_TO, urlWithExitTo);
=======
// When the URL is at the root of the site, go to sign-in, otherwise add the exitTo
const urlWithExitTo = url === '/'
? ROUTES.SIGNIN
: `${ROUTES.SIGNIN}/exitTo${url}`;
return redirect(urlWithExitTo);
});
>>>>>>>
// When the URL is at the root of the site, go to sign-in, otherwise add the exitTo
const urlWithExitTo = currentURL === '/'
? ROUTES.SIGNIN
: `${ROUTES.SIGNIN}/exitTo${currentURL}`;
redirect(urlWithExitTo); |
<<<<<<<
var wid_id = $('#' + that.activeWidgets[0]).attr('id');
that.inspectWidgets();
var $target = $('#' + wid_id);
var $clone = $target.clone();
$clone.wrap('<div>');
var html = $clone.parent().html();
html = html
.replace(/(vis-widget )/g, 'vis-widget_prev ')
.replace('vis-widget-body', 'vis-widget-prev-body')
.replace('ui-draggable', ' ')
.replace('ui-resizable', ' ')
.replace('<div class="editmode-helper"></div>', ' ')
.replace(/(id=")[A-Za-z0-9\[\]._]+"/g, ' ')
.replace(/(?:\r\n|\r|\n)/g, ' ')
.replace(/(<div class="ui-resizable-handle).+(<\/div>)/g, ' ')
.replace(/\t/g, ' ')
.replace(/[ ]{2,}/g, ' ');
html = 'data-vis-prev=\'<div id="prev_' + that.views[that.activeView].widgets[wid_id].tpl + '" style=" position: relative; text-align: initial;padding: 4px ">' + html.toString() + '\'';
$('body').append('<div id="dec_html_code"><textarea style="width: 100%; height: 100%">' + html + '</textarea></div>')
=======
var text = '';
for (var i = 0; i < that.activeWidgets.length; i++) {
var widID = $('#' + that.activeWidgets[i]).attr('id');
var $target = $('#' + widID);
var $clone = $target.clone();
$clone.wrap('<div>');
var html = $clone.parent().html();
html = html
.replace('vis-widget ', 'vis-widget_prev ')
.replace('vis-widget-body', 'vis-widget-prev-body')
.replace('ui-draggable', ' ')
.replace('ui-resizable', ' ')
.replace('<div class="editmode-helper"></div>', '')
.replace(/(id=")[A-Za-z0-9\[\]._]+"/g, '')
.replace(/(?:\r\n|\r|\n)/g, '')
.replace(/[ ]{2,}/g, ' ');
html = html
.replace('<div class="ui-resizable-handle ui-resizable-e" style="z-index: 90;"></div>', '')
.replace('<div class="ui-resizable-handle ui-resizable-s" style="z-index: 90;"></div>', '')
.replace('<div class="ui-resizable-handle ui-resizable-se ui-icon ui-icon-gripsmall-diagonal-se" style="z-index: 90;"></div>', '')
.replace('<div></div>', '')
html = '<div id="prev_' + that.views[that.activeView].widgets[widID].tpl + '" style="position: relative; text-align: initial;padding: 4px ">' + html.toString() + '</div>';
text += html;
}
$('body').append('<div id="dec_html_code"><textarea style="width: 100%; height: 100%">data-vis-prev=\'' + text + '\'</textarea></div>');
>>>>>>>
var text = '';
for (var i = 0; i < that.activeWidgets.length; i++) {
var widID = $('#' + that.activeWidgets[i]).attr('id');
var $target = $('#' + widID);
var $clone = $target.clone();
$clone.wrap('<div>');
var html = $clone.parent().html();
html = html
.replace('vis-widget ', 'vis-widget_prev ')
.replace('vis-widget-body', 'vis-widget-prev-body')
.replace('ui-draggable', ' ')
.replace('ui-resizable', ' ')
.replace('<div class="editmode-helper"></div>', '')
.replace(/(id=")[A-Za-z0-9\[\]._]+"/g, '')
.replace(/(?:\r\n|\r|\n)/g, '')
.replace(/\t/g, ' ')
.replace(/[ ]{2,}/g, ' ');
html = html
.replace('<div class="ui-resizable-handle ui-resizable-e" style="z-index: 90;"></div>', '')
.replace('<div class="ui-resizable-handle ui-resizable-s" style="z-index: 90;"></div>', '')
.replace('<div class="ui-resizable-handle ui-resizable-se ui-icon ui-icon-gripsmall-diagonal-se" style="z-index: 90;"></div>', '')
.replace('<div></div>', '')
html = '<div id="prev_' + that.views[that.activeView].widgets[widID].tpl + '" style="position: relative; text-align: initial;padding: 4px ">' + html.toString() + '</div>';
text += html;
}
$('body').append('<div id="dec_html_code"><textarea style="width: 100%; height: 100%">data-vis-prev=\'' + text + '\'</textarea></div>'); |
<<<<<<<
import UnreadIndicatorUpdater from '../../lib/UnreadIndicatorUpdater';
=======
import ROUTES from '../../ROUTES';
import NetworkConnection from '../../lib/NetworkConnection';
>>>>>>>
import UnreadIndicatorUpdater from '../../lib/UnreadIndicatorUpdater';
import ROUTES from '../../ROUTES';
import NetworkConnection from '../../lib/NetworkConnection'; |
<<<<<<<
margin: 0,
alignItems: 'center',
justifyContent: 'flex-end',
marginRight: windowDimensions.width - variables.sideBarWidth,
marginBottom: 100,
=======
...modalStyle,
...{
alignItems: 'center',
justifyContent: 'flex-end',
marginRight: windowDimensions.width - variables.sideBarWidth,
marginBottom: 82,
},
>>>>>>>
...modalStyle,
...{
alignItems: 'center',
justifyContent: 'flex-end',
marginRight: windowDimensions.width - variables.sideBarWidth,
marginBottom: 100,
}, |
<<<<<<<
* Returns a generated report title based on the participants
*
* @param {array} sharedReportList
* @return {string}
*/
function getChatReportName(sharedReportList) {
return _.chain(sharedReportList)
.map(participant => participant.email)
.filter(participant => participant !== currentUserEmail)
.map(participant => lodashGet(personalDetails, [participant, 'firstName']) || participant)
.value()
.join(', ');
}
/**
=======
>>>>>>>
<<<<<<<
* @param {object} report.sharedReportList
=======
* @param {string} accountID
>>>>>>>
* @param {string} accountID
<<<<<<<
function getSimplifiedReportObject(report) {
=======
function getSimplifiedReportObject(report, accountID) {
>>>>>>>
function getSimplifiedReportObject(report, accountID) {
<<<<<<<
reportName: !_.isEmpty(personalDetails) && lodashGet(report, 'reportNameValuePairs.type') === 'chat'
? getChatReportName(report.sharedReportList)
: report.reportName,
=======
reportName: report.reportName,
>>>>>>>
reportName: report.reportName,
<<<<<<<
const pusherChannelName = `private-user-accountID-${currentUserAccountID}`;
Pusher.subscribe(pusherChannelName, 'reportComment', (pushJSON) => {
updateReportWithNewAction(pushJSON.reportID, pushJSON.reportAction);
});
=======
return Ion.get(IONKEYS.SESSION, 'accountID')
.then((accountID) => {
const pusherChannelName = `private-user-accountID-${accountID}`;
if (Pusher.isSubscribed(pusherChannelName) || Pusher.isAlreadySubscribing(pusherChannelName)) {
return;
}
Pusher.subscribe(pusherChannelName, 'reportComment', (pushJSON) => {
updateReportWithNewAction(pushJSON.reportID, pushJSON.reportAction);
});
});
>>>>>>>
return Ion.get(IONKEYS.SESSION, 'accountID')
.then((accountID) => {
const pusherChannelName = `private-user-accountID-${accountID}`;
if (Pusher.isSubscribed(pusherChannelName) || Pusher.isAlreadySubscribing(pusherChannelName)) {
return;
}
Pusher.subscribe(pusherChannelName, 'reportComment', (pushJSON) => {
updateReportWithNewAction(pushJSON.reportID, pushJSON.reportAction);
});
});
<<<<<<<
const newReport = getSimplifiedReportObject(report);
=======
const newReport = getSimplifiedReportObject(report, currentUserAccountID);
newReport.reportName = getChatReportName(report.sharedReportList, personalDetails, currentUserEmail);
>>>>>>>
const newReport = getSimplifiedReportObject(report, currentUserAccountID);
newReport.reportName = getChatReportName(report.sharedReportList, personalDetails, currentUserEmail);
<<<<<<<
* Looks for a report in Ion and if it doesn't exist, the report will be fetched from the API and placed in Ion
*
* @param {string} reportID
*/
function fetchReportByIDIfNotExists(reportID) {
const report = currentReports[`${IONKEYS.REPORT}_${reportID}`];
if (lodashGet(report, 'reportName', false)) {
return;
}
// We don't have this report so let's fetch it
queueRequest('Get', {
returnValueList: 'reportStuff',
reportIDList: reportID,
shouldLoadOptionalKeys: true,
})
.then(({reports}) => {
if (reports === undefined) {
return;
}
// Store only the absolute bare minimum of data in Ion because space is limited
const newReport = getSimplifiedReportObject(reports[reportID]);
Ion.merge(`${IONKEYS.REPORT}_${reportID}`, newReport);
});
}
/**
=======
>>>>>>> |
<<<<<<<
import {
View,
Keyboard,
AppState,
ActivityIndicator,
} from 'react-native';
=======
import {
Animated,
View,
Keyboard,
AppState,
} from 'react-native';
>>>>>>>
import {
Animated,
View,
Keyboard,
AppState,
ActivityIndicator,
} from 'react-native';
<<<<<<<
this.loadMoreChats = this.loadMoreChats.bind(this);
this.sortedReportActions = this.updateSortedReportActions();
=======
this.sortedReportActions = [];
>>>>>>>
this.loadMoreChats = this.loadMoreChats.bind(this);
this.sortedReportActions = [];
<<<<<<<
* Retrieves the next set of report actions for the chat once we are nearing the end of what we are currently
* displaying.
*/
loadMoreChats() {
const minSequenceNumber = _.chain(this.props.reportActions)
.pluck('sequenceNumber')
.min()
.value();
if (minSequenceNumber === 0) {
return;
}
this.setState({isLoadingMoreChats: true}, () => {
// Retrieve the next REPORT_ACTIONS_LIMIT sized page of comments, unless we're near the beginning, in which
// case just get everything starting from 0.
const offset = Math.max(minSequenceNumber - CONST.REPORT.REPORT_ACTIONS_LIMIT, 0);
fetchActions(this.props.reportID, offset)
.then(() => this.setState({isLoadingMoreChats: false}));
});
}
/**
=======
* Checks if the unreadActionIndicator should be shown.
* If it does, starts a timeout for the fading out animation and creates
* a flag to not show it again if the report is still open
*/
setUpUnreadActionIndicator() {
if (!this.props.isActiveReport || !this.shouldShowUnreadActionIndicator) {
return;
}
this.unreadActionCount = this.props.report.unreadActionCount;
if (this.unreadActionCount > 0) {
this.unreadIndicatorOpacity = new Animated.Value(1);
this.timers.push(setTimeout(() => {
Animated.timing(this.unreadIndicatorOpacity, {
toValue: 0,
useNativeDriver: false,
}).start();
}, 3000));
}
this.shouldShowUnreadActionIndicator = false;
}
/**
>>>>>>>
* Checks if the unreadActionIndicator should be shown.
* If it does, starts a timeout for the fading out animation and creates
* a flag to not show it again if the report is still open
*/
setUpUnreadActionIndicator() {
if (!this.props.isActiveReport || !this.shouldShowUnreadActionIndicator) {
return;
}
this.unreadActionCount = this.props.report.unreadActionCount;
if (this.unreadActionCount > 0) {
this.unreadIndicatorOpacity = new Animated.Value(1);
this.timers.push(setTimeout(() => {
Animated.timing(this.unreadIndicatorOpacity, {
toValue: 0,
useNativeDriver: false,
}).start();
}, 3000));
}
this.shouldShowUnreadActionIndicator = false;
}
/**
* Retrieves the next set of report actions for the chat once we are nearing the end of what we are currently
* displaying.
*/
loadMoreChats() {
const minSequenceNumber = _.chain(this.props.reportActions)
.pluck('sequenceNumber')
.min()
.value();
if (minSequenceNumber === 0) {
return;
}
this.setState({isLoadingMoreChats: true}, () => {
// Retrieve the next REPORT_ACTIONS_LIMIT sized page of comments, unless we're near the beginning, in which
// case just get everything starting from 0.
const offset = Math.max(minSequenceNumber - CONST.REPORT.REPORT_ACTIONS_LIMIT, 0);
fetchActions(this.props.reportID, offset)
.then(() => this.setState({isLoadingMoreChats: false}));
});
}
/** |
<<<<<<<
import Account from '../libs/actions/Account';
import Icon from '../components/Icon';
import {DownArrow} from '../components/Icon/Expensicons';
import CONST from '../CONST';
=======
import HeaderGap from '../components/HeaderGap';
>>>>>>>
import Account from '../libs/actions/Account';
import Icon from '../components/Icon';
import {DownArrow} from '../components/Icon/Expensicons';
import CONST from '../CONST';
import HeaderGap from '../components/HeaderGap'; |
<<<<<<<
// Handle the drag events
if (this.textInput) {
this.textInput.addEventListener('dragenter', this.handleDragEnter.bind(this));
this.textInput.addEventListener('dragleave', this.handleDragLeave.bind(this));
this.textInput.addEventListener('drop', this.handleDrop.bind(this));
}
=======
// There is no onPaste for TextInput in react-native so we will add event
// listener here and unbind when the component unmounts
if (this.textInput) {
this.textInput.addEventListener('paste', this.checkForAttachment.bind(this));
}
>>>>>>>
// Handle the drag events
if (this.textInput) {
this.textInput.addEventListener('dragenter', this.handleDragEnter.bind(this));
this.textInput.addEventListener('dragleave', this.handleDragLeave.bind(this));
this.textInput.addEventListener('drop', this.handleDrop.bind(this));
}
// There is no onPaste for TextInput in react-native so we will add event
// listener here and unbind when the component unmounts
if (this.textInput) {
this.textInput.addEventListener('paste', this.checkForAttachment.bind(this));
}
<<<<<<<
componentWillUnmount() {
if (this.textInput) {
this.textInput.removeEventListener('dragenter', this.handleDragEnter.bind(this));
this.textInput.removeEventListener('dragleave', this.handleDragLeave.bind(this));
this.textInput.removeEventListener('drop', this.handleDrop.bind(this));
}
}
=======
componentWillUnmount() {
if (this.textInput) {
this.textInput.removeEventListener('paste', this.checkForAttachment.bind(this));
}
}
>>>>>>>
componentWillUnmount() {
if (this.textInput) {
this.textInput.removeEventListener('dragenter', this.handleDragEnter.bind(this));
this.textInput.removeEventListener('dragleave', this.handleDragLeave.bind(this));
this.textInput.removeEventListener('drop', this.handleDrop.bind(this));
this.textInput.removeEventListener('paste', this.checkForAttachment.bind(this));
}
} |
<<<<<<<
import addStorageEventHandler from './addStorageEventHandler';
=======
import Str from './Str';
import IONKEYS from '../IONKEYS';
>>>>>>>
import addStorageEventHandler from './addStorageEventHandler';
import Str from './Str';
import IONKEYS from '../IONKEYS';
<<<<<<<
* When a key change happens, search for any callbacks matching the regex pattern and trigger those callbacks
=======
* Get some data from the store
*
* @param {string} key
* @returns {*}
*/
function get(key) {
return AsyncStorage.getItem(key)
.then(val => JSON.parse(val))
.catch(err => console.error(`Unable to get item from persistent storage. Key: ${key} Error: ${err}`));
}
/**
* Checks to see if the a subscriber's supplied key
* is associated with a collection of keys.
*
* @param {String} key
* @returns {Boolean}
*/
function isCollectionKey(key) {
return _.contains(_.values(IONKEYS.COLLECTION), key);
}
/**
* Checks to see if a given key matches with the
* configured key of our connected subscriber
*
* @param {String} configKey
* @param {String} key
* @return {Boolean}
*/
function isKeyMatch(configKey, key) {
return isCollectionKey(configKey)
? Str.startsWith(key, configKey)
: configKey === key;
}
/**
* When a key change happens, search for any callbacks matching the key or collection key and trigger those callbacks
>>>>>>>
* When a key change happens, search for any callbacks matching the regex pattern and trigger those callbacks
* Get some data from the store
*
* @param {string} key
* @returns {*}
*/
function get(key) {
return AsyncStorage.getItem(key)
.then(val => JSON.parse(val))
.catch(err => console.error(`Unable to get item from persistent storage. Key: ${key} Error: ${err}`));
}
/**
* Checks to see if the a subscriber's supplied key
* is associated with a collection of keys.
*
* @param {String} key
* @returns {Boolean}
*/
function isCollectionKey(key) {
return _.contains(_.values(IONKEYS.COLLECTION), key);
}
/**
* Checks to see if a given key matches with the
* configured key of our connected subscriber
*
* @param {String} configKey
* @param {String} key
* @return {Boolean}
*/
function isKeyMatch(configKey, key) {
return isCollectionKey(configKey)
? Str.startsWith(key, configKey)
: configKey === key;
}
/**
* When a key change happens, search for any callbacks matching the key or collection key and trigger those callbacks
<<<<<<<
if (matchingKeys.length > 1 && config.withIonInstance && !config.indexBy) {
// eslint-disable-next-line no-console
console.warn(`It looks like a React component subscribed to multiple Ion keys without
providing an 'indexBy' option. This will result in undefined behavior. The best thing to do is
provide an 'indexBy' value, or use a more specific regex that will only match a single Ion key.`);
}
if (config.indexBy) {
=======
// When using a callback subscriber we will trigger the callback
// for each key we find. It's up to the subscriber to know whether
// to expect a single key or multiple keys in the case of a collection.
// React components are an exception since we'll want to send their
// initial data as a single object when using collection keys.
if (mapping.withIonInstance && isCollectionKey(mapping.key)) {
>>>>>>>
// When using a callback subscriber we will trigger the callback
// for each key we find. It's up to the subscriber to know whether
// to expect a single key or multiple keys in the case of a collection.
// React components are an exception since we'll want to send their
// initial data as a single object when using collection keys.
if (mapping.withIonInstance && isCollectionKey(mapping.key)) { |
<<<<<<<
<View>
{this.props.session && !_.isEmpty(this.props.session.error) && (
<Text style={[styles.formError]}>
{this.props.session.error}
</Text>
)}
</View>
</SignInPageLayout>
=======
{/* Because of the custom layout of the login form, session errors are displayed differently */}
{!showLoginForm && (
<View>
{this.props.session && !_.isEmpty(this.props.session.error) && (
<Text style={[styles.formError]}>
{this.props.session.error}
</Text>
)}
</View>
)}
</View>
>>>>>>>
{/* Because of the custom layout of the login form, session errors are displayed differently */}
{!showLoginForm && (
<View>
{this.props.session && !_.isEmpty(this.props.session.error) && (
<Text style={[styles.formError]}>
{this.props.session.error}
</Text>
)}
</View>
)}
</SignInPageLayout> |
<<<<<<<
if (!props.reportName) {
return null;
}
const paramsReportID = parseInt(props.match.params.reportID, 10);
const isReportActive = paramsReportID === props.reportID;
=======
const reportIDInUrl = parseInt(props.match.params.reportID, 10);
const isReportActive = reportIDInUrl === props.reportID;
>>>>>>>
if (!props.reportName) {
return null;
}
const reportIDInUrl = parseInt(props.match.params.reportID, 10);
const isReportActive = reportIDInUrl === props.reportID; |
<<<<<<<
// What the active route is for our navigator. Global route that determines what views to display.
=======
// When this key is changed, the active page changes (see Expensify.js and `redirect` in actions/App.js)
APP_REDIRECT_TO: 'appRedirectTo',
NETWORK_REQUEST_QUEUE: 'networkRequestQueue',
// The current URL, you should not change this directly (use `redirect` in App.js)
>>>>>>>
NETWORK_REQUEST_QUEUE: 'networkRequestQueue',
// What the active route is for our navigator. Global route that determines what views to display. |
<<<<<<<
import ROUTES from '../../ROUTES';
=======
import NetworkConnection from '../../lib/NetworkConnection';
>>>>>>>
import ROUTES from '../../ROUTES';
import NetworkConnection from '../../lib/NetworkConnection'; |
<<<<<<<
showTitleTooltip
=======
disableFocusOptions={this.props.isSmallScreenWidth}
>>>>>>>
showTitleTooltip
disableFocusOptions={this.props.isSmallScreenWidth} |
<<<<<<<
import CONST from '../../../CONST';
import MultipleAvatars from '../../../components/MultipleAvatars';
=======
import Avatar from '../../../components/Avatar';
>>>>>>>
import MultipleAvatars from '../../../components/MultipleAvatars'; |
<<<<<<<
import {redirect} from './App';
=======
import Timing from './Timing';
>>>>>>>
import {redirect} from './App';
import Timing from './Timing'; |
<<<<<<<
ipcMain.on(ELECTRON_EVENTS.REQUEST_VISIBILITY, (event) => {
=======
// Flag to determine is user is trying to quit the whole application altogether
let quitting = false;
// Closing the chat window should just hide it (vs. fully quitting the application)
browserWindow.on('close', (evt) => {
if (!quitting) {
evt.preventDefault();
browserWindow.minimize();
}
});
app.on('before-quit', () => quitting = true);
app.on('activate', () => browserWindow.show());
ipcMain.on('request-visibility', (event) => {
>>>>>>>
// Flag to determine is user is trying to quit the whole application altogether
let quitting = false;
// Closing the chat window should just hide it (vs. fully quitting the application)
browserWindow.on('close', (evt) => {
if (!quitting) {
evt.preventDefault();
browserWindow.minimize();
}
});
app.on('before-quit', () => quitting = true);
app.on('activate', () => browserWindow.show());
ipcMain.on(ELECTRON_EVENTS.REQUEST_VISIBILITY, (event) => { |
<<<<<<<
* @param {object} [mapping.reactComponent] whose setState() method will be called with any changed data
* @param {object} [mapping.callback] An alternative to using mapping.reactComponent so that a method can be bound to
* Ion without having to be a react component
=======
* @param {object} mapping.withIonInstance whose setState() method will be called with any changed data
>>>>>>>
* @param {object} [mapping.callback] An alternative to using mapping.reactComponent so that a method can be bound to
* Ion without having to be a react component
* @param {object} mapping.withIonInstance whose setState() method will be called with any changed data
<<<<<<<
// If there is a callback attached to the mapping, then trigger the callback and pass it the new value
if (mappedComponent.callback) {
mappedComponent.callback(newValue);
}
// If there is a react component attached to the mapping, then set the state of the react component
// with either the pathed data, or the data
if (mappedComponent.reactComponent) {
if (mappedComponent.addAsCollection) {
// Add the data to an array of existing items
mappedComponent.reactComponent.setState((prevState) => {
const collection = prevState[mappedComponent.statePropertyName] || {};
collection[newValue[mappedComponent.collectionID]] = newValue;
const newState = {
[mappedComponent.statePropertyName]: collection,
};
return newState;
});
} else {
mappedComponent.reactComponent.setState({
[mappedComponent.statePropertyName]: newValue,
});
}
=======
// Set the state of the react component with either the pathed data, or the data
if (mappedComponent.addAsCollection) {
// Add the data to an array of existing items
mappedComponent.withIonInstance.setState((prevState) => {
const collection = prevState[mappedComponent.statePropertyName] || {};
collection[newValue[mappedComponent.collectionID]] = newValue;
const newState = {
[mappedComponent.statePropertyName]: collection,
};
return newState;
});
} else {
mappedComponent.withIonInstance.setState({
[mappedComponent.statePropertyName]: newValue,
});
>>>>>>>
// If there is a callback attached to the mapping, then trigger the callback and pass it the new value
if (mappedComponent.callback) {
mappedComponent.callback(newValue);
}
// If there is a withIonInstance, then the state needs to be set on that instance with the new value
if (mappedComponent.withIonInstance) {
// Set the state of the react component with either the pathed data, or the data
if (mappedComponent.addAsCollection) {
// Add the data to an array of existing items
mappedComponent.withIonInstance.setState((prevState) => {
const collection = prevState[mappedComponent.statePropertyName] || {};
collection[newValue[mappedComponent.collectionID]] = newValue;
const newState = {
[mappedComponent.statePropertyName]: collection,
};
return newState;
});
} else {
mappedComponent.withIonInstance.setState({
[mappedComponent.statePropertyName]: newValue,
});
} |
<<<<<<<
import {fetchChatReport} from '../../../lib/actions/Report';
import {redirect} from '../../../lib/actions/App';
=======
import {fetchOrCreateChatReport} from '../../../lib/actions/Report';
>>>>>>>
import {fetchOrCreateChatReport} from '../../../lib/actions/Report';
import {redirect} from '../../../lib/actions/App';
<<<<<<<
.then(currentLogin => fetchChatReport([currentLogin, option.login]))
.then(reportID => redirect(reportID));
=======
.then(currentLogin => fetchOrCreateChatReport([currentLogin, option.login]))
.then(reportID => Ion.set(IONKEYS.APP_REDIRECT_TO, `/${reportID}`));
>>>>>>>
.then(currentLogin => fetchOrCreateChatReport([currentLogin, option.login]))
.then(reportID => redirect(reportID)); |
<<<<<<<
// TODO: Fix hard coded values
API_ROOT: 'https://www.expensify.com.dev/api?',
PARTNER_NAME: 'android',
PARTNER_PASSWORD: 'c3a9ac418ea3f152aae2',
=======
API_ROOT: Config.EXPENSIFY_API_ROOT,
SITE_ROOT: Config.EXPENSIFY_SITE_ROOT,
PARTNER_NAME: Config.EXPENSIFY_PARTNER_NAME,
PARTNER_PASSWORD: Config.EXPENSIFY_PARTNER_PASSWORD,
>>>>>>>
API_ROOT: Config.EXPENSIFY_API_ROOT,
SITE_ROOT: Config.EXPENSIFY_SITE_ROOT,
PARTNER_NAME: Config.EXPENSIFY_PARTNER_NAME,
PARTNER_PASSWORD: Config.EXPENSIFY_PARTNER_PASSWORD,
// TODO: Fix hard coded values
API_ROOT: 'https://www.expensify.com.dev/api?',
PARTNER_NAME: 'android',
PARTNER_PASSWORD: 'c3a9ac418ea3f152aae2', |
<<<<<<<
navigationSceneContainer: {
backgroundColor: themeColors.appBG,
},
navigationScreenCardStyle: {
backgroundColor: themeColors.appBG,
},
=======
profilePageContainer: {
justifyContent: 'space-between',
width: '100%',
flex: 1,
},
profilePageSectionContainer: {
alignSelf: 'flex-start',
},
profilePageSectionVersion: {
alignSelf: 'center',
color: themeColors.textSupporting,
fontSize: variables.fontSizeSmall,
height: 24,
lineHeight: 20,
},
>>>>>>>
navigationSceneContainer: {
backgroundColor: themeColors.appBG,
},
navigationScreenCardStyle: {
backgroundColor: themeColors.appBG,
},
profilePageContainer: {
justifyContent: 'space-between',
width: '100%',
flex: 1,
},
profilePageSectionContainer: {
alignSelf: 'flex-start',
},
profilePageSectionVersion: {
alignSelf: 'center',
color: themeColors.textSupporting,
fontSize: variables.fontSizeSmall,
height: 24,
lineHeight: 20,
}, |
<<<<<<<
=======
// Keeps track of the last read for each report
const lastReadActionIDs = {};
// List of reportIDs that we define in .env
const configReportIDs = CONFIG.REPORT_IDS.split(',').map(Number);
>>>>>>>
// Keeps track of the last read for each report
const lastReadActionIDs = {};
<<<<<<<
isUnread: hasUnreadActions(report)
=======
unreadActionCount: getUnreadActionCount(report),
pinnedReport: configReportIDs.includes(report.reportID),
maxSequenceNumber: report.reportActionList.length,
>>>>>>>
unreadActionCount: getUnreadActionCount(report),
maxSequenceNumber: report.reportActionList.length, |
<<<<<<<
// Check the reportAction for a clientGUID and remove the temporary action
// since we are about to merge in the real action with accurate sequenceNumber
const clientGUID = reportAction.clientGUID;
if (clientGUID) {
// Delete this item from the report since we are about to replace it at the
// correct action ID index
removeLoadingAction(reportID, clientGUID);
}
// Add the action into Ion
=======
// Add the action into Onyx
>>>>>>>
// Check the reportAction for a clientGUID and remove the temporary action
// since we are about to merge in the real action with accurate sequenceNumber
const clientGUID = reportAction.clientGUID;
if (clientGUID) {
// Delete this item from the report since we are about to replace it at the
// correct action ID index
removeLoadingAction(reportID, clientGUID);
}
// Add the action into Onyx
<<<<<<<
=======
const actionKey = `${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${reportID}`;
>>>>>>>
<<<<<<<
// Generate a client guid so we can identify this later when it
// returns via Pusher with the real sequenceNumber
const tempActionID = `${Date.now()}_${guid()}`;
=======
// The new sequence number will be one higher than the highest
const highestSequenceNumber = reportMaxSequenceNumbers[reportID] || 0;
const newSequenceNumber = highestSequenceNumber + 1;
// Update the report in Onyx to have the new sequence number
Onyx.merge(`${ONYXKEYS.COLLECTION.REPORT}${reportID}`, {
maxSequenceNumber: newSequenceNumber,
});
>>>>>>>
// The new sequence number will be one higher than the highest
const highestSequenceNumber = reportMaxSequenceNumbers[reportID] || 0;
const newSequenceNumber = highestSequenceNumber + 1;
// Update the report in Onyx to have the new sequence number
Onyx.merge(`${ONYXKEYS.COLLECTION.REPORT}${reportID}`, {
maxSequenceNumber: newSequenceNumber,
});
// Generate a client guid so we can identify this later when it
// returns via Pusher with the real sequenceNumber
const tempActionID = `${Date.now()}_${guid()}`;
<<<<<<<
Ion.merge(`${IONKEYS.COLLECTION.REPORT_ACTIONS}${reportID}`, {
[tempActionID]: {
=======
Onyx.merge(actionKey, {
[newSequenceNumber]: {
>>>>>>>
Onyx.merge(`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${reportID}`, {
[tempActionID]: { |
<<<<<<<
},
LOGIN: {
PARTNER_USER_ID: Config.PARTNER_USER_ID,
PARTNER_USER_SECRET: Config.PARTNER_USER_SECRET,
},
=======
}
>>>>>>>
}, |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.