conflict_resolution
stringlengths
27
16k
<<<<<<< const raw = await callBridge('get_state', { path: url, observer: observer === undefined ? null : observer, }); ======= } const raw = await api.getStateAsync(url); >>>>>>> } const raw = await callBridge('get_state', { path: url, observer: observer === undefined ? null : observer, });
<<<<<<< const hasActiveAuth = authority.get('active') === 'full'; if (!highSecurityLogin) { const accountName = account.get('name'); authority = authority.set('active', 'none'); ======= yield call(accountAuthLookup, { payload: { account, private_keys, highSecurityLogin, login_owner_pubkey, }, }); let authority = yield select(state => state.user.getIn(['authority', username]) ); const hasActiveAuth = authority.get('active') === 'full'; if (!highSecurityLogin) { const accountName = account.get('name'); authority = authority.set('active', 'none'); yield put(userActions.setAuthority({ accountName, auth: authority })); } const fullAuths = authority.reduce( (r, auth, type) => (auth === 'full' ? r.add(type) : r), Set() ); if (!fullAuths.size) { console.log('No full auths'); localStorage.removeItem('autopost2'); const owner_pub_key = account.getIn(['owner', 'key_auths', 0, 0]); if ( login_owner_pubkey === owner_pub_key || login_wif_owner_pubkey === owner_pub_key ) { yield put(userActions.loginError({ error: 'owner_login_blocked' })); } else if (!highSecurityLogin && hasActiveAuth) { >>>>>>> const hasActiveAuth = authority.get('active') === 'full'; if (!highSecurityLogin) { const accountName = account.get('name'); authority = authority.set('active', 'none'); <<<<<<< ======= if ( private_keys.get('memo_private') && account.get('memo_key') !== private_keys .get('memo_private') .toPublicKey() .toString() ) // provided password did not yield memo key private_keys = private_keys.remove('memo_private'); if (!highSecurityLogin) { console.log('Not high security login'); >>>>>>> <<<<<<< ======= const memo_pubkey = private_keys.has('memo_private') ? private_keys .get('memo_private') .toPublicKey() .toString() : null; if (memo_pubkey === owner_pubkey || memo_pubkey === active_pubkey) // Memo key could be saved in local storage.. In RAM it is not purged upon LOCATION_CHANGE private_keys = private_keys.remove('memo_private'); // If user is signing operation by operaion and has no saved login, don't save to RAM if (!operationType || saveLogin) { if (username) feedURL = '/@' + username + '/feed'; // Keep the posting key in RAM but only when not signing an operation. // No operation or the user has checked: Keep me logged in... yield put( userActions.setUser({ username, private_keys, login_owner_pubkey, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get('received_vesting_shares'), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } else { if (username) feedURL = '/@' + username + '/feed'; yield put( userActions.setUser({ username, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get('received_vesting_shares'), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } if (!autopost && saveLogin) { yield put(userActions.saveLogin()); } >>>>>>> <<<<<<< const buf = JSON.stringify(challenge, null, 0); const bufSha = hash.sha256(buf); if (hasCompatibleKeychain()) { const response = yield new Promise(resolve => { window.steem_keychain.requestSignBuffer( username, buf, 'Posting', response => { resolve(response); } ); }); if (response.success) { signatures['posting'] = response.result; } else { yield put( userActions.loginError({ error: response.message }) ); return; } feedURL = '/@' + username + '/feed'; yield put( userActions.setUser({ username, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get( 'received_vesting_shares' ), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } else { const sign = (role, d) => { if (!d) return; const sig = Signature.signBufferSha256(bufSha, d); signatures[role] = sig.toHex(); }; sign('posting', private_keys.get('posting_private')); // sign('active', private_keys.get('active_private')) } yield serverApiLogin(username, signatures); ======= const bufSha = hash.sha256(JSON.stringify(challenge, null, 0)); const sign = (role, d) => { console.log('Sign before'); if (!d) return; console.log('Sign after'); const sig = Signature.signBufferSha256(bufSha, d); signatures[role] = sig.toHex(); }; sign('posting', private_keys.get('posting_private')); // sign('active', private_keys.get('active_private')) console.log('Logging in as', username); const response = yield serverApiLogin(username, signatures); const body = yield response.json(); if (justLoggedIn) { // If ads are enabled, reload the page instead of changing the browser // history when they log in, so headers will get re-requested. const adsEnabled = yield select(state => state.app.getIn(['googleAds', 'enabled']) ); if (adsEnabled) { var url = new URL(window.location.href); url.searchParams.set('auth', 'true'); console.log('New post-login URL', url.toString()); window.location.replace(url.toString()); return; } } >>>>>>> const buf = JSON.stringify(challenge, null, 0); const bufSha = hash.sha256(buf); if (hasCompatibleKeychain()) { const response = yield new Promise(resolve => { window.steem_keychain.requestSignBuffer( username, buf, 'Posting', response => { resolve(response); } ); }); if (response.success) { signatures['posting'] = response.result; } else { yield put( userActions.loginError({ error: response.message }) ); return; } feedURL = '/@' + username + '/feed'; yield put( userActions.setUser({ username, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get( 'received_vesting_shares' ), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } else { const sign = (role, d) => { console.log('Sign before'); if (!d) return; console.log('Sign after'); const sig = Signature.signBufferSha256(bufSha, d); signatures[role] = sig.toHex(); }; sign('posting', private_keys.get('posting_private')); // sign('active', private_keys.get('active_private')) console.log('Logging in as', username); const response = yield serverApiLogin(username, signatures); const body = yield response.json(); if (justLoggedIn) { // If ads are enabled, reload the page instead of changing the browser // history when they log in, so headers will get re-requested. const adsEnabled = yield select(state => state.app.getIn(['googleAds', 'enabled']) ); if (adsEnabled) { var url = new URL(window.location.href); url.searchParams.set('auth', 'true'); console.log('New post-login URL', url.toString()); window.location.replace(url.toString()); return; } } } <<<<<<< const memoKey = private_keys ? private_keys.get('memo_private') : null; ======= const memoKey = private_keys.get('memo_private'); >>>>>>> const memoKey = private_keys ? private_keys.get('memo_private') : null;
<<<<<<< import {fromJS} from 'immutable' import {getAccount, getContent} from 'app/redux/SagaShared' ======= import {fromJS, Set, Map} from 'immutable' import {getAccount} from 'app/redux/SagaShared' >>>>>>> import {fromJS, Set, Map} from 'immutable' import {getAccount, getContent} from 'app/redux/SagaShared'
<<<<<<< import { communityWatches } from 'app/redux/CommunitySaga'; ======= import { userProfilesWatches } from 'app/redux/UserProfilesSaga'; >>>>>>> import { communityWatches } from 'app/redux/CommunitySaga'; import { userProfilesWatches } from 'app/redux/UserProfilesSaga'; <<<<<<< ...communityWatches, ======= ...userProfilesWatches, >>>>>>> ...communityWatches, ...userProfilesWatches,
<<<<<<< import ja from 'react-intl/locale-data/ja'; import {DEFAULT_LANGUAGE} from 'app/client_config'; ======= import ko from 'react-intl/locale-data/ko'; import zh from 'react-intl/locale-data/zh'; import pl from 'react-intl/locale-data/pl'; import { DEFAULT_LANGUAGE } from 'app/client_config'; >>>>>>> import ko from 'react-intl/locale-data/ko'; import zh from 'react-intl/locale-data/zh'; import pl from 'react-intl/locale-data/pl'; import ja from 'react-intl/locale-data/ja'; import { DEFAULT_LANGUAGE } from 'app/client_config'; <<<<<<< addLocaleData([...en, ...es, ...ru, ...fr, ...it, ...ja]); ======= addLocaleData([...en, ...es, ...ru, ...fr, ...it, ...ko, ...zh, ...pl]); >>>>>>> addLocaleData([...en, ...es, ...ru, ...fr, ...it, ...ko, ...zh, ...pl, ...ja]); <<<<<<< tt.registerTranslations('ja', require('app/locales/counterpart/ja')); tt.registerTranslations('ja', require('app/locales/ja.json')); ======= tt.registerTranslations('ko', require('app/locales/counterpart/ko')); tt.registerTranslations('ko', require('app/locales/ko.json')); tt.registerTranslations('zh', require('app/locales/counterpart/zh')); tt.registerTranslations('zh', require('app/locales/zh.json')); tt.registerTranslations('pl', require('app/locales/counterpart/pl')); tt.registerTranslations('pl', require('app/locales/pl.json')); >>>>>>> tt.registerTranslations('ko', require('app/locales/counterpart/ko')); tt.registerTranslations('ko', require('app/locales/ko.json')); tt.registerTranslations('zh', require('app/locales/counterpart/zh')); tt.registerTranslations('zh', require('app/locales/zh.json')); tt.registerTranslations('pl', require('app/locales/counterpart/pl')); tt.registerTranslations('pl', require('app/locales/pl.json')); tt.registerTranslations('ja', require('app/locales/counterpart/ja')); tt.registerTranslations('ja', require('app/locales/ja.json'));
<<<<<<< const strCmp = (a, b) => (a > b ? 1 : a < b ? -1 : 0); function* isHighSecurityPage(pathname = null) { pathname = pathname || (yield select(state => state.global.get('pathname'))); return highSecurityPages.find(p => p.test(pathname)) != null; } function* removeHighSecurityKeys({ payload: { pathname } }) { // Let the user keep the active key when going from one high security page // to another. This helps when the user logins into the Wallet then the // Permissions tab appears (it was hidden). This keeps them from getting // logged out when they click on Permissions (which is really bad because // that tab disappears again). const highSecurityPage = yield isHighSecurityPage(pathname); if (!highSecurityPage) { yield put(userActions.removeHighSecurityKeys()); } } function* shouldShowLoginWarning({ username, password }) { // If it's a high-security login page, don't show the warning. if (yield isHighSecurityPage()) { return false; } // If it's a master key, show the warning. if (!auth.isWif(password)) { const accounts = yield api.getAccountsAsync([username]); const account = accounts[0]; const pubKey = PrivateKey.fromSeed(username + 'posting' + password) .toPublicKey() .toString(); const postingPubKeys = account.posting.key_auths[0]; return postingPubKeys.includes(pubKey); } // For any other case, don't show the warning. return false; } /** @arg {object} action.username - Unless a WIF is provided, this is hashed with the password and key_type to create private keys. @arg {object} action.password - Password or WIF private key. A WIF becomes the posting key, a password can create all three key_types: active, owner, posting keys. */ function* checkKeyType(action) { if (yield call(shouldShowLoginWarning, action.payload)) { yield put(userActions.showLoginWarning(action.payload)); } else { yield put(userActions.usernamePasswordLogin(action.payload)); } ======= /** @arg {object} action.username - Unless a WIF is provided, this is hashed with the password and key_type to create private keys. @arg {object} action.password - Password or WIF private key. A WIF becomes the posting key, a password can create all three key_types: active, owner, posting keys. */ function* checkKeyType(action) { if (yield call(shouldShowLoginWarning, action.payload)) { yield put(userActions.showLoginWarning(action.payload)); } else { yield put(userActions.usernamePasswordLogin(action.payload)); } >>>>>>> /** @arg {object} action.username - Unless a WIF is provided, this is hashed with the password and key_type to create private keys. @arg {object} action.password - Password or WIF private key. A WIF becomes the posting key, a password can create all three key_types: active, owner, posting keys. */ function* checkKeyType(action) { if (yield call(shouldShowLoginWarning, action.payload)) { yield put(userActions.showLoginWarning(action.payload)); } else { yield put(userActions.usernamePasswordLogin(action.payload)); } <<<<<<< const highSecurityLogin = yield isHighSecurityPage(); ======= const pathname = yield select(state => state.global.get('pathname')); >>>>>>> const pathname = yield select(state => state.global.get('pathname')); <<<<<<< if (!useKeychain) { try { const private_key = PrivateKey.fromWif(password); login_wif_owner_pubkey = private_key.toPublicKey().toString(); private_keys = fromJS({ posting_private: isRole('posting', () => private_key), active_private: isRole('active', () => private_key), memo_private: private_key, }); } catch (e) { // Password (non wif) login_owner_pubkey = PrivateKey.fromSeed( username + 'owner' + password ) .toPublicKey() .toString(); private_keys = fromJS({ posting_private: isRole('posting', () => PrivateKey.fromSeed(username + 'posting' + password) ), active_private: isRole('active', () => PrivateKey.fromSeed(username + 'active' + password) ), memo_private: PrivateKey.fromSeed(username + 'memo' + password), }); } if (memoWif) private_keys = private_keys.set( 'memo_private', PrivateKey.fromWif(memoWif) ); yield call(accountAuthLookup, { payload: { account, private_keys, highSecurityLogin, login_owner_pubkey, }, ======= try { const private_key = PrivateKey.fromWif(password); login_wif_owner_pubkey = private_key.toPublicKey().toString(); private_keys = fromJS({ owner_private: isRole('owner', () => private_key), posting_private: isRole('posting', () => private_key), active_private: isRole('active', () => private_key), memo_private: private_key, }); } catch (e) { // Password (non wif) login_owner_pubkey = PrivateKey.fromSeed(username + 'owner' + password) .toPublicKey() .toString(); private_keys = fromJS({ posting_private: isRole('posting', () => PrivateKey.fromSeed(username + 'posting' + password) ), active_private: isRole('active', () => PrivateKey.fromSeed(username + 'active' + password) ), memo_private: PrivateKey.fromSeed(username + 'memo' + password), >>>>>>> if (!useKeychain) { try { const private_key = PrivateKey.fromWif(password); login_wif_owner_pubkey = private_key.toPublicKey().toString(); private_keys = fromJS({ owner_private: isRole('owner', () => private_key), posting_private: isRole('posting', () => private_key), active_private: isRole('active', () => private_key), memo_private: private_key, }); } catch (e) { // Password (non wif) login_owner_pubkey = PrivateKey.fromSeed( username + 'owner' + password ) .toPublicKey() .toString(); private_keys = fromJS({ posting_private: isRole('posting', () => PrivateKey.fromSeed(username + 'posting' + password) ), active_private: isRole('active', () => PrivateKey.fromSeed(username + 'active' + password) ), memo_private: PrivateKey.fromSeed(username + 'memo' + password), }); } if (memoWif) private_keys = private_keys.set( 'memo_private', PrivateKey.fromWif(memoWif) ); yield call(accountAuthLookup, { payload: { account, private_keys, login_owner_pubkey, }, <<<<<<< const owner_pubkey = account.getIn(['owner', 'key_auths', 0, 0]); const active_pubkey = account.getIn(['active', 'key_auths', 0, 0]); const posting_pubkey = account.getIn(['posting', 'key_auths', 0, 0]); if ( private_keys.get('memo_private') && account.get('memo_key') !== private_keys .get('memo_private') .toPublicKey() .toString() ) // provided password did not yield memo key private_keys = private_keys.remove('memo_private'); if (!highSecurityLogin) { console.log('Not high security login'); if ( posting_pubkey === owner_pubkey || posting_pubkey === active_pubkey ) { yield put( userActions.loginError({ error: 'This login gives owner or active permissions and should not be used here. Please provide a posting only login.', }) ); localStorage.removeItem('autopost2'); return; } } const memo_pubkey = private_keys.has('memo_private') ? private_keys .get('memo_private') .toPublicKey() .toString() : null; if (memo_pubkey === owner_pubkey || memo_pubkey === active_pubkey) // Memo key could be saved in local storage.. In RAM it is not purged upon LOCATION_CHANGE private_keys = private_keys.remove('memo_private'); // If user is signing operation by operaion and has no saved login, don't save to RAM if (!operationType || saveLogin) { if (username) feedURL = '/@' + username + '/feed'; // Keep the posting key in RAM but only when not signing an operation. // No operation or the user has checked: Keep me logged in... yield put( userActions.setUser({ username, private_keys, login_owner_pubkey, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get( 'received_vesting_shares' ), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } else { if (username) feedURL = '/@' + username + '/feed'; yield put( userActions.setUser({ username, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get( 'received_vesting_shares' ), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } } ======= const memo_pubkey = private_keys.has('memo_private') ? private_keys .get('memo_private') .toPublicKey() .toString() : null; if ( account.get('memo_key') !== memo_pubkey || memo_pubkey === owner_pubkey || memo_pubkey === active_pubkey ) // provided password did not yield memo key, or matched active/owner private_keys = private_keys.remove('memo_private'); if (posting_pubkey === owner_pubkey || posting_pubkey === active_pubkey) { yield put( userActions.loginError({ error: 'This login gives owner or active permissions and should not be used here. Please provide a posting only login.', }) ); localStorage.removeItem('autopost2'); return; } // If user is signing operation by operaion and has no saved login, don't save to RAM if (!operationType || saveLogin) { if (username) feedURL = '/@' + username + '/feed'; // Keep the posting key in RAM but only when not signing an operation. // No operation or the user has checked: Keep me logged in... yield put( userActions.setUser({ username, private_keys, login_owner_pubkey, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get('received_vesting_shares'), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } else { if (username) feedURL = '/@' + username + '/feed'; yield put( userActions.setUser({ username, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get('received_vesting_shares'), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } if (!autopost && saveLogin) { yield put(userActions.saveLogin()); } >>>>>>> const owner_pubkey = account.getIn(['owner', 'key_auths', 0, 0]); const active_pubkey = account.getIn(['active', 'key_auths', 0, 0]); const posting_pubkey = account.getIn(['posting', 'key_auths', 0, 0]); const memo_pubkey = private_keys.has('memo_private') ? private_keys .get('memo_private') .toPublicKey() .toString() : null; if ( account.get('memo_key') !== memo_pubkey || memo_pubkey === owner_pubkey || memo_pubkey === active_pubkey ) // provided password did not yield memo key, or matched active/owner private_keys = private_keys.remove('memo_private'); if ( posting_pubkey === owner_pubkey || posting_pubkey === active_pubkey ) { yield put( userActions.loginError({ error: 'This login gives owner or active permissions and should not be used here. Please provide a posting only login.', }) ); localStorage.removeItem('autopost2'); return; } // If user is signing operation by operaion and has no saved login, don't save to RAM if (!operationType || saveLogin) { if (username) feedURL = '/@' + username + '/feed'; // Keep the posting key in RAM but only when not signing an operation. // No operation or the user has checked: Keep me logged in... yield put( userActions.setUser({ username, private_keys, login_owner_pubkey, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get( 'received_vesting_shares' ), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } else { if (username) feedURL = '/@' + username + '/feed'; yield put( userActions.setUser({ username, vesting_shares: account.get('vesting_shares'), received_vesting_shares: account.get( 'received_vesting_shares' ), delegated_vesting_shares: account.get( 'delegated_vesting_shares' ), }) ); } }
<<<<<<< const pathname = yield select(state => state.global.get('pathname')); const highSecurityLogin = false; ======= const highSecurityLogin = yield isHighSecurityPage(); >>>>>>> const pathname = yield select(state => state.global.get('pathname')); <<<<<<< } else if (hasActiveAuth) { ======= return; } else if (!highSecurityLogin && hasActiveAuth) { >>>>>>> } else if (hasActiveAuth) {
<<<<<<< // needed for custom class decorators require("reflect-metadata"); require("zone.js/dist/zone-node"); const SpecReporter = require('jasmine-spec-reporter'); // add jasmine spec reporter jasmine.getEnv().addReporter(new SpecReporter({ displayStacktrace: true })); ======= >>>>>>> // needed for custom class decorators require("reflect-metadata"); require("zone.js/dist/zone-node");
<<<<<<< "activateLinkHintsMode", "activateLinkHintsModeToOpenInNewTab", "enterFindMode", "performFind", "performBackwardsFind", "nextFrame"], ======= "activateLinkHintsMode", "activateLinkHintsModeToOpenInNewTab", "activeteLinkHintsModeWithQueue", "enterFindMode", "performFind", "performBackwardsFind"], >>>>>>> "activateLinkHintsMode", "activateLinkHintsModeToOpenInNewTab", "activeteLinkHintsModeWithQueue", "enterFindMode", "performFind", "performBackwardsFind", "nextFrame"],
<<<<<<< if(docs.length > 0 && !docs[0].toggleChat) { socket.emit('chat', {from: "System", msg: ": Chat for this channel has been disabled.", icon: "https://zoff.me/assets/images/favicon-32x32.png"}); } else if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (msg.hasOwnProperty('pass') && docs[0].userpass == crypto.createHash('sha256').update(Functions.decrypt_string(msg.pass)).digest("base64")))) { ======= if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (msg.hasOwnProperty('pass') && docs[0].userpass == msg.pass))) { >>>>>>> if(docs.length > 0 && !docs[0].toggleChat) { socket.emit('chat', {from: "System", msg: ": Chat for this channel has been disabled.", icon: "https://zoff.me/assets/images/favicon-32x32.png"}); return; } else if(docs.length > 0 && (docs[0].userpass == undefined || docs[0].userpass == "" || (msg.hasOwnProperty('pass') && docs[0].userpass == msg.pass))) { <<<<<<< checkIfChatEnabled(coll, socket, function() { db.collection("user_names").find({"guid": guid}, function(err, docs) { if(docs.length == 1) { var old_name = docs[0].name; Functions.removeSessionChatPass(Functions.getSession(socket), function() { db.collection("user_names").update({"_id": "all_names"}, {$pull: {names: old_name}}, function(err, updated) { db.collection("user_names").remove({"guid": guid}, function(err, removed) { get_name(guid, {announce: true, old_name: old_name, channel: coll}); }); ======= db.collection("user_names").find({"guid": guid}, function(err, docs) { if(docs.length == 1) { var old_name = docs[0].name; Functions.removeSessionChatPass(Functions.getSession(socket), function() { db.collection("user_names").update({"_id": "all_names"}, {$pull: {names: old_name}}, function(err, updated) { db.collection("user_names").remove({"guid": guid}, function(err, removed) { get_name(guid, {announce: true, old_name: old_name, channel: coll, socket: socket}); >>>>>>> checkIfChatEnabled(coll, socket, function() { db.collection("user_names").find({"guid": guid}, function(err, docs) { if(docs.length == 1) { var old_name = docs[0].name; Functions.removeSessionChatPass(Functions.getSession(socket), function() { db.collection("user_names").update({"_id": "all_names"}, {$pull: {names: old_name}}, function(err, updated) { db.collection("user_names").remove({"guid": guid}, function(err, removed) { get_name(guid, {announce: true, old_name: old_name, channel: coll, socket: socket}); });
<<<<<<< var local_new_channel = false; ======= var hiddenPlaylist = false; >>>>>>> var local_new_channel = false; var hiddenPlaylist = false; <<<<<<< if(chan && !Helper.mobilecheck()){ if(document.querySelector("#wrapper") == null) return; if(window.innerWidth > 600 && document.querySelector("#wrapper").style.height != "") { document.querySelector("#wrapper").style.height = ""; document.querySelector("#chat-bar").style.height = ""; document.querySelector("#channelchat").style.height = ""; document.querySelector("#all_chat").style.height = ""; document.querySelector("#chat-container").style.height = ""; } else if(window.innerWidth < 601) { if(!client && !embed) { var scPlaying = false; var ytPlaying = false; try { ytPlaying = Player.player.getPlayerState() == YT.PlayerState.PLAYING || Player.player.getPlayerState() == YT.PlayerState.BUFFERING; } catch(e) {} try { scPlaying = Player.soundcloud_player.isPlaying(); } catch(e){} resizePlaylistPlaying(ytPlaying || scPlaying); return; } } var temp_fit = Math.round(Helper.computedStyle("#wrapper", "height") / 71)+1; if(temp_fit > List.can_fit || temp_fit < List.can_fit){ List.dynamicContentPage(-10); } if(List.can_fit < temp_fit){ for(var i = 0; i < List.page + temp_fit; i++) { Helper.css(document.querySelector("#wrapper").children[i], "display", "inline-flex"); } } else if(List.can_fit > temp_fit){ Helper.css(document.querySelector("#wrapper").children[List.page + temp_fit], "display", "none"); var elements = document.querySelector("#wrapper").children; for(var i = List.page + temp_fit; i < elements.length; i++) { Helper.css(document.querySelector("#wrapper").children[i], "display", "none"); } } List.can_fit = temp_fit; List.element_height = (Helper.computedStyle("#wrapper", "height") / List.can_fit)-5.3; Helper.css(".list-song", "height", List.element_height + "px"); Channel.set_title_width(); if(!client) { var controlsPosition = document.querySelector("#controls").offsetHeight - Helper.computedStyle("#controls", "height"); if(document.querySelectorAll("#controls").length > 0 && !Helper.mobilecheck()) { Helper.css(document.querySelector("#seekToDuration"), "top", controlsPosition - 55); } else if(document.querySelectorAll("#controls").length > 0) { Helper.css(document.querySelector("#seekToDuration"), "top", controlsPosition - 20); } Channel.window_width_volume_slider(); } } ======= resizeFunction(); >>>>>>> resizeFunction();
<<<<<<< require('../modules/union/test'); ======= require('../modules/sorted-index/test'); require('../modules/sorted-insert/test'); >>>>>>> require('../modules/union/test'); require('../modules/sorted-index/test'); require('../modules/sorted-insert/test');
<<<<<<< import Icon from 'components/Icon' import SideMenu from 'components/SideMenu' import MenuItem from 'components/MenuItem' ======= >>>>>>> <<<<<<< import liveStatus from 'computed/liveStatus' ======= import ProfileMenu from './ProfileMenu' import MainMenu from './MainMenu' >>>>>>> import liveStatus from 'computed/liveStatus' import ProfileMenu from './ProfileMenu' import MainMenu from './MainMenu' <<<<<<< logToggled: signal`bin.logToggled`, leftMenuButtonClicked: signal`app.leftMenuButtonClicked`, avatarClicked: signal`app.avatarClicked`, createBinClicked: signal`app.createBinClicked`, githubSignInClicked: signal`app.githubSignInClicked`, liveToggled: signal`bin.liveToggled` ======= logToggled: signal`bin.logToggled` >>>>>>> logToggled: signal`bin.logToggled`, createBinClicked: signal`app.createBinClicked`, liveToggled: signal`bin.liveToggled` <<<<<<< logToggled, leftMenuButtonClicked, avatarClicked, createBinClicked, githubSignInClicked, liveToggled ======= logToggled >>>>>>> logToggled, leftMenuButtonClicked, createBinClicked, liveToggled <<<<<<< <IconButton icon='user' onClick={(e) => { e.stopPropagation() avatarClicked() }} > Profile </IconButton> <SideMenu side='right' show={profileMenuIsOpened} > <MenuItem onClick={() => githubSignInClicked()}> Profile menu content </MenuItem> </SideMenu> ======= <ProfileMenu /> >>>>>>> <ProfileMenu />
<<<<<<< setUp : function (cb) { moment.lang('fr-ca'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, ======= setUp: function(cb) { moment.lang('fr-ca'); cb(); }, tearDown: function(cb) { moment.lang('en'); cb(); }, >>>>>>> setUp : function (cb) { moment.lang('fr-ca'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, <<<<<<< var i, tests = 'janvier janv._février févr._mars mars_avril avr._mai mai_juin juin_juillet juil._août août_septembre sept._octobre oct._novembre nov._décembre déc.'.split("_"); ======= var tests = 'janvier janv._février févr._mars mars_avril avr._mai mai_juin juin_juillet juil._août août_septembre sept._octobre oct._novembre nov._décembre déc.'.split("_"); var i; >>>>>>> var i, tests = 'janvier janv._février févr._mars mars_avril avr._mai mai_juin juin_juillet juil._août août_septembre sept._octobre oct._novembre nov._décembre déc.'.split("_"); <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< var i, expected = 'janvier janv._février févr._mars mars_avril avr._mai mai_juin juin_juillet juil._août août_septembre sept._octobre oct._novembre nov._décembre déc.'.split("_"); ======= var expected = 'janvier janv._février févr._mars mars_avril avr._mai mai_juin juin_juillet juil._août août_septembre sept._octobre oct._novembre nov._décembre déc.'.split("_"); var i; >>>>>>> var i, expected = 'janvier janv._février févr._mars mars_avril avr._mai mai_juin juin_juillet juil._août août_septembre sept._octobre oct._novembre nov._décembre déc.'.split("_"); <<<<<<< var i, expected = 'dimanche dim. Di_lundi lun. Lu_mardi mar. Ma_mercredi mer. Me_jeudi jeu. Je_vendredi ven. Ve_samedi sam. Sa'.split("_"); ======= var expected = 'dimanche dim. Di_lundi lun. Lu_mardi mar. Ma_mercredi mer. Me_jeudi jeu. Je_vendredi ven. Ve_samedi sam. Sa'.split("_"); var i; >>>>>>> var i, expected = 'dimanche dim. Di_lundi lun. Lu_mardi mar. Ma_mercredi mer. Me_jeudi jeu. Je_vendredi ven. Ve_samedi sam. Sa'.split("_"); <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>>
<<<<<<< formattingTokens = /(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|YYYY|YY|a|A|hh?|HH?|mm?|ss?|SS?S?|zz?|ZZ?)/g, localFormattingTokens = /(\[[^\[]*\])|(\\)?(LT|LL?L?L?)/g, formattingRemoveEscapes = /(^\[)|(\\)|\]$/g, ======= formattingTokens = /(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|YYYY|YY|a|A|hh?|HH?|mm?|ss?|SS?S?|zz?|ZZ?|.)/g, localFormattingTokens = /(LT|LL?L?L?)/g, >>>>>>> formattingTokens = /(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|YYYY|YY|a|A|hh?|HH?|mm?|ss?|SS?S?|zz?|ZZ?|.)/g, localFormattingTokens = /(\[[^\[]*\])|(\\)?(LT|LL?L?L?)/g, <<<<<<< // helper for building inline formatting functions function replaceFormatTokens(token) { return formatFunctionStrings[token] ? ("'+(" + formatFunctionStrings[token] + ")+'") : token.replace(formattingRemoveEscapes, "").replace(/\\?'/g, "\\'"); } ======= >>>>>>> <<<<<<< var lang = getLangDefinition(m), i = 5; function getValueFromArray(key, index) { return lang[key].call ? lang[key](m, format) : lang[key][index]; } while (i-- && localFormattingTokens.test(format)) { ======= while (localFormattingTokens.test(format)) { >>>>>>> var i = 5; while (i-- && localFormattingTokens.test(format)) {
<<<<<<< setUp : function (cb) { moment.lang('de'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, ======= setUp: function(cb) { moment.lang('de'); cb(); }, tearDown: function(cb) { moment.lang('en'); cb(); }, >>>>>>> setUp : function (cb) { moment.lang('de'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< var i; var m; ======= >>>>>>> <<<<<<< ======= >>>>>>>
<<<<<<< quickstarts: [ { title: 'ES2015', description: 'Creates an entrypoint with ES2016 transpiling, ready for you to add any NPM packages', template: 'es2015', }, { title: 'Typescript', description: 'Creates an entrypoint with Typescript transpiling, ready for you to add any NPM packages', template: 'typescript', }, ], ======= quickstarts: [{ title: 'ES2015', description: 'Creates an entrypoint with ES2015 transpiling, ready for you to add any NPM packages', template: 'es2015' }, { title: 'Typescript', description: 'Creates an entrypoint with Typescript transpiling, ready for you to add any NPM packages', template: 'typescript' }] >>>>>>> quickstarts: [ { title: 'ES2015', description: 'Creates an entrypoint with ES2015 transpiling, ready for you to add any NPM packages', template: 'es2015', }, { title: 'Typescript', description: 'Creates an entrypoint with Typescript transpiling, ready for you to add any NPM packages', template: 'typescript', }, ],
<<<<<<< setUp : function (cb) { moment.lang('ca'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, ======= setUp: function(cb) { moment.lang('ca'); cb(); }, tearDown: function(cb) { moment.lang('en'); cb(); }, >>>>>>> setUp : function (cb) { moment.lang('ca'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< var i; var m; ======= >>>>>>> var i; var m;
<<<<<<< ['LLL', '14 Februar 2010 15:25'], ['LLLL', 'Søndag 14. Februar, 2010 15:25'] ======= ['LLL', '14 Februar 2010 3:25 PM'], ['LLLL', 'Søndag 14. Februar, 2010 3:25 PM'], ['l', '14/2/2010'], ['ll', '14 Feb 2010'], ['lll', '14 Feb 2010 3:25 PM'], ['llll', 'Søn 14. Feb, 2010 3:25 PM'] >>>>>>> ['LLL', '14 Februar 2010 15:25'], ['LLLL', 'Søndag 14. Februar, 2010 15:25'], ['l', '14/2/2010'], ['ll', '14 Feb 2010'], ['lll', '14 Feb 2010 15:25'], ['llll', 'Søn 14. Feb, 2010 15:25']
<<<<<<< ======= (function () { var lang = { months : "januari_februari_mars_april_maj_juni_juli_augusti_september_oktober_november_december".split("_"), monthsShort : "jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"), weekdays : "söndag_måndag_tisdag_onsdag_torsdag_fredag_lördag".split("_"), weekdaysShort : "sön_mån_tis_ons_tor_fre_lör".split("_"), weekdaysMin : "sö_må_ti_on_to_fr_lö".split("_"), longDateFormat : { LT : "HH:mm", L : "YYYY-MM-DD", LL : "D MMMM YYYY", LLL : "D MMMM YYYY LT", LLLL : "dddd D MMMM YYYY LT" }, calendar : { sameDay: '[Idag klockan] LT', nextDay: '[Imorgon klockan] LT', lastDay: '[Igår klockan] LT', nextWeek: 'dddd [klockan] LT', lastWeek: '[Förra] dddd[en klockan] LT', sameElse: 'L' }, relativeTime : { future : "om %s", past : "för %s sen", s : "några sekunder", m : "en minut", mm : "%d minuter", h : "en timme", hh : "%d timmar", d : "en dag", dd : "%d dagar", M : "en månad", MM : "%d månader", y : "ett år", yy : "%d år" }, ordinal : function (number) { var b = number % 10; return (~~ (number % 100 / 10) === 1) ? 'e' : (b === 1) ? 'a' : (b === 2) ? 'a' : (b === 3) ? 'e' : 'e'; }, week : { dow : 1, // Monday is the first day of the week. doy : 4 // The week that contains Jan 4th is the first week of the year. } }; >>>>>>>
<<<<<<< ======= (function () { var lang = { months : "janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"), monthsShort : "janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"), weekdays : "dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"), weekdaysShort : "dim._lun._mar._mer._jeu._ven._sam.".split("_"), weekdaysMin : "Di_Lu_Ma_Me_Je_Ve_Sa".split("_"), longDateFormat : { LT : "HH:mm", L : "DD/MM/YYYY", LL : "D MMMM YYYY", LLL : "D MMMM YYYY LT", LLLL : "dddd D MMMM YYYY LT" }, calendar : { sameDay: "[Aujourd'hui à] LT", nextDay: '[Demain à] LT', nextWeek: 'dddd [à] LT', lastDay: '[Hier à] LT', lastWeek: 'dddd [dernier à] LT', sameElse: 'L' }, relativeTime : { future : "dans %s", past : "il y a %s", s : "quelques secondes", m : "une minute", mm : "%d minutes", h : "une heure", hh : "%d heures", d : "un jour", dd : "%d jours", M : "un mois", MM : "%d mois", y : "une année", yy : "%d années" }, ordinal : function (number) { return number === 1 ? 'er' : 'ème'; }, week : { dow : 1, // Monday is the first day of the week. doy : 4 // The week that contains Jan 4th is the first week of the year. } }; >>>>>>>
<<<<<<< ======= (function () { var lang = { months : "кăрлач_нарăс_пуш_ака_май_çĕртме_утă_çурла_авăн_юпа_чӳк_раштав".split("_"), monthsShort : "кăр_нар_пуш_ака_май_çĕр_утă_çур_ав_юпа_чӳк_раш".split("_"), weekdays : "вырсарникун_тунтикун_ытларикун_юнкун_кĕçнерникун_эрнекун_шăматкун".split("_"), weekdaysShort : "выр_тун_ытл_юн_кĕç_эрн_шăм".split("_"), weekdaysMin : "вр_тн_ыт_юн_кç_эр_шм".split("_"), longDateFormat : { LT : "HH:mm", L : "DD-MM-YYYY", LL : "YYYY çулхи MMMM уйăхĕн D-мĕшĕ", LLL : "YYYY çулхи MMMM уйăхĕн D-мĕшĕ, LT", LLLL : "dddd, YYYY çулхи MMMM уйăхĕн D-мĕшĕ, LT" }, calendar : { sameDay: '[Паян] LT [сехетре]', nextDay: '[Ыран] LT [сехетре]', lastDay: '[Ĕнер] LT [сехетре]', nextWeek: '[Çитес] dddd LT [сехетре]', lastWeek: '[Иртнĕ] dddd LT [сехетре]', sameElse: 'L' }, relativeTime : { future : function (output) { var affix = /сехет$/i.exec(output) ? "рен" : /çул$/i.exec(output) ? "тан" : "ран"; return output + affix; }, past : "%s каялла", s : "пĕр-ик çеккунт", m : "пĕр минут", mm : "%d минут", h : "пĕр сехет", hh : "%d сехет", d : "пĕр кун", dd : "%d кун", M : "пĕр уйăх", MM : "%d уйăх", y : "пĕр çул", yy : "%d çул" }, ordinal : function (number) { return '-мĕш'; }, week : { dow : 1, // Monday is the first day of the week. doy : 7 // The week that contains Jan 1st is the first week of the year. } }; >>>>>>>
<<<<<<< ======= (function () { var lang = { months : "Gener_Febrer_Març_Abril_Maig_Juny_Juliol_Agost_Setembre_Octubre_Novembre_Desembre".split("_"), monthsShort : "Gen._Febr._Mar._Abr._Mai._Jun._Jul._Ag._Set._Oct._Nov._Des.".split("_"), weekdays : "Diumenge_Dilluns_Dimarts_Dimecres_Dijous_Divendres_Dissabte".split("_"), weekdaysShort : "Dg._Dl._Dt._Dc._Dj._Dv._Ds.".split("_"), weekdaysMin : "Dg_Dl_Dt_Dc_Dj_Dv_Ds".split("_"), longDateFormat : { LT : "H:mm", L : "DD/MM/YYYY", LL : "D MMMM YYYY", LLL : "D MMMM YYYY LT", LLLL : "dddd D MMMM YYYY LT" }, calendar : { sameDay : function () { return '[avui a ' + ((this.hours() !== 1) ? 'les' : 'la') + '] LT'; }, nextDay : function () { return '[demà a ' + ((this.hours() !== 1) ? 'les' : 'la') + '] LT'; }, nextWeek : function () { return 'dddd [a ' + ((this.hours() !== 1) ? 'les' : 'la') + '] LT'; }, lastDay : function () { return '[ahir a ' + ((this.hours() !== 1) ? 'les' : 'la') + '] LT'; }, lastWeek : function () { return '[el] dddd [passat a ' + ((this.hours() !== 1) ? 'les' : 'la') + '] LT'; }, sameElse : 'L' }, relativeTime : { future : "en %s", past : "fa %s", s : "uns segons", m : "un minut", mm : "%d minuts", h : "una hora", hh : "%d hores", d : "un dia", dd : "%d dies", M : "un mes", MM : "%d mesos", y : "un any", yy : "%d anys" }, ordinal : function (number) { return 'º'; }, week : { dow : 1, // Monday is the first day of the week. doy : 4 // The week that contains Jan 4th is the first week of the year. } }; >>>>>>>
<<<<<<< ======= (function () { var lang = { months : "Xaneiro_Febreiro_Marzo_Abril_Maio_Xuño_Xullo_Agosto_Setembro_Octubro_Novembro_Decembro".split("_"), monthsShort : "Xan._Feb._Mar._Abr._Mai._Xuñ._Xul._Ago._Set._Out._Nov._Dec.".split("_"), weekdays : "Domingo_Luns_Martes_Mércores_Xoves_Venres_Sábado".split("_"), weekdaysShort : "Dom._Lun._Mar._Mér._Xov._Ven._Sáb.".split("_"), weekdaysMin : "Do_Lu_Ma_Mé_Xo_Ve_Sá".split("_"), longDateFormat : { LT : "H:mm", L : "DD/MM/YYYY", LL : "D MMMM YYYY", LLL : "D MMMM YYYY LT", LLLL : "dddd D MMMM YYYY LT" }, calendar : { sameDay : function () { return '[hoxe ' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT'; }, nextDay : function () { return '[mañá ' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT'; }, nextWeek : function () { return 'dddd [' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT'; }, lastDay : function () { return '[onte ' + ((this.hours() !== 1) ? 'á' : 'a') + '] LT'; }, lastWeek : function () { return '[o] dddd [pasado ' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT'; }, sameElse : 'L' }, relativeTime : { future : "en %s", past : "fai %s", s : "uns segundo", m : "un minuto", mm : "%d minutos", h : "unha hora", hh : "%d horas", d : "un día", dd : "%d días", M : "un mes", MM : "%d meses", y : "un ano", yy : "%d anos" }, ordinal : function (number) { return 'º'; }, week : { dow : 1, // Monday is the first day of the week. doy : 7 // The week that contains Jan 1st is the first week of the year. } }; >>>>>>>
<<<<<<< setUp : function (cb) { moment.lang('en-ca'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, ======= setUp: function(cb) { moment.lang('en-ca'); cb(); }, tearDown: function(cb) { moment.lang('en'); cb(); }, >>>>>>> setUp : function (cb) { moment.lang('en-ca'); cb(); }, tearDown : function (cb) { moment.lang('en'); cb(); }, <<<<<<< var i, tests = 'January Jan_February Feb_March Mar_April Apr_May May_June Jun_July Jul_August Aug_September Sep_October Oct_November Nov_December Dec'.split("_"); ======= var tests = 'January Jan_February Feb_March Mar_April Apr_May May_June Jun_July Jul_August Aug_September Sep_October Oct_November Nov_December Dec'.split("_"); var i; >>>>>>> var i, tests = 'January Jan_February Feb_March Mar_April Apr_May May_June Jun_July Jul_August Aug_September Sep_October Oct_November Nov_December Dec'.split("_"); <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< var i, expected = 'January Jan_February Feb_March Mar_April Apr_May May_June Jun_July Jul_August Aug_September Sep_October Oct_November Nov_December Dec'.split("_"); ======= var expected = 'January Jan_February Feb_March Mar_April Apr_May May_June Jun_July Jul_August Aug_September Sep_October Oct_November Nov_December Dec'.split("_"); var i; >>>>>>> var i, expected = 'January Jan_February Feb_March Mar_April Apr_May May_June Jun_July Jul_August Aug_September Sep_October Oct_November Nov_December Dec'.split("_"); <<<<<<< var i, expected = 'Sunday Sun Su_Monday Mon Mo_Tuesday Tue Tu_Wednesday Wed We_Thursday Thu Th_Friday Fri Fr_Saturday Sat Sa'.split("_"); ======= var expected = 'Sunday Sun Su_Monday Mon Mo_Tuesday Tue Tu_Wednesday Wed We_Thursday Thu Th_Friday Fri Fr_Saturday Sat Sa'.split("_"); var i; >>>>>>> var i, expected = 'Sunday Sun Su_Monday Mon Mo_Tuesday Tue Tu_Wednesday Wed We_Thursday Thu Th_Friday Fri Fr_Saturday Sat Sa'.split("_"); <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< ======= >>>>>>> <<<<<<< var i, m; ======= var i; var m; >>>>>>> var i, m; <<<<<<< var i, m; ======= >>>>>>> var i, m; <<<<<<< var weeksAgo = moment().subtract({ w: 1 }), weeksFromNow = moment().add({ w: 1 }); ======= var weeksAgo = moment().subtract({ w: 1 }); var weeksFromNow = moment().add({ w: 1 }); >>>>>>> var weeksAgo = moment().subtract({ w: 1 }), weeksFromNow = moment().add({ w: 1 });
<<<<<<< ======= (function () { var lang = { months : "januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"), monthsShort : "jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"), weekdays : "søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"), weekdaysShort : "søn_man_tir_ons_tor_fre_lør".split("_"), weekdaysMin : "sø_ma_ti_on_to_fr_lø".split("_"), longDateFormat : { LT : "HH:mm", L : "YYYY-MM-DD", LL : "D MMMM YYYY", LLL : "D MMMM YYYY LT", LLLL : "dddd D MMMM YYYY LT" }, calendar : { sameDay: '[I dag klokken] LT', nextDay: '[I morgen klokken] LT', nextWeek: 'dddd [klokken] LT', lastDay: '[I går klokken] LT', lastWeek: '[Forrige] dddd [klokken] LT', sameElse: 'L' }, relativeTime : { future : "om %s", past : "for %s siden", s : "noen sekunder", m : "ett minutt", mm : "%d minutter", h : "en time", hh : "%d timer", d : "en dag", dd : "%d dager", M : "en måned", MM : "%d måneder", y : "ett år", yy : "%d år" }, ordinal : function (number) { return '.'; }, week : { dow : 1, // Monday is the first day of the week. doy : 4 // The week that contains Jan 4th is the first week of the year. } }; >>>>>>>
<<<<<<< constructor(bluetooth, settings) { this._model = bluetooth._model; this._getDefaultAdapter = bluetooth._getDefaultAdapter; ======= constructor(bluetooth) { >>>>>>> constructor(bluetooth, settings) { <<<<<<< this._connectSignal(this._menu, 'open-state-changed', (menu, isOpen) => { if (isOpen && this._autoPowerOnEnabled()) this._proxy.BluetoothAirplaneMode = false; ======= this._loadBluetoothModel(); let signal = this._menu.connect('open-state-changed', (menu, isOpen) => { if (isOpen) this._sync(); >>>>>>> this._loadBluetoothModel(); this._connectSignal(this._menu, 'open-state-changed', (menu, isOpen) => { if (isOpen && this._autoPowerOnEnabled()) this._proxy.BluetoothAirplaneMode = false; <<<<<<< _idleMonitor() { this._idleMonitorId = GLib.timeout_add(GLib.PRIORITY_DEFAULT, 60 * 1000, () => { if (this._autoPowerOffEnabled() && this._getConnectedDevices().length === 0) this._proxy.BluetoothAirplaneMode = true; return true; }); } _connectSignal(subject, signal_name, method) { let signal_id = subject.connect(signal_name, method); this._signals.push({ subject: subject, signal_id: signal_id }); } _getDevices() { ======= _loadBluetoothModel() { this._client = new GnomeBluetooth.Client(); this._model = this._client.get_model(); } _getDefaultAdapter() { let [ret, iter] = this._model.get_iter_first(); while (ret) { let isDefault = this._model.get_value(iter, GnomeBluetooth.Column.DEFAULT); let isPowered = this._model.get_value(iter, GnomeBluetooth.Column.POWERED); if (isDefault && isPowered) return iter; ret = this._model.iter_next(iter); } return null; } _getPairedDevices() { >>>>>>> _idleMonitor() { this._idleMonitorId = GLib.timeout_add(GLib.PRIORITY_DEFAULT, 60 * 1000, () => { if (this._autoPowerOffEnabled() && this._getConnectedDevices().length === 0) this._proxy.BluetoothAirplaneMode = true; return true; }); } _connectSignal(subject, signal_name, method) { let signal_id = subject.connect(signal_name, method); this._signals.push({ subject: subject, signal_id: signal_id }); } _loadBluetoothModel() { this._client = new GnomeBluetooth.Client(); this._model = this._client.get_model(); } _getDefaultAdapter() { let [ret, iter] = this._model.get_iter_first(); while (ret) { let isDefault = this._model.get_value(iter, GnomeBluetooth.Column.DEFAULT); let isPowered = this._model.get_value(iter, GnomeBluetooth.Column.POWERED); if (isDefault && isPowered) return iter; ret = this._model.iter_next(iter); } return null; } _getDevices() {
<<<<<<< ghPath = __dirname + '/output/gh-pages/stylesheets/stylesheet.css', prevRun; ======= gh_path = path.join(__dirname, '/output/gh-pages/stylesheets/stylesheet.css'), prev_run; >>>>>>> ghPath = path.join(__dirname, '/output/gh-pages/stylesheets/stylesheet.css'), prevRun; <<<<<<< fs.writeFile(__dirname + '/output/gh-pages/stylesheets/stylesheet.css', prevRun, done); ======= fs.writeFile(path.join(__dirname, '/output/gh-pages/stylesheets/stylesheet.css'), prev_run, done); >>>>>>> fs.writeFile(path.join(__dirname, '/output/gh-pages/stylesheets/stylesheet.css'), prevRun, done);
<<<<<<< this.addAddonToProject('ember-moment', '3.2.1') ]; if (!emberDep.isAbove('2.0.0-beta.1')) { dependencies.push(this.addAddonToProject('ember-get-helper', '1.0.1')); } return RSVP.all(dependencies); ======= this.addAddonToProject('ember-moment', '3.6.2') ]); >>>>>>> this.addAddonToProject('ember-moment', '3.6.2') ]; if (!emberDep.isAbove('2.0.0-beta.1')) { dependencies.push(this.addAddonToProject('ember-get-helper', '1.0.1')); } return RSVP.all(dependencies);
<<<<<<< } else if (phase === 'get_dependencies') { let depdendencyTypes = ['globalStyles', 'globalScripts', 'styles', 'scripts']; for (const type of depdendencyTypes) { // For course elements, track dependencies separately so // we can properly construct the URLs let mappedDepType = type; if (context.course_elements.has(elementName)) { if (type === 'styles') { mappedDepType = 'courseStyles'; } else if (type === 'scripts') { mappedDepType = 'courseScripts'; } } ======= } else if (phase === 'dependencies') { for (const type of ['globalStyles', 'globalScripts', 'styles', 'scripts']) { >>>>>>> } else if (phase === 'dependencies') { let depdendencyTypes = ['globalStyles', 'globalScripts', 'styles', 'scripts']; for (const type of depdendencyTypes) { // For course elements, track dependencies separately so // we can properly construct the URLs let mappedDepType = type; if (context.course_elements.has(elementName)) { if (type === 'styles') { mappedDepType = 'courseStyles'; } else if (type === 'scripts') { mappedDepType = 'courseScripts'; } } <<<<<<< const context = module.exports.getContext(question, course); module.exports.processQuestionHtml('get_dependencies', pc, data, context, (err, ret_courseErrs, dependencies) => { ======= const options = { question_dir: path.join(course.path, 'questions', question.directory), }; module.exports.processQuestionHtml('dependencies', pc, data, options, (err, ret_courseErrs, dependencies) => { >>>>>>> const context = module.exports.getContext(question, course); module.exports.processQuestionHtml('dependencies', pc, data, context, (err, ret_courseErrs, dependencies) => {
<<<<<<< ======= courseInfo.gitCourseBranch = config.gitCourseBranch; courseInfo.timezone = config.timezone; courseInfo.currentCourseInstance = info.currentCourseInstance; courseInfo.questionsDir = path.join(courseDir, "questions"); courseInfo.courseInstancesDir = path.join(courseDir, "courseInstances"); courseInfo.testsDir = path.join(courseDir, "tests"); courseInfo.assessmentSets = info.assessmentSets; courseInfo.topics = info.topics; courseInfo.tags = info.tags; that.getCourseOriginURL(function(err, originURL) { courseInfo.remoteFetchURL = originURL; return callback(null); }); }); }; module.exports.loadCourseInstanceInfo = function(courseInfo, courseDir, courseInstance, callback) { var that = this; var courseInfoFilename = path.join(courseDir, "courseInstances", courseInstance, "courseInstanceInfo.json"); jsonLoad.readInfoJSON(courseInfoFilename, "schemas/courseInstanceInfo.json", undefined, undefined, function(err, info) { if (err) return callback(err); courseInfo.courseInstanceShortName = info.shortName; courseInfo.courseInstanceLongName = info.longName; >>>>>>>
<<<<<<< this.config.set('continuousIntegration', this.options.continuousIntegration); ======= this.config.set('pnp-vetting', this.options.vetting); >>>>>>> this.config.set('continuousIntegration', this.options.continuousIntegration); this.config.set('pnp-vetting', this.options.vetting);
<<<<<<< {listSubqueries} <RaisedButton label="Create SubQuery" fullWidth secondary type="submit" onClick={this.submitSubQueryHandler} /> </div> ======= {listSubqueries} <div style={{height: '10px', width: '100%'}} /> </div> >>>>>>> {listSubqueries} <div style={{height: '10px', width: '100%'}} /> <RaisedButton label="Create SubQuery" fullWidth secondary type="submit" onClick={this.submitSubQueryHandler} /> </div>
<<<<<<< if(string){ ======= if (string) { >>>>>>> if(string) { <<<<<<< ======= id="tableName" >>>>>>> id="tableName" <<<<<<< onCheck={this.handleCheck} id='idCheckbox' checked={!!this.props.selectedTable.fields[0]} ======= onCheck={this.handleClick} id="idCheckbox" checked={this.props.database === 'MongoDB' ? true : this.props.tableIDRequested} >>>>>>> onCheck={this.handleCheck} id='idCheckbox' checked={!!this.props.selectedTable.fields[0]}
<<<<<<< ======= {this.props.database !== 'MongoDb' && ( <Toggle label="Auto Increment" toggled={this.props.selectedField.autoIncrement} onToggle={this.handleToggle.bind(null, 'autoIncrement')} style={style.toggle} /> )} >>>>>>>
<<<<<<< if (event.keyCode == 13) this.applyOptionsToSelection(); else if (event.keyCode == 46) this.deleteSelection(); ======= if (event.keyCode == 46) { this.designer.selection.applyToShapes("removeShape"); } else if (event.keyCode == 36) { this.designer.selection.applyToShapes( function(){ this.zOrderMoved = true; this.moveToFront(); // console.log('Move ' + this.objId + ' to front'); } ); this.designer.selection.applyToShapes("save"); } else if (event.keyCode == 35) { this.designer.selection.applyToShapes( function(){ this.zOrderMoved = true; this.moveToBack(); // console.log('Move ' + this.objId + ' to back'); } ); this.designer.selection.applyToShapes("save"); } >>>>>>> if (event.keyCode == 13) { this.applyOptionsToSelection(); } else if (event.keyCode == 46) { this.deleteSelection(); } else if (event.keyCode == 36) { this.designer.selection.applyToShapes( function(){ this.zOrderMoved = true; this.moveToFront(); // console.log('Move ' + this.objId + ' to front'); } ); this.designer.selection.applyToShapes("save"); } else if (event.keyCode == 35) { this.designer.selection.applyToShapes( function(){ this.zOrderMoved = true; this.moveToBack(); // console.log('Move ' + this.objId + ' to back'); } ); this.designer.selection.applyToShapes("save"); }
<<<<<<< getCustomerTitle: getCustomerTitle, ======= getShortCustomerInfo: getShortCustomerInfo, applyAssignedCustomersInfo: applyAssignedCustomersInfo, applyAssignedCustomerInfo: applyAssignedCustomerInfo, >>>>>>> getShortCustomerInfo: getShortCustomerInfo, applyAssignedCustomersInfo: applyAssignedCustomersInfo, applyAssignedCustomerInfo: applyAssignedCustomerInfo, <<<<<<< function getCustomerTitle(customerId) { var deferred = $q.defer(); var url = '/api/customer/' + customerId + '/title'; $http.get(url, null).then(function success(response) { deferred.resolve(response.data); }, function fail(response) { deferred.reject(response.data); }); return deferred.promise; } ======= function getShortCustomerInfo(customerId) { var deferred = $q.defer(); var url = '/api/customer/' + customerId + '/shortInfo'; $http.get(url, null).then(function success(response) { deferred.resolve(response.data); }, function fail(response) { deferred.reject(response.data); }); return deferred.promise; } function applyAssignedCustomersInfo(items) { var deferred = $q.defer(); var assignedCustomersMap = {}; function loadNextCustomerInfoOrComplete(i) { i++; if (i < items.length) { loadNextCustomerInfo(i); } else { deferred.resolve(items); } } function loadNextCustomerInfo(i) { var item = items[i]; item.assignedCustomer = {}; if (item.customerId && item.customerId.id != types.id.nullUid) { item.assignedCustomer.id = item.customerId.id; var assignedCustomer = assignedCustomersMap[item.customerId.id]; if (assignedCustomer){ item.assignedCustomer = assignedCustomer; loadNextCustomerInfoOrComplete(i); } else { getShortCustomerInfo(item.customerId.id).then( function success(info) { assignedCustomer = { id: item.customerId.id, title: info.title, isPublic: info.isPublic }; assignedCustomersMap[assignedCustomer.id] = assignedCustomer; item.assignedCustomer = assignedCustomer; loadNextCustomerInfoOrComplete(i); }, function fail() { loadNextCustomerInfoOrComplete(i); } ); } } else { loadNextCustomerInfoOrComplete(i); } } if (items.length > 0) { loadNextCustomerInfo(0); } else { deferred.resolve(items); } return deferred.promise; } function applyAssignedCustomerInfo(items, customerId) { var deferred = $q.defer(); getShortCustomerInfo(customerId).then( function success(info) { var assignedCustomer = { id: customerId, title: info.title, isPublic: info.isPublic } items.forEach(function(item) { item.assignedCustomer = assignedCustomer; }); deferred.resolve(items); }, function fail() { deferred.reject(); } ); return deferred.promise; } >>>>>>> function getCustomerTitle(customerId) { var deferred = $q.defer(); var url = '/api/customer/' + customerId + '/title'; $http.get(url, null).then(function success(response) { deferred.resolve(response.data); }, function fail(response) { deferred.reject(response.data); }); return deferred.promise; } function getShortCustomerInfo(customerId) { var deferred = $q.defer(); var url = '/api/customer/' + customerId + '/shortInfo'; $http.get(url, null).then(function success(response) { deferred.resolve(response.data); }, function fail(response) { deferred.reject(response.data); }); return deferred.promise; } function applyAssignedCustomersInfo(items) { var deferred = $q.defer(); var assignedCustomersMap = {}; function loadNextCustomerInfoOrComplete(i) { i++; if (i < items.length) { loadNextCustomerInfo(i); } else { deferred.resolve(items); } } function loadNextCustomerInfo(i) { var item = items[i]; item.assignedCustomer = {}; if (item.customerId && item.customerId.id != types.id.nullUid) { item.assignedCustomer.id = item.customerId.id; var assignedCustomer = assignedCustomersMap[item.customerId.id]; if (assignedCustomer){ item.assignedCustomer = assignedCustomer; loadNextCustomerInfoOrComplete(i); } else { getShortCustomerInfo(item.customerId.id).then( function success(info) { assignedCustomer = { id: item.customerId.id, title: info.title, isPublic: info.isPublic }; assignedCustomersMap[assignedCustomer.id] = assignedCustomer; item.assignedCustomer = assignedCustomer; loadNextCustomerInfoOrComplete(i); }, function fail() { loadNextCustomerInfoOrComplete(i); } ); } } else { loadNextCustomerInfoOrComplete(i); } } if (items.length > 0) { loadNextCustomerInfo(0); } else { deferred.resolve(items); } return deferred.promise; } function applyAssignedCustomerInfo(items, customerId) { var deferred = $q.defer(); getShortCustomerInfo(customerId).then( function success(info) { var assignedCustomer = { id: customerId, title: info.title, isPublic: info.isPublic } items.forEach(function(item) { item.assignedCustomer = assignedCustomer; }); deferred.resolve(items); }, function fail() { deferred.reject(); } ); return deferred.promise; }
<<<<<<< // been (re-)rendered // publicChatDataAvailable: this hook runs after data for any of the // public chats has been received and processed, but not // yet been displayed. The data hash contains both the un- // processed raw ajax response as well as the processed // chat data that is going to be used for display. ======= // been (re-)rendered. Provides data about the portal that // has been selected. >>>>>>> // been (re-)rendered Provides data about the portal that // has been selected. // publicChatDataAvailable: this hook runs after data for any of the // public chats has been received and processed, but not // yet been displayed. The data hash contains both the un- // processed raw ajax response as well as the processed // chat data that is going to be used for display.
<<<<<<< var mid = lo + hi >> 1, y = f(a[mid]); if (x <= y || !(y <= y)) hi = mid; else lo = mid + 1; ======= var mid = lo + hi >>> 1; if (f(a[mid]) < x) lo = mid + 1; else hi = mid; >>>>>>> var mid = lo + hi >>> 1, y = f(a[mid]); if (x <= y || !(y <= y)) hi = mid; else lo = mid + 1; <<<<<<< var mid = lo + hi >> 1, y = f(a[mid]); if (x < y || !(y <= y)) hi = mid; ======= var mid = lo + hi >>> 1; if (x < f(a[mid])) hi = mid; >>>>>>> var mid = lo + hi >>> 1, y = f(a[mid]); if (x < y || !(y <= y)) hi = mid;
<<<<<<< + ">default</option>\n <option value=\"ace/keybindings/vim\" " + ((stack1 = (helpers.compare || (depth0 && depth0.compare) || alias1).call(depth0,(depth0 != null ? depth0.keyBindings : depth0),"ace/keybindings/vim",{"name":"compare","hash":{},"fn":this.program(1, data, 0),"inverse":this.noop,"data":data})) != null ? stack1 : "") + ">vim</option>\n <option value=\"ace/keybindings/emacs\" " + ((stack1 = (helpers.compare || (depth0 && depth0.compare) || alias1).call(depth0,(depth0 != null ? depth0.keyBindings : depth0),"ace/keybindings/emacs",{"name":"compare","hash":{},"fn":this.program(1, data, 0),"inverse":this.noop,"data":data})) != null ? stack1 : "") + ">emacs</option>\n </select>\n </div>\n \n <div class=\"form-group\">\n <div style=\"width:10%; max-width: 25%;\">\n <label for=\"fontSize\">Font Size</label>\n <select onchange=\"setFontSize($(this).val());\" class=\"form-control\" id=\"fontSize\" name=\"fontSize\" type=\"number\" value=\"" ======= + ">default</option>\n <option value=\"ace/keyboard/vim\" " + ((stack1 = (helpers.compare || (depth0 && depth0.compare) || alias1).call(depth0,(depth0 != null ? depth0.keyBindings : depth0),"ace/keyboard/vim",{"name":"compare","hash":{},"fn":this.program(1, data, 0),"inverse":this.noop,"data":data})) != null ? stack1 : "") + ">vim</option>\n <option value=\"ace/keyboard/emacs\" " + ((stack1 = (helpers.compare || (depth0 && depth0.compare) || alias1).call(depth0,(depth0 != null ? depth0.keyBindings : depth0),"ace/keyboard/emacs",{"name":"compare","hash":{},"fn":this.program(1, data, 0),"inverse":this.noop,"data":data})) != null ? stack1 : "") + ">emacs</option>\n </select>\n </div>\n <div class=\"form-group\">\n <label for=\"fontSize\">Font Size</label>\n <input onchange=\"setFontSize($(this).val());\" class=\"form-control\" id=\"fontSize\" name=\"fontSize\" type=\"number\" step=\"1\" value=\"" >>>>>>> + ">default</option>\n <option value=\"ace/keyboard/vim\" " + ((stack1 = (helpers.compare || (depth0 && depth0.compare) || alias1).call(depth0,(depth0 != null ? depth0.keyBindings : depth0),"ace/keyboard/vim",{"name":"compare","hash":{},"fn":this.program(1, data, 0),"inverse":this.noop,"data":data})) != null ? stack1 : "") + ">vim</option>\n <option value=\"ace/keyboard/emacs\" " + ((stack1 = (helpers.compare || (depth0 && depth0.compare) || alias1).call(depth0,(depth0 != null ? depth0.keyBindings : depth0),"ace/keyboard/emacs",{"name":"compare","hash":{},"fn":this.program(1, data, 0),"inverse":this.noop,"data":data})) != null ? stack1 : "") + ">emacs</option>\n </select>\n </div>\n \n <div class=\"form-group\">\n <div style=\"width:10%; max-width: 25%;\">\n <label for=\"fontSize\">Font Size</label>\n <select onchange=\"setFontSize($(this).val());\" class=\"form-control\" id=\"fontSize\" name=\"fontSize\" type=\"number\" value=\""
<<<<<<< * @param {String} arg.discordChannel Discord channel ID * @param {String} arg.fromName Display name of the sender ======= * @param {Message} arg.message Display name of the sender >>>>>>> * @param {String} arg.discordChannel Discord channel ID * @param {Message} arg.message Display name of the sender <<<<<<< return function({discordChannel, fromName, fileId, fileName, caption = "", resolveExtension = false}) { ======= return function({message, fileId, fileName, caption = "", resolveExtension = false}) { >>>>>>> return function({discordChannel, message, fileId, fileName, caption = "", resolveExtension = false}) { <<<<<<< return dcBot.channels.get(bridge.discord.channel).send(`**${fromName}**: ${text}`); ======= return dcBot.channels.get(Application.settings.discord.channelID).send(messageObj.composed); >>>>>>> return dcBot.channels.get(bridge.discord.channel).send(messageObj.composed); <<<<<<< discordChannel: bridge.discord.channel, fromName: getDisplayName(message.from, message.chat), ======= message, >>>>>>> discordChannel: bridge.discord.channel, message, <<<<<<< discordChannel: bridge.discord.channel, fromName: getDisplayName(message.from, message.chat), ======= message, >>>>>>> discordChannel: bridge.discord.channel, message, <<<<<<< discordChannel: bridge.discord.channel, fromName: getDisplayName(message.from, message.chat), ======= message, >>>>>>> discordChannel: bridge.discord.channel, message, <<<<<<< discordChannel: bridge.discord.channel, fromName: getDisplayName(message.from, message.chat), ======= message, >>>>>>> discordChannel: bridge.discord.channel, message, <<<<<<< discordChannel: bridge.discord.channel, fromName: getDisplayName(message.from, message.chat), ======= message, >>>>>>> discordChannel: bridge.discord.channel, message, <<<<<<< .catch((err) => Application.logger.error(`[${bridge.name}] Could not edit Discord message:`, err)); })); ======= .catch((err) => { Application.logger.error("Could not edit Discord message:", err); Application.logger.error("Failed message:", message.text); }); }); >>>>>>> .catch((err) => { Application.logger.error("Could not edit Discord message:", err); Application.logger.error("Failed message:", message.text); }); });
<<<<<<< import getNetwork from "../../lib/blockchain/getNetwork"; ======= import { getTruncatedText } from '../../lib/helpers' >>>>>>> import getNetwork from "../../lib/blockchain/getNetwork"; import { getTruncatedText } from '../../lib/helpers' <<<<<<< getNetwork() .then(network => { const { liquidPledging } = network; // set a 2 year commitTime. This is temporary so the campaign acts like a delegate and the donor can // still has control of their funds for upto 2 years. Once we implement campaign reviewers, we can set a // more reasonable commitTime let txHash; liquidPledging.addProject(model.title, 60 * 60 * 24 * 365 * 2, '0x0') .once('transactionHash', hash => { txHash = hash; React.toast.info(`New Campaign transaction hash ${network.etherscan}tx/${txHash}`) }) .then(txReceipt => React.toast.success(`New Campaign transaction mined ${network.etherscan}tx/${txHash}`)) .catch(err => { console.log('New Campaign transaction failed:', err); React.toast.error(`New Campaign transaction failed ${network.etherscan}tx/${txHash}`); }); }) ======= feathersClient.service('campaigns').create(constructedModel) .then(()=> afterEmit(true)) >>>>>>> getNetwork() .then(network => { const { liquidPledging } = network; // set a 2 year commitTime. This is temporary so the campaign acts like a delegate and the donor can // still has control of their funds for upto 2 years. Once we implement campaign reviewers, we can set a // more reasonable commitTime let txHash; liquidPledging.addProject(model.title, 60 * 60 * 24 * 365 * 2, '0x0') .once('transactionHash', hash => { // TODO update txHash = hash; React.toast.info(`New Campaign transaction hash ${network.etherscan}tx/${txHash}`) }) .then(() => { React.toast.success(`New Campaign transaction mined ${network.etherscan}tx/${txHash}`); afterEmit(true); }) .catch(err => { console.log('New Campaign transaction failed:', err); React.toast.error(`New Campaign transaction failed ${network.etherscan}tx/${txHash}`); }); })
<<<<<<< console.log(model, this.props.type.toLowerCase(), this.props.model._id) this.setState({ isSaving: true }); const amount = utils.toWei(model.amount); const service = feathersClient.service('donations'); // TODO will the txHash cause issues when instant mining? const donate = (etherScanUrl, txHash) => service.create({ amount, type: this.props.type.toLowerCase(), type_id: this.props.model._id, txHash, }).then(() =>{ this.setState({ isSaving: false, amount: 10 }); // For some reason (I suspect a rerender when donations are being fetched again) // the skylight dialog is sometimes gone and this throws error if(this.refs.donateDialog) this.refs.donateDialog.hide() if(this.props.type === "DAC") { React.swal("You're awesome!", `You're donation is pending. You have full control of this donation and can take it back at any time. You will also have a 3 day window to veto the use of these funds upon delegation by the dac. Please make sure you join the community to follow progress of this DAC. ${etherScanUrl}tx/${txHash}`, 'success') } else { React.swal("You're awesome!", "You're donation is pending. Please make sure to join the community to follow progress of this project.", 'success') } }); // TODO check for donorId first let txHash; let etherScanUrl; getNetwork() .then((network) => { const { liquidPledging } = network; etherScanUrl = network.etherscan; return liquidPledging.donate(this.state.user.donorId, this.props.model.managerId, { value: amount }) .once('transactionHash', hash => { txHash = hash; donate(etherScanUrl, txHash); }); }) .then(() => { React.toast.success(`Your donation has been confirmed! ${etherScanUrl}tx/${txHash}`); }).catch((e) => { console.log(e); let msg; if (txHash) { msg = `Something went wrong with the transaction. ${etherScanUrl}tx/${txHash}`; //TODO update or remove from feathers? maybe don't remove, so we can inform the user that the tx failed and retry } else { msg = "Something went wrong with the transaction. Is your wallet unlocked?"; } React.swal("Oh no!", msg, 'error'); this.setState({ isSaving: false }); ======= this.setState({ isSaving: true }) feathersClient.service('/donations').create({ amount: parseFloat(model.amount, 10), type: this.props.type.toLowerCase(), type_id: this.props.model._id, status: 'waiting' }).then(user => { this.setState({ isSaving: false, amount: 10 >>>>>>> console.log(model, this.props.type.toLowerCase(), this.props.model._id) this.setState({ isSaving: true }); const amount = utils.toWei(model.amount); const service = feathersClient.service('donations'); // TODO will the txHash cause issues when instant mining? const donate = (etherScanUrl, txHash) => service.create({ amount, type: this.props.type.toLowerCase(), type_id: this.props.model._id, txHash, }).then(() =>{ this.setState({ isSaving: false, amount: 10 }); // For some reason (I suspect a rerender when donations are being fetched again) // the skylight dialog is sometimes gone and this throws error if(this.refs.donateDialog) this.refs.donateDialog.hide() if(this.props.type === "DAC") { React.swal("You're awesome!", `You're donation is pending. You have full control of this donation and can take it back at any time. You will also have a 3 day window to veto the use of these funds upon delegation by the dac. Please make sure you join the community to follow progress of this DAC. ${etherScanUrl}tx/${txHash}`, 'success') } else { React.swal("You're awesome!", "You're donation is pending. Please make sure to join the community to follow progress of this project.", 'success') } }); // TODO check for donorId first let txHash; let etherScanUrl; getNetwork() .then((network) => { const { liquidPledging } = network; etherScanUrl = network.etherscan; return liquidPledging.donate(this.state.user.donorId, this.props.model.managerId, { value: amount }) .once('transactionHash', hash => { txHash = hash; donate(etherScanUrl, txHash); }); }) .then(() => { React.toast.success(`Your donation has been confirmed! ${etherScanUrl}tx/${txHash}`); }).catch((e) => { console.log(e); let msg; if (txHash) { msg = `Something went wrong with the transaction. ${etherScanUrl}tx/${txHash}`; //TODO update or remove from feathers? maybe don't remove, so we can inform the user that the tx failed and retry } else { msg = "Something went wrong with the transaction. Is your wallet unlocked?"; } React.swal("Oh no!", msg, 'error'); this.setState({ isSaving: false }); <<<<<<< render() { const { type, model } = this.props let { isSaving, amount, formIsValid, user } = this.state; ======= render(){ const { type, model, currentUser } = this.props let { isSaving, amount, formIsValid } = this.state const style = { display: 'inline-block' } >>>>>>> render() { const { type, model } = this.props let { isSaving, amount, formIsValid, user } = this.state; const style = { display: 'inline-block' } <<<<<<< <span> <a className={"btn btn-success " + (user && user.donorId ? "" : "disabled")} onClick={() => this.openDialog()}> ======= <span style={style}> <a className={`btn btn-success ${!currentUser ? 'disabled' : ''}`} onClick={() => this.openDialog()}> >>>>>>> <span style={style}> <a className={"btn btn-success " + (user && user.donorId ? "" : "disabled")} onClick={() => this.openDialog()}> <<<<<<< <SkyLight hideOnOverlayClicked ref="donateDialog" title={`Support this ${type}!`} afterOpen={() => this.focusInput()}> <h4>Give Ether to support {model.title}</h4> ======= <SkyLight hideOnOverlayClicked ref="donateDialog" title={`Support this ${type}!`} afterOpen={()=>this.focusInput()}> <strong>Give Ether to support <em>{model.title}</em></strong> >>>>>>> <SkyLight hideOnOverlayClicked ref="donateDialog" title={`Support this ${type}!`} afterOpen={() => this.focusInput()}> <strong>Give Ether to support <em>{model.title}</em></strong>
<<<<<<< this.setState({ //TODO should we filter the available cuases to those that have been mined? It is possible that a createCause tx will fail and the cause will not be available causesOptions: resp.data.map((c) => { return { label: c.title, value: c._id } }), // causesOptions: resp.data.filter((c) => (c.delegateId && c.delegateId > 0)).map((c) => { return { label: c.title, value: c._id} }), ======= this.setState({ causesOptions: resp.data.map((c) => { return { name: c.title, id: c._id, element: <span>{c.title}</span> } }), >>>>>>> this.setState({ //TODO should we filter the available cuases to those that have been mined? It is possible that a createCause tx will fail and the cause will not be available causesOptions: resp.data.map((c) => { return { name: c.title, id: c._id, element: <span>{c.title}</span> } }), // causesOptions: resp.data.filter((c) => (c.delegateId && c.delegateId > 0)).map((c) => { return { label: c.title, value: c._id} }), <<<<<<< projectId: this.state.projectId, causes: [ model.causes ] } ======= causes: this.state.causes, } >>>>>>> projectId: this.state.projectId, causes: this.state.causes, }
<<<<<<< ======= this.authenticate = this.authenticate.bind(this); >>>>>>> <<<<<<< function createWallet() { this.props.wallet.unlock(password) .then(() => authenticate(this.props.wallet)) .then(token => { this.props.onSignIn(); return feathersClient.passport.verifyJWT(token); }) .then(() => this.props.history.goBack()) .catch((err) => { console.error(err); const error = (err.type && err.type === 'FeathersError') ? "authentication error" : "Error unlocking wallet. Possibly an invalid password."; ======= function loadWallet() { GivethWallet.loadWallet(this.state.keystore, this.props.provider, password) .then(wallet => { const address = wallet.getAddresses()[ 0 ]; // find user, if does not exist, too bad. Redirect back. feathersClient.service('/users').get(address) .then(user => this.authenticate(wallet, false)) .catch(err => { if (err.code === 404) { feathersClient.service('/users').create({ address }) .then(user => { this.authenticate(wallet, true); }) } else { this.props.history.goBack(); } }) }) .catch((error) => { console.error(error); >>>>>>> function loadWallet() { this.props.wallet.unlock(password) .then(() => authenticate(this.props.wallet)) .then(token => { this.props.onSignIn(); return feathersClient.passport.verifyJWT(token); }) .then(() => this.props.history.goBack()) .catch((err) => { console.error(err); const error = (err.type && err.type === 'FeathersError') ? "authentication error" : "Error unlocking wallet. Possibly an invalid password.";
<<<<<<< import { feathersClient } from "../lib/feathersClient"; import GivethWallet from '../lib/GivethWallet'; ======= import { socket, feathersClient } from "../lib/feathersClient"; >>>>>>> import { feathersClient } from "../lib/feathersClient"; import GivethWallet from '../lib/GivethWallet'; <<<<<<< unlockWallet: false, cachedWallet: true, ======= userProfile: undefined >>>>>>> unlockWallet: false, cachedWallet: true, userProfile: undefined <<<<<<< <MainMenu authenticated={(this.state.currentUser)} onSignOut={this.onSignOut} wallet={this.state.wallet} unlockWallet={() => this.setState({ unlockWallet: true })} /> ======= <MainMenu authenticated={this.state.currentUser} handleWalletChange={this.handleWalletChange} userProfile={this.state.userProfile}/> >>>>>>> <MainMenu authenticated={(this.state.currentUser)} onSignOut={this.onSignOut} wallet={this.state.wallet} userProfile={this.state.userProfile} unlockWallet={() => this.setState({ unlockWallet: true })} />
<<<<<<< import getNetwork from '../../lib/blockchain/getNetwork'; ======= import _ from 'underscore' import moment from 'moment' >>>>>>> import getNetwork from '../../lib/blockchain/getNetwork'; import _ from 'underscore' import moment from 'moment' <<<<<<< let { donations, isLoading, etherScanUrl } = this.state; ======= let { donations, isLoading, isRefunding, isCommitting } = this.state >>>>>>> let { donations, isLoading, etherScanUrl, isRefunding, isCommitting } = this.state <<<<<<< } ======= <td>{moment(d.createdAt).format("MM/DD/YYYY")}</td> <td> { d.status === 'waiting' && <a className="btn btn-sm btn-danger" onClick={()=>this.refund(d)} disabled={isRefunding}> Refund </a> } { d.status === 'pending' && <a className="btn btn-sm btn-success" onClick={()=>this.commit(d)} disabled={isCommitting}> Commit </a> } </td> >>>>>>> } <td>{moment(d.createdAt).format("MM/DD/YYYY")}</td> <td> { d.status === 'waiting' && <a className="btn btn-sm btn-danger" onClick={()=>this.refund(d)} disabled={isRefunding}> Refund </a> } { d.status === 'pending' && <a className="btn btn-sm btn-success" onClick={()=>this.commit(d)} disabled={isCommitting}> Commit </a> } </td>
<<<<<<< const { history, currentUser } = this.props ======= const { history, wallet, currentUser } = this.props >>>>>>> const { history, wallet, currentUser } = this.props <<<<<<< <DonateButton type="milestone" model={{ title: title, _id: id, managerId: projectId }} currentUser={currentUser}/> ======= <DonateButton type="milestone" model={{ title: title, _id: id }} wallet={wallet} currentUser={currentUser}/> >>>>>>> <DonateButton type="milestone" model={{ title: title, _id: id, managerId: projectId }} wallet={wallet} currentUser={currentUser}/> <<<<<<< <DonateButton type="milestone" model={{ title: title, _id: id, managerId: projectId }} currentUser={currentUser}/> ======= <DonateButton type="milestone" model={{ title: title, _id: id }} wallet={wallet} currentUser={currentUser}/> >>>>>>> <DonateButton type="milestone" model={{ title: title, _id: id, managerId: projectId }} wallet={wallet} currentUser={currentUser}/>
<<<<<<< src: 'emojify.css', dest: 'emojify.min.css' } }, mochaTest: { test: { options: { reporter: 'spec' }, src: ['tests/node/*.js'] } ======= files: { 'emojify.min.css': 'emojify.css', 'emojify-emoticons.min.css': 'emojify-emoticons.css', } } }, datauri: { production: { options: { classPrefix: 'emoji-' }, files: { 'emojify.css': 'images/emoji/*.png', 'emojify-emoticons.css': 'images/emoji/{blush,scream,smirk,smiley,stuck_out_tongue_closed_eyes,stuck_out_tongue_winking_eye,rage,disappointed,sob,kissing_heart,wink,pensive,confounded,flushed,relaxed,mask,heart,broken_heart}.png' } } >>>>>>> files: { 'emojify.min.css': 'emojify.css', 'emojify-emoticons.min.css': 'emojify-emoticons.css', } } }, datauri: { production: { options: { classPrefix: 'emoji-' }, files: { 'emojify.css': 'images/emoji/*.png', 'emojify-emoticons.css': 'images/emoji/{blush,scream,smirk,smiley,stuck_out_tongue_closed_eyes,stuck_out_tongue_winking_eye,rage,disappointed,sob,kissing_heart,wink,pensive,confounded,flushed,relaxed,mask,heart,broken_heart}.png' } } }, mochaTest: { test: { options: { reporter: 'spec' }, src: ['tests/node/*.js'] } <<<<<<< grunt.loadNpmTasks('grunt-mocha-test'); ======= grunt.loadNpmTasks('grunt-datauri'); >>>>>>> grunt.loadNpmTasks('grunt-datauri');
<<<<<<< import * as D3Chart from './createTree.js'; import $ from 'jquery'; ======= import createTree from './createTree.js'; import $ from 'jquery'; >>>>>>> import * as D3Chart from './createTree.js'; import $ from 'jquery'; <<<<<<< cache.addToHead(msg); currentState = cache.head; treeInput = currentState.value.data.currentState[0]; console.log('TREE DATA', treeInput); D3Chart.createTree(treeInput); // reactData = cache.head.value.data.currentState[0]; // prevNode = cache.head.prev; // cleanData = getChildren(reactData); ======= cache.addToHead(msg.data); currentState = cache.head; treeInput = currentState.value.data.currentState[0]; console.log('TREE DATA', treeInput); createTree(treeInput); // reactData = cache.head.value.data.currentState[0]; // prevNode = cache.head.prev; // cleanData = getChildren(reactData); >>>>>>> cache.addToHead(msg.data); currentState = cache.head; treeInput = currentState.value.data.currentState[0]; console.log('TREE DATA', treeInput); D3Chart.createTree(treeInput); // reactData = cache.head.value.data.currentState[0]; // prevNode = cache.head.prev; // cleanData = getChildren(reactData); <<<<<<< } //on click functionality: //current state variable that starts a this.head; //currentState.value holds the data; //click events: ////next: currentState = currentState.next; ////prev: currentState = currentState.prev; ////oldest: currentState = cache.tail; ////newest: currentState = cache.head; $(document).ready(function() { $('#optimize').click(function() { console.log('Optimize') $('#opt').empty(); curr = getChildren(cache.head.value.data.currentState[0]) prev = getChildren(cache.head.prev.value.data.currentState[0]) console.log('curr', curr) console.log('prev', prev) console.log('click cache', cache) let result = checkOptComponents(curr,prev, cache) // stored optimize data console.log('results!!!!!!', result) $('#opt').append("<p>stateful Comp being re-rendered w/o state changes:"+ JSON.stringify(result[0], null, 2)+ "</p>"); $('#opt').append("<p>stateful Comp that are re-rendered w/ state changes:"+ JSON.stringify(result[1], null, 2)+ "</p>"); $('#opt').append("<p>All components re-render w/o state changes:"+ JSON.stringify(result[2], null, 2)+ "</p>"); Object.keys(result[0]).forEach(val=> { console.log('checking val!!!!~~~~',val) $('#'+val+'').css('fill', 'pink') }) // D3Chart.createTree(currentState.value.data.currentState[0], result); }) $('#oldestBtn').click(function() { console.log('Tail') $('#nodeData').empty(); $('#opt').empty(); currentState = cache.tail; D3Chart.createTree(currentState.value.data.currentState[0]); }) $('#newestBtn').click(function() { console.log('Head') $('#nodeData').empty(); $('#opt').empty(); currentState = cache.head; D3Chart.createTree(currentState.value.data.currentState[0]); }) $('#prevBtn').click(function() { console.log('Prev') $('#nodeData').empty(); $('#opt').empty(); currentState = currentState.prev; D3Chart.createTree(currentState.value.data.currentState[0]); }) $('#nextBtn').click(function() { console.log('Next') $('#nodeData').empty(); $('#opt').empty(); currentState = currentState.next; D3Chart.createTree(currentState.value.data.currentState[0]); }) }); //to check which stateful components are being re-rendered without having any state changes //the currentArray and prevArray are the return values of getChildren(cache.head.value.data.currentState[0]) and getChildren(cache.head.prev.value.data.currentState[0]) ======= } // clear cache on refresh of application chrome.runtime.onMessage.addListener(function(req, sender, res) { if (req.refresh === 'true') { cache.head = cache.tail = null; cache.length = 0; } }); $(document).ready(function() { const stateStatus = (state) => state.value.data.currentState[0]; $('#oldestBtn').click(function() { $('#nodeData').empty(); currentState = cache.tail; createTree(stateStatus(currentState)); }); $('#newestBtn').click(function() { $('#nodeData').empty(); currentState = cache.head; createTree(stateStatus(currentState)); }); $('#prevBtn').click(function() { $('#nodeData').empty(); currentState = currentState.prev; createTree(stateStatus(currentState)); }); $('#nextBtn').click(function() { $('#nodeData').empty(); currentState = currentState.next; createTree(stateStatus(currentState)); }); }); // to check which stateful components are being re-rendered without having any state changes // the currentArray and prevArray are the return values of getChildren(cache.head.value.data.currentState[0]) // and getChildren(cache.head.prev.value.data.currentState[0]) >>>>>>> } // clear cache on refresh of application chrome.runtime.onMessage.addListener(function(req, sender, res) { if (req.refresh === 'true') { cache.head = cache.tail = null; cache.length = 0; } }); $(document).ready(function() { const stateStatus = (state) => state.value.data.currentState[0]; // $('#optimize').click(function() { // test - optimization // console.log('Optimize') // $('#opt').empty(); // curr = getChildren(cache.head.value.data.currentState[0]) // prev = getChildren(cache.head.prev.value.data.currentState[0]) // console.log('curr', curr) // console.log('prev', prev) // console.log('click cache', cache) // let result = checkOptComponents(curr,prev, cache) // stored optimize data // console.log('results!!!!!!', result) // $('#opt').append("<p>stateful Comp being re-rendered w/o state changes:"+ JSON.stringify(result[0], null, 2)+ "</p>"); // $('#opt').append("<p>stateful Comp that are re-rendered w/ state changes:"+ JSON.stringify(result[1], null, 2)+ "</p>"); // $('#opt').append("<p>All components re-render w/o state changes:"+ JSON.stringify(result[2], null, 2)+ "</p>"); // Object.keys(result[0]).forEach(val=> { // console.log('checking val!!!!~~~~',val) // $('#'+val+'').css('fill', 'pink') // }) // }); $('#oldestBtn').click(function() { $('#nodeData').empty(); // $('#opt').empty(); currentState = cache.tail; D3Chart.createTree(stateStatus(currentState)); }); $('#newestBtn').click(function() { $('#nodeData').empty(); // $('#opt').empty(); currentState = cache.head; D3Chart.createTree(stateStatus(currentState)); }); $('#prevBtn').click(function() { $('#nodeData').empty(); // $('#opt').empty(); currentState = currentState.prev; D3Chart.createTree(stateStatus(currentState)); }); $('#nextBtn').click(function() { $('#nodeData').empty(); // $('#opt').empty(); currentState = currentState.next; D3Chart.createTree(stateStatus(currentState)); }); }); // to check which stateful components are being re-rendered without having any state changes // the currentArray and prevArray are the return values of getChildren(cache.head.value.data.currentState[0]) // and getChildren(cache.head.prev.value.data.currentState[0]) <<<<<<< let count = 0; let current = cache.head; console.log("before previous") let previous = cache.head.prev console.log("is it going in?") console.log("inside opt function", previous) while (current!== null && previous !== null && JSON.stringify(current.value.data) === JSON.stringify(previous.value.data)) { count++ ======= let count = 0; let current = cache.head; let previous = cache.head.prev; while ( current !== null && previous !== null && JSON.stringify(current.value.data) === JSON.stringify(previous.value.data) ) { count++; >>>>>>> let count = 0; let current = cache.head; let previous = cache.head.prev; while ( current !== null && previous !== null && JSON.stringify(current.value.data) === JSON.stringify(previous.value.data) ) { count++; <<<<<<< console.log('All components are being re-rendered without any state changes at all for: ', count, " time(s).") return [badRendered,goodRendered,count]; ======= console.log( 'All components are being re-rendered without any state changes at all for: ', count, ' time(s).' ); return; >>>>>>> console.log( 'All components are being re-rendered without any state changes at all for: ', count, ' time(s).' ); return;
<<<<<<< ======= if (!powercord.account || !this.settings['pc-general'].get('settingsSync', false)) { return; } const settings = {}; Object.keys(this.settings).forEach(category => { settings[category] = this.settings[category].config; }); >>>>>>> if (!powercord.account || !this.settings['pc-general'].get('settingsSync', false)) { return; } <<<<<<< const passphrase = this.store.getSetting('pc-general', 'passphrase', ''); const token = this.store.getSetting('pc-general', 'powercordToken'); const baseUrl = this.store.getSetting('pc-general', 'backendURL', WEBSITE); ======= if (!powercord.account || !this.settings['pc-general'].get('settingsSync', false)) { return; } const passphrase = this.get('pc-general', 'passphrase', ''); const token = this.get('pc-general', 'powercordToken'); const baseUrl = this.get('pc-general', 'backendURL', WEBSITE); >>>>>>> if (!powercord.account || !this.settings['pc-general'].get('settingsSync', false)) { return; } const passphrase = this.store.getSetting('pc-general', 'passphrase', ''); const token = this.store.getSetting('pc-general', 'powercordToken'); const baseUrl = this.store.getSetting('pc-general', 'backendURL', WEBSITE);
<<<<<<< // request url case if (config.testmodule === 'request') { data.path = (swagger.schemes !== undefined ? swagger.schemes[0] : 'http') + '://' + (swagger.host !== undefined ? swagger.host : 'localhost:10010'); ======= // request url vs. supertest path if (config.testModule === 'request') { data.url = swagger.schemes[0] + '://' + swagger.host + (swagger.basePath !== undefined ? swagger.basePath : '') + path; } else { data.path = (swagger.basePath !== undefined ? swagger.basePath : '') + path; >>>>>>> // request url case if (config.testModule === 'request') { data.path = (swagger.schemes !== undefined ? swagger.schemes[0] : 'http') + '://' + (swagger.host !== undefined ? swagger.host : 'localhost:10010'); <<<<<<< // no specified paths to build, so build all of them if (config.pathNames.length === 0) { ======= if (config.pathName.length === 0) { >>>>>>> // no specified paths to build, so build all of them if (config.pathName.length === 0) {
<<<<<<< res.set('Access-Control-Allow-Origin', '*'); if (allowHeaders) { var headers = Array.isArray(allowHeaders) ? allowHeaders.join(',') : allowHeaders; res.set('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept, ' + headers); } else { res.set('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept'); } ======= res.set('Access-Control-Allow-Origin', req.headers.origin || '*'); res.set('Access-Control-Allow-Credentials', 'true'); res.set('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept'); >>>>>>> res.set('Access-Control-Allow-Origin', req.headers.origin || '*'); res.set('Access-Control-Allow-Credentials', 'true'); if (allowHeaders) { var headers = Array.isArray(allowHeaders) ? allowHeaders.join(',') : allowHeaders; res.set('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept, ' + headers); } else { res.set('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept'); }
<<<<<<< constructor($containerElement, utils, initCallback, defaultZoomLevel, dontFitMapBounds, disableScrollZooming, minZoomLevel, mapProvider) { ======= constructor($containerElement, utils, initCallback, defaultZoomLevel, dontFitMapBounds, minZoomLevel, mapProvider, credentials) { >>>>>>> constructor($containerElement, utils, initCallback, defaultZoomLevel, dontFitMapBounds, disableScrollZooming, minZoomLevel, mapProvider, credentials) { <<<<<<< if (disableScrollZooming) { this.map.scrollWheelZoom.disable(); } var tileLayer = mapProvider.isCustom ? L.tileLayer(mapProvider.name) : L.tileLayer.provider(mapProvider.name); ======= this.map = L.map($containerElement[0]).setView([0, 0], this.defaultZoomLevel || 8); >>>>>>> if (disableScrollZooming) { this.map.scrollWheelZoom.disable(); } this.map = L.map($containerElement[0]).setView([0, 0], this.defaultZoomLevel || 8);
<<<<<<< $scope.seconds = Math.floor(($scope.millis / 1000) % 60); $scope.secondsS = $scope.seconds==1 ? '' : 's'; $scope.minutes = Math.floor((($scope.millis / (60000)) % 60)); $scope.minutesS = $scope.minutes==1 ? '' : 's'; $scope.hours = Math.floor((($scope.millis / (3600000)) % 24)); $scope.hoursS = $scope.hours==1 ? '' : 's'; $scope.days = Math.floor((($scope.millis / (3600000)) / 24)); $scope.daysS = $scope.days==1 ? '' : 's'; } ======= $scope.seconds = Math.floor(($scope.millis / 1000) % 60); $scope.minutes = Math.floor((($scope.millis / (60000)) % 60)); $scope.hours = Math.floor((($scope.millis / (3600000)) % 24)); $scope.days = Math.floor((($scope.millis / (3600000)) / 24)); //add leading zero if number is smaller than 10 $scope.sseconds = $scope.seconds < 10 ? '0' + $scope.seconds : $scope.seconds; $scope.mminutes = $scope.minutes < 10 ? '0' + $scope.minutes : $scope.minutes; $scope.hhours = $scope.hours < 10 ? '0' + $scope.hours : $scope.hours; $scope.ddays = $scope.days < 10 ? '0' + $scope.days : $scope.days; >>>>>>> $scope.seconds = Math.floor(($scope.millis / 1000) % 60); $scope.secondsS = $scope.seconds==1 ? '' : 's'; $scope.minutes = Math.floor((($scope.millis / (60000)) % 60)); $scope.minutesS = $scope.minutes==1 ? '' : 's'; $scope.hours = Math.floor((($scope.millis / (3600000)) % 24)); $scope.hoursS = $scope.hours==1 ? '' : 's'; $scope.days = Math.floor((($scope.millis / (3600000)) / 24)); $scope.daysS = $scope.days==1 ? '' : 's'; //add leading zero if number is smaller than 10 $scope.sseconds = $scope.seconds < 10 ? '0' + $scope.seconds : $scope.seconds; $scope.mminutes = $scope.minutes < 10 ? '0' + $scope.minutes : $scope.minutes; $scope.hhours = $scope.hours < 10 ? '0' + $scope.hours : $scope.hours; $scope.ddays = $scope.days < 10 ? '0' + $scope.days : $scope.days;
<<<<<<< var colors = []; for (var i = 0; i < ctx.data.length; i++) { var series = ctx.data[i]; colors.push(series.dataKey.color); var keySettings = series.dataKey.settings; series.lines = { fill: keySettings.fillLines === true, show: this.chartType === 'line' ? keySettings.showLines !== false : keySettings.showLines === true }; series.points = { show: false, radius: 8 }; if (keySettings.showPoints === true) { series.points.show = true; series.points.lineWidth = 5; series.points.radius = 3; } if (this.chartType === 'line' && settings.smoothLines && !series.points.show) { series.curvedLines = { apply: true } } var lineColor = tinycolor(series.dataKey.color); lineColor.setAlpha(.75); series.highlightColor = lineColor.toRgbString(); } ======= >>>>>>> if (this.chartType === 'line' && settings.smoothLines && !series.points.show) { series.curvedLines = { apply: true } }
<<<<<<< $startDialog.dialog({ title: 'Welcome to @NAME@!', dialogClass: 'tour', modal: true, width: 700, height: 'auto', draggable: false, resizable: false }); ======= $startDialog .dialog({ title: 'Welcome to @NAME@!', dialogClass: 'tour', modal: true, width: 700, height: 'auto', draggable: false, resizable: false, closeText: '' }); >>>>>>> $startDialog.dialog({ title: 'Welcome to @NAME@!', dialogClass: 'tour', modal: true, width: 700, height: 'auto', draggable: false, resizable: false, closeText: '' }); <<<<<<< $dialog.dialog({ title: 'Finished!', dialogClass: 'tour', modal: true, width: 600, height: 'auto', draggable: false, resizable: false }); ======= $dialog .dialog({ title: 'Finished!', dialogClass: 'tour', modal: true, width: 600, height: 'auto', draggable: false, resizable: false, closeText: '' }); >>>>>>> $dialog.dialog({ title: 'Finished!', dialogClass: 'tour', modal: true, width: 600, height: 'auto', draggable: false, resizable: false, closeText: '' }); <<<<<<< $('.ui-dialog-content').dialog('close'); $('#joyRideTipContent').joyride({ autoStart: true, includepage: true, template: { link: '<a href="#" class="joyride-close-tip">X</a>' }, postStepCallback: function(index, tip) { if (index === 5) { endTour(); ======= $('.ui-dialog-content') .dialog('close'); $('#joyRideTipContent') .joyride({ scroll: false, autoStart: true, includepage: true, template: { 'link': '<a href="#" class="joyride-close-tip">X</a>' }, postStepCallback: function (index, tip) { if (index === 5) { endTour(); } >>>>>>> $('.ui-dialog-content').dialog('close'); $('#joyRideTipContent').joyride({ scroll: false, autoStart: true, includepage: true, template: { link: '<a href="#" class="joyride-close-tip">X</a>' }, postStepCallback: function(index, tip) { if (index === 5) { endTour(); <<<<<<< $('#joyRideTipContent').joyride({ autoStart: true, includepage: true, template: { link: '<a href="#" class="joyride-close-tip">X</a>' }, postStepCallback: onStop }); ======= $('#joyRideTipContent') .joyride({ scroll: false, autoStart: true, includepage: true, template: { 'link': '<a href="#" class="joyride-close-tip">X</a>' }, postStepCallback: onStop }); >>>>>>> $('#joyRideTipContent').joyride({ scroll: false, autoStart: true, includepage: true, template: { link: '<a href="#" class="joyride-close-tip">X</a>' }, postStepCallback: onStop });
<<<<<<< if (!isDistractionFreeModeActive && window.location.search === '') return; // Nothing to reset var msg = 'Do you want to reset Worldview to its defaults? You will lose your current state.'; if (confirm(msg)) { ======= if (window.location.search === '') return; // Nothing to reset const msg = 'Do you want to reset Worldview to its defaults? You will lose your current state.'; if (window.confirm(msg)) { >>>>>>> if (!isDistractionFreeModeActive && window.location.search === '') return; // Nothing to reset const msg = 'Do you want to reset Worldview to its defaults? You will lose your current state.'; if (confirm(msg)) { <<<<<<< className={`${isDistractionFreeModeActive ? 'wv-logo-distraction-free-mode' : ''}`} onClick={(e) => resetWorldview(e, isDistractionFreeModeActive)} ref={iconElement => (this.iconElement = iconElement)} ======= onClick={resetWorldview} // eslint-disable-next-line no-return-assign ref={(iconElement) => (this.iconElement = iconElement)} >>>>>>> onClick={resetWorldview} // eslint-disable-next-line no-return-assign ref={(iconElement) => (this.iconElement = iconElement)} <<<<<<< style={{ maxHeight: isCollapsed ? '0' : screenHeight + 'px', display: isDistractionFreeModeActive ? 'none' : 'block' }} ======= style={ isCollapsed ? { maxHeight: '0' } : { maxHeight: `${screenHeight}px` } } >>>>>>> style={ isCollapsed ? { maxHeight: '0' } : { maxHeight: `${screenHeight}px` } } <<<<<<< events, ui ======= events, >>>>>>> events, ui, <<<<<<< config, isDistractionFreeModeActive ======= config, >>>>>>> config, isDistractionFreeModeActive,
<<<<<<< endColor: PropTypes.string, ======= axisWidth: PropTypes.number, position: PropTypes.number, transformX: PropTypes.number, timeScale: PropTypes.string, frontDate: PropTypes.string, timelineStartDateLimit: PropTypes.string, timelineEndDateLimit: PropTypes.string, startLocation: PropTypes.number, >>>>>>> axisWidth: PropTypes.number, <<<<<<< endTriangleColor: PropTypes.string, frontDate: PropTypes.string, ======= >>>>>>> endTriangleColor: PropTypes.string, frontDate: PropTypes.string, <<<<<<< onDrag: PropTypes.func, parentOffset: PropTypes.number, pinWidth: PropTypes.number, position: PropTypes.number, ======= pinWidth: PropTypes.number, rangeOpacity: PropTypes.number, >>>>>>> onDrag: PropTypes.func, parentOffset: PropTypes.number, pinWidth: PropTypes.number, position: PropTypes.number, <<<<<<< timelineEndDateLimit: PropTypes.string, timelineStartDateLimit: PropTypes.string, timeScale: PropTypes.string, transformX: PropTypes.number, updateAnimationDateAndLocation: PropTypes.func, width: PropTypes.number ======= endColor: PropTypes.string, endTriangleColor: PropTypes.string, updateAnimationDateAndLocation: PropTypes.func >>>>>>> timelineEndDateLimit: PropTypes.string, timelineStartDateLimit: PropTypes.string, timeScale: PropTypes.string, transformX: PropTypes.number, updateAnimationDateAndLocation: PropTypes.func, width: PropTypes.number
<<<<<<< ui.timeline.data = timelineData(models, config, ui); ui.timeline.zoom = timelineZoom(models, config, ui); ui.timeline.ticks = timelineTicks(models, config, ui); ui.timeline.pick = timelinePick(models, config, ui); ui.timeline.pan = timelinePan(models, config, ui); ui.timeline.input = timelineInput(models, config, ui, store); ui.timeline.config = timelineConfig(models, config, ui); ======= // ui.timeline.data = timelineData(models, config, ui); // ui.timeline.zoom = timelineZoom(models, config, ui); // ui.timeline.ticks = timelineTicks(models, config, ui); // ui.timeline.pick = timelinePick(models, config, ui); // ui.timeline.pan = timelinePan(models, config, ui); // ui.timeline.input = timelineInput(models, config, ui); // ui.timeline.config = timelineConfig(models, config, ui); >>>>>>> // ui.timeline.data = timelineData(models, config, ui); // ui.timeline.zoom = timelineZoom(models, config, ui); // ui.timeline.ticks = timelineTicks(models, config, ui); // ui.timeline.pick = timelinePick(models, config, ui); // ui.timeline.pan = timelinePan(models, config, ui); // ui.timeline.input = timelineInput(models, config, ui); // ui.timeline.config = timelineConfig(models, config, ui); <<<<<<< ======= // FIXME: Old hack $(window).resize(function() { if (util.browser.small) { $('#productsHoldertabs li.first a').trigger('click'); } if (!ui.timeline) { timelineInit(); } }); >>>>>>>
<<<<<<< config.pageLoadTime = new Date(); ======= config.now = parameters.now ? util.parseDateUTC(parameters.now) || new Date() : new Date(); >>>>>>> config.pageLoadTime = parameters.now ? util.parseDateUTC(parameters.now) || new Date() : new Date();
<<<<<<< this.map = new TbOpenStreetMap($element, this.utils, initCallback, this.defaultZoomLevel, this.dontFitMapBounds, settings.disableScrollZooming, minZoomLevel, settings.mapProvider); ======= let openStreetMapProvider = {}; if (settings.useCustomProvider && settings.customProviderTileUrl) { openStreetMapProvider.name = settings.customProviderTileUrl; openStreetMapProvider.isCustom = true; } else { openStreetMapProvider.name = settings.mapProvider; } this.map = new TbOpenStreetMap($element, this.utils, initCallback, this.defaultZoomLevel, this.dontFitMapBounds, minZoomLevel, openStreetMapProvider); >>>>>>> let openStreetMapProvider = {}; if (settings.useCustomProvider && settings.customProviderTileUrl) { openStreetMapProvider.name = settings.customProviderTileUrl; openStreetMapProvider.isCustom = true; } else { openStreetMapProvider.name = settings.mapProvider; } this.map = new TbOpenStreetMap($element, this.utils, initCallback, this.defaultZoomLevel, this.dontFitMapBounds, settings.disableScrollZooming, minZoomLevel, openStreetMapProvider);
<<<<<<< this.runPlanUrl = this.base_url + '/run-plan' this.runProtocolUrl = this.base_url + '/run' ======= this.jogToContainerUrl = this.base_url + '/move_to_container' this.jogToPlungerUrl = this.base_url + '/move_to_plunger_position' >>>>>>> this.runPlanUrl = this.base_url + '/run-plan' this.runProtocolUrl = this.base_url + '/run' this.jogToContainerUrl = this.base_url + '/move_to_container' this.jogToPlungerUrl = this.base_url + '/move_to_plunger_position' <<<<<<< getRunPlan () { return Vue.http .get(this.runPlanUrl) .then((response) => { if (response.body.status == 'success') { return response.body.data || [] } return [] }, (response) => { console.log('failed', response) }) } runProtocol () { return Vue.http .get(this.runProtocolUrl) .then((response) => { console.log("Protocol run successfully initiated", response) }, (response) => { console.log("Protocol run failed to execute", response) }) } pauseProtocol () { return Vue.http .get(this.pauseProtocolUrl) .then((response) => { console.log("success", response) }, (response) => { console.log('failed', response) }) } resumeProtocol () { return Vue.http .get(this.resumeProtocolUrl) .then((response) => { console.log("success", response) }, (response) => { console.log('failed', response) }) } ======= calibrate(data, type) { return Vue.http .post(`${this.base_url}/calibrate_${type}`, JSON.stringify(data), {emulateJSON: true}) .then((response) => { let tasks = response.body.data.calibrations addHrefs(tasks) return tasks }, (response) => { console.log('failed', response) return false }) } >>>>>>> getRunPlan () { return Vue.http .get(this.runPlanUrl) .then((response) => { if (response.body.status == 'success') { return response.body.data || [] } return [] }, (response) => { console.log('failed', response) }) } runProtocol () { return Vue.http .get(this.runProtocolUrl) .then((response) => { console.log("Protocol run successfully initiated", response) }, (response) => { console.log("Protocol run failed to execute", response) }) } pauseProtocol () { return Vue.http .get(this.pauseProtocolUrl) .then((response) => { console.log("success", response) }, (response) => { console.log('failed', response) }) } resumeProtocol () { return Vue.http .get(this.resumeProtocolUrl) .then((response) => { console.log("success", response) }, (response) => { console.log('failed', response) }) } calibrate(data, type) { return Vue.http .post(`${this.base_url}/calibrate_${type}`, JSON.stringify(data), {emulateJSON: true}) .then((response) => { let tasks = response.body.data.calibrations addHrefs(tasks) return tasks }, (response) => { console.log('failed', response) return false }) }
<<<<<<< export { default as stub } from './stub'; export { parse as mapParser } from './map/wv.map.js'; ======= export { stub, stub2 } from './stub'; export { polyfill } from './polyfill'; export { util } from './util/util'; >>>>>>> export { stub, stub2 } from './stub'; export { polyfill } from './polyfill'; export { util } from './util/util'; export { parse } from './map/wv.map.js';
<<<<<<< ======= // Date import { parse as dateParser } from './date/date'; import { dateModel } from './date/model'; import { dateLabel } from './date/label'; import dateWheels from './date/wheels'; // Timeline import { timeline } from './date/timeline'; import { timelineData } from './date/timeline-data'; // remove // import { timelineConfig } from './date/config'; // replaced // import { timelineZoom } from './date/timeline-zoom'; // replaced // import { timelineTicks } from './date/timeline-ticks'; // replaced // import { timelinePick } from './date/timeline-pick'; // replaced // import { timelinePan } from './date/timeline-pan'; // replaced // import { timelineInput } from './date/timeline-input'; // import { timelineCompare } from './date/compare-picks'; // Layers import { parse as layerParser, validate as layerValidate } from './layers/layers'; import { layersModel } from './layers/model'; import { layersModal } from './layers/modal'; import { layersActive } from './layers/active'; import { layersOptions } from './layers/options'; import { sidebarUi } from './sidebar/ui'; // Map import { mapParser } from './map/map'; import { mapModel } from './map/model'; import { mapui } from './map/ui'; import { MapRotate } from './map/rotation'; import { MapRunningData } from './map/runningdata'; import { mapLayerBuilder } from './map/layerbuilder'; import { mapDateLineBuilder } from './map/datelinebuilder'; import { mapPrecacheTile } from './map/precachetile'; import { mapAnimate } from './map/animate'; >>>>>>> <<<<<<< > <div id="timeline-header"> <div id="date-selector-main" /> <div id="zoom-buttons-group"> <div id="zoom-btn-container"> <span id="current-zoom" className="zoom-btn zoom-btn-active" data-zoom="3" > Days </span> <div className="wv-tooltip"> <div id="timeline-zoom" className="timeline-zoom"> <span id="zoom-years" className="zoom-btn zoom-btn-inactive zoom-years" data-zoom="1" > Years </span> <span id="zoom-months" className="zoom-btn zoom-btn-inactive zoom-months" data-zoom="2" > Months </span> <span id="zoom-days" className="zoom-btn zoom-btn-inactive zoom-days" data-zoom="3" > Days </span> <span id="zoom-minutes" className="zoom-btn zoom-btn-inactive zoom-minutes" data-zoom="4" > Minutes </span> </div> </div> </div> <div className="button-action-group" id="left-arrow-group" title="Click and hold to animate backwards" > <svg id="timeline-svg" width="24" height="30"> <path d="M 10.240764,0 24,15 10.240764,30 0,30 13.759236,15 0,0 10.240764,0 z" className="arrow" /> </svg> </div> <div className="button-action-group" id="right-arrow-group" title="Click and hold to animate forwards" > <svg width="24" height="30"> <path d="M 10.240764,0 24,15 10.240764,30 0,30 13.759236,15 0,0 10.240764,0 z" className="arrow" /> </svg> </div> </div> <div className="button-action-group animate-button" id="animate-button" title="Set up animation" > <i id="wv-animate" className="fas fa-video wv-animate" /> </div> </div> <div id="timeline-footer"> <div id="wv-animation-widet-case"> </div> </div> <div id="timeline-hide"> <svg className="hamburger" width="10" height="9"> <path d="M 0,0 0,1 10,1 10,0 0,0 z M 0,4 0,5 10,5 10,4 0,4 z M 0,8 0,9 10,9 10,8 0,8 z" /> </svg> </div> </section> <OlCoordinates mouseEvents={this.props.mapMouseEvents} /> <Modal /> ======= ></section> <OlCoordinates mouseEvents={this.mapMouseEvents} /> >>>>>>> ></section> <OlCoordinates mouseEvents={this.props.mapMouseEvents} /> <<<<<<< ======= // HACK: Map needs to be created before the data download model var mapComponents = { Rotation: MapRotate, Runningdata: MapRunningData, Layerbuilder: mapLayerBuilder, Dateline: mapDateLineBuilder, Precache: mapPrecacheTile }; ui.map = mapui(models, config, mapComponents); registerMapMouseHandlers(ui.map.proj, self.mapMouseEvents); ui.map.animate = mapAnimate(models, config, ui); if (config.features.animation) { models.anim = animationModel(models, config); models.link.register(models.anim); } if (config.features.dataDownload) { models.data = dataModel(models, config); models.link.register(models.data); } if (config.features.naturalEvents) { models.naturalEvents = naturalEventsModel(models, config, ui); models.link.register(models.naturalEvents); } if (config.features.tour) { models.tour = tourModel(config, ui); models.link.register(models.tour); } // HACK: Map needs permalink state loaded before starting. But // data download now needs it too. models.link.load(state); // needs to be loaded twice elapsed('ui'); // Create widgets ui.alert = alertUi(ui); ui.proj = projectionUi(models, config); ui.sidebar = sidebarUi(models, config, ui); ui.tour = tourUi(models, ui, config); ui.activeLayers = layersActive(models, ui, config); ui.addModal = layersModal(models, ui, config); ui.layerSettingsModal = layersOptions(models, ui, config); // Test via a getter in the options object to see if the passive property is accessed ui.supportsPassive = false; try { var opts = Object.defineProperty({}, 'passive', { get: function() { ui.supportsPassive = true; } }); window.addEventListener('testPassive', null, opts); window.removeEventListener('testPassive', null, opts); } catch (e) {} function timelineInit() { ui.timeline = timeline(models, config, ui); // ui.timeline.data = timelineData(models, config, ui); // ui.timeline.zoom = timelineZoom(models, config, ui); // ui.timeline.ticks = timelineTicks(models, config, ui); // ui.timeline.pick = timelinePick(models, config, ui); // ui.timeline.pan = timelinePan(models, config, ui); // ui.timeline.input = timelineInput(models, config, ui); // ui.timeline.config = timelineConfig(models, config, ui); if (config.features.animation) { ui.anim = {}; ui.anim.rangeselect = animationRangeSelect(models, config, ui); // SETS STATE: NEEDS TO LOAD BEFORE ANIMATION WIDGET ui.anim.widget = animationWidget(models, config, ui); ui.anim.gif = animationGif(models, config, ui); ui.anim.ui = animationUi(models, ui); } if (config.features.compare) { // # need to trigger that it is active somewhere in new timeline parent object // ui.timeline.compare = timelineCompare(models, config, ui); } ui.dateLabel = dateLabel(models); } // TODO: config.startDate doesn't work anymore?!?! if (config.startDate) { if (!util.browser.small) { // If mobile device, do not build timeline timelineInit(); } // TODO: date wheels break now ui.dateWheels = dateWheels(models, config); } ui.rubberband = imageRubberband(models, ui, config); ui.image = imagePanel(models, ui, config); if (config.features.dataDownload) { ui.data = dataUi(models, ui, config); } if (config.features.naturalEvents) { var request = naturalEventsRequest(models, ui, config); ui.naturalEvents = naturalEventsUI(models, ui, config, request); } ui.link = linkUi(models, config); ui.info = uiInfo(ui, config); if (config.features.notification) { ui.notification = notificationsUi(ui, config); } if (config.features.compare) { ui.compare = compareUi(models, ui, config); } // FIXME: Old hack $(window).resize(function() { if (util.browser.small) { $('#productsHoldertabs li.first a').trigger('click'); } if (!ui.timeline) { timelineInit(); } }); >>>>>>>
<<<<<<< import { OlCoordinates } from '../components/map/ol-coordinates'; ======= import { groupBy as lodashGroupBy, debounce as lodashDebounce, get as lodashGet } from 'lodash'; import OlCoordinates from '../components/map/ol-coordinates'; >>>>>>> import { groupBy as lodashGroupBy, debounce as lodashDebounce, get as lodashGet } from 'lodash'; import { OlCoordinates } from '../components/map/ol-coordinates'; <<<<<<< const { isDistractionFreeModeActive, isShowingClick, mouseEvents } = this.props; let mapClasses = isShowingClick ? 'wv-map' + ' cursor-pointer' : 'wv-map'; mapClasses = isDistractionFreeModeActive ? mapClasses + ' distraction-free-active' : mapClasses; ======= const { isShowingClick, mouseEvents } = this.props; const mapClasses = isShowingClick ? 'wv-map cursor-pointer' : 'wv-map'; >>>>>>> const { isDistractionFreeModeActive, isShowingClick, mouseEvents, } = this.props; let mapClasses = isShowingClick ? 'wv-map cursor-pointer' : 'wv-map'; mapClasses = isDistractionFreeModeActive ? `${mapClasses} distraction-free-active` : mapClasses; <<<<<<< {!isDistractionFreeModeActive && <OlCoordinates mouseEvents={mouseEvents} /> } </React.Fragment> ======= <OlCoordinates mouseEvents={mouseEvents} /> </> >>>>>>> {!isDistractionFreeModeActive && ( <OlCoordinates mouseEvents={mouseEvents} /> )} </> <<<<<<< const { modal, map, measure, vectorStyles, browser, compare, proj, ui } = state; ======= const { modal, map, measure, vectorStyles, browser, compare, proj, } = state; >>>>>>> const { modal, map, measure, vectorStyles, browser, compare, proj, ui, } = state;
<<<<<<< date = models.date[models.date.activeDate]; ======= date = models.date.selected; // If this not a subdaily layer, truncate the selected time to // UTC midnight if (def.period !== 'subdaily') { date = util.clearTimeUTC(date); } >>>>>>> date = models.date[models.date.activeDate]; // If this not a subdaily layer, truncate the selected time to // UTC midnight if (def.period !== 'subdaily') { date = util.clearTimeUTC(date); } <<<<<<< date = options.date ? options.date : models.date[models.date.activeDate]; layerGroupStr = options.group ? options.group : models.layers[models.layers.activeLayers]; ======= >>>>>>> layerGroupStr = options.group ? options.group : models.layers[models.layers.activeLayers];
<<<<<<< var end = util.parseDateUTC(def.endDate).getTime(); ======= let end = util.parseDateUTC(def.endDate) .getTime(); >>>>>>> var end = util.parseDateUTC(def.endDate).getTime(); <<<<<<< self.add = function(id, spec, activeLayerString) { activeLayerString = activeLayerString || self.activeLayers; if ( lodashFind(self[activeLayerString], { id: id }) ) { return self[activeLayerString]; ======= self.lastDate = function () { var endDate; var layersDateRange = self.dateRange(); var now = util.today(); if (layersDateRange && layersDateRange.end > now) { endDate = layersDateRange.end; } else { endDate = util.today(); } return endDate; }; self.add = function (id, spec) { if (lodashFind(self.active, { id: id })) { return; >>>>>>> self.lastDate = function () { var endDate; var layersDateRange = self.dateRange(); var now = util.today(); if (layersDateRange && layersDateRange.end > now) { endDate = layersDateRange.end; } else { endDate = util.today(); } return endDate; }; self.add = function(id, spec, activeLayerString) { activeLayerString = activeLayerString || self.activeLayers; if ( lodashFind(self[activeLayerString], { id: id }) ) { return self[activeLayerString];
<<<<<<< <ButtonToolbar id="wv-toolbar" className={'wv-toolbar'} > { !isDistractionFreeModeActive && ( <React.Fragment> <Button id="wv-link-button" className="wv-toolbar-button" title="Share this map" onClick={() => openModal( 'TOOLBAR_SHARE_LINK', CUSTOM_MODAL_PROPS.TOOLBAR_SHARE_LINK ) } > <i className="fas fa-share-square fa-2x" /> </Button> {config.ui && config.ui.projections ? ( <Button id="wv-proj-button" className="wv-toolbar-button" title="Switch projection" onClick={() => openModal( 'TOOLBAR_PROJECTION', CUSTOM_MODAL_PROPS.TOOLBAR_PROJECTION ) } > <i className="fas fa-globe-asia fa-2x" />{' '} </Button> ) : ( '' )} <Button id="wv-image-button" className={ isImageDownloadActive ? 'wv-toolbar-button' : 'wv-toolbar-button disabled' } disabled={!isImageDownloadActive} title={ isCompareActive ? 'You must exit comparison mode to use the snapshot feature' : !isImageDownloadActive ? 'You must exit data download mode to use the snapshot feature' : 'Take a snapshot' } onClick={this.openImageDownload} > <i className="fa fa-camera fa-2x" />{' '} </Button> </React.Fragment> ======= <ButtonToolbar id="wv-toolbar" className={'wv-toolbar'}> <Button id="wv-link-button" className="wv-toolbar-button" title="Share this map" onClick={() => openModal( 'TOOLBAR_SHARE_LINK', CUSTOM_MODAL_PROPS.TOOLBAR_SHARE_LINK ) } > <FontAwesomeIcon icon={faShareSquare} size='2x' /> </Button> {config.ui && config.ui.projections ? ( <Button id="wv-proj-button" className="wv-toolbar-button" title="Switch projection" onClick={() => openModal( 'TOOLBAR_PROJECTION', CUSTOM_MODAL_PROPS.TOOLBAR_PROJECTION ) } > <FontAwesomeIcon icon={faGlobeAsia} size='2x' /> </Button> ) : ( '' >>>>>>> <ButtonToolbar id="wv-toolbar" className={'wv-toolbar'} > { !isDistractionFreeModeActive && ( <React.Fragment> <Button id="wv-link-button" className="wv-toolbar-button" title="Share this map" onClick={() => openModal( 'TOOLBAR_SHARE_LINK', CUSTOM_MODAL_PROPS.TOOLBAR_SHARE_LINK ) } > <FontAwesomeIcon icon={faShareSquare} size='2x' /> </Button> {config.ui && config.ui.projections ? ( <Button id="wv-proj-button" className="wv-toolbar-button" title="Switch projection" onClick={() => openModal( 'TOOLBAR_PROJECTION', CUSTOM_MODAL_PROPS.TOOLBAR_PROJECTION ) } > <FontAwesomeIcon icon={faGlobeAsia} size='2x' /> </Button> ) : ( '' )} <Button id="wv-image-button" className={ isImageDownloadActive ? 'wv-toolbar-button' : 'wv-toolbar-button disabled' } disabled={!isImageDownloadActive} title={ isCompareActive ? 'You must exit comparison mode to use the snapshot feature' : !isImageDownloadActive ? 'You must exit data download mode to use the snapshot feature' : 'Take a snapshot' } onClick={this.openImageDownload} > <FontAwesomeIcon icon={faCamera} size='2x' /> </Button> </React.Fragment> <<<<<<< ======= id="wv-image-button" className={ isImageDownloadActive ? 'wv-toolbar-button' : 'wv-toolbar-button disabled' } disabled={!isImageDownloadActive} title={ isCompareActive ? 'You must exit comparison mode to use the snapshot feature' : !isImageDownloadActive ? 'You must exit data download mode to use the snapshot feature' : 'Take a snapshot' } onClick={this.openImageDownload} > <FontAwesomeIcon icon={faCamera} size='2x' /> </Button> <Button >>>>>>>
<<<<<<< $("#timeline-zoom").hover(function(e){ $("#timeline footer").css("background","rgba(40,40,40,0.9)"); },function(e){ $("#timeline footer").css("background",""); }); $("#timeline-zoom input").on("input",function(e){ var testZoomLevel = $(this).val(); if (zoomLevel != testZoomLevel){ switch(testZoomLevel){ case '0': zoomScale = 1; break; case '1': zoomScale = 2; break; case '2': zoomScale = 4; break; case '3': zoomScale = 20; break; case '4': zoomScale = 60; break; default: console.log("Doesn't work"); } //console.log(zoom.scale()); zoomLevel = testZoomLevel; zoom.scale(zoomScale); tx = Math.min(0, width * (1 - zoomScale)); ty = Math.min(0, height * (1 - zoomScale)); zoom.translate([tx, ty]); redrawAxis(); var firstTickZ = svg.select(".x.axis .tick:nth-child(2) text"); var firstTickDataZ = firstTickZ.data()[0]; console.log(firstTickZ); if ((zoomScale === 20) || (zoomScale === 60)){ console.log("Correct" + firstTickDataZ.getUTCMonth()); svg.select(".x.axis .first text").text(firstTickDataZ.getUTCFullYear() + " " + monthNames[firstTickDataZ.getUTCMonth()]); } else{ svg.select(".x.axis .first text").text(firstTickDataZ.getUTCFullYear()); } } }); $("#timeline-hide").click(function(e){ var tl = $("#timeline footer"); if(tl.is(":hidden")) { tl.show("slow"); $("#timeline-zoom input").show(); $("#timeline-hide").text("Hide Timeline"); $("#timeline-zoom").css("right","10px"); $("#timeline-zoom").css("left","auto"); $("#now-line").show(); } else{ tl.hide("slow"); $("#timeline-zoom input").hide(); $("#timeline-hide").text("Show Timeline"); $("#timeline-zoom").css("left","183px"); $("#timeline-zoom").css("right","auto"); $("#now-line").hide(); } }); ======= $("#day-input-group").blur(); >>>>>>> $("#timeline-zoom").hover(function(e){ $("#timeline footer").css("background","rgba(40,40,40,0.9)"); },function(e){ $("#timeline footer").css("background",""); }); $("#timeline-zoom input").on("input",function(e){ var testZoomLevel = $(this).val(); if (zoomLevel != testZoomLevel){ switch(testZoomLevel){ case '0': zoomScale = 1; break; case '1': zoomScale = 2; break; case '2': zoomScale = 4; break; case '3': zoomScale = 20; break; case '4': zoomScale = 60; break; default: console.log("Doesn't work"); } //console.log(zoom.scale()); zoomLevel = testZoomLevel; zoom.scale(zoomScale); tx = Math.min(0, width * (1 - zoomScale)); ty = Math.min(0, height * (1 - zoomScale)); zoom.translate([tx, ty]); redrawAxis(); var firstTickZ = svg.select(".x.axis .tick:nth-child(2) text"); var firstTickDataZ = firstTickZ.data()[0]; console.log(firstTickZ); if ((zoomScale === 20) || (zoomScale === 60)){ console.log("Correct" + firstTickDataZ.getUTCMonth()); svg.select(".x.axis .first text").text(firstTickDataZ.getUTCFullYear() + " " + monthNames[firstTickDataZ.getUTCMonth()]); } else{ svg.select(".x.axis .first text").text(firstTickDataZ.getUTCFullYear()); } } }); $("#timeline-hide").click(function(e){ var tl = $("#timeline footer"); if(tl.is(":hidden")) { tl.show("slow"); $("#timeline-zoom input").show(); $("#timeline-hide").text("Hide Timeline"); $("#timeline-zoom").css("right","10px"); $("#timeline-zoom").css("left","auto"); $("#now-line").show(); } else{ tl.hide("slow"); $("#timeline-zoom input").hide(); $("#timeline-hide").text("Show Timeline"); $("#timeline-zoom").css("left","183px"); $("#timeline-zoom").css("right","auto"); $("#now-line").hide(); } }); $("#day-input-group").blur(); <<<<<<< //$('.button-input-group-selected').select(); ======= // Don't grab focus to allow arrow keys to work //$('.button-input-group-selected').select(); >>>>>>> // Don't grab focus to allow arrow keys to work //$('.button-input-group-selected').select();
<<<<<<< , function(){ return 'expected ' + this.inspect + ' to equal ' + should.inspect(val) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not equal ' + should.inspect(val) + (desc ? " | " + desc : "") } ======= , function(){ return 'expected ' + this.inspect + ' to equal ' + i(val) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not equal ' + i(val) + (description ? " | " + description : "") } >>>>>>> , function(){ return 'expected ' + this.inspect + ' to equal ' + should.inspect(val) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not equal ' + should.inspect(val) + (description ? " | " + description : "") } <<<<<<< , function(){ return 'expected ' + this.inspect + ' to equal ' + should.inspect(val) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not equal ' + should.inspect(val) + (desc ? " | " + desc : "") } , val); ======= , function(){ return 'expected ' + this.inspect + ' to equal ' + i(val) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not equal ' + i(val) + (description ? " | " + description : "") } , val , void 0 , description); >>>>>>> , function(){ return 'expected ' + this.inspect + ' to equal ' + should.inspect(val) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not equal ' + should.inspect(val) + (description ? " | " + description : "") } , val , void 0 , description); <<<<<<< , function(){ return 'expected ' + this.inspect + ' to have type ' + type + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' not to have type ' + type + (desc ? " | " + desc : "") }) ======= , function(){ return 'expected ' + this.inspect + ' to be a ' + type + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' not to be a ' + type + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function(){ return 'expected ' + this.inspect + ' to have type ' + type + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' not to have type ' + type + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< throw new Error(this.inspect + ' has no property ' + should.inspect(name) + (desc ? " | " + desc : "")); ======= throw new Error(this.inspect + ' has no property ' + i(name) + (description ? " | " + description : "")); >>>>>>> throw new Error(this.inspect + ' has no property ' + should.inspect(name) + (description ? " | " + description : "")); <<<<<<< , function(){ return 'expected ' + this.inspect + ' to have a property ' + should.inspect(name) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not have a property ' + should.inspect(name) + (desc ? " | " + desc : "") }); ======= , function(){ return 'expected ' + this.inspect + ' to have a property ' + i(name) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not have a property ' + i(name) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function(){ return 'expected ' + this.inspect + ' to have a property ' + should.inspect(name) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not have a property ' + should.inspect(name) + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< , function(){ return 'expected ' + this.inspect + ' to have a property ' + should.inspect(name) + ' of ' + should.inspect(val) + ', but got ' + should.inspect(this.obj[name]) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not have a property ' + should.inspect(name) + ' of ' + should.inspect(val) + (desc ? " | " + desc : "") }); ======= , function(){ return 'expected ' + this.inspect + ' to have a property ' + i(name) + ' of ' + i(val) + ', but got ' + i(this.obj[name]) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not have a property ' + i(name) + ' of ' + i(val) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function(){ return 'expected ' + this.inspect + ' to have a property ' + should.inspect(name) + ' of ' + should.inspect(val) + ', but got ' + should.inspect(this.obj[name]) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not have a property ' + should.inspect(name) + ' of ' + should.inspect(val) + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< hasOwnProperty.call(this.obj, name) , function(){ return 'expected ' + this.inspect + ' to have own property ' + should.inspect(name) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not have own property ' + should.inspect(name) + (desc ? " | " + desc : "") }); ======= this.obj.hasOwnProperty(name) , function(){ return 'expected ' + this.inspect + ' to have own property ' + i(name) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not have own property ' + i(name) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> hasOwnProperty.call(this.obj, name) , function(){ return 'expected ' + this.inspect + ' to have own property ' + should.inspect(name) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not have own property ' + should.inspect(name) + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< , function() { return 'expected ' + this.inspect + ' to start with ' + should.inspect(str) + (desc ? " | " + desc : "") } , function() { return 'expected ' + this.inspect + ' to not start with ' + should.inspect(str) + (desc ? " | " + desc : "") }); ======= , function() { return 'expected ' + this.inspect + ' to start with ' + i(str) + (description ? " | " + description : "") } , function() { return 'expected ' + this.inspect + ' to not start with ' + i(str) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function() { return 'expected ' + this.inspect + ' to start with ' + should.inspect(str) + (description ? " | " + description : "") } , function() { return 'expected ' + this.inspect + ' to not start with ' + should.inspect(str) + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< , function() { return 'expected ' + this.inspect + ' to end with ' + should.inspect(str) + (desc ? " | " + desc : "") } , function() { return 'expected ' + this.inspect + ' to not end with ' + should.inspect(str) + (desc ? " | " + desc : "") }); ======= , function() { return 'expected ' + this.inspect + ' to end with ' + i(str) + (description ? " | " + description : "") } , function() { return 'expected ' + this.inspect + ' to not end with ' + i(str) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function() { return 'expected ' + this.inspect + ' to end with ' + should.inspect(str) + (description ? " | " + description : "") } , function() { return 'expected ' + this.inspect + ' to not end with ' + should.inspect(str) + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< , function(){ return 'expected ' + this.inspect + ' to include an object equal to ' + should.inspect(obj) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not include an object equal to ' + should.inspect(obj) + (desc ? " | " + desc : "") }); ======= , function(){ return 'expected ' + this.inspect + ' to include an object equal to ' + i(obj) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not include an object equal to ' + i(obj) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function(){ return 'expected ' + this.inspect + ' to include an object equal to ' + should.inspect(obj) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not include an object equal to ' + should.inspect(obj) + (description ? " | " + description : "") } , void 0 , void 0 , description); <<<<<<< , function(){ return 'expected ' + this.inspect + ' to include ' + should.inspect(obj) + (desc ? " | " + desc : "") } , function(){ return 'expected ' + this.inspect + ' to not include ' + should.inspect(obj) + (desc ? " | " + desc : "") }); ======= , function(){ return 'expected ' + this.inspect + ' to include ' + i(obj) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not include ' + i(obj) + (description ? " | " + description : "") } , void 0 , void 0 , description); >>>>>>> , function(){ return 'expected ' + this.inspect + ' to include ' + should.inspect(obj) + (description ? " | " + description : "") } , function(){ return 'expected ' + this.inspect + ' to not include ' + should.inspect(obj) + (description ? " | " + description : "") } , void 0 , void 0 , description);
<<<<<<< var m_tileOffsetValues = {}; ======= // initialize the tile fetch queue this._queue = geo.fetchQueue({ // this should probably be 6 * subdomains.length if subdomains are used size: 6, // if track is the same as the cache size, then neither processing time // nor memory will be wasted. Larger values will use more memory, // smaller values will do needless computations. track: options.cacheSize, needed: function (tile) { return tile === this.cache.get(tile.toString()); }.bind(this) }); >>>>>>> // initialize the tile fetch queue this._queue = geo.fetchQueue({ // this should probably be 6 * subdomains.length if subdomains are used size: 6, // if track is the same as the cache size, then neither processing time // nor memory will be wasted. Larger values will use more memory, // smaller values will do needless computations. track: options.cacheSize, needed: function (tile) { return tile === this.cache.get(tile.toString()); }.bind(this) }); var m_tileOffsetValues = {};
<<<<<<< m_viewer = null, m_interactorStyle = ggl.mapInteractorStyle(), s_init = this._init, m_width = 0, m_height = 0; ======= m_viewer = ggl.vglViewerInstance(), m_contextRenderer = vgl.renderer(), s_init = this._init; >>>>>>> m_viewer = ggl.vglViewerInstance(), m_contextRenderer = vgl.renderer(), m_width = 0, m_height = 0, s_init = this._init;
<<<<<<< /** * General specification for features. * * @typedef {object} geo.feature.spec * @property {geo.layer} [layer] the parent layer associated with the feature. * @property {boolean} [selectionAPI=false] If truthy, enable selection events * on the feature. Selection events are those in `geo.event.feature`. * They can be bound via a call like * <pre><code> * feature.geoOn(geo.event.feature.mousemove, function (evt) { * // do something with the feature * }); * </code></pre> * where the handler is passed a `geo.feature.event` object. * @property {boolean} [visible=true] If truthy, show the feature. If falsy, * hide the feature and do not allow interaction with it. * @property {string} [gcs] The interface gcs for this feature. If `undefined` * or `null`, this uses the layer's interface gcs. This is a string used * by {@linkcode geo.transform}. * @property {number} [bin=0] The bin number is used to determine the order * of multiple features on the same layer. It has no effect except on the * vgl renderer. A negative value hides the feature without stopping * interaction with it. Otherwise, more features with higher bin numbers * are drawn above those with lower bin numbers. If two features have the * same bin number, their order relative to one another is indeterminate * and may be unstable. * @property {geo.renderer?} [renderer] A reference to the renderer used for * the feature. * @property {object} [style] An object that contains style values for the * feature. * @property {function|number} [style.opacity=1] The opacity on a scale of 0 to * 1. */ /** * @typedef {geo.feature.spec} geo.feature.createSpec * @property {string} type A supported feature type. * @property {object[]} [data=[]] An array of arbitrary objects used to * construct the feature. These objects (and their associated indices in the * array) will be passed back to style and attribute accessors provided by the * user. */ /** * @typedef {geo.event} geo.feature.event * @property {number} index The index of the feature within the data array. * @property {object} data The data element associated with the indexed * feature. * @property {geo.mouseState} mouse The mouse information during the event. * @property {object} [extra] Additional information about the feature. This * is sometimes used to identify a subsection of the feature. * @property {number} [eventID] A monotonically increasing number identifying * this feature event loop. This is provided on * `geo.event.feature.mousemove`, `geo.event.feature.mouseclick`, * `geo.event.feature.mouseover`, `geo.event.feature.mouseout`, * `geo.event.feature.brush`, and `geo.event.feature.brushend` * events, since each of those can trigger multiple events for one mouse * action (all events triggered by the same mouse action will have the * same `eventID`). * @property {boolean} [top] `true` if this is the top-most feature that the * mouse is over. Only the top-most feature gets * `geo.event.feature.mouseon` events, whereas multiple features can get * other events. */ /** * @typedef {object} geo.feature.searchResult * @property {object[]} found A list of elements from the data array that were * found by the search. * @property {number[]} index A list of the indices of the elements that were * found by the search. * @property {object[]} [extra] A list of additional information per found * element. The information is passed to events without change. */ ////////////////////////////////////////////////////////////////////////////// ======= >>>>>>> /** * General specification for features. * * @typedef {object} geo.feature.spec * @property {geo.layer} [layer] the parent layer associated with the feature. * @property {boolean} [selectionAPI=false] If truthy, enable selection events * on the feature. Selection events are those in `geo.event.feature`. * They can be bound via a call like * <pre><code> * feature.geoOn(geo.event.feature.mousemove, function (evt) { * // do something with the feature * }); * </code></pre> * where the handler is passed a `geo.feature.event` object. * @property {boolean} [visible=true] If truthy, show the feature. If falsy, * hide the feature and do not allow interaction with it. * @property {string} [gcs] The interface gcs for this feature. If `undefined` * or `null`, this uses the layer's interface gcs. This is a string used * by {@linkcode geo.transform}. * @property {number} [bin=0] The bin number is used to determine the order * of multiple features on the same layer. It has no effect except on the * vgl renderer. A negative value hides the feature without stopping * interaction with it. Otherwise, more features with higher bin numbers * are drawn above those with lower bin numbers. If two features have the * same bin number, their order relative to one another is indeterminate * and may be unstable. * @property {geo.renderer?} [renderer] A reference to the renderer used for * the feature. * @property {object} [style] An object that contains style values for the * feature. * @property {function|number} [style.opacity=1] The opacity on a scale of 0 to * 1. */ /** * @typedef {geo.feature.spec} geo.feature.createSpec * @property {string} type A supported feature type. * @property {object[]} [data=[]] An array of arbitrary objects used to * construct the feature. These objects (and their associated indices in the * array) will be passed back to style and attribute accessors provided by the * user. */ /** * @typedef {geo.event} geo.feature.event * @property {number} index The index of the feature within the data array. * @property {object} data The data element associated with the indexed * feature. * @property {geo.mouseState} mouse The mouse information during the event. * @property {object} [extra] Additional information about the feature. This * is sometimes used to identify a subsection of the feature. * @property {number} [eventID] A monotonically increasing number identifying * this feature event loop. This is provided on * `geo.event.feature.mousemove`, `geo.event.feature.mouseclick`, * `geo.event.feature.mouseover`, `geo.event.feature.mouseout`, * `geo.event.feature.brush`, and `geo.event.feature.brushend` * events, since each of those can trigger multiple events for one mouse * action (all events triggered by the same mouse action will have the * same `eventID`). * @property {boolean} [top] `true` if this is the top-most feature that the * mouse is over. Only the top-most feature gets * `geo.event.feature.mouseon` events, whereas multiple features can get * other events. */ /** * @typedef {object} geo.feature.searchResult * @property {object[]} found A list of elements from the data array that were * found by the search. * @property {number[]} index A list of the indices of the elements that were * found by the search. * @property {object[]} [extra] A list of additional information per found * element. The information is passed to events without change. */ <<<<<<< //////////////////////////////////////////////////////////////////////////// this.pointSearch = function (geo) { ======= /** * Search for features containing the given point. * * Returns an object: :: * * { * data: [...] // an array of data objects for matching features * index: [...] // an array of indices of the matching features * } * * @argument {Object} coordinate * @returns {Object} */ this.pointSearch = function () { >>>>>>> this.pointSearch = function (geo) {
<<<<<<< /** * Contour feature specification. * * @typedef {geo.feature.spec} geo.contourFeature.spec * @property {object[]} [data=[]] An array of arbitrary objects used to * construct the feature. * @property {object} [style] An object that contains style values for the * feature. * @property {function|number} [style.opacity=1] The opacity on a scale of 0 to * 1. * @property {function|geo.geoPosition} [style.position=data] The position of * each data element. This defaults to just using `x`, `y`, and `z` * properties of the data element itself. The position is in the * feature's gcs coordinates. * @property {function|number} [style.value=data.z] The contour value of each * data element. This defaults `z` properties of the data element. If * the value of a grid point is `null` or `undefined`, that point will not * be included in the contour display. Since the values are on a grid, if * this point is in the interior of the grid, this can remove up to four * squares. * @property {geo.contourFeature.contourSpec} [contour] The contour * specification for the feature. */ /** * Contour specification. * * @typedef {object} geo.contourFeature.contourSpec * @property {function|number} [gridWidth] The number of data columns in the * grid. If this is not specified and `gridHeight` is given, this is the * number of data elements divided by `gridHeight`. If neither * `gridWidth` not `gridHeight` are specified, the square root of the * number of data elements is used. If both are specified, some data * could be unused. * @property {function|number} [gridHeight] The number of data rows in the * grid. If this is not specified and `gridWidth` is given, this is the * number of data elements divided by `gridWidth`. If neither * `gridWidth` not `gridHeight` are specified, the square root of the * number of data elements is used. If both are specified, some data * could be unused. * @property {function|number} [x0] The x coordinate of the 0th point in the * `value` array. If `null` or `undefined`, the coordinate is taken from * the `position` style. * @property {function|number} [y0] The y coordinate of the 0th point in the * `value` array. If `null` or `undefined`, the coordinate is taken from * the `position` style. * @property {function|number} [dx] The distance in the x direction between the * 0th and 1st point in the `value` array. This may be positive or * negative. If 0, `null`, or `undefined`, the coordinate is taken from * the `position` style. * @property {function|number} [dy] The distance in the y direction between the * 0th and `gridWidth`th point in the `value` array. This may be positive * or negative. If 0, `null`, or `undefined`, the coordinate is taken * from the `position` style. * @property {function|boolean} [wrapLongitude] If truthy and `position` is not * used (`x0`, `y0`, `dx`, and `dy` are all set appropriately), assume the * x coordinates is longitude and should be adjusted to be within -180 to * 180. If the data spans 180 degrees, the points or squares that * straddle the meridian will be duplicated to ensure that * the map is covered from -180 to 180 as appropriate. Set this to * `false` if using a non-longitude x coordinate. This is ignored if * `position` is used. * @property {function|number} [min] Minimum contour value. If unspecified, * taken from the computed minimum of the `value` style. * @property {function|number} [max] Maximum contour value. If unspecified, * taken from the computed maxi,um of the `value` style. * @property {function|geo.geoColor} [minColor='black'] Color used for any * value below the minimum. * @property {function|number} [minOpacity=0] Opacity used for any value below * the minimum. * @property {function|geo.geoColor} [maxColor='black'] Color used for any * value above the maximum. * @property {function|number} [maxOpacity=0] Opacity used for any value above * the maximum. * @property {function|boolean} [stepped] If falsy but not `undefined`, smooth * transitions between colors. * @property {function|geo.geoColor[]} [colorRange=<color table>] An array of * colors used to show the range of values. The default is a 9-step color * table. * @property {function|number[]} [opacityRange] An array of opacities used to * show the range of values. If unspecified, the opacity is 1. If this * is a shorter list than the `colorRange`, an opacity of 1 is used for * the entries near the end of the color range. * @property {function|number[]} [rangeValues] An array used to map values to * the `colorRange`. By default, values are spaced linearly. If * specified, the entries must be increasing weakly monotonic, and there * must be one more entry then the length of `colorRange`. */ /** * Computed contour information. * * @typedef {object} geo.contourFeature.contourInfo * @property {number[]} elements An array of 0-based indices into the values * array. Each set of the three values forms a triangle that should be * rendered. If no contour data can be used, this will be a zero-length * array and other properties may not be set. * @property {number[]} pos An flat array of coordinates for the vertices in * the triangular mesh. The array is in the order x0, y0, z0, x1, y1, z1, * x2, ..., and is always three times as long as the number of vertices. * @property {number[]} value An array of values that have been normalized to a * range of [0, steps]. There is one value per vertex. * @property {number[]} opacity An array of opacities per vertex. * @property {number} minValue the minimum value used for the contour. If * `rangeValues` was specified, this is the first entry of that array. * @property {number} maxValue the maximum value used for the contour. If * `rangeValues` was specified, this is the last entry of that array. * @property {number} factor If linear value scaling is used, this is the * number of color values divided by the difference between the maximum and * minimum values. It is ignored if non-linear value scaling is used. * @property {geo.geoColorObject} minColor The color used for values below * minValue. Includes opacity. * @property {geo.geoColorObject} maxColor The color used for values above * maxValue. Includes opacity. * @property {geo.geoColorObject[]} colorMap The specified `colorRange` and * `opacityRange` converted into objects that include opacity. */ ////////////////////////////////////////////////////////////////////////////// ======= >>>>>>> /** * Contour feature specification. * * @typedef {geo.feature.spec} geo.contourFeature.spec * @property {object[]} [data=[]] An array of arbitrary objects used to * construct the feature. * @property {object} [style] An object that contains style values for the * feature. * @property {function|number} [style.opacity=1] The opacity on a scale of 0 to * 1. * @property {function|geo.geoPosition} [style.position=data] The position of * each data element. This defaults to just using `x`, `y`, and `z` * properties of the data element itself. The position is in the * feature's gcs coordinates. * @property {function|number} [style.value=data.z] The contour value of each * data element. This defaults `z` properties of the data element. If * the value of a grid point is `null` or `undefined`, that point will not * be included in the contour display. Since the values are on a grid, if * this point is in the interior of the grid, this can remove up to four * squares. * @property {geo.contourFeature.contourSpec} [contour] The contour * specification for the feature. */ /** * Contour specification. * * @typedef {object} geo.contourFeature.contourSpec * @property {function|number} [gridWidth] The number of data columns in the * grid. If this is not specified and `gridHeight` is given, this is the * number of data elements divided by `gridHeight`. If neither * `gridWidth` not `gridHeight` are specified, the square root of the * number of data elements is used. If both are specified, some data * could be unused. * @property {function|number} [gridHeight] The number of data rows in the * grid. If this is not specified and `gridWidth` is given, this is the * number of data elements divided by `gridWidth`. If neither * `gridWidth` not `gridHeight` are specified, the square root of the * number of data elements is used. If both are specified, some data * could be unused. * @property {function|number} [x0] The x coordinate of the 0th point in the * `value` array. If `null` or `undefined`, the coordinate is taken from * the `position` style. * @property {function|number} [y0] The y coordinate of the 0th point in the * `value` array. If `null` or `undefined`, the coordinate is taken from * the `position` style. * @property {function|number} [dx] The distance in the x direction between the * 0th and 1st point in the `value` array. This may be positive or * negative. If 0, `null`, or `undefined`, the coordinate is taken from * the `position` style. * @property {function|number} [dy] The distance in the y direction between the * 0th and `gridWidth`th point in the `value` array. This may be positive * or negative. If 0, `null`, or `undefined`, the coordinate is taken * from the `position` style. * @property {function|boolean} [wrapLongitude] If truthy and `position` is not * used (`x0`, `y0`, `dx`, and `dy` are all set appropriately), assume the * x coordinates is longitude and should be adjusted to be within -180 to * 180. If the data spans 180 degrees, the points or squares that * straddle the meridian will be duplicated to ensure that * the map is covered from -180 to 180 as appropriate. Set this to * `false` if using a non-longitude x coordinate. This is ignored if * `position` is used. * @property {function|number} [min] Minimum contour value. If unspecified, * taken from the computed minimum of the `value` style. * @property {function|number} [max] Maximum contour value. If unspecified, * taken from the computed maxi,um of the `value` style. * @property {function|geo.geoColor} [minColor='black'] Color used for any * value below the minimum. * @property {function|number} [minOpacity=0] Opacity used for any value below * the minimum. * @property {function|geo.geoColor} [maxColor='black'] Color used for any * value above the maximum. * @property {function|number} [maxOpacity=0] Opacity used for any value above * the maximum. * @property {function|boolean} [stepped] If falsy but not `undefined`, smooth * transitions between colors. * @property {function|geo.geoColor[]} [colorRange=<color table>] An array of * colors used to show the range of values. The default is a 9-step color * table. * @property {function|number[]} [opacityRange] An array of opacities used to * show the range of values. If unspecified, the opacity is 1. If this * is a shorter list than the `colorRange`, an opacity of 1 is used for * the entries near the end of the color range. * @property {function|number[]} [rangeValues] An array used to map values to * the `colorRange`. By default, values are spaced linearly. If * specified, the entries must be increasing weakly monotonic, and there * must be one more entry then the length of `colorRange`. */ /** * Computed contour information. * * @typedef {object} geo.contourFeature.contourInfo * @property {number[]} elements An array of 0-based indices into the values * array. Each set of the three values forms a triangle that should be * rendered. If no contour data can be used, this will be a zero-length * array and other properties may not be set. * @property {number[]} pos An flat array of coordinates for the vertices in * the triangular mesh. The array is in the order x0, y0, z0, x1, y1, z1, * x2, ..., and is always three times as long as the number of vertices. * @property {number[]} value An array of values that have been normalized to a * range of [0, steps]. There is one value per vertex. * @property {number[]} opacity An array of opacities per vertex. * @property {number} minValue the minimum value used for the contour. If * `rangeValues` was specified, this is the first entry of that array. * @property {number} maxValue the maximum value used for the contour. If * `rangeValues` was specified, this is the last entry of that array. * @property {number} factor If linear value scaling is used, this is the * number of color values divided by the difference between the maximum and * minimum values. It is ignored if non-linear value scaling is used. * @property {geo.geoColorObject} minColor The color used for values below * minValue. Includes opacity. * @property {geo.geoColorObject} maxColor The color used for values above * maxValue. Includes opacity. * @property {geo.geoColorObject[]} colorMap The specified `colorRange` and * `opacityRange` converted into objects that include opacity. */ <<<<<<< ======= * Override the parent data method to keep track of changes to the * internal coordinates. */ this.data = function (arg) { var ret = s_data(arg); return ret; }; /** >>>>>>> <<<<<<< //////////////////////////////////////////////////////////////////////////// this.contour = function (specOrProperty, value) { if (specOrProperty === undefined) { ======= this.contour = function (arg1, arg2) { if (arg1 === undefined) { >>>>>>> this.contour = function (specOrProperty, value) { if (specOrProperty === undefined) {
<<<<<<< ======= var ALCE = require('alce') var extend = require('extend-object') var fs = require('fs') var path = require('path') var os = require('os') require('colors') >>>>>>>
<<<<<<< pip_position: translate(pipPosition, pipPosition), str_zoomlevel: "1.0" ======= logo: logo, show_embed: showEmbed >>>>>>> //pip_position: translate(pipPosition, pipPosition), str_zoomlevel: "1.0" logo: logo, show_embed: showEmbed <<<<<<< ======= function addQualityListener(quality) { $("#quality" + quality).click(function(element) { element.preventDefault(); $("#" + id_qualityIndicator).html(translate(quality, quality)); Engage.trigger(plugin.events.qualitySet.getName(), quality); }); } >>>>>>> function addQualityListener(quality) { $("#quality" + quality).click(function(element) { element.preventDefault(); $("#" + id_qualityIndicator).html(translate(quality, quality)); Engage.trigger(plugin.events.qualitySet.getName(), quality); }); }
<<<<<<< export default function App({ Component, pageProps }) { return ( <> <Head> <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" /> <meta name="description" content="claim any subdomain and have fun!" /> </Head> <style jsx global>{` * { margin: 0; padding: 0; box-sizing: border-box; } html { height: 100%; width: 100%; } body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; height: 100vh; width: 100vw; } #__next(:global) { height: 100vh; } `}</style> <Component {...pageProps} /> </> ); ======= export default function App({ Component, pageProps }) { return ( <> <Head> <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" /> <meta name="description" content="claim any subdomain and have fun!" /> </Head> <style jsx global>{` * { margin: 0; padding: 0; box-sizing: border-box; } html { height: 100%; width: 100%; } body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; } `}</style> <Component {...pageProps} /> </> ); >>>>>>> export default function App({ Component, pageProps }) { return ( <> <Head> <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" /> <meta name="description" content="claim any subdomain and have fun!" /> </Head> <style jsx global>{` * { margin: 0; padding: 0; box-sizing: border-box; } html { height: 100%; width: 100%; } body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; height: 100vh; width: 100vw; } `}</style> <Component {...pageProps} /> </> );
<<<<<<< if(brush == 'area'){ canvas.style.cursor = 'crosshair'; } else { brushSize = Math.floor((this.value * canvas.width) / brushAdjustment); setCursor(); } ======= var biggerDimension = Math.max(canvas.width, canvas.height); brushSize = Math.floor((this.value * biggerDimension) / brushAdjustment); setCursor(); >>>>>>> if(brush == 'area'){ canvas.style.cursor = 'crosshair'; } else { var biggerDimension = Math.max(canvas.width, canvas.height); brushSize = Math.floor((this.value * biggerDimension) / brushAdjustment); setCursor(); }
<<<<<<< $(this).val(""); token_list.removeClass($(input).data("settings").classes.focused); ======= if (settings.allowFreeTagging) { add_freetagging_tokens(); } else { $(this).val(""); } token_list.removeClass(settings.classes.focused); >>>>>>> $(this).val(""); token_list.removeClass($(input).data("settings").classes.focused); if ($(input).data("settings").allowFreeTagging) { add_freetagging_tokens(); } else { $(this).val(""); } token_list.removeClass($(input).data("settings").classes.focused); <<<<<<< input_box.prop('disabled', $(input).data("settings").disabled); token_list.toggleClass($(input).data("settings").classes.disabled, $(input).data("settings").disabled); ======= input_box.attr('disabled', settings.disabled); token_list.toggleClass(settings.classes.disabled, settings.disabled); >>>>>>> input_box.attr('disabled', $(input).data("settings").disabled); token_list.toggleClass($(input).data("settings").classes.disabled, $(input).data("settings").disabled); <<<<<<< hidden_input.prop('disabled', $(input).data("settings").disabled); ======= hidden_input.attr('disabled', settings.disabled); >>>>>>> hidden_input.attr('disabled', $(input).data("settings").disabled); <<<<<<< if($(input).data("settings").searchingText) { dropdown.html("<p>"+$(input).data("settings").searchingText+"</p>"); ======= if(settings.searchingText) { dropdown.html("<p>" + escapeHTML(settings.searchingText) + "</p>"); >>>>>>> if($(input).data("settings").searchingText) { dropdown.html("<p>" + escapeHTML($(input).data("settings").searchingText) + "</p>"); <<<<<<< if($(input).data("settings").hintText) { dropdown.html("<p>"+$(input).data("settings").hintText+"</p>"); ======= if(settings.hintText) { dropdown.html("<p>" + escapeHTML(settings.hintText) + "</p>"); >>>>>>> if($(input).data("settings").hintText) { dropdown.html("<p>" + escapeHTML($(input).data("settings").hintText) + "</p>"); <<<<<<< if($(input).data("settings").noResultsText) { dropdown.html("<p>"+$(input).data("settings").noResultsText+"</p>"); ======= if(settings.noResultsText) { dropdown.html("<p>" + escapeHTML(settings.noResultsText) + "</p>"); >>>>>>> if($(input).data("settings").noResultsText) { dropdown.html("<p>" + escapeHTML($(input).data("settings").noResultsText) + "</p>"); <<<<<<< if($.isFunction($(input).data("settings").onResult)) { results = $(input).data("settings").onResult.call(hidden_input, results); ======= cache.add(cache_key, results); if($.isFunction(settings.onResult)) { results = settings.onResult.call(hidden_input, results); >>>>>>> cache.add(cache_key, results); if($.isFunction($(input).data("settings").onResult)) { results = $(input).data("settings").onResult.call(hidden_input, results);
<<<<<<< exports.version = '1.0.6'; ======= di.version = '1.0.7'; >>>>>>> exports.version = '1.0.7'; <<<<<<< for (i = 0; i < func.length - 1; i++) { parameters.push(func[i]); } func = func[func.length - 1]; if (typeof func !== 'function') { throw new DependencyResolverException("The last item of the array passed to the method 'inject' has " + "to be a 'function'"); } for (i = 0; i < parameters.length; i++) { if (typeof parameters[i] === 'string' && this.contains(parameters[i])) { parameters[i] = this.__resolve(parameters[i], context); ======= registration = this.getRegistration(name); } var dependencyName; if (typeof func === 'function') { if (registration) { parameters = this.__getConstructorParameters(registration, context); } else { var args = this.__getFunctionArguments(func); for (i = 0; i < args.length; i++) { dependencyName = this.__resolveDependencyName(args[i]); if (this.contains(dependencyName)) { parameters.push(this.__resolve(dependencyName, context)); } else { parameters.push(null); } >>>>>>> for (i = 0; i < func.length - 1; i++) { parameters.push(func[i]); } func = func[func.length - 1]; if (typeof func !== 'function') { throw new DependencyResolverException("The last item of the array passed to the method 'inject' has " + "to be a 'function'"); } for (i = 0; i < parameters.length; i++) { if (typeof parameters[i] === 'string' && this.contains(parameters[i])) { parameters[i] = this.__resolve(parameters[i], context); <<<<<<< } else { var registration = null; if (arguments.length === 2 && typeof arguments[1] === 'string') { var name = arguments[1]; if (!this.contains(name)) { throw new DependencyResolverException("Type with name '" + name + "' is not registered"); } registration = this.getRegistration(name); } var dependencyName; if (typeof func === 'function') { if (registration) { parameters = this.__getConstructorParameters(registration, context); } else { var args = this.__getFunctionArguments(func); for (i = 0; i < args.length; i++) { dependencyName = this.__resolveDependencyName(args[i]); if (this.contains(dependencyName)) { parameters.push(this.__resolve(dependencyName, context)); } else { parameters.push(null); } ======= } else if (typeof func === 'object') { if (registration) { this.__setProperties(func, registration, context); } else { for (var propertyName in func) { dependencyName = this.__resolveDependencyName(propertyName); if (this.contains(dependencyName)) { parameters.push({ name: propertyName, value: this.__resolve(dependencyName, context) }); >>>>>>> } else { var registration = null; if (arguments.length === 2 && typeof arguments[1] === 'string') { var name = arguments[1]; if (!this.contains(name)) { throw new DependencyResolverException("Type with name '" + name + "' is not registered"); } registration = this.getRegistration(name); } var dependencyName; if (typeof func === 'function') { if (registration) { parameters = this.__getConstructorParameters(registration, context); } else { var args = this.__getFunctionArguments(func); for (i = 0; i < args.length; i++) { dependencyName = this.__resolveDependencyName(args[i]); if (this.contains(dependencyName)) { parameters.push(this.__resolve(dependencyName, context)); } else { parameters.push(null); } <<<<<<< __setProperties: { value: function (instance, registration, context) { if (registration.dependencies) { if (this.__autowired) { for (var propertyName in instance) { var dependencyName = this.__resolveDependencyName(propertyName); if (!this.__hasProperty(propertyName) && this.contains(dependencyName)) { instance[propertyName] = this.__resolve(dependencyName, context); } ======= __setProperties: function (instance, registration, context) { if (registration.dependencies) { if (this.__autowired) { for (var propertyName in instance) { var dependencyName = this.__resolveDependencyName(propertyName); if (!this.__hasProperty(propertyName) && this.contains(dependencyName)) { instance[propertyName] = this.__resolve(dependencyName, context); >>>>>>> __setProperties: { value: function (instance, registration, context) { if (registration.dependencies) { if (this.__autowired) { for (var propertyName in instance) { var dependencyName = this.__resolveDependencyName(propertyName); if (!this.__hasProperty(propertyName) && this.contains(dependencyName)) { instance[propertyName] = this.__resolve(dependencyName, context); }
<<<<<<< ======= 'build/download/twister-theme-default.zip': 'http://twisterd.net/twister-html-master.zip', >>>>>>> <<<<<<< twister_osx_x64: { src: '<%= twister_mac_x64_url %>', dest: 'build/download/twister-osx-bundle.zip' ======= twister_osx_libs: { src: 'http://twisterd.net/osx_bin.zip', dest: 'build/download/osx_bin.zip' }, twister_win_libs: { src: 'http://twisterd.net/twister_0.9.21_bin_win32.zip', dest: 'build/download/win_bin.zip' >>>>>>> twister_osx_x64: { src: '<%= twister_mac_x64_url %>', dest: 'build/download/twister-osx-bundle.zip' }, twister_win_libs: { src: 'http://twisterd.net/twister_0.9.21_bin_win32.zip', dest: 'build/download/win_bin.zip' <<<<<<< 'curl:twister_theme_default', 'curl:twister_theme_calm', 'curl:twister_win_ia32', 'curl:twister_osx_x64', ======= 'wget:twister_themes', 'wget:twister_osx_libs', 'wget:twister_win_libs', >>>>>>> 'curl:twister_theme_default', 'curl:twister_theme_calm', 'curl:twister_win_ia32', 'curl:twister_osx_x64', 'wget:twister_win_libs',
<<<<<<< hidden: true, ======= describe: 'Acquia API key', hidden: false, >>>>>>> describe: 'Acquia API key', <<<<<<< ======= description: 'Acquia API secret', hidden: true, >>>>>>> description: 'Acquia API secret', hidden: true,
<<<<<<< sorting = [[$.cookie('column'), $.cookie('direction')]]; ocSeriesList.views.totalCount = ocSeriesList.Configuration.total; ======= >>>>>>> ocSeriesList.views.totalCount = ocSeriesList.Configuration.total;
<<<<<<< // ---------------------------------------------------------------------------- // Globals // ---------------------------------------------------------------------------- // Browserstack. // See: https://github.com/browserstack/api var BS_ENVS = { // Already tested in Travis. bs_firefox: { base: "BrowserStack", browser: "firefox", os: "Windows", os_version: "7" } // TODO: ENABLE. // bs_chrome: { // base: "BrowserStack", // browser: "chrome" // }, // bs_safari: { // base: "BrowserStack", // browser: "safari", // os: "OS X" // os_version: "Lion" // }, // bs_ie_9: { // base: "BrowserStack", // browser: "internet explorer", // browser_version: 9.0, // os: "Windows", // os_version: "7" // }, // bs_ie_10: { // base: "BrowserStack", // browser: "internet explorer", // browser_version: 10.0, // os: "Windows", // os_version: "7" // }, // bs_ie_11: { // base: "BrowserStack", // browser: "ie", // browser_version: 11.0, // os: "Windows", // os_version: "7" // } }; // SauceLabs tag. var BS_BRANCH = process.env.TRAVIS_BRANCH || "local"; var BS_TAG = process.env.BROWSER_STACK_USERNAME + "@" + BS_BRANCH; // ---------------------------------------------------------------------------- // Configuration // ---------------------------------------------------------------------------- ======= // ---------------------------------------------------------------------------- // Globals // ---------------------------------------------------------------------------- // Sauce labs environments. var SAUCE_ENVS = { // Already tested in Travis. // sl_firefox: { // base: "SauceLabs", // browserName: "firefox" // }, sl_chrome: { base: "SauceLabs", browserName: "chrome" }, sl_safari: { base: "SauceLabs", browserName: "safari", platform: "OS X 10.9" }, sl_ie_9: { base: "SauceLabs", browserName: "internet explorer", platform: "Windows 7", version: "9" }, sl_ie_10: { base: "SauceLabs", browserName: "internet explorer", platform: "Windows 7", version: "10" }, sl_ie_11: { base: "SauceLabs", browserName: "internet explorer", platform: "Windows 7", version: "11" } }; // SauceLabs tag. var SAUCE_BRANCH = process.env.TRAVIS_BRANCH || "local"; var SAUCE_TAG = process.env.SAUCE_USERNAME + "@" + SAUCE_BRANCH; >>>>>>> // ---------------------------------------------------------------------------- // Globals // ---------------------------------------------------------------------------- // Browserstack. // See: https://github.com/browserstack/api var BS_ENVS = { // Already tested in Travis. bs_firefox: { base: "BrowserStack", browser: "firefox", os: "Windows", os_version: "7" } // TODO: ENABLE. // bs_chrome: { // base: "BrowserStack", // browser: "chrome" // }, // bs_safari: { // base: "BrowserStack", // browser: "safari", // os: "OS X" // os_version: "Lion" // }, // bs_ie_9: { // base: "BrowserStack", // browser: "internet explorer", // browser_version: 9.0, // os: "Windows", // os_version: "7" // }, // bs_ie_10: { // base: "BrowserStack", // browser: "internet explorer", // browser_version: 10.0, // os: "Windows", // os_version: "7" // }, // bs_ie_11: { // base: "BrowserStack", // browser: "ie", // browser_version: 11.0, // os: "Windows", // os_version: "7" // } }; // SauceLabs tag. var BS_BRANCH = process.env.TRAVIS_BRANCH || "local"; var BS_TAG = process.env.BROWSER_STACK_USERNAME + "@" + BS_BRANCH; // ---------------------------------------------------------------------------- // Globals // ---------------------------------------------------------------------------- // Sauce labs environments. var SAUCE_ENVS = { // Already tested in Travis. // sl_firefox: { // base: "SauceLabs", // browserName: "firefox" // }, sl_chrome: { base: "SauceLabs", browserName: "chrome" }, sl_safari: { base: "SauceLabs", browserName: "safari", platform: "OS X 10.9" }, sl_ie_9: { base: "SauceLabs", browserName: "internet explorer", platform: "Windows 7", version: "9" }, sl_ie_10: { base: "SauceLabs", browserName: "internet explorer", platform: "Windows 7", version: "10" }, sl_ie_11: { base: "SauceLabs", browserName: "internet explorer", platform: "Windows 7", version: "11" } }; // SauceLabs tag. var SAUCE_BRANCH = process.env.TRAVIS_BRANCH || "local"; var SAUCE_TAG = process.env.SAUCE_USERNAME + "@" + SAUCE_BRANCH; <<<<<<< browsers: ["PhantomJS"] ======= browsers: ["PhantomJS"], reporters: ["mocha"] >>>>>>> browsers: ["PhantomJS"] <<<<<<< browsers: ["PhantomJS", "Firefox"] ======= browsers: ["PhantomJS", "Firefox"], reporters: ["mocha"] >>>>>>> browsers: ["PhantomJS", "Firefox"] <<<<<<< browsers: ["PhantomJS", "Chrome", "Firefox", "Safari"] ======= browsers: ["PhantomJS", "Chrome", "Firefox", "Safari"], reporters: ["mocha"] >>>>>>> browsers: ["PhantomJS", "Chrome", "Firefox", "Safari"] <<<<<<< browsers: ["PhantomJS", "Chrome", "Firefox", "Safari"] }, bs: { project: "Backbone.js Testing", name: "Karma JS tests", build: BS_TAG, captureTimeout: 0, // Pass through to BS. customLaunchers: BS_ENVS, browsers: Object.keys(BS_ENVS) ======= browsers: ["PhantomJS", "Chrome", "Firefox", "Safari"], reporters: ["mocha"] }, sauce: { singleRun: true, reporters: ["mocha", "saucelabs"], sauceLabs: { testName: "Backbone Testing - Frontend Unit Tests", tags: [SAUCE_TAG], public: "public" }, // Timeouts: Allow "n" minutes before saying "good enough". See also: // https://github.com/angular/angular.js/blob/master/ // karma-shared.conf.js captureTimeout: 0, // Pass through to SL. customLaunchers: SAUCE_ENVS, browsers: Object.keys(SAUCE_ENVS) >>>>>>> browsers: ["PhantomJS", "Chrome", "Firefox", "Safari"] }, bs: { project: "Backbone.js Testing", name: "Karma JS tests", build: BS_TAG, captureTimeout: 0, // Pass through to BS. customLaunchers: BS_ENVS, browsers: Object.keys(BS_ENVS) }, sauce: { singleRun: true, reporters: ["mocha", "saucelabs"], sauceLabs: { testName: "Backbone Testing - Frontend Unit Tests", tags: [SAUCE_TAG], public: "public" }, // Timeouts: Allow "n" minutes before saying "good enough". See also: // https://github.com/angular/angular.js/blob/master/ // karma-shared.conf.js captureTimeout: 0, // Pass through to SL. customLaunchers: SAUCE_ENVS, browsers: Object.keys(SAUCE_ENVS)
<<<<<<< currentIndex: -1, currentCell: -1, ======= currentIndex: null, >>>>>>> currentIndex: -1, currentCell: -1, <<<<<<< index:index, key: item.data.key, cell: item.data.cell ======= key: item.data.key, cell: item.data.cell >>>>>>> index:index, key: item.data.key, cell: item.data.cell <<<<<<< tapGridItem(e) { const { gridIndex } = e.target.dataset; this.setData({ currentIndex: gridIndex, currentCell: this.data.gridItems[gridIndex].cell }); }, tapGrid(e) { this.triggerEvent('lintap', { index: this.data.currentIndex, cell: this.data.currentCell }, { bubbles: true, composed: true }); this.setData({ currentIndex: -1, currentCell: -1 }); } ======= >>>>>>> tapGridItem(e) { const { gridIndex } = e.target.dataset; this.setData({ currentIndex: gridIndex, currentCell: this.data.gridItems[gridIndex].cell }); }, tapGrid(e) { this.triggerEvent('lintap', { index: this.data.currentIndex, cell: this.data.currentCell }, { bubbles: true, composed: true }); this.setData({ currentIndex: -1, currentCell: -1 }); }
<<<<<<< // expand macro forms (recursively) expand: function(x, flag){ flag || (flag = {}) var ret = null; if(x instanceof BiwaScheme.Pair){ switch(x.car){ case BiwaScheme.Sym("define"): var left = x.cdr.car, exp = x.cdr.cdr; ret = new BiwaScheme.Pair(BiwaScheme.Sym("define"), new BiwaScheme.Pair(left, this.expand(exp, flag))); break; case BiwaScheme.Sym("begin"): ret = new BiwaScheme.Pair(BiwaScheme.Sym("begin"), this.expand(x.cdr, flag)); break; case BiwaScheme.Sym("quote"): ret = x; break; case BiwaScheme.Sym("lambda"): var vars=x.cdr.car, body=x.cdr.cdr; ret = new BiwaScheme.Pair(BiwaScheme.Sym("lambda"), new BiwaScheme.Pair(vars, this.expand(body, flag))); break; case BiwaScheme.Sym("if"): var testc=x.second(), thenc=x.third(), elsec=x.fourth(); if (elsec == BiwaScheme.inner_of_nil){ elsec = BiwaScheme.undef; } ret = BiwaScheme.List(BiwaScheme.Sym("if"), this.expand(testc, flag), this.expand(thenc, flag), this.expand(elsec, flag)); break; case BiwaScheme.Sym("set!"): var v=x.second(), x=x.third(); ret = BiwaScheme.List(BiwaScheme.Sym("set!"), v, this.expand(x, flag)); break; case BiwaScheme.Sym("call-with-current-continuation"): case BiwaScheme.Sym("call/cc"): var x=x.second(); ret = BiwaScheme.List(BiwaScheme.Sym("call/cc"), this.expand(x, flag)); break; default: //apply var transformer = null; if(BiwaScheme.isSymbol(x.car)){ if(BiwaScheme.TopEnv[x.car.name] instanceof BiwaScheme.Syntax) transformer = BiwaScheme.TopEnv[x.car.name]; else if(BiwaScheme.CoreEnv[x.car.name] instanceof BiwaScheme.Syntax) transformer = BiwaScheme.CoreEnv[x.car.name]; } if(transformer){ flag["modified"] = true; ret = transformer.transform(x); // // Debug // var before = BiwaScheme.to_write(x); // var after = BiwaScheme.to_write(ret); // if(before != after){ // console.log("before: " + before) // console.log("expand: " + after) // } var fl; for(;;){ ret = this.expand(ret, fl={}); if(!fl["modified"]) break; } } else{ var expanded_car = this.expand(x.car, flag); var expanded_cdr = BiwaScheme.array_to_list( _.map(x.cdr.to_array(), _.bind(function(item){ return this.expand(item, flag); }, this))); ret = new BiwaScheme.Pair(expanded_car, expanded_cdr); } } } else{ ret = x; } return ret; }, ======= >>>>>>>
<<<<<<< , exitProcess : true ======= , force : false >>>>>>> , exitProcess : true , force : false <<<<<<< logger('Exiting process with some open connections left') exit(1); ======= if (options.force) { logger('Destorying ' + sockets.length + ' open sockets') sockets.forEach(function (socket) { socket.destroy() }) } else { logger('Exiting process with some open connections left') } process.exit(1) >>>>>>> if (options.force) { logger('Destorying ' + sockets.length + ' open sockets') sockets.forEach(function (socket) { socket.destroy() }) } else { logger('Exiting process with some open connections left') } process.exit(1)
<<<<<<< editScope.definition = angular.copy(definition); ======= var adfEditTemplatePath = adfTemplatePath + 'widget-edit.html'; if (definition.editTemplateUrl) { adfEditTemplatePath = definition.editTemplateUrl; } >>>>>>> editScope.definition = angular.copy(definition); var adfEditTemplatePath = adfTemplatePath + 'widget-edit.html'; if (definition.editTemplateUrl) { adfEditTemplatePath = definition.editTemplateUrl; }
<<<<<<< var auto_switch_planet = { "active": false, // Automatically switch to the best planet available (true : yes, false : no) "current_difficulty": undefined, "wanted_difficulty": 3, // Difficulty prefered. Will check planets if the current one differs "rounds_before_check": 5, // If we're not in a wanted difficulty zone, we start a planets check in this amount of rounds "current_round": 0, "coeffScore": { 1: 1, 2: 100, 3: 10000 } }; ======= var current_game_start = undefined; // Timestamp for when the current game started var time_passed_ms = 0 >>>>>>> var auto_switch_planet = { "active": false, // Automatically switch to the best planet available (true : yes, false : no) "current_difficulty": undefined, "wanted_difficulty": 3, // Difficulty prefered. Will check planets if the current one differs "rounds_before_check": 5, // If we're not in a wanted difficulty zone, we start a planets check in this amount of rounds "current_round": 0, "coeffScore": { 1: 1, 2: 100, 3: 10000 } }; <<<<<<< gui.updateStatus(true); gui.progressbar.SetValue(time_passed_ms/(resend_frequency*1000)) ======= gui.updateEstimatedTime(calculateTimeToNextLevel()) >>>>>>> gui.updateStatus(true); gui.updateEstimatedTime(calculateTimeToNextLevel()) gui.progressbar.SetValue(time_passed_ms/(resend_frequency*1000))
<<<<<<< window.gui.updateZone(zone, data.response.zone_info.capture_progress); if (auto_switch_planet.active == true) { if (auto_switch_planet.current_difficulty != data.response.zone_info.difficulty) auto_switch_planet.current_round = 0; // Difficulty changed, reset rounds counter before new planet check auto_switch_planet.current_difficulty = data.response.zone_info.difficulty; if (auto_switch_planet.current_difficulty < auto_switch_planet.wanted_difficulty) { if (auto_switch_planet.current_round >= auto_switch_planet.rounds_before_check) { auto_switch_planet.current_round = 0; CheckSwitchBetterPlanet(); } else { auto_switch_planet.current_round++; } } } ======= gui.updateStatus(true); gui.updateZone(zone, data.response.zone_info.capture_progress, data.response.zone_info.difficulty); gui.updateEstimatedTime(calculateTimeToNextLevel()) >>>>>>> if (auto_switch_planet.active == true) { if (auto_switch_planet.current_difficulty != data.response.zone_info.difficulty) auto_switch_planet.current_round = 0; // Difficulty changed, reset rounds counter before new planet check auto_switch_planet.current_difficulty = data.response.zone_info.difficulty; if (auto_switch_planet.current_difficulty < auto_switch_planet.wanted_difficulty) { if (auto_switch_planet.current_round >= auto_switch_planet.rounds_before_check) { auto_switch_planet.current_round = 0; CheckSwitchBetterPlanet(); } else { auto_switch_planet.current_round++; } } } gui.updateStatus(true); gui.updateZone(zone, data.response.zone_info.capture_progress, data.response.zone_info.difficulty); gui.updateEstimatedTime(calculateTimeToNextLevel()); <<<<<<< } else { if (auto_switch_planet.active == true) { CheckSwitchBetterPlanet(); } else { SwitchNextZone(); } ======= >>>>>>> <<<<<<< if (current_retry < max_retry) { gui.updateTask("Empty Response. Waiting 5s and trying again.", true); current_timeout = setTimeout(function() { INJECT_end_round(); }, 5000); current_retry++; } else { current_retry = 0; if (auto_switch_planet.active == true) { CheckSwitchBetterPlanet(); } else { SwitchNextZone(); } ======= if(attempt_no < max_retry) { console.log("Error getting zone response:",data); gui.updateTask("Waiting 5s and re-sending score(Attempt #" + attempt_no + ")."); setTimeout(function() { INJECT_end_round(attempt_no+1); }, 5000); } else { gui.updateTask("Something went wrong attempting to send results. Please refresh"); gui.updateStatus(false); return; >>>>>>> if (attempt_no < max_retry) { console.log("Error getting zone response:",data); gui.updateTask("Waiting 5s and re-sending score(Attempt #" + attempt_no + ")."); setTimeout(function() { INJECT_end_round(attempt_no+1); }, 5000); } else { attempt_no = 0; if (auto_switch_planet.active == true) { CheckSwitchBetterPlanet(); } else { SwitchNextZone(); } <<<<<<< function SwitchNextZone() { ======= function SwitchNextZone(attempt_no) { if(attempt_no === undefined) attempt_no = 0; INJECT_leave_round(); >>>>>>> function SwitchNextZone() { if(attempt_no === undefined) attempt_no = 0; <<<<<<< if (next_zone != target_zone) { INJECT_leave_round(); console.log("Zone #" + target_zone + " has ended. Trying #" + next_zone); target_zone = next_zone; } else { console.log("Current zone #" + target_zone + " is already the best. No switch."); } INJECT_start_round(target_zone, access_token); } else { if (auto_switch_planet.active == true) { console.log("There's no more zone, the planet must be completed. Searching a new one."); CheckSwitchBetterPlanet(); } else { INJECT_leave_round(); INJECT_update_grid(); console.log("There's no more zone, the planet must be completed. You'll need to choose another planet!"); target_zone = -1; } } } // Check & switch for a potentially better planet, start to the best available zone function CheckSwitchBetterPlanet() { var best_planet = GetBestPlanet(); if (best_planet !== undefined && best_planet !== null && best_planet !== current_planet_id) { INJECT_leave_round(); console.log("Planet #" + best_planet + " has higher XP potentiel. Switching to it. Bye planet #" + current_planet_id); INJECT_leave_planet(); current_planet_id = best_planet; INJECT_join_planet(best_planet, access_token); target_zone = GetBestZone(); INJECT_start_round(target_zone, access_token); } else if (best_planet == current_planet_id) { SwitchNextZone(); } else if (best_planet === null) { console.log("Too many errors while searching a better planet. Let's continue on the current zone."); INJECT_start_round(target_zone, access_token); ======= console.log("Found Best Zone: " + next_zone); INJECT_start_round(next_zone, access_token, attempt_no); >>>>>>> if (next_zone != target_zone) { INJECT_leave_round(); console.log("Found Best Zone: " + next_zone); target_zone = next_zone; } else { console.log("Current zone #" + target_zone + " is already the best. No switch."); } INJECT_start_round(target_zone, access_token, attempt_no); } else { if (auto_switch_planet.active == true) { console.log("There's no more zone, the planet must be completed. Searching a new one."); CheckSwitchBetterPlanet(); } else { INJECT_leave_round(); INJECT_update_grid(); console.log("There's no more zone, the planet must be completed. You'll need to choose another planet!"); target_zone = -1; } } } // Check & switch for a potentially better planet, start to the best available zone function CheckSwitchBetterPlanet() { var best_planet = GetBestPlanet(); if (best_planet !== undefined && best_planet !== null && best_planet !== current_planet_id) { INJECT_leave_round(); console.log("Planet #" + best_planet + " has higher XP potentiel. Switching to it. Bye planet #" + current_planet_id); INJECT_auto_leave_planet(); current_planet_id = best_planet; INJECT_auto_join_planet(best_planet, access_token); target_zone = GetBestZone(); INJECT_start_round(target_zone, access_token); } else if (best_planet == current_planet_id) { SwitchNextZone(); } else if (best_planet === null) { console.log("Too many errors while searching a better planet. Let's continue on the current zone."); INJECT_start_round(target_zone, access_token);
<<<<<<< ======= $(this).dialog('close'); }, 'Abbrechen': function() { >>>>>>> $(this).dialog('close'); }, 'Abbrechen': function() { <<<<<<< switch (property) { ======= switch(property) { >>>>>>> switch (property) { <<<<<<< ======= case 'color': var value = $('<span>') .text(this.color) .css('background-color', this.color) .css('padding-left', 5) .css('padding-right', 5); break; >>>>>>> <<<<<<< switch (property) { case 'cost': value = Number(value * 1000 * 100).toFixed(2) + ' ct/k' + this.definition.unit + 'h'; // ct per kWh break; case 'color': var value = $('<span>') .text(this.color) .css('background-color', this.color) .css('padding-left', 5) .css('padding-right', 5); break; case 'style': switch (this.style) { case 'lines': var value = 'Linien'; break; case 'steps': var value = 'Stufen'; break; case 'points': var value = 'Punkte'; break; } break; ======= if (property == 'cost') { value = Number(value * 1000 * 100).toFixed(2) + ' ct/k' + this.definition.unit + 'h'; // ct per kWh >>>>>>> switch (property) { case 'cost': value = Number(value * 1000 * 100).toFixed(2) + ' ct/k' + this.definition.unit + 'h'; // ct per kWh break; case 'color': var value = $('<span>') .text(this.color) .css('background-color', this.color) .css('padding-left', 5) .css('padding-right', 5); break; case 'style': switch (this.style) { case 'lines': var value = 'Linien'; break; case 'steps': var value = 'Stufen'; break; case 'points': var value = 'Punkte'; break; } break;
<<<<<<< $(this).dialog('close'); }, 'Abbrechen': function() { ======= >>>>>>> $(this).dialog('close'); }, 'Abbrechen': function() { <<<<<<< ======= case 'color': var value = $('<span>') .text(this.color) .css('background-color', this.color) .css('padding-left', 5) .css('padding-right', 5); break; >>>>>>> <<<<<<< ======= case 'active': var value = '<img src="images/' + ((this.active) ? 'tick' : 'cross') + '.png" alt="' + ((this.active) ? 'ja' : 'nein') + '" />'; break; case 'style': switch (this.style) { case 'lines': var value = 'Linien'; break; case 'steps': var value = 'Stufen'; break; case 'points': var value = 'Punkte'; break; } break; >>>>>>> case 'active': var value = '<img src="images/' + ((this.active) ? 'tick' : 'cross') + '.png" alt="' + ((this.active) ? 'ja' : 'nein') + '" />'; break; case 'style': switch (this.style) { case 'lines': var value = 'Linien'; break; case 'steps': var value = 'Stufen'; break; case 'points': var value = 'Punkte'; break; } break; <<<<<<< switch (property) { case 'cost': value = Number(value * 1000 * 100).toFixed(2) + ' ct/k' + this.definition.unit + 'h'; // ct per kWh break; case 'color': var value = $('<span>') .text(this.color) .css('background-color', this.color) .css('padding-left', 5) .css('padding-right', 5); break; case 'style': switch (this.style) { case 'lines': var value = 'Linien'; break; case 'steps': var value = 'Stufen'; break; case 'points': var value = 'Punkte'; break; } break; ======= if (property == 'cost') { if (this.definition.unit == 'W') { value = Number(value * 1000 * 100).toFixed(2) + ' ct/k' + vz.wui.formatConsumptionUnit(this.definition.unit); // ct per kWh } else { value = Number(value * 100).toFixed(2) + ' ct/' + vz.wui.formatConsumptionUnit(this.definition.unit); // ct per m3 etc } >>>>>>> switch (property) { case 'cost': if (this.definition.unit == 'W') { value = Number(value * 1000 * 100).toFixed(2) + ' ct/k' + vz.wui.formatConsumptionUnit(this.definition.unit); // ct per kWh } else { value = Number(value * 100).toFixed(2) + ' ct/' + vz.wui.formatConsumptionUnit(this.definition.unit); // ct per m3 etc } break; case 'color': var value = $('<span>') .text(this.color) .css('background-color', this.color) .css('padding-left', 5) .css('padding-right', 5); break; case 'style': switch (this.style) { case 'lines': var value = 'Linien'; break; case 'steps': var value = 'Stufen'; break; case 'points': var value = 'Punkte'; break; } break; <<<<<<< .text(vz.wui.formatNumber(this.data.consumption, true) + this.definition.unit + 'h') .attr('title', vz.wui.formatNumber(this.data.consumption * (year/delta), true) + this.definition.unit + 'h' + '/Jahr'); ======= .text(vz.wui.formatNumber(this.data.consumption, true) + unit) .attr('title', vz.wui.formatNumber(this.data.consumption * (year/delta), true) + unit + '/Jahr'); } >>>>>>> .text(vz.wui.formatNumber(this.data.consumption, true) + unit) .attr('title', vz.wui.formatNumber(this.data.consumption * (year/delta), true) + unit + '/Jahr'); }
<<<<<<< function Spot(i, j, grid) { this.grid = grid; // Location this.i = i; this.j = j; // f, g, and h values for A* this.f = 0; this.g = 0; this.h = 0; this.vh = 0; //visual heuristic for prioritising path options // Neighbors this.neighbors = undefined; this.neighboringWalls = undefined; // Where did I come from? this.previous = undefined; // Am I an wall? this.wall = false; // Did the maze algorithm already visit me? this.visited = false; if (obstaclesOption == 0 && random(1) < percentWalls) { this.wall = true; } else if (obstaclesOption == 1) { // All the spots start as walls when generating a maze this.wall = true; } // Display me this.show = function(col) { if (this.wall) { fill(0); noStroke(); if (drawingOption === 0) { var x = this.i * w + w / 2; var y = this.j * h + h / 2; ellipse(x, y, w / 2, h / 2); } else { var x = this.i * w; var y = this.j * h; rect(x, y, w, h); } stroke(0); strokeWeight(w / 2); var nWalls = this.getNeighboringWalls(); for (var i = 0; i < nWalls.length; i++) { var nw = nWalls[i]; // Draw line between this and bottom/right neighbor walls if ((nw.i > this.i && nw.j == this.j) || (nw.i == this.i && nw.j > this.j)) { line(this.i * w + w / 2, this.j * h + h / 2, nw.i * w + w / 2, nw.j * h + h / 2); } // Draw line between this and bottom-left/bottom-right neighbor walls if (!canPassThroughCorners && (nw.j > this.j) && (nw.i < this.i || nw.i > this.i)) { line(this.i * w + w / 2, this.j * h + h / 2, nw.i * w + w / 2, nw.j * h + h / 2); } } } else if (col) { fill(col); noStroke(); rect(this.i * w, this.j * h, w, h); } } ======= function Spot(i, j, x, y, width, height, isWall, grid) { this.grid = grid; // Location this.i = i; this.j = j; this.x = x; this.y = y; this.width = width; this.height = height; // f, g, and h values for A* this.f = 0; this.g = 0; this.h = 0; this.vh = 0; //visual heuristic for prioritising path options // Neighbors this.neighbors = undefined; this.neighboringWalls = undefined; // Where did I come from? this.previous = undefined; // Am I an wall? this.wall = isWall; // Display me this.show = function(color) { if (this.wall) { fill(0); noStroke(); if (drawingOption === 0) { ellipse(this.x + this.width * 0.5, this.y + this.width * 0.5, this.width * 0.5, this.height * 0.5); } else { rect(this.x, this.y, this.width, this.height); } >>>>>>> function Spot(i, j, x, y, width, height, isWall, grid) { this.grid = grid; // Location this.i = i; this.j = j; this.x = x; this.y = y; this.width = width; this.height = height; // f, g, and h values for A* this.f = 0; this.g = 0; this.h = 0; this.vh = 0; //visual heuristic for prioritising path options // Neighbors this.neighbors = undefined; this.neighboringWalls = undefined; // Where did I come from? this.previous = undefined; // Am I an wall? this.wall = isWall; // Did the maze algorithm already visit me? this.visited = false; if (random(1) < percentWalls) { this.wall = true; } // Display me this.show = function(color) { if (this.wall) { fill(0); noStroke(); if (drawingOption === 0) { ellipse(this.x + this.width * 0.5, this.y + this.width * 0.5, this.width * 0.5, this.height * 0.5); } else { rect(this.x, this.y, this.width, this.height); }
<<<<<<< //Set to true to allow diagonal moves //This will also switch from Manhattan to Euclidean distance measures var allowDiagonals = false; ======= // Daniel Shiffman // http://codingtra.in // http://patreon.com/codingtrain // Part 1: https://youtu.be/aKYlikFAV4k // Part 2: https://youtu.be/EaZxUCWAjb0 // Part 3: https://youtu.be/jwRT4PCT6RU // Function to delete element from the array >>>>>>> // Daniel Shiffman // http://codingtra.in // http://patreon.com/codingtrain // Part 1: https://youtu.be/aKYlikFAV4k // Part 2: https://youtu.be/EaZxUCWAjb0 // Part 3: https://youtu.be/jwRT4PCT6RU //Set to true to allow diagonal moves //This will also switch from Manhattan to Euclidean distance measures var allowDiagonals = true; // Function to delete element from the array <<<<<<< //This function returns a measure of aesthetic preference for //use when ordering the openSet. It is used to prioritise //between equal standard heuristic scores. It can therefore //be anything you like without affecting the ability to find //a minimum cost path. function visualDist(a, b) { return dist(a.i, a.j, b.i, b.j); } ======= // An educated guess of how far it is between two points >>>>>>> //This function returns a measure of aesthetic preference for //use when ordering the openSet. It is used to prioritise //between equal standard heuristic scores. It can therefore //be anything you like without affecting the ability to find //a minimum cost path. function visualDist(a, b) { return dist(a.i, a.j, b.i, b.j); } // An educated guess of how far it is between two points <<<<<<< ======= // How many columns and rows? >>>>>>> // How many columns and rows? <<<<<<< var w, h; var path = []; function Spot(i, j) { this.i = i; this.j = j; this.f = 0; this.g = 0; this.h = 0; this.vh = 0; //visual heuristic for tie-breaking this.neighbors = []; this.previous = undefined; this.wall = false; if (random(1) < 0.3) { this.wall = true; } this.show = function(col) { fill(col); if (this.wall) { fill(0); noStroke(); ellipse(this.i * w + w / 2, this.j * h + h / 2, w / 2, h / 2); } else { rect(this.i * w, this.j * h, w - 1, h - 1); } } this.addNeighbors = function(grid) { var i = this.i; var j = this.j; if (i < cols - 1) { this.neighbors.push(grid[i + 1][j]); } if (i > 0) { this.neighbors.push(grid[i - 1][j]); } if (j < rows - 1) { this.neighbors.push(grid[i][j + 1]); } if (j > 0) { this.neighbors.push(grid[i][j - 1]); } if (allowDiagonals) { if (i > 0 && j > 0) { this.neighbors.push(grid[i - 1][j - 1]); } if (i < cols - 1 && j > 0) { this.neighbors.push(grid[i + 1][j - 1]); } if (i > 0 && j < rows - 1) { this.neighbors.push(grid[i - 1][j + 1]); } if (i < cols - 1 && j < rows - 1) { this.neighbors.push(grid[i + 1][j + 1]); } } } ======= >>>>>>> <<<<<<< // we can keep going ======= // Uh oh, no solution >>>>>>> // Uh oh, no solution <<<<<<< // no solution ======= >>>>>>> <<<<<<< closedSet[i].show(color(255, 0, 0)); ======= closedSet[i].show(color(255, 0, 0, 50)); >>>>>>> closedSet[i].show(color(255, 0, 0, 50)); <<<<<<< openSet[i].show(color(0, 255, 0)); ======= openSet[i].show(color(0, 255, 0, 50)); >>>>>>> openSet[i].show(color(0, 255, 0, 50));
<<<<<<< <<<<<<< HEAD './src/client/test-helpers/bind-polyfill.js', ======= './src/client/test/bind-polyfill.js', >>>>>>> master ======= './src/client/test/bind-polyfill.js', >>>>>>> './src/client/test-helpers/bind-polyfill.js',
<<<<<<< idConfigElement = '#new-event-workflow-configuration', workflowConfigEl = angular.element(idConfigElement), originalValues = {}; ======= idConfigElement = '#new-event-workflow-configuration'; >>>>>>> idConfigElement = '#new-event-workflow-configuration', originalValues = {}; <<<<<<< // This is used for the new task post request this.getWorkflowConfigs = function () { var workflowConfigs = {}, element, isRendered = workflowConfigEl.find('.configField').length > 0; ======= // Get the workflow configuration this.getWorkflowConfig = function () { var workflowConfig = {}, element, workflowConfigEl = angular.element(idConfigElement), isRendered = workflowConfigEl.find('.configField').length > 0; >>>>>>> // This is used for the new task post request this.getWorkflowConfigs = function () { var workflowConfig = {}, element, workflowConfigEl = angular.element(idConfigElement), isRendered = workflowConfigEl.find('.configField').length > 0;
<<<<<<< var videoDisplayClass = "videoDisplay"; var videoDefaultLayoutClass = "videoDefaultLayout"; var videoUnfocusedClass = "videoUnfocusedPiP"; var videoFocusedClass = "videoFocusedPiP"; var unfocusedPiPClass = "videoUnfocusedPiP"; var focusedPiPClass = "videoFocusedPiP"; var unfocusedClass = "videoUnfocused"; var focusedClass = "videoFocused"; var isPiP = true; var pipPos = "left"; ======= var foundQualities = undefined; >>>>>>> var videoDisplayClass = "videoDisplay"; var videoDefaultLayoutClass = "videoDefaultLayout"; var videoUnfocusedClass = "videoUnfocusedPiP"; var videoFocusedClass = "videoFocusedPiP"; var unfocusedPiPClass = "videoUnfocusedPiP"; var focusedPiPClass = "videoFocusedPiP"; var unfocusedClass = "videoUnfocused"; var focusedClass = "videoFocused"; var isPiP = true; var pipPos = "left"; var foundQualities = undefined; <<<<<<< function registerEvents(videoDisplay) { var videodisplay = videojs(videoDisplay); $(window).resize(function() { checkVideoDisplaySize(); }); Engage.on(plugin.events.play.getName(), function() { if (videosReady) { clearAutoplay(); videodisplay.play(); pressedPlayOnce = true; } }); Engage.on(plugin.events.autoplay.getName(), function() { interval_autoplay = window.setInterval(function() { if (pressedPlayOnce) { clearAutoplay(); } else if (videosReady) { videodisplay.play(); clearAutoplay(); } }, interval_autoplay_ms); }); Engage.on(plugin.events.initialSeek.getName(), function(e) { parsedSeconds = Utils.parseSeconds(e); interval_initialSeek = window.setInterval(function() { if (pressedPlayOnce) { clearInitialSeek(); } else if (videosReady) { videodisplay.play(); window.setTimeout(function() { Engage.trigger(plugin.events.seek.getName(), parsedSeconds); }, timeout_initialSeek_ms); clearInitialSeek(); } }, interval_initialSeek_ms); }); Engage.on(plugin.events.pause.getName(), function() { clearAutoplay(); videodisplay.pause(); }); Engage.on(plugin.events.playPause.getName(), function() { if (videodisplay.paused()) { Engage.trigger(plugin.events.play.getName()); } else { Engage.trigger(plugin.events.pause.getName()); } }); Engage.on(plugin.events.seekLeft.getName(), function() { if (pressedPlayOnce) { var currTime = videodisplay.currentTime(); if ((currTime - seekSeconds) >= 0) { Engage.trigger(plugin.events.seek.getName(), currTime - seekSeconds); } else { Engage.trigger(plugin.events.seek.getName(), 0); } } }); Engage.on(plugin.events.seekRight.getName(), function() { if (pressedPlayOnce) { var currTime = videodisplay.currentTime(); var duration = parseInt(Engage.model.get("videoDataModel").get("duration")) / 1000; if (duration && ((currTime + seekSeconds) < duration)) { Engage.trigger(plugin.events.seek.getName(), currTime + seekSeconds); } else { Engage.trigger(plugin.events.seek.getName(), duration); } } }); Engage.on(plugin.events.playbackRateIncrease.getName(), function() { if (pressedPlayOnce) { var rate = videodisplayMaster.playbackRate(); switch (rate * 100) { case 50: Engage.trigger(plugin.events.playbackRateChanged.getName(), 0.75) break; case 75: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.0) break; case 100: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.25) break; case 125: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.5) break; default: break; } } }); Engage.on(plugin.events.playbackRateDecrease.getName(), function() { if (pressedPlayOnce) { var rate = videodisplayMaster.playbackRate(); switch (rate * 100) { case 75: Engage.trigger(plugin.events.playbackRateChanged.getName(), 0.5) break; case 100: Engage.trigger(plugin.events.playbackRateChanged.getName(), 0.75) break; case 125: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.0) break; case 150: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.25) break; default: break; } } }); } ======= >>>>>>> function registerEvents(videoDisplay) { var videodisplay = videojs(videoDisplay); $(window).resize(function() { checkVideoDisplaySize(); }); Engage.on(plugin.events.play.getName(), function() { if (videosReady) { clearAutoplay(); videodisplay.play(); pressedPlayOnce = true; } }); Engage.on(plugin.events.autoplay.getName(), function() { interval_autoplay = window.setInterval(function() { if (pressedPlayOnce) { clearAutoplay(); } else if (videosReady) { videodisplay.play(); clearAutoplay(); } }, interval_autoplay_ms); }); Engage.on(plugin.events.initialSeek.getName(), function(e) { parsedSeconds = Utils.parseSeconds(e); interval_initialSeek = window.setInterval(function() { if (pressedPlayOnce) { clearInitialSeek(); } else if (videosReady) { videodisplay.play(); window.setTimeout(function() { Engage.trigger(plugin.events.seek.getName(), parsedSeconds); }, timeout_initialSeek_ms); clearInitialSeek(); } }, interval_initialSeek_ms); }); Engage.on(plugin.events.pause.getName(), function() { clearAutoplay(); videodisplay.pause(); }); Engage.on(plugin.events.playPause.getName(), function() { if (videodisplay.paused()) { Engage.trigger(plugin.events.play.getName()); } else { Engage.trigger(plugin.events.pause.getName()); } }); Engage.on(plugin.events.seekLeft.getName(), function() { if (pressedPlayOnce) { var currTime = videodisplay.currentTime(); if ((currTime - seekSeconds) >= 0) { Engage.trigger(plugin.events.seek.getName(), currTime - seekSeconds); } else { Engage.trigger(plugin.events.seek.getName(), 0); } } }); Engage.on(plugin.events.seekRight.getName(), function() { if (pressedPlayOnce) { var currTime = videodisplay.currentTime(); var duration = parseInt(Engage.model.get("videoDataModel").get("duration")) / 1000; if (duration && ((currTime + seekSeconds) < duration)) { Engage.trigger(plugin.events.seek.getName(), currTime + seekSeconds); } else { Engage.trigger(plugin.events.seek.getName(), duration); } } }); Engage.on(plugin.events.playbackRateIncrease.getName(), function() { if (pressedPlayOnce) { var rate = videodisplayMaster.playbackRate(); switch (rate * 100) { case 50: Engage.trigger(plugin.events.playbackRateChanged.getName(), 0.75) break; case 75: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.0) break; case 100: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.25) break; case 125: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.5) break; default: break; } } }); Engage.on(plugin.events.playbackRateDecrease.getName(), function() { if (pressedPlayOnce) { var rate = videodisplayMaster.playbackRate(); switch (rate * 100) { case 75: Engage.trigger(plugin.events.playbackRateChanged.getName(), 0.5) break; case 100: Engage.trigger(plugin.events.playbackRateChanged.getName(), 0.75) break; case 125: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.0) break; case 150: Engage.trigger(plugin.events.playbackRateChanged.getName(), 1.25) break; default: break; } } }); }
<<<<<<< const { Transform } = require("stream"); ======= const { Writable } = require("stream"); const cp = require("child_process"); >>>>>>> const { Writable } = require("stream"); <<<<<<< setImmediate(function() { ======= >>>>>>> setImmediate(function() {
<<<<<<< // Reset all states angular.forEach($scope.states, function(state) { if (angular.isDefined(state.stateController.reset)) { state.stateController.reset(); } }); window.onbeforeunload = null; ======= resetStates(); >>>>>>> resetStates(); window.onbeforeunload = null; <<<<<<< window.onbeforeunload = null; ======= resetStates(); >>>>>>> resetStates(); window.onbeforeunload = null;