code
stringlengths
122
4.99k
label
int64
0
14
diff --git a/app.js b/app.js @@ -21,7 +21,7 @@ import hpManager from './hp-manager.js'; // import npcManager from './npc-manager.js'; import equipmentRender from './equipment-render.js'; // import {bindInterface as inventoryBindInterface} from './inventory.js'; -import fx from './fx.js'; +// import fx from './fx.js'; import {parseCoord, getExt} from './util.js'; import {storageHost, tokensHost} from './constants.js'; // import './procgen.js'; @@ -484,7 +484,7 @@ export default class WebaverseApp extends EventTarget { // activateManager.update(); // dropManager.update(); // npcManager.update(timeDiffCapped); - fx.update(); + // fx.update(); appManager.tick(timestamp, frame);
2
diff --git a/src/routes.js b/src/routes.js @@ -231,7 +231,7 @@ export function loadPlanFromCSV(assignmentList, state) { const delimiter = (state.place.id === "louisiana") ? ";" : ","; - let districtIds = new Set(rows.map((row, index) => row.split(delimiter)[1].split("_")[0] )); + let districtIds = new Set(rows.slice(1).map((row, index) => row.split(delimiter)[1].split("_")[0] )); if (headers) {districtIds.delete(rows[0].split(delimiter)[1]);} districtIds.delete(undefined);
8
diff --git a/src/Formio.js b/src/Formio.js @@ -650,7 +650,7 @@ export default class Formio { .then(() => Formio.pluginGet('staticRequest', requestArgs) .then((result) => { if (isNil(result)) { - return Formio.request(url, method, requestArgs.data, requestArgs.opts.header, requestArgs.opts); + return Formio.request(requestArgs.url, requestArgs.method, requestArgs.data, requestArgs.opts.header, requestArgs.opts); } return result; })); @@ -670,7 +670,7 @@ export default class Formio { .then(() => Formio.pluginGet('request', requestArgs) .then((result) => { if (isNil(result)) { - return Formio.request(url, method, requestArgs.data, requestArgs.opts.header, requestArgs.opts); + return Formio.request(requestArgs.url, requestArgs.method, requestArgs.data, requestArgs.opts.header, requestArgs.opts); } return result; }));
11
diff --git a/lib/voice/VoiceConnectionManager.js b/lib/voice/VoiceConnectionManager.js @@ -10,7 +10,7 @@ class VoiceConnectionManager extends Collection { join(guildID, channelID, options) { var connection = this.get(guildID); - if(connection) { + if(connection && connection.ws) { connection.switchChannel(channelID); return Promise.resolve(connection); }
8
diff --git a/app/scripts/controllers/transactions/index.js b/app/scripts/controllers/transactions/index.js @@ -568,9 +568,14 @@ class TransactionController extends EventEmitter { const historicalTransactions = Object.assign({}, this.gethistoricalTransactions()) if (!historicalTransactions) return + const txHistory = this.txStateManager.getFilteredTxList({ + metamaskNetworkId: this.getNetwork(), + }) + Object.keys(historicalTransactions) .forEach(address => { - historicalTransactions[address].forEach(tx => { + for (let tx of historicalTransactions[address]) { + if (txHistory.some(txh => txh.hash === tx.hash)) continue const txMeta = Object.assign( this.txStateManager.generateTxMeta(tx), { @@ -578,8 +583,8 @@ class TransactionController extends EventEmitter { }, tx, ) - this.addTx(txMeta) - }) + this.txStateManager.addTx(txMeta) + } }) }
8
diff --git a/lib/support/cliUtil.js b/lib/support/cliUtil.js 'use strict'; const fs = require('fs'); +const path = require('path'); module.exports = { getURLs(urls) { const allUrls = []; urls = urls.map((url) => url.trim()); - for (var url of urls) { + for (let url of urls) { if (url.startsWith('http')) { allUrls.push(url); } else { - const filePath = url; - var lines = fs.readFileSync(filePath).toString().split('\n'); + const filePath = path.resolve(url); + try { + const lines = fs.readFileSync(filePath).toString().split('\n'); for (let line of lines) { if (line.trim().length > 0) { let lineArray = line.split(" ", 2); @@ -22,6 +24,12 @@ module.exports = { } } } + } catch (e) { + if (e.code === 'ENOENT') { + throw new Error(`Couldn't find url file at ${filePath}`); + } + throw e; + } } } return allUrls; @@ -30,12 +38,12 @@ module.exports = { const urlMetaData = {}; urls = urls.map((url) => url.trim()); - for (var url of urls) { + for (let url of urls) { if (url.startsWith('http')) { return {}; } else { const filePath = url; - var lines = fs.readFileSync(filePath).toString().split('\n'); + const lines = fs.readFileSync(filePath).toString().split('\n'); for (let line of lines) { if (line.trim().length > 0) { let url, alias = null;
7
diff --git a/articles/appliance/cli/adding-node-to-backup-role.md b/articles/appliance/cli/adding-node-to-backup-role.md @@ -13,10 +13,6 @@ applianceId: appliance11 # PSaaS Appliance: Adding a Node to the Backup Role -::: note - This document applies beginning with PSaaS Appliance update **build 7247**. -::: - ## Prerequisites * Backup can be configured on single or multiple-node setups. In multi-node setups, the backup must be placed on a non-primary device.
2
diff --git a/ethereum.js b/ethereum.js @@ -36,4 +36,11 @@ import contractAbi from 'https://contracts.webaverse.com/ethereum/abi.js'; return ecrecover(prefixedHash, v, r, s) == a; } */ + /* + const events = await contract.getPastEvents('Transfer', {fromBlock: 0, toBlock: 'latest',}) + for (const event of events) { + const {returnValues} = event; + const {from, to, amount} = returnValues; + } + */ })(); \ No newline at end of file
0
diff --git a/src/Router/index.js b/src/Router/index.js @@ -43,7 +43,7 @@ export let activePage * @param routes * @param provider */ -export const initRouter = ({ appInstance, routes, provider }) => { +export const startRouter = ({ appInstance, routes, provider }) => { app = appInstance application = appInstance.application host = application.childList @@ -715,7 +715,7 @@ window.addEventListener('hashchange', () => { }) export default { - initRouter, + startRouter, navigate, root, route,
10
diff --git a/lock-manager.js b/lock-manager.js @@ -76,5 +76,5 @@ export class LockManager { } } } -const locks = new LockManager(); -export default locks; \ No newline at end of file +// const locks = new LockManager(); +// export default locks; \ No newline at end of file
2
diff --git a/src/embeds/EarthCycleEmbed.js b/src/embeds/EarthCycleEmbed.js @@ -13,13 +13,14 @@ class EarthCycleEmbed extends BaseEmbed { constructor(bot, state) { super(); + this.title = `Worldstate - ${state.isCetus ? 'Plains of Eidolon' : 'Earth'} Cycle - ${state.isDay ? 'Day' : 'Night'}time`; this.color = state.isDay ? 0xB64624 : 0x000066; this.thumbnail = { url: state.isCetus ? 'https://i.imgur.com/Ph337PR.png' : 'https://i.imgur.com/oR6Sskf.png', }; this.fields = [ { - name: `Operator, ${state.isCetus ? 'the Plains of Eidolon are' : 'Earth is'} currently in ${state.isDay ? 'Day' : 'Night'}time`, + name: '_ _', value: `Time remaining until ${state.isDay ? 'night' : 'day'}: ${state.timeLeft}\n` + `${state.isDay ? 'Night' : 'Day'} starts at ${new Date(state.expiry).toLocaleString()}`, },
2
diff --git a/src/components/CurrentTeams/index.js b/src/components/CurrentTeams/index.js @@ -51,8 +51,12 @@ class currentTeams extends PureComponent { this.setState({ editRoleLoading: true }); const { dispatch, eid, userInfo } = this.props; const { toEditAction } = this.state; + let type = 'user/editUserRoles'; + if (toEditAction.roles && toEditAction.roles.length > 0) { + type = 'teamControl/editMember'; + } dispatch({ - type: 'user/editUserRoles', + type, payload: { enterprise_id: eid, team_name: toEditAction.team_name,
1
diff --git a/src/libs/actions/FormActions.js b/src/libs/actions/FormActions.js @@ -21,7 +21,7 @@ function setErrors(formID, errors) { * @param {Object} draftValues */ function setDraftValues(formID, draftValues) { - Onyx.merge(`${formID}Draft`, draftValues); + Onyx.merge(`${formID}DraftValues`, draftValues); } export {
13
diff --git a/includes/Modules/Subscribe_With_Google/Header.php b/includes/Modules/Subscribe_With_Google/Header.php @@ -66,14 +66,6 @@ final class Header { true ); - // Make WP URLs available to SwgPress' JavaScript. - $api_base_url = get_option( 'siteurl' ) . '/wp-json/subscribewithgoogle/v1'; - wp_localize_script( - 'subscribe-with-google', - 'SubscribeWithGoogleWpGlobals', - array( 'API_BASE_URL' => $api_base_url ) - ); - // Styles for SwgPress. wp_enqueue_style( 'subscribe-with-google',
2
diff --git a/token-metadata/0x2129fF6000b95A973236020BCd2b2006B0D8E019/metadata.json b/token-metadata/0x2129fF6000b95A973236020BCd2b2006B0D8E019/metadata.json "symbol": "MYX", "address": "0x2129fF6000b95A973236020BCd2b2006B0D8E019", "decimals": 18, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/token-metadata/0x1453Dbb8A29551ADe11D89825CA812e05317EAEB/metadata.json b/token-metadata/0x1453Dbb8A29551ADe11D89825CA812e05317EAEB/metadata.json "symbol": "TEND", "address": "0x1453Dbb8A29551ADe11D89825CA812e05317EAEB", "decimals": 18, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/app-template/config-template.xml b/app-template/config-template.xml <plugin name="cordova-plugin-screen-orientation" spec="~1.4.2" /> <plugin name="ionic-plugin-keyboard" spec="~2.2.1" /> <plugin name="cordova-plugin-whitelist" spec="~1.3.0" /> - <plugin name="cordova-plugin-wkwebview-engine" spec="https://github.com/driftyco/cordova-plugin-wkwebview-engine.git#4221015eb3f309fe593a7d81205b691e27088743" /> + <plugin name="cordova-plugin-ionic-webview" spec="https://github.com/ionic-team/cordova-plugin-ionic-webview.git" /> <plugin name="cordova-plugin-qrscanner" spec="~2.5.0" /> <plugin name="cordova-plugin-customurlscheme" spec="https://github.com/cmgustavo/Custom-URL-scheme.git"> <variable name="URL_SCHEME" value="bitcoin" />
3
diff --git a/site/rabbit.ent b/site/rabbit.ent @@ -15,7 +15,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> -<!ENTITY version-java-client "5.1.2"> +<!ENTITY version-java-client "5.2.0"> <!ENTITY version-dotnet-client "5.0.1"> <!ENTITY version-server "3.7.4"> <!ENTITY version-server-series "v3.7.x">
12
diff --git a/src/agent/index.js b/src/agent/index.js @@ -1500,12 +1500,15 @@ function listMemoryRangesJson () { }); } -function changeMemoryProtection (args) { - const [address, size, protection] = args; - - Memory.protect(ptr(address), parseInt(size), protection); - - return true; +async function changeMemoryProtection (args) { + const [addr, size, protection] = args; + if (args.length !== 3 || protection.length > 3) { + return 'Usage: \\dmp [address] [size] [rwx]'; + } + const address = getPtr(addr); + const mapsize = await numEval(size); + Memory.protect(address, ptr(mapsize).toInt32(), protection); + return ''; } function getPidJson () { @@ -1925,6 +1928,9 @@ function traceListJson () { function getPtr (p) { p = p.trim(); + if (!p || p === '$$') { + return ptr(offset); + } if (p.startsWith('objc:')) { const hatSign = p.indexOf('^') !== -1; if (hatSign !== -1) { @@ -1976,9 +1982,6 @@ function getPtr (p) { } return found ? found.implementation : ptr(0); } - if (!p || p === '$$') { - return ptr(offset); - } try { if (p.substring(0, 2) === '0x') { return ptr(p);
7
diff --git a/client/src/containers/FlightDirector/SimulatorConfig/config/Stations/ambianceConfig.js b/client/src/containers/FlightDirector/SimulatorConfig/config/Stations/ambianceConfig.js @@ -18,7 +18,7 @@ class AmbianceConfig extends Component { mutation SetAmbiance( $stationSetID: ID! $stationName: String! - $ambiance: String! + $ambiance: String ) { setStationAmbiance( stationSetID: $stationSetID @@ -45,7 +45,7 @@ class AmbianceConfig extends Component { variables: { stationSetID: selectedStationSet, stationName: station.name, - training: "" + ambiance: "" } }); this.setState({ edit: false });
1
diff --git a/packages/cli/src/models/compiler/Compiler.ts b/packages/cli/src/models/compiler/Compiler.ts @@ -18,7 +18,12 @@ export async function compile( if (!force && state.alreadyCompiled) return; // Merge config file compiler options with those set explicitly - const resolvedOptions: ProjectCompilerOptions = {}; + const resolvedOptions: ProjectCompilerOptions = { + optimizer: { + enabled: false, + runs: 200, + }, + }; merge(resolvedOptions, projectFile.compilerOptions, compilerOptions); // Validate compiler manager setting
12
diff --git a/docs/layout/content.html b/docs/layout/content.html @@ -22,7 +22,7 @@ next: "layout-footer" You can specify the size your content has adding <code class="siimple-code">siimple-content--[SIZE]</code> class. </div> <pre class="siimple-pre"> -&lt;div class="siimple-content siimple--large"&gt; +&lt;div class="siimple-content siimple-content--large"&gt; Lorem ipsum dolor sit amet, consectetur adipiscing elit... &lt;/div&gt; </pre>
1
diff --git a/articles/user-profile/normalized.md b/articles/user-profile/normalized.md @@ -41,7 +41,7 @@ The `identities` array contains the following attributes: **NOTE:** Auth0 will pass to your app all other properties supplied by the identity provider, even if those that are not mapped to the standard attributes listed above. -## Storing User Data +## Store User Data When outsourcing user authentication, there is usually no need to maintain your own users/passwords table. Even so, you may still want to associate application data to authenticated users. @@ -158,3 +158,16 @@ This is a sample profile from **ADFS (Active Directory Federation Services)**: "user_id": "adfs|[email protected]" } ``` + +## How to retrieve the User Profile + +You can retrieve the user profile using [Lock](/libraries/lock/v10/api#getuserinfo-), [Auth0.js](/libraries/auth0js#user-management), or our [Authentication API /userinfo endpoint](/api/authentication#get-user-info). + +We also have a _User Profile_ section on most of our [quickstarts](/quickstarts). Some of the most popular technologies we offer quickstarts and samples for are: +- [Android](/quickstart/native/android/04-user-profile) +- [Angular 1.x](/quickstart/spa/angularjs/04-user-profile) and [Angular 2](/quickstart/spa/angular2/04-user-profile) +- [React](/quickstart/spa/react/04-user-profile) +- [Node.js](/quickstart/webapp/nodejs/04-user-profile) +- [ASP .NET Core](/quickstart/webapp/aspnet-core/05-user-profile) +- [jQuery](/quickstart/spa/jquery/04-user-profile) +- and [many more](/quickstarts)
0
diff --git a/policykit/policyengine/templates/policyengine/v2/index.html b/policykit/policyengine/templates/policyengine/v2/index.html {% else %} {% display_action event.action_object %} {% endif %} - + {% endfor %} <!-- {# Time #} {{ event.timestamp|timesince }} --> </div>
0
diff --git a/sketch/README.md b/sketch/README.md # Using the Sketch Files -## System Icons: +## System Icons This is to explain the different methods and tools used to maintain `ids-icons-system.sketch` in the Uplift theme. (Please note that no changes to the icons Sketch files in `theme-soho` are permitted at this time unless requested otherwise). @@ -53,12 +53,12 @@ This is to explain the different methods and tools used to maintain `ids-icons-s ### Sketch Plugin -- Sort Me "https://github.com/romashamin/sort-me-sketch". +- [Sort Me](https://github.com/romashamin/sort-me-sketch) -## App Icons: +## App Icons This is to explain the different methods and tools used to maintain `ids-icons-apps.sketch`, in the Uplift theme, which contains Application/Product Icons for Infor Ming.le. -## Fancy Icons: +## Fancy Icons `ids-icons-fancy.sketch` contains accent icons, empty state icons, each in their own page respectively. Fancy icons should be black at varying opacity.
1
diff --git a/src/components/seo.js b/src/components/seo.js @@ -53,7 +53,7 @@ function SEO({ description, lang, meta, title }) { }, { name: `twitter:card`, - content: `summary`, + content: `summary_large_image`, }, { name: `twitter:creator`,
4
diff --git a/modules/site/parent_templates/site/common/js/application.js b/modules/site/parent_templates/site/common/js/application.js @@ -3199,29 +3199,24 @@ var XBOOTSTRAP = (function ($, parent) { var self = parent.VARIABLES = {}; ); for (var k=0; k<variables.length; k++) { - // if it's first attempt to replace vars on this page look at vars in image & mathjax tags first + // if it's first attempt to replace vars on this page look at vars in image, iframe, a & mathjax tags first // these are simply replaced with no surrounding tag so vars can be used as image sources etc. - if (tempText.indexOf('[' + variables[k].name + ']') != -1) { - var $tempText = $(tempText); - for (var m=0; m<$tempText.find('img').length; m++){ - var tempImgTag = $tempText.find('img')[m].outerHTML, - regExp2 = new RegExp('\\[' + variables[k].name + '\\]', 'g'); - tempImgTag = tempImgTag.replace(regExp2, checkDecimalSeparator(variables[k].value)); - $($tempText.find('img')[m]).replaceWith(tempImgTag); - } - tempText = $tempText.map(function(){ return this.outerHTML; }).get().join(''); - } + var tags = ['img', '.mathjax', 'iframe', 'a']; + + for (var p=0; p<tags.length; p++) { + var thisTag = tags[p]; if (tempText.indexOf('[' + variables[k].name + ']') != -1) { - var $tempText = $(tempText); - for (var m=0; m<$tempText.find('.mathjax').length; m++){ - var tempImgTag = $tempText.find('.mathjax')[m].outerHTML, + var $tempText = $(tempText).length == 0 ? $('<span>' + tempText + '</span>') : $(tempText); + for (var m=0; m<$tempText.find(thisTag).length; m++){ + var tempTag = $tempText.find(thisTag)[m].outerHTML, regExp2 = new RegExp('\\[' + variables[k].name + '\\]', 'g'); - tempImgTag = tempImgTag.replace(regExp2, checkDecimalSeparator(variables[k].value)); - $($tempText.find('.mathjax')[m]).replaceWith(tempImgTag); + tempTag = tempTag.replace(regExp2, checkDecimalSeparator(variables[k].value)); + $($tempText.find(thisTag)[m]).replaceWith(tempTag); } tempText = $tempText.map(function(){ return this.outerHTML; }).get().join(''); } + } // replace with the variable text (this looks at both original variable mark up (e.g. [a]) & the tag it's replaced with as it might be updating a variable value that's already been inserted) var regExp = new RegExp('\\[' + variables[k].name + '\\]|<span class="x_var x_var_' + variables[k].name + '">(.*?)</span>', 'g');
11
diff --git a/pages/measurement.js b/pages/measurement.js @@ -34,11 +34,12 @@ export default class Measurement extends React.Component { } let msmtContent = await client.get(measurementUrl) initialProps['measurement'] = msmtContent.data + let countries = countriesR.data.countries - const { name: country } = countries.find(c => + const countryObj = countries.find(c => c.alpha_2 === msmtContent.data.probe_cc ) - initialProps['country'] = country + initialProps['country'] = (countryObj) ? countryObj.name : 'Unknown' } return initialProps }
9
diff --git a/CHANGELOG.md b/CHANGELOG.md @@ -9,6 +9,13 @@ To see all merged commits on the master branch that will be part of the next plo where X.Y.Z is the semver of most recent plotly.js release. +## [1.58.1] -- 2020-12-04 + +### Fixed + - Fix `automargin` bug for the case of short remaining height or width for plot [#5315], + (regression introduced in 1.58.0) + + ## [1.58.0] -- 2020-12-02 ### Added
3
diff --git a/src/modules/app/initialize/AppRun.js b/src/modules/app/initialize/AppRun.js event.preventDefault(); } + if (toState.name === 'desktop' && !this._canOpenDesktopPage) { + event.preventDefault(); + $state.go(START_STATES[0]); + } + if (needShowTutorial && toState.name !== 'dex-demo') { modalManager.showTutorialModals(); needShowTutorial = false; // } else { $state.go(states[0]); // } - } else if (currentState.name === 'desktop' && !this._canOpenDesktopPage) { - $state.go(states[0]); } return user.onLogin();
1
diff --git a/karma.conf.js b/karma.conf.js @@ -169,7 +169,7 @@ module.exports = function(config) { // level of logging // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG - logLevel: process.env.ABLY_LOG_LEVEL, + logLevel: config.LOG_WARN, // enable / disable watching file and executing tests whenever any file changes
12
diff --git a/src/traces/splom/index.js b/src/traces/splom/index.js @@ -74,6 +74,11 @@ function calc(gd, trace) { } } + // augment options with proper upper/lower halves + if(!trace.showupperhalf) opts.upper = false; + if(!trace.showlowerhalf) opts.lower = false; + if(!trace.diagonal.visible) opts.diagonal = false; + var scene = stash._scene = sceneUpdate(gd, stash); if(!scene.matrix) scene.matrix = true; scene.matrixOptions = opts;
9
diff --git a/src/vdom/diff.js b/src/vdom/diff.js @@ -40,7 +40,7 @@ export function diff(dom, vnode, context, mountAll, parent, componentRoot) { // when first starting the diff, check if we're diffing an SVG or within an SVG isSvgMode = parent!=null && parent.ownerSVGElement!==undefined; - // hydration is inidicated by the existing element to be diffed not having a prop cache + // hydration is indicated by the existing element to be diffed not having a prop cache hydrating = dom!=null && !(ATTR_KEY in dom); }
1
diff --git a/src/sdk/conference/channel.js b/src/sdk/conference/channel.js @@ -104,7 +104,9 @@ export class ConferencePeerConnectionChannel extends EventDispatcher { } this._options = options; const mediaOptions = {}; - if (stream.mediaStream.getAudioTracks().length > 0) { + this._createPeerConnection(); + if (stream.mediaStream.getAudioTracks().length > 0 && options.audio !== + false && options.audio !== null) { if (stream.mediaStream.getAudioTracks().length > 1) { Logger.warning( 'Publishing a stream with multiple audio tracks is not fully supported.' @@ -118,10 +120,14 @@ export class ConferencePeerConnectionChannel extends EventDispatcher { } mediaOptions.audio = {}; mediaOptions.audio.source = stream.source.audio; + for(const track of stream.mediaStream.getAudioTracks()){ + this._pc.addTrack(track); + } } else { mediaOptions.audio = false; } - if (stream.mediaStream.getVideoTracks().length > 0) { + if (stream.mediaStream.getVideoTracks().length > 0 && options.video !== + false && options.video !== null) { if (stream.mediaStream.getVideoTracks().length > 1) { Logger.warning( 'Publishing a stream with multiple video tracks is not fully supported.' @@ -137,6 +143,9 @@ export class ConferencePeerConnectionChannel extends EventDispatcher { }, framerate: trackSettings.frameRate }; + for(const track of stream.mediaStream.getVideoTracks()){ + this._pc.addTrack(track); + } } else { mediaOptions.video = false; } @@ -151,8 +160,6 @@ export class ConferencePeerConnectionChannel extends EventDispatcher { }); this.dispatchEvent(messageEvent); this._internalId = data.id; - this._createPeerConnection(); - this._pc.addStream(stream.mediaStream); const offerOptions = { offerToReceiveAudio: false, offerToReceiveVideo: false
11
diff --git a/boilerplate/test/contract_spec.js b/boilerplate/test/contract_spec.js var assert = require('assert'); -var Embark = require('embark'); -var EmbarkSpec = Embark.initTests(); -var web3 = EmbarkSpec.web3; +var EmbarkSpec = require('embark/lib/core/test.js'); + // describe("SimpleStorage", function() { // before(function(done) {
3
diff --git a/.travis.yml b/.travis.yml @@ -20,7 +20,7 @@ before_script: - DIST=./dist/debug ./bin/fauxton & - sleep 30 script: - - ./node_modules/grunt-cli/bin/grunt nightwatch + - travis_retry ./node_modules/.bin/grunt nightwatch after_script: - npm run docker:down
4
diff --git a/articles/architecture-scenarios/implementations/spa-api/spa-implementation-angular2.md b/articles/architecture-scenarios/implementations/spa-api/spa-implementation-angular2.md @@ -428,4 +428,4 @@ public unscheduleRenewal() { } ``` -Finally you need to initiate the schedule renewal. This can be done by calling the `cheduleRenewal` inside your `AppComponent` which will happen when the page is loaded. This will occur after every authentication flow, either when the user explicitly logs in, or when the silent authentication happens.g \ No newline at end of file +Finally you need to initiate the schedule renewal. This can be done by calling the `scheduleRenewal` inside your `AppComponent` which will happen when the page is loaded. This will occur after every authentication flow, either when the user explicitly logs in, or when the silent authentication happens. \ No newline at end of file
1
diff --git a/public/app/js/cbus-data.js b/public/app/js/cbus-data.js @@ -564,9 +564,7 @@ cbus.broadcast.listen("startFeedsImport", function(e) { } }); } - remote.dialog.showMessageBox(remote.getCurrentWindow(), { - message: "Subscriptions now importing. May take time to gather all necessary information." - }); + cbus.ui.showSnackbar("Subscriptions now importing. May take time to gather necessary information."); }) }); });
14
diff --git a/src/components/Calendar.js b/src/components/Calendar.js @@ -191,7 +191,7 @@ class Calendar extends React.Component { return ( <a - aria-label={day.format('dddd, MMMM Do, YYYY')} + aria-label={`${day.format('dddd, MMMM Do, YYYY')}${isSelectedDay ? ', Currently Selected' : ''}`} className='calendar-day' id={ day.isSame(moment.unix(this.state.focusedDay), 'day') ?
9
diff --git a/camera-manager.js b/camera-manager.js @@ -140,6 +140,8 @@ class CameraManager extends EventTarget { update(timeDiff) { const localPlayer = metaversefile.useLocalPlayer(); + const startMode = this.getMode(); + let newVal = cameraOffsetTargetZ; let hasIntersection = false; @@ -230,6 +232,15 @@ class CameraManager extends EventTarget { camera.position.sub(localVector.copy(cameraOffset).applyQuaternion(camera.quaternion)); camera.updateMatrixWorld(); } + + const endMode = this.getMode(); + if (endMode !== startMode) { + this.dispatchEvent(new MessageEvent('modechange', { + data: { + mode: endMode, + }, + })); + } } }; const cameraManager = new CameraManager();
0
diff --git a/ext/abp-filter-parser-modified/abp-filter-parser.js b/ext/abp-filter-parser-modified/abp-filter-parser.js @@ -455,12 +455,15 @@ function matchOptions (filterOptions, input, contextParams, currentHost) { subdomains are also considered "same origin hosts" for the purposes of thirdParty and domain list checks see https://adblockplus.org/filter-cheatsheet#options: "The page loading it comes from example.com domain (for example example.com itself or subdomain.example.com) but not from foo.example.com or its subdomains" + + Additionally, subdomain matches are bidrectional, i.e. a request for "a.b.com" on "b.com" and a request for "b.com" on "a.b.com" are both first-party */ - if (filterOptions.thirdParty && isSameOriginHost(contextParams.domain, currentHost)) { + + if (filterOptions.thirdParty && (isSameOriginHost(contextParams.domain, currentHost) || isSameOriginHost(currentHost, contextParams.domain))) { return false } - if (filterOptions.notThirdParty && !isSameOriginHost(contextParams.domain, currentHost)) { + if (filterOptions.notThirdParty && !(isSameOriginHost(contextParams.domain, currentHost) || isSameOriginHost(currentHost, contextParams.domain))) { return false }
7
diff --git a/src/parser/character/ac.js b/src/parser/character/ac.js @@ -98,10 +98,12 @@ function getUnarmoredAC(modifiers, character) { // }); // } + const ignoreDex = modifiers.some((modifier) => modifier.type === "ignore" && modifier.subType === "unarmored-dex-ac-bonus"); + const maxUnamoredDexMods = modifiers.filter( (modifier) => modifier.type === "set" && modifier.subType === "ac-max-dex-modifier" && modifier.isGranted ).map((mods) => mods.value); - const maxUnamoredDexMod = Math.min(...maxUnamoredDexMods, 20); + const maxUnamoredDexMod = ignoreDex ? 0 : Math.min(...maxUnamoredDexMods, 20); // console.log(`Max Dex: ${maxUnamoredDexMod}`); const characterAbilities = character.flags.ddbimporter.dndbeyond.effectAbilities; @@ -119,10 +121,8 @@ function getUnarmoredAC(modifiers, character) { if (unarmored.statId !== null) { let ability = DICTIONARY.character.abilities.find((ability) => ability.id === unarmored.statId); unarmoredACValue += characterAbilities[ability.value].mod; - } else { - // others are picked up here e.g. Draconic Resilience - unarmoredACValue += unarmored.value; } + if (unarmored.value) unarmoredACValue += unarmored.value; unarmoredACValues.push(unarmoredACValue); }); // console.warn(unarmoredACValues); @@ -441,11 +441,12 @@ export function getArmorClass(ddb, character) { switch (ddb.character.race.fullName) { case "Lizardfolk": baseAC = Math.max(getUnarmoredAC(ddb.character.modifiers.race, character)); - equippedArmor.push(getBaseArmor(baseAC, "Natural Armor", "Lizardfolk")); + equippedArmor.push(getBaseArmor(baseAC, "Natural Armor", ddb.character.race.fullName)); break; + case "Loxodon": case "Tortle": baseAC = Math.max(getMinimumBaseAC(ddb.character.modifiers.race, character), getUnarmoredAC(ddb.character.modifiers.race, character)); - equippedArmor.push(getBaseArmor(baseAC, "Natural Armor", "Tortle")); + equippedArmor.push(getBaseArmor(baseAC, "Natural Armor", ddb.character.race.fullName)); break; default: equippedArmor.push(getBaseArmor(baseAC, "Unarmored"));
7
diff --git a/edit.js b/edit.js @@ -303,15 +303,18 @@ const _makePlanetMesh = (tileScale = 1) => { const mesh = new THREE.Mesh(geometry, material); return mesh; }; +const planetContainer = new THREE.Object3D(); +scene.add(planetContainer); + const planetMesh = _makePlanetMesh(0.95); -// planetMesh.position.x = -10; planetMesh.position.y = -10/2; -// planetMesh.position.z = -10; -scene.add(planetMesh); +planetContainer.add(planetMesh); +const planetAuxContainer = new THREE.Object3D(); const planetAuxMesh = _makePlanetMesh(); planetAuxMesh.position.copy(planetMesh.position); planetAuxMesh.updateMatrixWorld(); +planetAuxContainer.add(planetAuxMesh); const numRemotePlanetMeshes = 10; for (let i = 0; i < numRemotePlanetMeshes; i++) { @@ -322,7 +325,7 @@ for (let i = 0; i < numRemotePlanetMeshes; i++) { textMesh.position.y = 10; remotePlanetMesh.add(textMesh); - scene.add(remotePlanetMesh); + planetContainer.add(remotePlanetMesh); } @@ -378,22 +381,22 @@ const _animatePlanet = (startMatrix, pivot, startQuaternion, endQuaternion) => { startQuaternion, endQuaternion, }; - planetAuxMesh.matrix + planetAuxContainer.matrix .copy(startMatrix) .premultiply(localMatrix2.makeTranslation(-pivot.x, -pivot.y, -pivot.z)) .premultiply(localMatrix2.makeRotationFromQuaternion(localQuaternion.copy(startQuaternion).slerp(endQuaternion, 1))) .premultiply(localMatrix2.makeTranslation(pivot.x, pivot.y, pivot.z)) - .decompose(planetAuxMesh.position, planetAuxMesh.quaternion, planetAuxMesh.scale) - planetAuxMesh.updateMatrixWorld(); + .decompose(planetAuxContainer.position, planetAuxContainer.quaternion, planetAuxContainer.scale) + planetAuxContainer.updateMatrixWorld(); }; const _tickPlanetAnimation = factor => { const {startTime, endTime, startMatrix, pivot, startQuaternion, endQuaternion} = planetAnimation; - planetMesh.matrix + planetContainer.matrix .copy(startMatrix) .premultiply(localMatrix2.makeTranslation(-pivot.x, -pivot.y, -pivot.z)) .premultiply(localMatrix2.makeRotationFromQuaternion(localQuaternion.copy(startQuaternion).slerp(endQuaternion, factor))) .premultiply(localMatrix2.makeTranslation(pivot.x, pivot.y, pivot.z)) - .decompose(planetMesh.position, planetMesh.quaternion, planetMesh.scale); + .decompose(planetContainer.position, planetContainer.quaternion, planetContainer.scale); if (factor >= 1) { planetAnimation = null; } @@ -430,7 +433,7 @@ function animate(timestamp, frame) { planetAnimation && _tickPlanetAnimation(1); const sub = lastParcel.clone().sub(currentParcel); const pivot = currentParcel.clone().add(lastParcel).multiplyScalar(10/2); - _animatePlanet(planetMesh.matrix.clone(), pivot, new THREE.Quaternion(), new THREE.Quaternion().setFromUnitVectors(new THREE.Vector3(0, 1, 0), sub)); + _animatePlanet(planetContainer.matrix.clone(), pivot, new THREE.Quaternion(), new THREE.Quaternion().setFromUnitVectors(new THREE.Vector3(0, 1, 0), sub)); lastParcel = currentParcel; }
0
diff --git a/website/ops.py b/website/ops.py @@ -637,8 +637,8 @@ def searchEntries(dictDB: Connection, configs: Configs, doctype: str, searchtext results = sortEntries(configs, results, reverse=sortdesc) total = len(results) - if (limit is not None and limit > 0): - results = results[0:limit] + if (limit is not None and int(limit) > 0): + results = results[0:int(limit)] return total, results def readEntries(dictDB: Connection, configs: Configs, ids: Union[int, List[int], List[SortableEntry]], xml: bool=True, tag: bool=False, html: bool=False, titlePlain: bool = False, sortdesc: Union[str, bool] = False) -> List[EntryFromDatabase]: @@ -2276,7 +2276,7 @@ def readRandoms(dictDB: Connection): ids_and_sortkeys.append({"id": r["id"], "sortkey": r["sortkey"]}) return { - "entries": readEntries(dictDB, configs, ids_and_sortkeys), + "entries": readEntries(dictDB, configs, ids_and_sortkeys, titlePlain=True), "more": dictDB.execute("select count(*) as total from entries").fetchone()["total"] > limit }
1
diff --git a/generators/entity-server/templates/src/test/gatling/user-files/simulations/EntityGatlingTest.scala.ejs b/generators/entity-server/templates/src/test/gatling/user-files/simulations/EntityGatlingTest.scala.ejs @@ -38,7 +38,7 @@ class <%= entityClass %>GatlingTest extends Simulation { // Log failed HTTP requests //context.getLogger("io.gatling.http").setLevel(Level.valueOf("DEBUG")) - val baseURL = Option(System.getProperty("baseURL")) getOrElse """http://localhost:8080""" + val baseURL = Option(System.getProperty("baseURL")) getOrElse """http://localhost:<%= serverPort %>""" val httpConf = http .baseUrl(baseURL)
14
diff --git a/imports/startup/both/modules/metamask.js b/imports/startup/both/modules/metamask.js @@ -45,9 +45,7 @@ const _web3 = (activateModal) => { return false; } if (!web3) { - // We don't know window.web3 version, so we use our own instance of web3 - // with provider given by window.web3 - web3 = new Web3(window.web3.currentProvider); + web3 = new Web3(window.ethereum); } web3.eth.getCoinbase().then(function (coinbase) { @@ -203,10 +201,12 @@ if (Meteor.isClient) { const loginWithMetamask = () => { if (_web3(true)) { const nonce = Math.floor(Math.random() * 10000); - // const publicAddress = web3.eth.getCoinbase.toLowerCase(); + let publicAddress; - web3.eth.getCoinbase().then(function (coinbaseAddress) { + window.ethereum.enable().then(function () { + return web3.eth.getCoinbase(); + }).then(function (coinbaseAddress) { publicAddress = coinbaseAddress.toLowerCase(); return handleSignMessage(publicAddress, nonce); }).then(function (signature) {
9
diff --git a/routes/profile.js b/routes/profile.js @@ -58,6 +58,7 @@ router.post("/mod/ajax/processavatarrequest", middleware.isLoggedIn, middleware. avatarRequest.findById(req.body.avatarreqid).exec(function(err, foundReq){ if(err){console.log(err);} else{ + if(foundReq){ foundReq.processed = true; foundReq.modComment = req.body.modcomment; foundReq.approved = req.body.decision; @@ -114,6 +115,7 @@ router.post("/mod/ajax/processavatarrequest", middleware.isLoggedIn, middleware. foundReq.save(); } + } }); // console.log(mongoose.Types.ObjectId(req.query.idOfNotif));
1
diff --git a/tasks/util/constants.js b/tasks/util/constants.js @@ -124,7 +124,7 @@ module.exports = { licenseSrc: [ '/**', - '* Copyright 2012-' + year + ', Plotly, Inc.', + '* Copyright 2012-' + '2020' + ', Plotly, Inc.', '* All rights reserved.', '*', '* This source code is licensed under the MIT license found in the',
12
diff --git a/app/components/Account/CreateAccountPassword.jsx b/app/components/Account/CreateAccountPassword.jsx @@ -5,7 +5,6 @@ import AccountActions from "actions/AccountActions"; import AccountStore from "stores/AccountStore"; import AccountNameInput from "./../Forms/AccountNameInput"; import WalletDb from "stores/WalletDb"; -import notify from "actions/NotificationActions"; import {Link} from "react-router-dom"; import AccountSelect from "../Forms/AccountSelect"; import TransactionConfirmStore from "stores/TransactionConfirmStore"; @@ -21,6 +20,7 @@ import Icon from "../Icon/Icon"; import CopyButton from "../Utility/CopyButton"; import {withRouter} from "react-router-dom"; import {scroller} from "react-scroll"; +import {Notification} from "bitshares-ui-style-guide"; class CreateAccountPassword extends React.Component { constructor() { @@ -172,11 +172,17 @@ class CreateAccountPassword extends React.Component { ? error.base[0] : "unknown error"; if (error.remote_ip) error_msg = error.remote_ip[0]; - notify.addNotification({ - message: `Failed to create account: ${name} - ${error_msg}`, - level: "error", - autoDismiss: 10 + + Notification.error({ + message: counterpart.translate( + "notifications.account_create_failure", + { + account_name: name, + error_msg: error_msg + } + ) }); + this.setState({loading: false}); }); } @@ -258,7 +264,9 @@ class CreateAccountPassword extends React.Component { <section className="form-group"> <label className="left-label"> - <Translate content="wallet.generated" />&nbsp;&nbsp;<span + <Translate content="wallet.generated" /> + &nbsp;&nbsp; + <span className="tooltip" data-html={true} data-tip={counterpart.translate( @@ -691,11 +699,14 @@ class CreateAccountPassword extends React.Component { CreateAccountPassword = withRouter(CreateAccountPassword); -export default connect(CreateAccountPassword, { +export default connect( + CreateAccountPassword, + { listenTo() { return [AccountStore]; }, getProps() { return {}; } -}); + } +);
14
diff --git a/civictechprojects/static/css/partials/_AboutProject.scss b/civictechprojects/static/css/partials/_AboutProject.scss .AboutProjects_tabs { clear: both; display:flex; + flex-direction: row; // column mobile, row desktop flex-wrap: wrap; justify-self: flex-start; align-self: flex-end; .AboutProjects-positions-available { border-bottom: $color-grey-disabled solid 1px; } + .AboutProjects_tabs { + flex-direction: column; + } }
12
diff --git a/token-metadata/0x827Eed050df933F6fda3A606b5F716cec660ECBa/metadata.json b/token-metadata/0x827Eed050df933F6fda3A606b5F716cec660ECBa/metadata.json "symbol": "BD", "address": "0x827Eed050df933F6fda3A606b5F716cec660ECBa", "decimals": 8, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/src/abstract-ops/testing-comparison.mjs b/src/abstract-ops/testing-comparison.mjs @@ -263,7 +263,7 @@ export function AbstractRelationalComparison(x, y, LeftFirst = true) { } let k = 0; while (true) { - if (px.stringValue()[k] !== py.stringValue[k]) { + if (px.stringValue()[k] !== py.stringValue()[k]) { break; } k += 1; @@ -281,7 +281,7 @@ export function AbstractRelationalComparison(x, y, LeftFirst = true) { if (nx.isNaN()) { return Value.undefined; } - if (y.isNaN()) { + if (ny.isNaN()) { return Value.undefined; } // If nx and ny are the same Number value, return false.
1
diff --git a/components/mapbox/open-gps.js b/components/mapbox/open-gps.js @@ -11,7 +11,6 @@ function OpenGPS({lat, lon, isSafariBrowser}) { <button type='button' className='mapboxgl-ctrl' - title='Ouvrir le GPS' > <MapPin size={18} /> </button>
2
diff --git a/admin/client/App/screens/Item/actions.js b/admin/client/App/screens/Item/actions.js @@ -136,7 +136,7 @@ export function deleteItem (id, router) { } // TODO Proper error handling if (err) { - alert('Error deleting item, please try again!'); + alert(err.error || 'Error deleting item, please try again!'); } else { dispatch(loadItems()); }
3
diff --git a/src/plots/smith/helpers.js b/src/plots/smith/helpers.js @@ -59,17 +59,6 @@ function smith(a) { return circleCircleIntersect(reactanceCircle(X), resistanceCircle(R)); } -function smithInvert(a) { - var x = a[0]; - var y = a[1]; - - if(hypot(x, y) > 1) return; - return [ - (1 - x * x - y * y) / (x * x - 2 * x + y * y + 1), - 2 * y / ((x - 1) * (x - 1) + y * y) - ]; -} - function transform(subplot, a) { var x = a[0]; var y = a[1]; @@ -139,7 +128,6 @@ function resistanceArc(subplot, R, X1, X2) { module.exports = { smith: smith, - smithInvert: smithInvert, reactanceArc: reactanceArc, resistanceArc: resistanceArc, smithTransform: transform
2
diff --git a/src/core/operations/MicrosoftScriptDecoder.mjs b/src/core/operations/MicrosoftScriptDecoder.mjs @@ -24,6 +24,13 @@ class MicrosoftScriptDecoder extends Operation { this.inputType = "string"; this.outputType = "string"; this.args = []; + this.checks = [ + { + pattern: "#@~\\^.{6}==(.+).{6}==\\^#~@", + flags: "i", + args: [] + } + ]; } /**
0
diff --git a/android/src/main/java/com/RNFetchBlob/Utils/PathResolver.java b/android/src/main/java/com/RNFetchBlob/Utils/PathResolver.java @@ -59,6 +59,14 @@ public class PathResolver { return getDataColumn(context, contentUri, selection, selectionArgs); } + else if ("content".equalsIgnoreCase(uri.getScheme())) { + + // Return the remote address + if (isGooglePhotosUri(uri)) + return uri.getLastPathSegment(); + + return getDataColumn(context, uri, null, null); + } } // MediaStore (and general) else if ("content".equalsIgnoreCase(uri.getScheme())) { @@ -103,7 +111,12 @@ public class PathResolver { final int index = cursor.getColumnIndexOrThrow(column); return cursor.getString(index); } - } finally { + } + catch (Exception ex) { + ex.printStackTrace(); + return null; + } + finally { if (cursor != null) cursor.close(); }
0
diff --git a/docs/topics/multiplatform-mobile/multiplatform-mobile-understand-project-structure.md b/docs/topics/multiplatform-mobile/multiplatform-mobile-understand-project-structure.md @@ -264,10 +264,10 @@ The configuration of Android library is stored in the `android {}` top-level blo ```kotlin android { - compileSdkVersion(29) + compileSdk = 29 defaultConfig { - minSdkVersion(24) - targetSdkVersion(29) + minSdk = 24 + targetSdk = 29 versionCode = 1 versionName = "1.0" } @@ -284,10 +284,10 @@ android { ```groovy android { - compileSdkVersion 29 + compileSdk 29 defaultConfig { - minSdkVersion 24 - targetSdkVersion 29 + minSdk 24 + targetSdk 29 versionCode 1 versionName '1.0' } @@ -456,11 +456,11 @@ The build configuration of the Android application is located in the `android {} ```kotlin android { - compileSdkVersion(29) + compileSdk = 29 defaultConfig { applicationId = "org.example.androidApp" - minSdkVersion(24) - targetSdkVersion(29) + minSdk = 24 + targetSdk = 29 versionCode = 1 versionName = "1.0" } @@ -477,11 +477,11 @@ android { ```groovy android { - compileSdkVersion 29 + compileSdk 29 defaultConfig { applicationId 'org.example.androidApp' - minSdkVersion 24 - targetSdkVersion 29 + minSdk 24 + targetSdk 29 versionCode 1 versionName '1.0' }
14
diff --git a/lib/cli.js b/lib/cli.js @@ -330,7 +330,7 @@ exports.run = async () => { // eslint-disable-line complexity require: arrify(combined.require), serial: combined.serial, snapshotDir: combined.snapshotDir ? path.resolve(projectDir, combined.snapshotDir) : null, - timeout: combined.timeout, + timeout: combined.timeout || '10s', updateSnapshots: combined.updateSnapshots, workerArgv: argv['--'] });
12
diff --git a/src/setattr.js b/src/setattr.js @@ -14,6 +14,8 @@ export const setAttr = (view, arg1, arg2) => { setStyle(el, arg2); } else if (isSVG && isFunction(arg2)) { el[arg1] = arg2; + } else if (arg1 === 'dataset') { + setData(el, arg2); } else if (!isSVG && (arg1 in el || isFunction(arg2))) { el[arg1] = arg2; } else { @@ -35,3 +37,9 @@ function setXlink (el, obj) { el.setAttributeNS(xlinkns, key, obj[key]); } } + +function setData (el, obj) { + for (const key in obj) { + el.dataset[key] = obj[key]; + } +}
0
diff --git a/app/src/RoomClient.js b/app/src/RoomClient.js @@ -810,6 +810,8 @@ export default class RoomClient 'changeAudioDevice() | new selected webcam [device:%o]', device); + this._micProducer.track.stop(); + logger.debug('changeAudioDevice() | calling getUserMedia()'); const stream = await navigator.mediaDevices.getUserMedia( @@ -822,14 +824,18 @@ export default class RoomClient const track = stream.getAudioTracks()[0]; - const newTrack = await this._micProducer.replaceTrack(track); + await this._micProducer.replaceTrack({ track }); const harkStream = new MediaStream(); - harkStream.addTrack(newTrack); + harkStream.addTrack(track); + if (!harkStream.getAudioTracks()[0]) throw new Error('changeAudioDevice(): given stream has no audio track'); - if (this._micProducer.hark != null) this._micProducer.hark.stop(); + + if (this._micProducer.hark != null) + this._micProducer.hark.stop(); + this._micProducer.hark = hark(harkStream, { play: false }); // eslint-disable-next-line no-unused-vars @@ -855,7 +861,7 @@ export default class RoomClient track.stop(); store.dispatch( - stateActions.setProducerTrack(this._micProducer.id, newTrack)); + stateActions.setProducerTrack(this._micProducer.id, track)); store.dispatch(stateActions.setSelectedAudioDevice(deviceId)); @@ -1885,8 +1891,10 @@ export default class RoomClient const harkStream = new MediaStream(); harkStream.addTrack(track); + if (!harkStream.getAudioTracks()[0]) throw new Error('enableMic(): given stream has no audio track'); + this._micProducer.hark = hark(harkStream, { play: false }); // eslint-disable-next-line no-unused-vars
3
diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/editors/code-editors/monaco.js b/packages/node_modules/@node-red/editor-client/src/js/ui/editors/code-editors/monaco.js @@ -150,19 +150,6 @@ RED.editor.codeEditor.monaco = (function() { function init(options) { - //Handles "Uncaught (in promise) Canceled: Canceled" - //@see https://github.com/microsoft/monaco-editor/issues/2382 - //This is fixed in commit microsoft/vscode@49cad9a however it is not yet present monaco-editor - //Remove the below addEventListener once monaco-editor V0.23.1 or greater is published - window.addEventListener('unhandledrejection', function(evt) { - if(evt && evt.reason && evt.reason.stack) { - if (evt.reason.name === 'Canceled' && evt.reason.stack.indexOf('vendor/monaco/dist') >= 0) { - evt.preventDefault(); - evt.stopImmediatePropagation(); - } - } - }); - //Handles orphaned models //ensure loaded models that are not explicitly destroyed by a call to .destroy() are disposed RED.events.on("editor:close",function() {
2
diff --git a/test/jasmine/assets/custom_matchers.js b/test/jasmine/assets/custom_matchers.js @@ -64,25 +64,11 @@ var matchers = { }; }, - // toBeCloseTo... but for arrays toBeCloseToArray: function() { return { compare: function(actual, expected, precision, msgExtra) { - precision = coercePosition(precision); - - var passed; - - if(Array.isArray(actual) && Array.isArray(expected)) { - var tested = actual.map(function(element, i) { - return isClose(element, expected[i], precision); - }); - - passed = ( - expected.length === actual.length && - tested.indexOf(false) < 0 - ); - } - else passed = false; + var testFn = makeIsCloseFn(coercePosition(precision)); + var passed = assertArray(actual, expected, testFn); var message = [ 'Expected', actual, 'to be close to', expected, msgExtra @@ -96,30 +82,11 @@ var matchers = { }; }, - // toBeCloseTo... but for 2D arrays toBeCloseTo2DArray: function() { return { compare: function(actual, expected, precision, msgExtra) { - precision = coercePosition(precision); - - var passed = true; - - if(expected.length !== actual.length) passed = false; - else { - for(var i = 0; i < expected.length; ++i) { - if(expected[i].length !== actual[i].length) { - passed = false; - break; - } - - for(var j = 0; j < expected[i].length; ++j) { - if(!isClose(actual[i][j], expected[i][j], precision)) { - passed = false; - break; - } - } - } - } + var testFn = makeIsCloseFn(coercePosition(precision)); + var passed = assert2DArray(actual, expected, testFn); var message = [ 'Expected', @@ -140,7 +107,29 @@ var matchers = { toBeWithin: function() { return { compare: function(actual, expected, tolerance, msgExtra) { - var passed = Math.abs(actual - expected) < tolerance; + var testFn = makeIsWithinFn(tolerance); + var passed = testFn(actual, expected); + + var message = [ + 'Expected', actual, + 'to be close to', expected, + 'within', tolerance, + msgExtra + ].join(' '); + + return { + pass: passed, + message: message + }; + } + }; + }, + + toBeWithinArray: function() { + return { + compare: function(actual, expected, tolerance, msgExtra) { + var testFn = makeIsWithinFn(tolerance); + var passed = assertArray(actual, expected, testFn); var message = [ 'Expected', actual, @@ -183,15 +172,59 @@ var matchers = { } }; -function isClose(actual, expected, precision) { +function assertArray(actual, expected, testFn) { + if(Array.isArray(actual) && Array.isArray(expected)) { + var tested = actual.map(function(element, i) { + return testFn(element, expected[i]); + }); + + return ( + expected.length === actual.length && + tested.indexOf(false) < 0 + ); + } + return false; +} + +function assert2DArray(actual, expected, testFn) { + if(expected.length !== actual.length) return false; + + for(var i = 0; i < expected.length; i++) { + if(expected[i].length !== actual[i].length) { + return false; + } + + for(var j = 0; j < expected[i].length; j++) { + if(!testFn(actual[i][j], expected[i][j])) { + return false; + } + } + } + return true; +} + +function makeIsCloseFn(precision) { + return function isClose(actual, expected) { if(isNumeric(actual) && isNumeric(expected)) { return Math.abs(actual - expected) < precision; } + return ( + actual === expected || + (isNaN(actual) && isNaN(expected)) + ); + }; +} +function makeIsWithinFn(tolerance) { + return function isWithin(actual, expected) { + if(isNumeric(actual) && isNumeric(expected)) { + return Math.abs(actual - expected) < tolerance; + } return ( actual === expected || (isNaN(actual) && isNaN(expected)) ); + }; } function coercePosition(precision) {
0
diff --git a/packages/app/src/components/Admin/PluginsExtension/PluginInstallerForm.tsx b/packages/app/src/components/Admin/PluginsExtension/PluginInstallerForm.tsx import React, { useCallback } from 'react'; -import { useTranslation } from 'react-i18next'; - -import { toastSuccess, toastError } from '~/client/util/apiNotification'; import { apiv3Post } from '~/client/util/apiv3-client'; +import { toastError, toastSuccess } from '~/client/util/toastr'; import AdminInstallButtonRow from '../Common/AdminUpdateButtonRow'; // TODO: error notification (toast, loggerFactory) @@ -35,7 +33,6 @@ export const PluginInstallerForm = (): JSX.Element => { } catch (err) { toastError(err); - // logger.error(err); } }, []);
4
diff --git a/server/bootstrap/broadcast.ts b/server/bootstrap/broadcast.ts @@ -5,6 +5,6 @@ export default function(port = 443, httpOnly) { name: `Thorium-${require("os").hostname()}`, type: "thorium-http", port: port, - txt: {https: !httpOnly}, + txt: {https: String(process.env.NODE_ENV === "production" && !httpOnly)}, }); }
1
diff --git a/environment/core/mapgen/SolarSystem.cpp b/environment/core/mapgen/SolarSystem.cpp @@ -85,6 +85,8 @@ namespace mapgen { const auto max_radius = static_cast<int>( std::sqrt(std::min(map.map_width, map.map_height)) / 2); + const auto min_separation = static_cast<int>( + std::sqrt(std::min(map.map_width, map.map_height))); auto rand_x_axis = std::bind( std::uniform_int_distribution<int>(1, map.map_width / 2 - 1), std::ref(rng)); auto rand_y_axis = std::bind( @@ -102,7 +104,7 @@ namespace mapgen { auto is_ok_location = [&](const hlt::Location& location, int radius) -> bool { // I promise this pun was an accident for (const auto& zone : spawn_zones) { - const auto min_distance = zone.radius + radius + 15; + const auto min_distance = zone.radius + radius + min_separation; if (map.get_distance(zone.location, location) <= min_distance) { return false; @@ -110,7 +112,7 @@ namespace mapgen { } for (const auto& zone : planets) { - const auto min_distance = zone.radius + radius + 3; + const auto min_distance = zone.radius + radius + 5; if (map.get_distance(zone.location, location) <= min_distance) { return false; @@ -118,7 +120,7 @@ namespace mapgen { } for (const auto& planet : map.planets) { - const auto min_distance = planet.radius + radius + 15; + const auto min_distance = planet.radius + radius + min_separation; if (map.get_distance(planet.location, location) <= min_distance) { return false;
11
diff --git a/app/core/tokenList.json b/app/core/tokenList.json "image": "https://rawgit.com/CityOfZion/neo-tokens/master/assets/svg/tnc.svg" }, - "TOLL": { - "symbol": "TOLL", + "BRDG": { + "symbol": "BRDG", "companyName": "Bridge Protocol", "type": "NEP5", "networks": { "1": { "name": "Bridge Protocol", - "hash": "78fd589f7894bf9642b4a573ec0e6957dfd84c48", + "hash": "bac0d143a547dc66a1d6a2b7d66b06de42614971", "decimals": 8, - "totalSupply": 708097040 + "totalSupply": 450000000 } } },
3
diff --git a/packages/reason-fela/src/Fela.re b/packages/reason-fela/src/Fela.re @@ -26,6 +26,7 @@ module RendererConfig = { ~selectorPrefix=?, ~keyframePrefixes=?, ~mediaQueryOrder=?, + ~sortMediaQuery=?, ~filterClassName=?, ~plugins=?, ~enhancers=?, @@ -38,6 +39,7 @@ module RendererConfig = { "devMode": devMode, "keyframePrefixes": keyframePrefixes, "mediaQueryOrder": mediaQueryOrder, + "sortMediaQuery": sortMediaQuery, "filterClassName": filterClassName, }; }; @@ -95,7 +97,7 @@ module Plugins = { external namedKeys: Js.t('a) => plugin = "default"; [@bs.module "fela-plugin-named-keys"] - external namedKeysWithProps: (Js.t('a), Js.t('a)) => plugin = "default"; + external namedKeysWithProps: (Js.t('a) => Js.t('a)) => plugin = "default"; [@bs.module "fela-plugin-responsive-value"] external responsiveValue:
1
diff --git a/src/static/js/ace2_inner.js b/src/static/js/ace2_inner.js @@ -556,7 +556,7 @@ function Ace2Inner(){ { doesWrap = newVal; var dwClass = "doesWrap"; - setClassPresence(root, "doesWrap", doesWrap); + root.classList.toggle('doesWrap', doesWrap); scheduler.setTimeout(function() { inCallStackIfNecessary("setWraps", function() @@ -618,7 +618,7 @@ function Ace2Inner(){ { setDesignMode(true); } - setClassPresence(root, "static", !isEditable); + root.classList.toggle('static', !isEditable); } function enforceEditability() @@ -890,25 +890,17 @@ function Ace2Inner(){ // @param value the value to set to editorInfo.ace_setProperty = function(key, value) { - - // Convinience function returning a setter for a class on an element - var setClassPresenceNamed = function(element, cls){ - return function(value){ - setClassPresence(element, cls, !! value) - } - }; - // These properties are exposed var setters = { wraps: setWraps, - showsauthorcolors: setClassPresenceNamed(root, "authorColors"), - showsuserselections: setClassPresenceNamed(root, "userSelections"), + showsauthorcolors: (val) => root.classList.toggle('authorColors', !!val), + showsuserselections: (val) => root.classList.toggle('userSelections', !!val), showslinenumbers : function(value){ hasLineNumbers = !! value; - setClassPresence(sideDiv.parentNode, "line-numbers-hidden", !hasLineNumbers); + sideDiv.parentNode.classList.toggle('line-numbers-hidden', !hasLineNumbers); fixView(); }, - grayedout: setClassPresenceNamed(outerWin.document.body, "grayedout"), + grayedout: (val) => outerWin.document.body.classList.toggle('grayedout', !!val), dmesg: function(){ dmesg = window.dmesg = value; }, userauthor: function(value){ thisAuthor = String(value); @@ -917,8 +909,8 @@ function Ace2Inner(){ styled: setStyled, textface: setTextFace, rtlistrue: function(value) { - setClassPresence(root, "rtl", value) - setClassPresence(root, "ltr", !value) + root.classList.toggle('rtl', value); + root.classList.toggle('ltr', !value); document.documentElement.dir = value? 'rtl' : 'ltr' } }; @@ -4916,12 +4908,6 @@ function Ace2Inner(){ elem.className = array.join(' '); } - function setClassPresence(elem, className, present) - { - if (present) $(elem).addClass(className); - else $(elem).removeClass(className); - } - function focus() { window.focus(); @@ -5335,8 +5321,8 @@ function Ace2Inner(){ if (browser.firefox) $(root).addClass("mozilla"); if (browser.safari) $(root).addClass("safari"); if (browser.msie) $(root).addClass("msie"); - setClassPresence(root, "authorColors", true); - setClassPresence(root, "doesWrap", doesWrap); + root.classList.toggle('authorColors', true); + root.classList.toggle('doesWrap', doesWrap); initDynamicCSS();
14
diff --git a/src/components/Header.js b/src/components/Header.js @@ -80,7 +80,7 @@ const Header = ({ context, setContext }) => { const usingSparkComponents = useUsingSparkData().components.map(page => ( { text: page.node.frontmatter.title, - to: `/using-spark/${page.node.parent.name}`, + to: `/using-spark/components/${page.node.parent.name}`, element: Link, } )); @@ -88,7 +88,7 @@ const Header = ({ context, setContext }) => { const usingSparkExamples = useUsingSparkData().examples.map(page => ( { text: page.node.frontmatter.title, - to: `/using-spark/${page.node.parent.name}`, + to: `/using-spark/examples/${page.node.parent.name}`, element: Link, } )); @@ -96,7 +96,7 @@ const Header = ({ context, setContext }) => { const usingSparkFoundations = useUsingSparkData().foundations.map(page => ( { text: page.node.frontmatter.title, - to: `/using-spark/${page.node.parent.name}`, + to: `/using-spark/foundations/${page.node.parent.name}`, element: Link, } ));
3
diff --git a/packages/vulcan-lib/lib/server/apollo-server/context.js b/packages/vulcan-lib/lib/server/apollo-server/context.js @@ -86,7 +86,7 @@ const getUser = async loginToken => { } // @see https://www.apollographql.com/docs/react/recipes/meteor#Server -const setupAuthToken = async (context, req) => { +export const setupAuthToken = async (context, req) => { const authToken = getAuthToken(req); const user = await getUser(authToken); if (user) {
11
diff --git a/src/traces/scatterpolar/hover.js b/src/traces/scatterpolar/hover.js @@ -19,8 +19,6 @@ module.exports = function hoverPoints(pointData, xval, yval, hovermode) { var newPointData = scatterPointData[0]; // hovering on fill case - // TODO do we need to constrain the scatter point data further (like for - // ternary subplots) or not? if(newPointData.index === undefined) { return scatterPointData; }
0
diff --git a/lib/waterline/utils/query/private/normalize-criteria.js b/lib/waterline/utils/query/private/normalize-criteria.js @@ -301,6 +301,9 @@ module.exports = function normalizeCriteria(criteria, modelIdentity, orm, meta) 'usage has changed. Now, to calculate the minimum value of an attribute '+ 'across multiple records, use the `.find()` model method.\n'+ '\n'+ + 'Alternatively, if you are using `min` as a column/attribute name then '+ + 'please be advised that some things won\'t work as expected.\n'+ + '\n'+ 'For example:\n'+ '```\n'+ '// Get the smallest account balance from amongst all account holders '+'\n'+ @@ -335,6 +338,9 @@ module.exports = function normalizeCriteria(criteria, modelIdentity, orm, meta) 'usage has changed. Now, to calculate the maximum value of an attribute '+ 'across multiple records, use the `.find()` model method.\n'+ '\n'+ + 'Alternatively, if you are using `max` as a column/attribute name then '+ + 'please be advised that some things won\'t work as expected.\n'+ + '\n'+ 'For example:\n'+ '```\n'+ '// Get the largest account balance from amongst all account holders '+'\n'+
0
diff --git a/dashboard/basicPreferences.source.ts b/dashboard/basicPreferences.source.ts @@ -49,7 +49,7 @@ export const basicPreferencesPane: PaneDefinition = { ui:label "I am a Developer". ` - const preferencesForm = kb.sym('https://solid.github.io/solid-panes/dashboard/basicPreferencesForm.ttl#this') + const preferencesForm = kb.sym('urn:uuid:93774ba1-d3b6-41f2-85b6-4ae27ffd2597#this') const preferencesFormDoc = preferencesForm.doc() if (!kb.holds(undefined, undefined, undefined, preferencesFormDoc)) { // If not loaded already (parse as any)(preferencesFormText, kb, preferencesFormDoc.uri, 'text/turtle', null) // Load form directly
4
diff --git a/server/workers/api/src/apis/export.py b/server/workers/api/src/apis/export.py @@ -25,7 +25,7 @@ def transform2bibtex(metadata): "author": author, "year": year, "doi": doi, - "published_in": published_in, + "journal": published_in, "url": url, "ENTRYTYPE": "article", "ID": id
10
diff --git a/src/technologies.json b/src/technologies.json "cookies": { "VtexFingerPrint": "", "VtexWorkspace": "", - "vtex_session": "" + "vtex_session": "", + "VtexStoreVersion": "" }, "description": "VTEX is an ecommerce software that manages multiple online stores.", "headers": { "powered": "vtex" }, "icon": "VTEX.svg", + "js": { + "vtex": "" + }, "pricing": [ "payg" ], "saas": true, + "scripts": "io\\.vtex\\.com\\.br", "website": "https://vtex.com/" }, "VWO": {
7
diff --git a/sandbox/src/Home.js b/sandbox/src/Home.js @@ -11,9 +11,7 @@ function HomeWithHistory({ history }) { window[instanceName]("event", { viewStart: true, xdm: { - eventType: "page-view", - url: window.location.href, - name: loc.pathname.substring(1) + eventType: "page-view" } }); }
2
diff --git a/src/libs/ReportUtils.js b/src/libs/ReportUtils.js @@ -347,7 +347,7 @@ function formatReportLastMessageText(lastMessageText) { function getDefaultAvatar(login = '') { // There are 8 possible default avatars, so we choose which one this user has based // on a simple hash of their login (which is converted from HEX to INT) - const loginHashBucket = (parseInt(md5(login).substring(0, 4), 16) % 8) + 1; + const loginHashBucket = (parseInt(md5(login.toLowerCase()).substring(0, 4), 16) % 8) + 1; return `${CONST.CLOUDFRONT_URL}/images/avatars/avatar_${loginHashBucket}.png`; }
8
diff --git a/module/modifier-bucket/tooltip-window.js b/module/modifier-bucket/tooltip-window.js @@ -51,8 +51,8 @@ export default class ModifierBucketEditor extends Application { get journals() { let journals = Array.from(game.journal) journals = game.data.journal - .filter(it => ModifierBucketJournals.getJournalIds().includes(it._id)) - .map(it => game.journal.get(it._id)) + .filter(it => ModifierBucketJournals.getJournalIds().includes(it.id)) + .map(it => game.journal.get(it.id)) journals = journals.filter(it => it.hasPerm(game.user, CONST.ENTITY_PERMISSIONS.OBSERVER)) return journals } @@ -78,7 +78,7 @@ export default class ModifierBucketEditor extends Application { data.othermods1 = ModifierLiterals.OtherMods1.split('\n') data.othermods2 = ModifierLiterals.OtherMods2.split('\n') data.cansend = game.user?.isGM || game.user?.isRole('TRUSTED') || game.user?.isRole('ASSISTANT') - data.users = game.users?.filter(u => u._id != game.user._id) || [] + data.users = game.users?.filter(u => u.id != game.user.id) || [] data.everyone = data.users.length > 1 ? { name: 'Everyone!' } : null data.taskdificulties = ModifierLiterals.TaskDifficultyModifiers data.lightingmods = ModifierLiterals.LightingModifiers
14
diff --git a/runtime.js b/runtime.js @@ -561,11 +561,22 @@ const _loadScn = async (file, opts) => { let physicsIds = []; for (const object of objects) { - let {name, position = [0, 0, 0], quaternion = [0, 0, 0, 1], scale = [1, 1, 1], start_url, physics_url = null, optimize = false, physics = false} = object; + let {name, position = [0, 0, 0], quaternion = [0, 0, 0, 1], scale = [1, 1, 1], start_url, filename, content, physics_url = null, optimize = false, physics = false} = object; const parentId = null; position = new THREE.Vector3().fromArray(position); quaternion = new THREE.Quaternion().fromArray(quaternion); + if (start_url) { start_url = new URL(start_url, srcUrl).href; + } else if (filename && content) { + const blob = new Blob([content], { + type: 'application/octet-stream', + }); + start_url = URL.createObjectURL(blob); + start_url += '/' + filename; + } else { + console.warn('cannot load contentless object', object); + continue; + } if (physics_url) { physics_url = new URL(physics_url, srcUrl).href; } @@ -609,7 +620,13 @@ const _loadScn = async (file, opts) => { return scene; }; const _loadLink = async file => { - const href = await file.text(); + let href; + if (file.url) { + const res = await fetch(file.url); + href = await res.text(); + } else { + href = await file.text(); + } const geometry = new THREE.CircleBufferGeometry(1, 32) .applyMatrix4(new THREE.Matrix4().makeScale(0.5, 1, 1))
0
diff --git a/lib/node_modules/@stdlib/_tools/test-cov/tape-istanbul/bin/cli b/lib/node_modules/@stdlib/_tools/test-cov/tape-istanbul/bin/cli @@ -7,6 +7,7 @@ var join = require( 'path' ).join; var resolve = require( 'path' ).resolve; var readFileSync = require( '@stdlib/fs/read-file' ).sync; var CLI = require( '@stdlib/tools/cli' ); +var cwd = require( '@stdlib/process/cwd' ); var writeFile = require( '@stdlib/fs/write-file' ); var runner = require( './../lib' ); @@ -66,7 +67,7 @@ function main() { if ( flags.output ) { out = flags.output; } else { - out = join( process.cwd(), 'coverage.json' ); + out = join( cwd(), 'coverage.json' ); } runner( args[ 0 ], opts, done );
4
diff --git a/node_common/managers/viewer.js b/node_common/managers/viewer.js @@ -83,8 +83,12 @@ export const getById = async ({ id }) => { library: user.data.library, // TODO(jim): Move this elsewhere. - allow_automatic_data_storage: user.data.allow_automatic_data_storage, - allow_encrypted_data_storage: user.data.allow_encrypted_data_storage, + allow_automatic_data_storage: user.data.allow_automatic_data_storage + ? user.data.allow_automatic_data_storage + : null, + allow_encrypted_data_storage: user.data.allow_encrypted_data_storage + ? user.data.allow_encrypted_data_storage + : null, // NOTE(jim): Remaining data. stats: {
1
diff --git a/core/pipeline-driver/lib/tasks/task-runner.js b/core/pipeline-driver/lib/tasks/task-runner.js @@ -49,6 +49,9 @@ class TaskRunner extends EventEmitter { this._stateManager.on(Events.TASKS.FAILED, (task) => { this._handleTaskEvent(task); }); + this._stateManager.on(Events.TASKS.STALLED, (task) => { + this._handleTaskEvent(task); + }); this._stateManager.on(Events.TASKS.CRASHED, (task) => { const data = { ...task, status: NodeStates.FAILED }; this._handleTaskEvent(data); @@ -57,6 +60,9 @@ class TaskRunner extends EventEmitter { _handleTaskEvent(task) { switch (task.status) { + case NodeStates.STALLED: + this._setTaskState(task.taskId, { status: NodeStates.STALLED }); + break; case NodeStates.ACTIVE: this._setTaskState(task.taskId, { status: NodeStates.ACTIVE }); break; @@ -190,7 +196,7 @@ class TaskRunner extends EventEmitter { const resultError = await this._stateManager.setJobResults({ jobId: this._jobId, startTime: this.pipeline.startTime, pipeline: this.pipeline.name, data, reason, error: errorMsg, status }); if (errorMsg || resultError) { - const error = `${errorMsg || ''}, ${resultError || ''}`; + const error = resultError || errorMsg; await this._progressError({ status, error }); if (err.batchTolerance) { await this._stateManager.stopJob({ jobId: this._jobId });
0
diff --git a/physics-manager.js b/physics-manager.js @@ -30,11 +30,11 @@ const localMatrix = new THREE.Matrix4(); const physicsManager = new EventTarget(); const physicsUpdates = []; -const _makePhysicsObject = (physicsId, position, quaternion/*, scale*/) => { +const _makePhysicsObject = (physicsId, position, quaternion, scale) => { const physicsObject = new THREE.Object3D(); physicsObject.position.copy(position); physicsObject.quaternion.copy(quaternion); - // physicsObject.scale.copy(scale); + physicsObject.scale.copy(scale); physicsObject.updateMatrixWorld(); physicsObject.physicsId = physicsId; physicsObject.detached = false; @@ -56,7 +56,7 @@ physicsManager.addCapsuleGeometry = (position, quaternion, radius, halfHeight, p const physicsId = getNextPhysicsId(); physx.physxWorker.addCapsuleGeometryPhysics(physx.physics, position, quaternion, radius, halfHeight, physicsMaterial, physicsId, ccdEnabled); - const physicsObject = _makePhysicsObject(physicsId, position, quaternion); + const physicsObject = _makePhysicsObject(physicsId, position, quaternion, localVector2.set(1, 1, 1)); const physicsMesh = new THREE.Mesh( new CapsuleGeometry(radius, radius, halfHeight*2) ); @@ -70,7 +70,7 @@ physicsManager.addBoxGeometry = (position, quaternion, size, dynamic) => { const physicsId = getNextPhysicsId(); physx.physxWorker.addBoxGeometryPhysics(physx.physics, position, quaternion, size, physicsId, dynamic); - const physicsObject = _makePhysicsObject(physicsId, position, quaternion/*, size*/); + const physicsObject = _makePhysicsObject(physicsId, position, quaternion, localVector2.set(1, 1, 1)); const physicsMesh = new THREE.Mesh( new THREE.BoxGeometry(2, 2, 2) ); @@ -98,7 +98,7 @@ physicsManager.addGeometry = mesh => { physx.physxWorker.addGeometryPhysics(physx.physics, physicsMesh, physicsId, physicsMaterial); physicsMesh.geometry = _extractPhysicsGeometryForId(physicsId); - const physicsObject = _makePhysicsObject(physicsId, physicsMesh.position, physicsMesh.quaternion/*, physicsMesh.scale*/); + const physicsObject = _makePhysicsObject(physicsId, physicsMesh.position, physicsMesh.quaternion, physicsMesh.scale); physicsObject.add(physicsMesh); physicsMesh.position.set(0, 0, 0); physicsMesh.quaternion.set(0, 0, 0, 1); @@ -112,7 +112,7 @@ physicsManager.addCookedGeometry = (buffer, position, quaternion, scale) => { const physicsId = getNextPhysicsId(); physx.physxWorker.addCookedGeometryPhysics(physx.physics, buffer, position, quaternion, scale, physicsId); - const physicsObject = _makePhysicsObject(physicsId, position, quaternion/*, scale*/); + const physicsObject = _makePhysicsObject(physicsId, position, quaternion, scale); const physicsMesh = new THREE.Mesh(_extractPhysicsGeometryForId(physicsId)); physicsMesh.visible = false; physicsObject.add(physicsMesh); @@ -135,7 +135,7 @@ physicsManager.addConvexGeometry = mesh => { physx.physxWorker.addConvexGeometryPhysics(physx.physics, physicsMesh, physicsId); physicsMesh.geometry = _extractPhysicsGeometryForId(physicsId); - const physicsObject = _makePhysicsObject(physicsId, mesh.position, mesh.quaternion/*, mesh.scale*/); + const physicsObject = _makePhysicsObject(physicsId, mesh.position, mesh.quaternion, mesh.scale); physicsObject.add(physicsMesh); physicsMesh.position.set(0, 0, 0); physicsMesh.quaternion.set(0, 0, 0, 1); @@ -149,7 +149,7 @@ physicsManager.addCookedConvexGeometry = (buffer, position, quaternion, scale) = const physicsId = getNextPhysicsId(); physx.physxWorker.addCookedConvexGeometryPhysics(physx.physics, buffer, position, quaternion, scale, physicsId); - const physicsObject = _makePhysicsObject(physicsId, position, quaternion/*, scale*/); + const physicsObject = _makePhysicsObject(physicsId, position, quaternion, scale); const physicsMesh = new THREE.Mesh(_extractPhysicsGeometryForId(physicsId)); physicsMesh.visible = false; physicsObject.add(physicsMesh);
0
diff --git a/packages/neutrine/src/future/side/style.scss b/packages/neutrine/src/future/side/style.scss &-content { display: block; //display: none; - width: 400px; //Default width - height: 100%; + //width: 400px; //Default width + //height: 100%; background-color: #ffffff; border-radius: 0px; position: fixed; - top: 0px; + //top: 0px; z-index: 120; overflow-x: hidden; overflow-y: auto; //Right aligned side &--right { + top: 0px; right: calc(-1 * 100%); transition: right 0.3s; } //Left aligned side &--left { + top: 0px; left: calc(-1 * 100%); transition: left 0.3s; } + //Top aligned side + &--top { + left: 0px; + top: calc(-1 * 100%); + transition: top 0.3s; + } + //Bottom aligned side + &--bottom { + left: 0px; + bottom: calc(-1 * 100%); + transition: bottom 0.3s; + } } //Side visible //&--visible &-content { &--visible &-content--left { left: 0px; } + &--visible &-content--top { + top: 0px; + } + &--visible &-content--bottom { + bottom: 0px; + } //Side close icon &-close { display: block;
11
diff --git a/screenshot.html b/screenshot.html // camera.lookAt(model.boundingBoxMesh.getWorldPosition(new THREE.Vector3())); + /* const ambientLight = new THREE.AmbientLight(0xFFFFFF, 0.1); + scene.add(ambientLight); */ + const directionalLight = new THREE.DirectionalLight(0xFFFFFF, 1); + directionalLight.position.set(1, 2, -3); + scene.add(directionalLight); + /* const directionalLight2 = new THREE.DirectionalLight(0xFFFFFF, 2); + directionalLight2.position.set(0, 0, -3); + scene.add(directionalLight2); */ + return {renderer, scene, camera}; };
0
diff --git a/core.js b/core.js @@ -1198,7 +1198,7 @@ const _makeWindow = (options = {}, parent = null, top = null) => { } return RequestCamera.apply(this, arguments); })(nativeMlProxy.RequestCamera); - nativeMlProxy.RequestMeshing = (RequestMeshing => function(cb) { + nativeMlProxy.RequestMesh = (RequestMesh => function(cb) { if (typeof cb === 'function') { cb = (cb => function(datas) { for (let i = 0; i < datas.length; i++) { @@ -1207,8 +1207,8 @@ const _makeWindow = (options = {}, parent = null, top = null) => { return cb.apply(this, arguments); })(cb); } - return RequestMeshing.apply(this, arguments); - })(nativeMlProxy.RequestMeshing); + return RequestMesh.apply(this, arguments); + })(nativeMlProxy.RequestMesh); return nativeMlProxy; })(), };
10
diff --git a/angular/projects/spark-angular/src/lib/components/inputs/sprk-checkbox-item/sprk-checkbox-item.component.ts b/angular/projects/spark-angular/src/lib/components/inputs/sprk-checkbox-item/sprk-checkbox-item.component.ts @@ -61,8 +61,8 @@ export class SprkCheckboxItemComponent implements OnInit { idString: string; /** - * Determines whether the `sprk-b-InputContainer__visibility-toggle` - * class is applied. + * If `true`, the checkbox item will receive styling to make it a + * visibility toggle. Use this for "Show Password" checkboxes. */ @Input() isVisibilityToggle: boolean;
3
diff --git a/tests/e2e/plugins/reset.php b/tests/e2e/plugins/reset.php @@ -21,17 +21,4 @@ register_activation_hook( __FILE__, static function () { } ( new Reset( new Context( GOOGLESITEKIT_PLUGIN_MAIN_FILE ) ) )->all(); - - /** - * Remove anything left behind. - * @link https://github.com/google/site-kit-wp/issues/351 - */ - global $wpdb; - - $wpdb->query( - "DELETE FROM $wpdb->options WHERE option_name LIKE '%googlesitekit%'" - ); - $wpdb->query( - "DELETE FROM $wpdb->usermeta WHERE meta_key LIKE '%googlesitekit%'" - ); } );
2
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml @@ -20,6 +20,7 @@ jobs: git switch -c master git config --global user.email "[email protected]" git config --global user.name "Adam Argyle" + git push --set-upstream origin master - name: Install & Build run: |
12
diff --git a/public/app/js/global-requires.js b/public/app/js/global-requires.js @@ -32,7 +32,7 @@ const sanitizeHTML = require("sanitize-html") sanitizeHTML.defaults.allowedTags = [ "h1", "h2", "h3", "h4", "h5", "h6", "blockquote", "p", "a", "ul", "ol", "nl", "li", "b", "i", "strong", "em", "strike", "code", "hr", "br", "div", "table", - "thead", "caption", "tbody", "tr", "th", "td", "pre" + "thead", "caption", "tbody", "tr", "th", "td", "pre", "img" ] var MPRISPlayer;
11
diff --git a/package.json b/package.json "vinyl-fs": "^3.0.3", "web-streams-polyfill": "^3.0.2", "webpack": "^5.23.0", - "webpack-stream": "~6.1.2", + "webpack-stream": "^6.1.2", "wintersmith": "^2.5.0", "yargs": "^11.1.1" },
11
diff --git a/assets/js/googlesitekit/widgets/default-areas.js b/assets/js/googlesitekit/widgets/default-areas.js * limitations under the License. */ -/** - * Internal dependencies - */ -import { isFeatureEnabled } from '../../features'; - export const AREA_DASHBOARD_ALL_TRAFFIC = 'dashboardAllTraffic'; export const AREA_DASHBOARD_SEARCH_FUNNEL = 'dashboardSearchFunnel'; export const AREA_DASHBOARD_ACQUISITION = 'dashboardAcquisition'; @@ -31,8 +26,24 @@ export const AREA_PAGE_DASHBOARD_SEARCH_FUNNEL = 'pageDashboardSearchFunnel'; export const AREA_PAGE_DASHBOARD_ALL_TRAFFIC = 'pageDashboardAllTraffic'; export const AREA_PAGE_DASHBOARD_ACQUISITION = 'pageDashboardAcquisition'; export const AREA_PAGE_DASHBOARD_SPEED = 'pageDashboardSpeed'; + +// Main dashboard +export const AREA_MAIN_DASHBOARD_TRAFFIC_PRIMARY = + 'mainDashboardTrafficPrimary'; +export const AREA_MAIN_DASHBOARD_CONTENT_PRIMARY = + 'mainDashboardContentPrimary'; +export const AREA_MAIN_DASHBOARD_SPEED_PRIMARY = 'mainDashboardSpeedPrimary'; export const AREA_MAIN_DASHBOARD_MONETIZATION_PRIMARY = 'mainDashboardMonetizationPrimary'; +// Entity dashboard +export const AREA_ENTITY_DASHBOARD_TRAFFIC_PRIMARY = + 'entityDashboardTrafficPrimary'; +export const AREA_ENTITY_DASHBOARD_CONTENT_PRIMARY = + 'entityDashboardContentPrimary'; +export const AREA_ENTITY_DASHBOARD_SPEED_PRIMARY = + 'entityDashboardSpeedPrimary'; +export const AREA_ENTITY_DASHBOARD_MONETIZATION_PRIMARY = + 'entityDashboardMonetizationPrimary'; export default { AREA_DASHBOARD_ALL_TRAFFIC, @@ -44,25 +55,4 @@ export default { AREA_PAGE_DASHBOARD_ALL_TRAFFIC, AREA_PAGE_DASHBOARD_ACQUISITION, AREA_PAGE_DASHBOARD_SPEED, - ...( isFeatureEnabled( 'unifiedDashboard' ) - ? { - // Main dashboard - AREA_MAIN_DASHBOARD_TRAFFIC_PRIMARY: - 'mainDashboardTrafficPrimary', - AREA_MAIN_DASHBOARD_CONTENT_PRIMARY: - 'mainDashboardContentPrimary', - AREA_MAIN_DASHBOARD_SPEED_PRIMARY: 'mainDashboardSpeedPrimary', - AREA_MAIN_DASHBOARD_MONETIZATION_PRIMARY: - 'mainDashboardMonetizationPrimary', - // Entity dashboard - AREA_ENTITY_DASHBOARD_TRAFFIC_PRIMARY: - 'entityDashboardTrafficPrimary', - AREA_ENTITY_DASHBOARD_CONTENT_PRIMARY: - 'entityDashboardContentPrimary', - AREA_ENTITY_DASHBOARD_SPEED_PRIMARY: - 'entityDashboardSpeedPrimary', - AREA_ENTITY_DASHBOARD_MONETIZATION_PRIMARY: - 'entityDashboardMonetizationPrimary', - } - : {} ), };
2
diff --git a/src/resources/Fetcher.js b/src/resources/Fetcher.js @@ -5,6 +5,7 @@ const https = require('https'); const logger = require('../Logger'); const retryCodes = [429].concat((process.env.JSON_CACHE_RETRY_CODES || '').split(',').map(code => parseInt(code.trim(), 10))); +const redirectCodes = [302, 301].concat((process.env.JSON_CACHE_REDIRECT_CODES || '').split(',').map(code => parseInt(code.trim(), 10))); const fetch = (url, { promiseLib = Promise, maxRetry = 10, headers } = { promiseLib: Promise, maxRetry: 10, headers: {} }) => { @@ -15,11 +16,17 @@ const fetch = (url, { promiseLib = Promise, maxRetry = 10, headers } = const body = []; if (response.statusCode < 200 || response.statusCode > 299) { - if ((response.statusCode > 499 || retryCodes.indexOf(response.statusCode) > -1) + if (redirectCodes.includes(response.statusCode)) { + setTimeout(() => { + fetch(response.headers.location, { promiseLib, maxRetry, headers }) + .then(resolve) + .catch(logger.error); + }, 1000); + } else if ((response.statusCode > 499 || retryCodes.includes(response.statusCode)) && maxRetry > 0) { maxRetry -= 1; // eslint-disable-line no-param-reassign setTimeout(() => { - fetch(url, promiseLib, maxRetry) + fetch(url, { promiseLib, maxRetry }) .then(resolve) .catch(logger.error); }, 1000); @@ -30,16 +37,7 @@ const fetch = (url, { promiseLib = Promise, maxRetry = 10, headers } = } else { response.on('data', chunk => body.push(chunk)); response.on('end', () => { - let r = body.join(''); - try { - r = JSON.parse(r); - } catch (e) { - logger.error(`Failed to parse ${url}`); - logger.debug(r); - r = {}; - } finally { - resolve(r); - } + resolve(JSON.parse(body.join(''))); }); } });
9
diff --git a/token-metadata/0xE48972fCd82a274411c01834e2f031D4377Fa2c0/metadata.json b/token-metadata/0xE48972fCd82a274411c01834e2f031D4377Fa2c0/metadata.json "symbol": "2KEY", "address": "0xE48972fCd82a274411c01834e2f031D4377Fa2c0", "decimals": 18, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/src/lib/utils/asyncStorage.js b/src/lib/utils/asyncStorage.js import AsyncStorage from '@react-native-async-storage/async-storage' -import { isFunction } from 'lodash' +import { isArray, isEmpty, isFunction } from 'lodash' import { AB_TESTING, DESTINATION_PATH, INVITE_CODE, IS_FIRST_VISIT } from '../constants/localStorage' import logger from '../logger/js-logger' @@ -66,6 +66,10 @@ export default new class { } async multiSet(keyValuePairs) { + if (!isArray(keyValuePairs) || isEmpty(keyValuePairs)) { + return + } + const stringifiedPairs = keyValuePairs.map(([key, value]) => [key, JSON.stringify(value)]) await this.storageApi.multiSet(stringifiedPairs)
0
diff --git a/assets/js/modules/adsense/datastore/report.test.js b/assets/js/modules/adsense/datastore/report.test.js @@ -112,7 +112,7 @@ describe( 'modules/adsense report', () => { data: { status: 500 }, }; fetchMock.getOnce( - /^\/google-site-kit\/v1\/modules\/adsense\/data\/earnings/, + /^\/google-site-kit\/v1\/modules\/adsense\/data\/report/, { body: response, status: 500 } );
1
diff --git a/src/components/withDelayToggleButtonState.js b/src/components/withDelayToggleButtonState.js @@ -4,10 +4,10 @@ import getComponentDisplayName from '../libs/getComponentDisplayName'; const withDelayToggleButtonStatePropTypes = { /** A value whether the button state is complete */ - isButtonStateComplete: PropTypes.bool.isRequired, + isDelayButtonStateComplete: PropTypes.bool.isRequired, /** A function to call to change the complete state */ - toggleButtonStateComplete: PropTypes.func.isRequired, + toggleDelayButtonState: PropTypes.func.isRequired, }; export default function (WrappedComponent) { @@ -16,9 +16,9 @@ export default function (WrappedComponent) { super(props); this.state = { - isButtonStateComplete: false, + isDelayButtonStateComplete: false, }; - this.toggleButtonStateComplete = this.toggleButtonStateComplete.bind(this); + this.toggleDelayButtonState = this.toggleDelayButtonState.bind(this); } componentWillUnmount() { @@ -30,29 +30,31 @@ export default function (WrappedComponent) { } /** - * @param {Boolean} [resetAfterDelay=true] Impose delay before toggling state + * @param {Boolean} [resetAfterDelay] Impose delay before toggling state */ - toggleButtonStateComplete(resetAfterDelay = true) { + toggleDelayButtonState(resetAfterDelay) { this.setState({ - isButtonStateComplete: true, + isDelayButtonStateComplete: true, }); - if (resetAfterDelay) { + if (!resetAfterDelay) { + return; + } + this.resetButtonStateCompleteTimer = setTimeout(() => { this.setState({ - isButtonStateComplete: false, + isDelayButtonStateComplete: false, }); }, 1800); } - } render() { return ( <WrappedComponent // eslint-disable-next-line react/jsx-props-no-spreading {...this.props} - isButtonStateComplete={this.state.isButtonStateComplete} - toggleButtonStateComplete={this.toggleButtonStateComplete} + isDelayButtonStateComplete={this.state.isDelayButtonStateComplete} + toggleDelayButtonState={this.toggleDelayButtonState} /> ); }
10
diff --git a/google-site-kit.php b/google-site-kit.php @@ -30,7 +30,6 @@ define( 'GOOGLESITEKIT_VERSION', '1.84.0' ); define( 'GOOGLESITEKIT_PLUGIN_MAIN_FILE', __FILE__ ); define( 'GOOGLESITEKIT_PHP_MINIMUM', '5.6.0' ); define( 'GOOGLESITEKIT_WP_MINIMUM', '4.7.0' ); -define( 'GOOGLESITEKIT_WORDPRESS_VERSION', get_bloginfo( 'version' ) ); /** * Handles plugin activation. @@ -52,10 +51,10 @@ function googlesitekit_activate_plugin( $network_wide ) { ); } - if ( version_compare( GOOGLESITEKIT_WORDPRESS_VERSION, GOOGLESITEKIT_WP_MINIMUM, '<' ) ) { + if ( version_compare( get_bloginfo( 'version' ), GOOGLESITEKIT_WP_MINIMUM, '<' ) ) { wp_die( /* translators: 1: version number */ - esc_html( sprintf( __( 'Site Kit requires WP version %s or higher', 'google-site-kit' ), GOOGLESITEKIT_WP_MINIMUM ) ), + esc_html( sprintf( __( 'Site Kit requires WordPress version %s or higher', 'google-site-kit' ), GOOGLESITEKIT_WP_MINIMUM ) ), esc_html__( 'Error Activating', 'google-site-kit' ) ); } @@ -119,7 +118,7 @@ add_action( 'upgrader_process_complete', 'googlesitekit_opcache_reset' ); if ( version_compare( PHP_VERSION, GOOGLESITEKIT_PHP_MINIMUM, '>=' ) && - version_compare( GOOGLESITEKIT_WORDPRESS_VERSION, GOOGLESITEKIT_WP_MINIMUM, '>=' ) + version_compare( get_bloginfo( 'version' ), GOOGLESITEKIT_WP_MINIMUM, '>=' ) ) { require_once plugin_dir_path( __FILE__ ) . 'includes/loader.php'; }
10
diff --git a/tools/subgraph/subgraph.template.yaml b/tools/subgraph/subgraph.template.yaml @@ -23,7 +23,7 @@ dataSources: - Swap abis: - name: SwapContract - file: ../deployer/build/contracts/Swap.json + file: ./abis/Swap.json eventHandlers: - event: AuthorizeSender(indexed address,indexed address) handler: handleAuthorizeSender @@ -60,7 +60,7 @@ dataSources: - Unstake abis: - name: Indexer - file: ../deployer/build/contracts/Indexer.json + file: ./abis//Indexer.json eventHandlers: - event: AddTokenToBlacklist(address) handler: handleAddTokenToBlacklist @@ -90,7 +90,7 @@ dataSources: - CreateDelegate abis: - name: DelegateFactory - file: ../deployer/build/contracts/DelegateFactory.json + file: ./abis//DelegateFactory.json eventHandlers: - event: CreateDelegate(indexed address,address,address,indexed address,address) handler: handleCreateDelegate @@ -112,7 +112,7 @@ dataSources: - Swap abis: - name: SwapLightContract - file: ../deployer/build/contracts/Light.json + file: ./abis/Light.json eventHandlers: - event: Cancel(indexed uint256,indexed address) handler: handleCancel @@ -137,7 +137,7 @@ templates: - Index abis: - name: Index - file: ../deployer/build/contracts/Index.json + file: ./abis//Index.json eventHandlers: - event: SetLocator(indexed address,uint256,indexed bytes32) handler: handleSetLocator @@ -157,7 +157,7 @@ templates: - Delegate abis: - name: Delegate - file: ../deployer/build/contracts/Delegate.json + file: ./abis/Delegate.json eventHandlers: - event: SetRule(indexed address,indexed address,indexed address,uint256,uint256,uint256) handler: handleSetRule
3