code
stringlengths 122
4.99k
| label
int64 0
14
|
---|---|
diff --git a/assets/js/modules/pagespeed-insights/index.js b/assets/js/modules/pagespeed-insights/index.js @@ -26,11 +26,10 @@ import domReady from '@wordpress/dom-ready';
* Internal dependencies
*/
import './datastore';
-import { getModulesData, fillFilterWithComponent, createAddToFilter } from '../../util';
+import { fillFilterWithComponent } from '../../util';
import { WIDGET_WIDTHS } from '../../googlesitekit/widgets/datastore/constants';
import { AREA_DASHBOARD_SPEED, AREA_PAGE_DASHBOARD_SPEED } from '../../googlesitekit/widgets/default-areas';
import { SettingsMain as PageSpeedInsightsSettings } from './settings';
-import DashboardSpeed from './dashboard/dashboard-widget-speed';
import DashboardPageSpeedWidget from './components/DashboardPageSpeedWidget';
/**
@@ -42,28 +41,6 @@ addFilter(
fillFilterWithComponent( PageSpeedInsightsSettings )
);
-const {
- active,
- setupComplete,
-} = getModulesData()[ 'pagespeed-insights' ];
-
-if ( active && setupComplete ) {
- // Add to main dashboard.
- addFilter(
- 'googlesitekit.DashboardModule',
- 'googlesitekit.PageSpeedInsights',
- createAddToFilter( <DashboardSpeed /> ),
- 45
- );
- // Add to dashboard-details view.
- addFilter(
- 'googlesitekit.DashboardDetailsModule',
- 'googlesitekit.PageSpeedInsights',
- createAddToFilter( <DashboardSpeed /> ),
- 45
- );
-}
-
domReady( () => {
global.googlesitekit.widgets.registerWidget( 'pagespeedInsightsWebVitals', {
component: DashboardPageSpeedWidget,
| 2 |
diff --git a/articles/architecture-scenarios/mobile-api/index.md b/articles/architecture-scenarios/mobile-api/index.md @@ -15,16 +15,16 @@ We will also be building a mobile application which will be used to view and log
::: panel TL;DR
-* Auth0 provides API Authentication and Authorization as a means to secure access to API endpoints (see [API Authentication and Authorization](/architecture-scenarios/application/mobile-api/part-1#api-authentication-and-authorization))
-* For authorizing a mobile app user and granting access to the API, Auth0 supports the Authorization Code Grant Flow with PKCE (see [Proof Key for Code Exchange](/architecture-scenarios/application/mobile-api/part-1#proof-key-for-code-exchange-pkce-))
-* Both the mobile app and the API must be configured in the Auth0 Dashboard (see [Auth0 Configuration](/architecture-scenarios/application/mobile-api/part-2))
-* User Permissions can be enforced using the Authorization Extension (see [Configure the Authorization Extension](/architecture-scenarios/application/mobile-api/part-2#configure-the-authorization-extension))
-* The API is secured by ensuring that a valid [Access Token](/tokens/access-token) is passed in the HTTP Authorization header when calls are made to the API (see [Implement the API](/architecture-scenarios/application/mobile-api/part-3#secure-the-endpoints))
-* The Auth0.Android SDK can be used to authorize the user of the mobile app and obtain a valid Access Token which can be used to call the API (see [Authorize the User](/architecture-scenarios/application/mobile-api/part-3#authorize-the-user))
-* The mobile app can retrieve the user's profile information by decoding the ID Token (see [Get the User Profile](/architecture-scenarios/application/mobile-api/part-3#get-the-user-profile))
-* UI Elements can be displayed conditionally based on the scope that was granted to the user (see [Display UI Elements Conditionally Based on Scope](/architecture-scenarios/application/mobile-api/part-3#display-ui-elements-conditionally-based-on-scope))
-* The mobile app provides the Access Token in the HTTP Authorization header when making calls to the API (see [Call the API](/architecture-scenarios/application/mobile-api/part-3#call-the-api))
-* The mobile app user's Access Token can be renewed to ensure the user does not have to log in again during a session (see [Renew the Token](/architecture-scenarios/application/mobile-api/part-3#renew-the-token))
+* Auth0 provides API Authentication and Authorization as a means to secure access to API endpoints (see [API Authentication and Authorization](/architecture-scenarios/mobile-api/part-1#api-authentication-and-authorization))
+* For authorizing a mobile app user and granting access to the API, Auth0 supports the Authorization Code Grant Flow with PKCE (see [Proof Key for Code Exchange](/architecture-scenarios/mobile-api/part-1#proof-key-for-code-exchange-pkce-))
+* Both the mobile app and the API must be configured in the Auth0 Dashboard (see [Auth0 Configuration](/architecture-scenarios/mobile-api/part-2))
+* User Permissions can be enforced using the Authorization Extension (see [Configure the Authorization Extension](/architecture-scenarios/mobile-api/part-2#configure-the-authorization-extension))
+* The API is secured by ensuring that a valid [Access Token](/tokens/access-token) is passed in the HTTP Authorization header when calls are made to the API (see [Implement the API](/architecture-scenarios/mobile-api/part-3#secure-the-endpoints))
+* The Auth0.Android SDK can be used to authorize the user of the mobile app and obtain a valid Access Token which can be used to call the API (see [Authorize the User](/architecture-scenarios/mobile-api/part-3#authorize-the-user))
+* The mobile app can retrieve the user's profile information by decoding the ID Token (see [Get the User Profile](/architecture-scenarios/mobile-api/part-3#get-the-user-profile))
+* UI Elements can be displayed conditionally based on the scope that was granted to the user (see [Display UI Elements Conditionally Based on Scope](/architecture-scenarios/mobile-api/part-3#display-ui-elements-conditionally-based-on-scope))
+* The mobile app provides the Access Token in the HTTP Authorization header when making calls to the API (see [Call the API](/architecture-scenarios/mobile-api/part-3#call-the-api))
+* The mobile app user's Access Token can be renewed to ensure the user does not have to log in again during a session (see [Renew the Token](/architecture-scenarios/mobile-api/part-3#renew-the-token))
:::
## The Premise
| 1 |
diff --git a/scripts/dist.sh b/scripts/dist.sh # Copyright (c) 2015-present, salesforce.com, inc. All rights reserved
# Licensed under BSD 3-Clause - see LICENSE.txt or git.io/sfdc-license
+# NOTE: eventually use "babel.config.js" instead of setting --config-path.
+# Use of --config-path is ok for now because babel-cli is searching for "babel.config.js"
+# and not falling back to ".babelrc" at all, so it doesn't double-load by default.
+# See:
+# https://babeljs.io/docs/en/configuration#what-s-your-use-case
+# https://babeljs.io/docs/en/options#configfile
+
npx babel-node scripts/inline-icons.js \
- --plugins transform-es2015-modules-commonjs
+ --plugins @babel/plugin-transform-modules-commonjs
echo "# Building design-system-react"
echo "## Preparing the .tmp directory"
@@ -42,7 +49,7 @@ cp docs/README-dist.md .tmp/README.md
echo "## Running JS steps"
npx babel-node scripts/dist.js \
- --plugins transform-es2015-modules-commonjs
+ --plugins @babel/plugin-transform-modules-commonjs
echo "## Copying the components"
@@ -66,7 +73,8 @@ echo "## Transpiling with Babel"
# NODE_ENV=amd \
# ./node_modules/.bin/babel \
# .tmp-es/components \
-# --plugins transform-es2015-modules-amd \
+# --config-file ./.babelrc \
+# --plugins @babel/plugin-transform-modules-amd \
# --out-dir .tmp-amd/components \
# --ignore site-stories.js,__docs__,__examples__,__tests__
@@ -74,22 +82,25 @@ echo "## Transpiling with Babel"
# ./node_modules/.bin/babel \
# .tmp-es/icons \
-# --plugins transform-es2015-modules-amd \
+# --config-file ./.babelrc \
+# --plugins @babel/plugin-transform-modules-amd \
# --out-dir .tmp-amd/icons
# NODE_ENV=amd \
# ./node_modules/.bin/babel \
# .tmp-es/utilities \
-# --plugins transform-es2015-modules-amd \
+# --config-file ./.babelrc \
+# --plugins @babel/plugin-transform-modules-amd \
# --out-dir .tmp-amd/utilities
# CommonJS module transpilation
NODE_ENV=commonjs \
npx babel \
.tmp-es/components \
+ --config-file ./.babelrc \
--out-dir .tmp-commonjs/components \
--copy-files \
- --plugins transform-es2015-modules-commonjs \
+ --plugins @babel/plugin-transform-modules-commonjs \
--ignore site-stories.js,__docs__,__examples__,__tests__
cp -r assets .tmp-commonjs/assets
@@ -97,21 +108,24 @@ cp -r styles .tmp-commonjs/styles
npx babel \
.tmp-es/icons \
+ --config-file ./.babelrc \
--out-dir .tmp-commonjs/icons \
--copy-files \
- --plugins transform-es2015-modules-commonjs
+ --plugins @babel/plugin-transform-modules-commonjs
NODE_ENV=commonjs \
npx babel \
.tmp-es/utilities \
+ --config-file ./.babelrc \
--out-dir .tmp-commonjs/utilities \
--copy-files \
- --plugins transform-es2015-modules-commonjs
+ --plugins @babel/plugin-transform-modules-commonjs
# ES6 module transpilation
NODE_ENV=esm \
npx babel \
.tmp-es/components \
+ --config-file ./.babelrc \
--out-dir .tmp-esm/components \
--copy-files \
--source-maps \
@@ -126,6 +140,7 @@ cp -r icons .tmp-esm/icons
NODE_ENV=esm \
npx babel \
.tmp-es/utilities \
+ --config-file ./.babelrc \
--out-dir .tmp-esm/utilities \
--copy-files \
--source-maps
@@ -133,6 +148,7 @@ npx babel \
NODE_ENV=esm \
npx babel \
.tmp-es/icons \
+ --config-file ./.babelrc \
--out-dir .tmp-esm/icons \
--copy-files
@@ -151,4 +167,4 @@ rm .tmp-npm/lib/*.map
rm .tmp-npm/lib/*.js
npx babel-node scripts/npm-transform.js \
- --plugins transform-es2015-modules-commonjs
+ --plugins @babel/plugin-transform-modules-commonjs
| 3 |
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md @@ -39,7 +39,7 @@ This Code of Conduct applies within all community spaces, and also applies when
## Enforcement
-Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at [INSERT CONTACT METHOD]. All complaints will be reviewed and investigated promptly and fairly.
+Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at [email protected]. All complaints will be reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the reporter of any incident.
| 12 |
diff --git a/shim/src/stdlib.js b/shim/src/stdlib.js @@ -2,18 +2,35 @@ import { getIntrinsics } from "./intrinsics";
export function getStdLib(sandbox) {
const intrinsics = getIntrinsics(sandbox);
+
return {
+ // *** 18.1 Value Properties of the Global Object
+
+ Infinity: { value: Infinity },
+ NaN: { value: NaN },
+ undefined: { value: undefined },
+
+ // *** 18.2 Function Properties of the Global Object
+
+ eval: { value: intrinsics.eval },
+ isFinite: { value: intrinsics.isFinite },
+ isNaN: { value: intrinsics.isNaN },
+ parseFloat: { value: intrinsics.parseFloat },
+ parseInt: { value: intrinsics.parseInt },
+
+ decodeURI: { value: intrinsics.decodeURI },
+ decodeURIComponent: { value: intrinsics.decodeURIComponent },
+ encodeURI: { value: intrinsics.encodeURI },
+ encodeURIComponent: { value: intrinsics.encodeURIComponent },
+
+ // *** 18.3 Constructor Properties of the Global Object
+
Array: { value: intrinsics.Array },
ArrayBuffer: { value: intrinsics.ArrayBuffer },
Boolean: { value: intrinsics.Boolean },
DataView: { value: intrinsics.DataView },
Date: { value: intrinsics.Date },
- decodeURI: { value: intrinsics.decodeURI },
- decodeURIComponent: { value: intrinsics.decodeURIComponent },
- encodeURI: { value: intrinsics.encodeURI },
- encodeURIComponent: { value: intrinsics.encodeURIComponent },
Error: { value: intrinsics.Error },
- eval: { value: intrinsics.eval },
EvalError: { value: intrinsics.EvalError },
Float32Array: { value: intrinsics.Float32Array },
Float64Array: { value: intrinsics.Float64Array },
@@ -21,22 +38,17 @@ export function getStdLib(sandbox) {
Int8Array: { value: intrinsics.Int8Array },
Int16Array: { value: intrinsics.Int16Array },
Int32Array: { value: intrinsics.Int32Array },
- isFinite: { value: intrinsics.isFinite },
- isNaN: { value: intrinsics.isNaN },
- JSON: { value: intrinsics.JSON },
Map: { value: intrinsics.Map },
- Math: { value: intrinsics.Math },
Number: { value: intrinsics.Number },
Object: { value: intrinsics.Object },
- parseFloat: { value: intrinsics.parseFloat },
- parseInt: { value: intrinsics.parseInt },
Promise: { value: intrinsics.Promise },
Proxy: { value: intrinsics.Proxy },
RangeError: { value: intrinsics.RangeError },
ReferenceError: { value: intrinsics.ReferenceError },
- Reflect: { value: intrinsics.Reflect },
RegExp: { value: intrinsics.RegExp },
Set: { value: intrinsics.Set },
+ // Deprecated
+ // SharedArrayBuffer: intrinsics.SharedArrayBuffer,
String: { value: intrinsics.String },
Symbol: { value: intrinsics.Symbol },
SyntaxError: { value: intrinsics.SyntaxError },
@@ -49,7 +61,16 @@ export function getStdLib(sandbox) {
WeakMap: { value: intrinsics.WeakMap },
WeakSet: { value: intrinsics.WeakSet },
- // TODO: Annex B
- // TODO: other special cases
+ // *** 18.4 Other Properties of the Global Object
+
+ Atomics: { value: intrinsics.Atomics },
+ JSON: { value: intrinsics.JSON },
+ Math: { value: intrinsics.Math },
+ Reflect: { value: intrinsics.Reflect },
+
+ // *** Annex B
+
+ escape: { value: intrinsics.escape },
+ unescape: { value: intrinsics.unescape }
};
}
| 7 |
diff --git a/polyfills/WebAnimations/config.toml b/polyfills/WebAnimations/config.toml +aliases = [
+ "Animation",
+ "AnimationTimeline",
+ "Element.prototype.animate",
+ "KeyframeEffect",
+ "document.timeline"
+]
dependencies = [ ]
license = "Apache-2.0"
spec = "https://w3c.github.io/web-animations/"
| 0 |
diff --git a/edit.js b/edit.js @@ -24,7 +24,7 @@ import {makePromise} from './util.js';
import {world} from './world.js';
import * as universe from './universe.js';
// import {Bot} from './bot.js';
-import {Sky} from './Sky.js';
+// import {Sky} from './Sky.js';
import {GuardianMesh} from './land.js';
import {storageHost} from './constants.js';
import {renderer, scene, avatarScene, camera, avatarCamera, dolly, /*orbitControls,*/ renderer2, scene2, scene3, appManager} from './app-object.js';
@@ -58,7 +58,7 @@ const localMatrix3 = new THREE.Matrix4();
const localRay = new THREE.Ray();
const localTriangle = new THREE.Triangle();
-let skybox = null;
+// let skybox = null;
let xrscenetexture = null;
let xrsceneplane = null;
let xrscenecam = null;
| 2 |
diff --git a/packages/openneuro-app/src/scripts/datalad/routes/share.jsx b/packages/openneuro-app/src/scripts/datalad/routes/share.jsx @@ -4,10 +4,16 @@ import { Link } from 'react-router-dom'
import ShareDataset from '../mutations/share.jsx'
import RemovePermissions from '../mutations/remove-permissions.jsx'
+const description = {
+ admin: 'Edit dataset and edit permissions',
+ rw: 'Edit dataset',
+ ro: 'View dataset',
+}
+
const PermissionRow = ({ datasetId, userId, userEmail, access }) => (
<tr>
<td className="col-xs-4">{userEmail}</td>
- <td className="col-xs-2">{access}</td>
+ <td className="col-xs-2">{description[access]}</td>
<td className="col-xs-2">
<RemovePermissions datasetId={datasetId} userId={userId} />
</td>
@@ -58,34 +64,35 @@ const Share = ({ datasetId, permissions }) => {
))}
</tbody>
</table>
- <div className="row">
<p>
Enter a user's email address and select access level to share
</p>
+ <div className="input-group">
<input
+ className="form-control"
type="email"
value={userEmail}
onChange={e => setUserEmail(e.target.value)}
/>
- </div>
- <div className="row btn-group">
+ <div className="input-group-btn">
<button
- className={`btn btn-default btn-lg ${readActive}`}
+ className={`btn btn-default ${readActive}`}
onClick={() => setAccess('ro')}>
Read
</button>
<button
- className={`btn btn-default btn-lg ${writeActive}`}
+ className={`btn btn-default ${writeActive}`}
onClick={() => setAccess('rw')}>
Read and Write
</button>
<button
- className={`btn btn-default btn-lg ${adminActive}`}
+ className={`btn btn-default ${adminActive}`}
onClick={() => setAccess('admin')}>
Admin
</button>
</div>
</div>
+ </div>
<div className="col-xs-12 dataset-form-controls">
<div className="col-xs-12 modal-actions">
<Link to={`/datasets/${datasetId}`}>
| 7 |
diff --git a/diorama.js b/diorama.js import * as THREE from 'three';
-import {getRenderer, camera} from './renderer.js';
+import {getRenderer, scene} from './renderer.js';
import * as BufferGeometryUtils from 'three/examples/jsm/utils/BufferGeometryUtils.js';
// import {world} from './world.js';
import {fitCameraToBoundingBox} from './util.js';
| 0 |
diff --git a/server/classes/longRangeComm.js b/server/classes/longRangeComm.js @@ -37,7 +37,6 @@ export default class LongRangeComm extends System {
params.ra = params.a;
params.rf = params.f;
}
- console.log(decoded, params);
this.messages.push(new LRMessage(params));
}
sendMessage(message){
| 2 |
diff --git a/lib/assets/test/spec/builder/editor/style/style-form/style-form-components-dictionary.spec.js b/lib/assets/test/spec/builder/editor/style/style-form/style-form-components-dictionary.spec.js @@ -322,7 +322,7 @@ describe('editor/style/style-form/style-form-components-dictionary', function ()
}));
expect(componentDef.editorAttrs).toEqual(jasmine.objectContaining({
help: {
- color: 'editor.style.tooltips.fill.color',
+ color: 'editor.style.tooltips.fill.color-heatmap',
image: null
},
hidePanes: ['fixed'],
@@ -365,7 +365,7 @@ describe('editor/style/style-form/style-form-components-dictionary', function ()
expect(componentDef.options.length).toBe(1);
expect(componentDef.editorAttrs).toEqual(jasmine.objectContaining({
help: {
- color: 'editor.style.tooltips.fill.color',
+ color: 'editor.style.tooltips.fill.color-heatmap',
image: null
},
hidePanes: ['fixed'],
| 1 |
diff --git a/assets/js/components/link.js b/assets/js/components/link.js @@ -27,7 +27,6 @@ import classnames from 'classnames';
*/
import { _x } from '@wordpress/i18n';
import { Component } from '@wordpress/element';
-import { VisuallyHidden } from '@wordpress/components';
class Link extends Component {
render() {
@@ -77,9 +76,9 @@ class Link extends Component {
{ children }
{ external && (
- <VisuallyHidden as="span" className="screen-reader-text">
+ <span className="screen-reader-text">
{ _x( '(opens in a new tab)', 'screen reader text', 'google-site-kit' ) }
- </VisuallyHidden>
+ </span>
) }
</SemanticLink>
);
| 2 |
diff --git a/src/services/schema-form.provider.spec.js b/src/services/schema-form.provider.spec.js @@ -617,8 +617,8 @@ describe('schema-form.provider.js', function() {
var nameKey = objectPropertyKeys.items[0].key;
var ageKey = objectPropertyKeys.items[1].key;
- nameKey.pop().should.eq("name");
- ageKey.pop().should.eq("age");
+ nameKey.join('.').should.eq("peopleLivingWithYou.dependentChildren..name");
+ ageKey.join('.').should.eq("peopleLivingWithYou.dependentChildren..age");
});
});
});
| 7 |
diff --git a/lib/cmds/blockchain/geth_commands.js b/lib/cmds/blockchain/geth_commands.js @@ -153,6 +153,9 @@ GethCommands.prototype.mainCommand = function(address, done) {
callback(null, "");
}
], function(err, results) {
+ if (err) {
+ throw new Error(err.message);
+ }
done(self.geth_bin + " " + results.join(" "));
});
};
| 9 |
diff --git a/src/components/modebar/modebar.js b/src/components/modebar/modebar.js @@ -191,7 +191,7 @@ proto.createIcon = function(thisIcon, name) {
if(thisIcon.transform) {
path.setAttribute('transform', thisIcon.transform);
}
- else if(thisIcon.ascent) {
+ else if(thisIcon.ascent !== undefined) {
// Legacy icon transform calculation
var transform = name === 'toggleSpikelines' ?
'matrix(1.5 0 0 -1.5 0 ' + thisIcon.ascent + ')' :
| 3 |
diff --git a/tools/metadata/package.json b/tools/metadata/package.json {
"name": "@airswap/metadata",
- "version": "0.1.1",
+ "version": "0.1.2",
"description": "Token Metadata Tools for AirSwap Developers",
"contributors": [
"Don Mosites <[email protected]>",
| 3 |
diff --git a/docs/_data/categories.json b/docs/_data/categories.json "path": "form/form.html",
"group": "form"
},
- "form-field": {
+ "field": {
"name": "Form field",
"description": "A simple form container to group form sections",
"keywords": "form,field,groups",
| 10 |
diff --git a/packages/bitcore-node/src/models/coin.ts b/packages/bitcore-node/src/models/coin.ts @@ -65,12 +65,18 @@ class CoinModel extends BaseModel<ICoin> {
async getBalance(params: { query: any }) {
let { query } = params;
const result = await this.collection
- .aggregate<{ _id: string, balance: number }>([
+ .aggregate<{ _id: string; balance: number }>([
{ $match: query },
{
$project: {
value: 1,
- status: { $cond: { if: { $gte: ['$mintHeight', SpentHeightIndicators.minimum] }, then: 'confirmed', else: 'unconfirmed' } },
+ status: {
+ $cond: {
+ if: { $gte: ['$mintHeight', SpentHeightIndicators.minimum] },
+ then: 'confirmed',
+ else: 'unconfirmed'
+ }
+ },
_id: 0
}
},
@@ -78,33 +84,39 @@ class CoinModel extends BaseModel<ICoin> {
$group: {
_id: '$status',
balance: { $sum: '$value' }
-
}
}
])
.toArray();
- return result.reduce<{ confirmed: number, unconfirmed: number, balance: number }>((acc, cur) => {
+ return result.reduce<{ confirmed: number; unconfirmed: number; balance: number }>(
+ (acc, cur) => {
acc[cur._id] = cur.balance;
acc.balance += cur.balance;
return acc;
- }, { confirmed: 0, unconfirmed: 0, balance: 0 });
+ },
+ { confirmed: 0, unconfirmed: 0, balance: 0 }
+ );
}
- async getBalanceAtTime(params: { query: any, time: string, chain: string, network: string }) {
+ async getBalanceAtTime(params: { query: any; time: string; chain: string; network: string }) {
let { query, time, chain, network } = params;
const block = await BlockStorage.collection.findOne({
$query: {
chain,
network,
- time: { $lte: new Date(time) }
+ timeNormalized: { $lte: new Date(time) }
},
- $orderBy: { _id: -1 }
+ $orderBy: { timeNormalized: -1 }
});
- const blockHeight = block!.height
- const combinedQuery = Object.assign({}, {
+ const blockHeight = block!.height;
+ const combinedQuery = Object.assign(
+ {},
+ {
$or: [{ spentHeight: { $gt: blockHeight } }, { spentHeight: { $lt: SpentHeightIndicators.minimum } }],
mintHeight: { $lte: blockHeight }
- }, query);
+ },
+ query
+ );
return this.getBalance({ query: combinedQuery });
}
| 14 |
diff --git a/tests/accordion/__snapshots__/accordion.snapshot-test.jsx.snap b/tests/accordion/__snapshots__/accordion.snapshot-test.jsx.snap @@ -50,7 +50,7 @@ exports[`Base DOM Snapshot 1`] = `
stopPropagation={false}
/>
}
- summary="Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."
+ summary="Accordion Summary"
>
Accordion details - A
</SLDSAccordionPanel>
@@ -157,7 +157,7 @@ exports[`Base HTML Snapshot 1`] = `
<li class=\\"slds-accordion__list-item\\">
<section class=\\"slds-accordion__section\\">
<div class=\\"slds-accordion__summary\\">
- <h3 class=\\"slds-text-heading_small slds-accordion__summary-heading slds-has-flexi-truncate\\"><button aria-controls=\\"1-accordion-panel\\" aria-expanded=\\"false\\" class=\\"slds-button slds-button_reset slds-accordion__summary-action\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon slds-accordion__summary-action-icon slds-button__icon slds-button__icon_left\\"><use xlink:href=\\"/assets/icons/utility-sprite/svg/symbols.svg#switch\\"></use></svg><span class=\\"slds-truncate\\" title=\\"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.\\">Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</span></button></h3>
+ <h3 class=\\"slds-text-heading_small slds-accordion__summary-heading slds-has-flexi-truncate\\"><button aria-controls=\\"1-accordion-panel\\" aria-expanded=\\"false\\" class=\\"slds-button slds-button_reset slds-accordion__summary-action\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon slds-accordion__summary-action-icon slds-button__icon slds-button__icon_left\\"><use xlink:href=\\"/assets/icons/utility-sprite/svg/symbols.svg#switch\\"></use></svg><span class=\\"slds-truncate\\" title=\\"Accordion Summary\\">Accordion Summary</span></button></h3>
<div
class=\\"slds-dropdown-trigger slds-dropdown-trigger--click\\" id=\\"ButtonGroupExampleDropdown\\"><button aria-expanded=\\"false\\" aria-haspopup=\\"true\\" class=\\"slds-button slds-button--icon-border-filled slds-button--icon-x-small ignore-click-ButtonGroupExampleDropdown slds-shrink-none\\" tabindex=\\"0\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon\\"><use xlink:href=\\"/assets/icons/utility-sprite/svg/symbols.svg#down\\"></use></svg><span class=\\"slds-assistive-text\\">More Options</span></button></div>
</div>
| 3 |
diff --git a/articles/api-auth/dynamic-client-registration.md b/articles/api-auth/dynamic-client-registration.md @@ -215,6 +215,11 @@ https://${account.namespace}/authorize?
Where:
- `audience` (optional): The target API for which the Client Application is requesting access on behalf of the user. Set this parameter if you need API access.
- `scope` (optional): The scopes which you want to request authorization for. These must be separated by a space. You can request any of the [standard OIDC scopes](https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims) about users, such as `profile` and `email`, custom claims that must conform to a namespaced format (see panel below for more info), or any scopes supported by the target API (for example, `read:contacts`). Set this parameter if you need API access.
+
+ ::: panel-info Custom claims namespaced format
+ In order to improve compatibility for client applications, Auth0 will now return profile information in a [structured claim format as defined by the OIDC specification](https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims). This means that in order to add custom claims to ID tokens or access tokens, they must conform to a namespaced format to avoid possible collisions with standard OIDC claims. For example, if you choose the namespace `https://foo.com/` and you want to add a custom claim named `myclaim`, you would name the claim `https://foo.com/myclaim`, instead of `myclaim`.
+ :::
+
- `response_type`: The response type. For Implicit Grant you can either use `token` or `id_token token`. This will specify the type of token you will receive at the end of the flow. Use `token` to get only an `access_token`, or `id_token token` to get both an `id_token` and an `access_token`.
- `client_id`: Your application's Client ID.
- `redirect_uri`: The URL to which the Authorization Server (Auth0) will redirect the User Agent (Browser) after authorization has been granted by the User. The `access_token` (and optionally an `id_token`) will be available in the hash fragment of this URL. This URL must be specified as a valid callback URL under the Client Settings of your application.
| 0 |
diff --git a/articles/api-auth/tutorials/client-credentials/customize-with-hooks.md b/articles/api-auth/tutorials/client-credentials/customize-with-hooks.md @@ -64,6 +64,10 @@ If you haven't done these yet, refer to these docs for details:
- add an arbitrary claim (`https://foo.com/claim`) to the `access_token`
- add an `extra` scope to the default scopes configured on your [API](${manage_url}/#/apis).
+ ::: panel-info Arbitrary claims namespaced format
+ In order to improve compatibility for client applications, Auth0 now returns profile information in a [structured claim format as defined by the OIDC specification](https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims). This means that in order to add custom claims to ID tokens or access tokens, they must conform to a namespaced format to avoid possible collisions with standard OIDC claims. For example, if you choose the namespace `https://foo.com/` and you want to add a custom claim named `claim`, you would name the claim `https://foo.com/claim`, instead of just `claim`.
+ :::
+

Click __Save__ (or hit Ctrl+S/Cmd+S) and close the Editor.
| 0 |
diff --git a/assets/sass/widgets/_googlesitekit-widget-analyticsAllTraffic.scss b/assets/sass/widgets/_googlesitekit-widget-analyticsAllTraffic.scss .googlesitekit-widget--analyticsAllTraffic__dimensions-chart-gathering-data {
color: $c-silver-2;
font-size: 18px;
- font-weight: 400;
left: 50%;
line-height: 21px;
max-width: 80px;
| 2 |
diff --git a/token-metadata/0x0Ebb614204E47c09B6C3FeB9AAeCad8EE060E23E/metadata.json b/token-metadata/0x0Ebb614204E47c09B6C3FeB9AAeCad8EE060E23E/metadata.json "symbol": "CPAY",
"address": "0x0Ebb614204E47c09B6C3FeB9AAeCad8EE060E23E",
"decimals": 0,
- "dharmaVerificationStatus": {
"dharmaVerificationStatus": "VERIFIED"
}
\ No newline at end of file
-}
\ No newline at end of file
| 3 |
diff --git a/src/platform/web/ThemeLoader.ts b/src/platform/web/ThemeLoader.ts @@ -17,15 +17,35 @@ limitations under the License.
import type {ILogItem} from "../../logging/types.js";
import type {Platform} from "./Platform.js";
+type NormalVariant = {
+ id: string;
+ cssLocation: string;
+};
+
+type DefaultVariant = {
+ dark: {
+ id: string;
+ cssLocation: string;
+ themeDisplayName: string;
+ };
+ light: {
+ id: string;
+ cssLocation: string;
+ themeDisplayName: string;
+ };
+}
+type ThemeInformation = NormalVariant | DefaultVariant;
+
export class ThemeLoader {
private _platform: Platform;
- private _themeMapping: Record<string, string> = {};
+ private _themeMapping: Record<string, ThemeInformation>;
constructor(platform: Platform) {
this._platform = platform;
}
async init(manifestLocations: string[]): Promise<void> {
+ this._themeMapping = {};
for (const manifestLocation of manifestLocations) {
const { body } = await this._platform
.request(manifestLocation, {
@@ -36,8 +56,8 @@ export class ThemeLoader {
.response();
/*
After build has finished, the source section of each theme manifest
- contains `built-assets` which is a mapping from the theme-name to the
- location of the css file in build.
+ contains `built-assets` which is a mapping from the theme-name to theme
+ details which includes the location of the CSS file.
*/
Object.assign(this._themeMapping, body["source"]["built-assets"]);
}
@@ -45,7 +65,7 @@ export class ThemeLoader {
setTheme(themeName: string, log?: ILogItem) {
this._platform.logger.wrapOrRun(log, {l: "change theme", id: themeName}, () => {
- const themeLocation = this._themeMapping[themeName];
+ const themeLocation = this._findThemeLocationFromId(themeName);
if (!themeLocation) {
throw new Error( `Cannot find theme location for theme "${themeName}"!`);
}
@@ -54,8 +74,8 @@ export class ThemeLoader {
});
}
- get themes(): string[] {
- return Object.keys(this._themeMapping);
+ get themeMapping(): Record<string, ThemeInformation> {
+ return this._themeMapping;
}
async getActiveTheme(): Promise<string> {
@@ -72,4 +92,18 @@ export class ThemeLoader {
}
throw new Error("Cannot find active theme!");
}
+
+ private _findThemeLocationFromId(themeId: string) {
+ for (const themeData of Object.values(this._themeMapping)) {
+ if ("id" in themeData && themeData.id === themeId) {
+ return themeData.cssLocation;
+ }
+ else if ("light" in themeData && themeData.light?.id === themeId) {
+ return themeData.light.cssLocation;
+ }
+ else if ("dark" in themeData && themeData.dark?.id === themeId) {
+ return themeData.dark.cssLocation;
+ }
+ }
+ }
}
| 4 |
diff --git a/assets/js/components/Button.js b/assets/js/components/Button.js @@ -118,7 +118,16 @@ const Button = forwardRef(
tooltip: 'googlesitekit-tooltip',
} }
>
- { ButtonComponent }
+ {
+ // If the button is disabled it has no events for the Tooltip
+ // component to use, so it needs to be wrapped in a containing
+ // element.
+ disabled ? (
+ <span>{ ButtonComponent }</span>
+ ) : (
+ ButtonComponent
+ )
+ }
</Tooltip>
);
}
| 1 |
diff --git a/scripts/generate-documentation.py b/scripts/generate-documentation.py @@ -81,12 +81,12 @@ def search_files(type, files):
text = text[idx:]
braced_html = find_braces(text)
if test_file in debug_tests:
- print(braced_html)
- print("====")
+ print("\033[0m" + re.sub(prop_re, lambda m: "\033[1;31m" + m.group(0) + "\033[0m", braced_html))
+ print("\033[1;34m==================================================================\033[0m")
ms = re.findall(prop_re, braced_html)
if test_file in debug_tests:
- print('\n'.join(ms))
+ print('\n'.join(sorted(set(ms))))
for opt in ms:
if opt in docs and test_file not in docs[opt][type]:
docs[opt][type].append(test_file)
| 7 |
diff --git a/src/victory-util/events.js b/src/victory-util/events.js @@ -148,7 +148,7 @@ export default {
const parseEventReturn = (eventReturn, eventKey) => {
return Array.isArray(eventReturn) ?
eventReturn.reduce((memo, props) => {
- memo = merge({}, memo, parseEvent(props, eventKey));
+ memo = assign({}, memo, parseEvent(props, eventKey));
return memo;
}, {}) :
parseEvent(eventReturn, eventKey);
| 14 |
diff --git a/src/components/general/character-select/CharacterSelect.jsx b/src/components/general/character-select/CharacterSelect.jsx @@ -31,6 +31,7 @@ const characters = {
voice: `Sweetie Belle`,
class: 'Drop Hunter',
bio: `Her nickname is Scilly or SLY. 13/F drop hunter. She is an adventurer, swordfighter and fan of potions. She is exceptionally skilled and can go Super Saiyan.`,
+ themeSong: `https://webaverse.github.io/music/themes/149274046-smooth-adventure-quest.mp3`,
},
{
name: 'Drake',
@@ -39,6 +40,7 @@ const characters = {
voice: `Shining Armor`,
class: 'Neural Hacker',
bio: `His nickname is DRK. 15/M hacker. Loves guns. Likes plotting new hacks. He has the best equipment and is always ready for a fight.`,
+ themeSong: `https://webaverse.github.io/music/themes/129079005-im-gonna-find-it-mystery-sci-fi`,
},
{
name: 'Hyacinth',
@@ -47,6 +49,7 @@ const characters = {
voice: `Maud Pie`,
class: 'Beast Painter',
bio: `Scillia's mentor. 15/F beast tamer. She is quite famous. She is known for releasing beasts on her enemies when she get angry.`,
+ themeSongUrl: `https://webaverse.github.io/music/themes/092909594-fun-electro-dance-groove-racin.mp3`,
},
{
name: 'Juniper',
@@ -55,6 +58,7 @@ const characters = {
voice: `Cadance`,
class: 'Academy Engineer',
bio: `She is an engineer. 17/F engineer. She is new on the street. She has a strong moral compass and it the voice of reason in the group.`,
+ themeSongUrl: `https://webaverse.github.io/music/themes/092958842-groovy-jazzy-band-fun-light-su.mp3`,
},
{
name: 'Anemone',
@@ -63,6 +67,7 @@ const characters = {
voice: `Trixie`,
class: 'Lisk Witch',
bio: `A witch studying to make the best potions. 13/F. She is exceptionally skilled and sells her potions on the black market, but she is very shy.`,
+ themeSongUrl: `https://webaverse.github.io/music/themes/158618260-ghost-catcher-scary-funny-adve.mp3`,
},
],
};
| 0 |
diff --git a/src/core/ChefWorker.js b/src/core/ChefWorker.js @@ -27,7 +27,6 @@ self.chef = new Chef();
self.OpModules = OpModules;
self.OperationConfig = OperationConfig;
-self.inputNum = "0";
// Tell the app that the worker has loaded and is ready to operate
self.postMessage({
@@ -108,7 +107,7 @@ async function bake(data) {
action: "bakeComplete",
data: Object.assign(response, {
id: data.id,
- inputNum: data.inputNum || 0
+ inputNum: data.inputNum
})
});
} catch (err) {
@@ -116,7 +115,7 @@ async function bake(data) {
action: "bakeError",
data: Object.assign(err, {
id: data.id,
- inputNum: data.inputNum || 0
+ inputNum: data.inputNum
})
});
}
@@ -146,8 +145,7 @@ async function getDishAs(data) {
action: "dishReturned",
data: {
value: value,
- id: data.id,
- inputNum: self.inputNum
+ id: data.id
}
});
}
@@ -167,8 +165,7 @@ async function calculateHighlights(recipeConfig, direction, pos) {
self.postMessage({
action: "highlightsCalculated",
- data: pos,
- inputNum: self.inputNum
+ data: pos
});
}
@@ -200,8 +197,9 @@ self.loadRequiredModules = function(recipeConfig) {
self.sendStatusMessage = function(msg) {
self.postMessage({
action: "statusMessage",
- data: msg,
- inputNum: self.inputNum
+ data: {
+ message: msg
+ }
});
};
@@ -217,8 +215,7 @@ self.setOption = function(option, value) {
action: "optionUpdate",
data: {
option: option,
- value: value,
- inputNum: self.inputNum
+ value: value
}
});
};
@@ -237,8 +234,7 @@ self.setRegisters = function(opIndex, numPrevRegisters, registers) {
data: {
opIndex: opIndex,
numPrevRegisters: numPrevRegisters,
- registers: registers,
- inputNum: self.inputNum
+ registers: registers
}
});
};
| 2 |
diff --git a/src/web/OutputWaiter.mjs b/src/web/OutputWaiter.mjs @@ -796,7 +796,9 @@ class OutputWaiter {
* Handler for go to tab button clicked
*/
goToTab() {
- const tabNum = parseInt(window.prompt("Enter tab number:", this.getActiveTab().toString()), 10);
+ const min = this.getSmallestInputNum(),
+ max = this.getLargestInputNum(),
+ tabNum = parseInt(window.prompt(`Enter tab number (${min} - ${max}):`, this.getActiveTab().toString()), 10);
if (this.outputExists(tabNum)) {
this.changeTab(tabNum, this.app.options.syncTabs);
}
| 0 |
diff --git a/app/views/layouts/_page_header.html.erb b/app/views/layouts/_page_header.html.erb <!-- Appcues integration setup for Segment only (excludes PII)-->
analytics.identify(
- <%= current_user.id %>,
+ '<%= "Appcues-#{current_user.id}" %>',
<%= raw escape_json(current_user.traits_for_segment(include_pii: false)) %>,
{ integrations: { "All": false, "Appcues": true }},
);
| 12 |
diff --git a/lib/xiaomi.js b/lib/xiaomi.js @@ -196,9 +196,10 @@ const numericAttributes2Payload = (msg, meta, model, options, dataObject) => {
payload[`state_${mapping}`] = value === 1 ? 'ON' : 'OFF';
} else if (['WXKG14LM', 'WXKG16LM', 'WXKG17LM'].includes(model.model)) {
payload.click_mode = {1: 'fast', 2: 'multi'}[value];
- } else if (['WXCJKG11LM', 'WXCJKG12LM', 'WXCJKG13LM'].includes(model.model)) {
+ } else if (['WXCJKG11LM', 'WXCJKG12LM', 'WXCJKG13LM', 'ZNMS12LM'].includes(model.model)) {
// We don't know what the value means for these devices.
// https://github.com/Koenkk/zigbee2mqtt/issues/11126
+ // https://github.com/Koenkk/zigbee2mqtt/issues/12279
} else if (['WSDCGQ01LM', 'WSDCGQ11LM'].includes(model.model)) {
// https://github.com/Koenkk/zigbee2mqtt/issues/798
// Sometimes the sensor publishes non-realistic vales, filter these
| 8 |
diff --git a/db.js b/db.js @@ -16,6 +16,7 @@ var db;
var files;
var jobs;
var users;
+var thumbnails;
function notifyChange() {
var machine = require('./machine').machine;
@@ -551,6 +552,7 @@ exports.configureDB = function(callback) {
files = db.collection("files");
jobs = db.collection("jobs");
users = db.collection("users");
+ thumbnails = db.collection("thumbnails");
users.find({}).toArray(function(err,result){ //init the user database with an admin account if it's empty
if (err){
@@ -569,6 +571,9 @@ exports.configureDB = function(callback) {
},
function(cb) {
checkCollection(jobs, cb);
+ },
+ function(cb) {
+ checkCollection(thumbnails, cb);
}
],
function(err, results) {
| 0 |
diff --git a/plugins/shared_filesystem_storage/config/policy.json b/plugins/shared_filesystem_storage/config/policy.json "shared_filesystem_storage:share_delete": "rule:context_is_share_editor",
"shared_filesystem_storage:share_update": "rule:context_is_share_editor",
"shared_filesystem_storage:share_export_locations": "rule:context_is_share_viewer",
- "shared_filesystem_storage:share_force_delete": "rule:context_is_sharedfilesystem_admin",
+ "shared_filesystem_storage:share_force_delete": "rule:context_is_cloud_sharedfilesystem_admin",
"shared_filesystem_storage:share_reset_status": "rule:context_is_sharedfilesystem_admin",
"shared_filesystem_storage:share_revert_to_snapshot": "rule:context_is_share_editor",
"shared_filesystem_storage:share_extend": "rule:context_is_share_editor",
| 11 |
diff --git a/game.js b/game.js @@ -25,6 +25,7 @@ import npcManager from './npc-manager.js';
import raycastManager from './raycast-manager.js';
import zTargeting from './z-targeting.js';
import Avatar from './avatars/avatars.js';
+import {getRandomString} from './util.js';
const localVector = new THREE.Vector3();
const localVector2 = new THREE.Vector3();
@@ -1437,6 +1438,8 @@ class GameManager extends EventTarget {
const app = await metaversefileApi.createAppAsync({
start_url: u,
});
+ app.instanceId = getRandomString();
+ // this process "creates" a new app on what we currently have in inventory
world.appManager.importApp(app);
app.activate();
// XXX set to index
| 0 |
diff --git a/spec/composer-spec.js b/spec/composer-spec.js @@ -41,6 +41,7 @@ describe('Composer', () => {
spyOn(composer, 'showResult').andReturn()
spyOn(composer, 'showError').andReturn()
fixturesPath = helpers.cloneFixtures()
+ atom.config.set('latex.loggingLevel', 'error')
})
it('does nothing for new, unsaved files', () => {
| 12 |
diff --git a/bin/sails-www.js b/bin/sails-www.js @@ -97,12 +97,14 @@ module.exports = function() {
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
// Execute a command like you would on the terminal.
Process.executeCommand({
- command: 'grunt '+overrideGruntTask,
+ command: path.join('node_modules', '.bin', 'grunt')+' '+overrideGruntTask,
}).exec(function (err) {
if (err) {
log.error('Error occured running `grunt ' + overrideGruntTask + '`');
log.error('Please resolve any issues and try running `sails www` again.');
- log.error('Details:');
+ log.error('Hint: you must have the Grunt CLI installed! Try `npm install grunt`.');
+ log.error();
+ log.error('Error details:');
log.error(err);
return process.exit(1);
}
| 4 |
diff --git a/src/components/TableResize.js b/src/components/TableResize.js @@ -78,8 +78,9 @@ class TableResize extends React.Component {
let parentOffsetLeft = getParentOffsetLeft(tableEl);
let finalCells = Object.entries(this.cellsRef);
+ let cellMinusOne = finalCells.filter((_item, ix) => ix + 1 < finalCells.length);
- finalCells.forEach(([key, item], idx) => {
+ cellMinusOne.forEach(([key, item], idx) => {
if (!item) return;
let elRect = item.getBoundingClientRect();
let left = elRect.left;
| 0 |
diff --git a/accessibility-checker-engine/src/v4/rules/element_tabbable_role_invalid.ts b/accessibility-checker-engine/src/v4/rules/element_tabbable_role_invalid.ts @@ -54,7 +54,7 @@ export let element_tabbable_role_invalid: Rule = {
if (RPTUtil.isNodeDisabled(ruleContext) || RPTUtil.isNodeHiddenFromAT(ruleContext)) return null;
const nodeName = ruleContext.nodeName.toLowerCase();
- // if the elemen is tabbable by default without tabindex, let the other rules (such as IBMA_Focus_MultiTab) to handle it
+ // if the elemen is tabbable by default with or without tabindex, let the other rules (such as IBMA_Focus_MultiTab) to handle it
if (nodeName in RPTUtil.tabTagMap ) {
let value = RPTUtil.tabTagMap[nodeName];
if (typeof (value) === "function") {
| 3 |
diff --git a/js/views/search/Search.js b/js/views/search/Search.js @@ -399,7 +399,7 @@ export default class extends baseVw {
if (this.categoryViews.length === this._categorySearches.length) {
app.router.navigate('search/home');
- this._search.provider = app.searchProviders.at(0);
+ this._search = { ...this._defaultSearch, provider: app.searchProviders.at(0) };
scrollPageIntoView();
// The state may not be changed here, so always fire a render.
this.setState({ tab: 'home' }, { renderOnChange: false });
| 12 |
diff --git a/CHANGELOG.md b/CHANGELOG.md # Changelog
-## Unreleased
+## 1.65.1
- Fix: Init metrics correctly when no config is passed ([#138](https://github.com/instana/nodejs-sensor/issues/138)).
- Add data.rpc.host and data.rpc.port to GRPC exits to improve service discovery.
| 6 |
diff --git a/CHANGELOG.md b/CHANGELOG.md @@ -10,6 +10,15 @@ https://github.com/plotly/plotly.js/compare/vX.Y.Z...master
where X.Y.Z is the semver of most recent plotly.js release.
+## [1.51.3] -- 2019-12-16
+
+### Fixed
+- Fix `Plotly.Plots.resize` edge cases ensuring now that
+ its promises always resolve [#4392]
+- Fix position of link hover labels in vertical `sankey` [#4404]
+- Fix `box` autorange for traces with "inverted" notched [#4388]
+
+
## [1.51.2] -- 2019-11-25
### Fixed
| 3 |
diff --git a/src/web/containers/Settings/About/UpdateStatusContainer.jsx b/src/web/containers/Settings/About/UpdateStatusContainer.jsx @@ -34,7 +34,7 @@ const UpdateStatusContainer = (props) => {
</div>
<div className={styles.updateStatusMessageContainer}>
<div className={styles.updateStatusMessage}>
- {i18n._('A new version of {{name}} is available', { name: 'cnc' })}
+ {i18n._('A new version of {{name}} is available', { name: settings.name })}
</div>
<div className={styles.releaseLatest}>
{i18n._('Version {{version}}', { version: latest })}
| 14 |
diff --git a/bin/ractive.js b/bin/ractive.js @@ -20,8 +20,11 @@ const opts = {
base: process.cwd()
};
-function readFile(name) {
- return Promise.resolve(fs.readFileSync(path.resolve(opts.base, name), { encoding: 'utf8' }));
+function mkReadFile(file) {
+ const base = path.join(opts.base, path.dirname(file));
+ return function readFile(name) {
+ return Promise.resolve(fs.readFileSync(path.join(base, name), { encoding: 'utf8' }));
+ };
}
function dirIndexOrFile(name) {
@@ -76,7 +79,9 @@ const commands = {
util
.readToString(fs.createReadStream(path.join(opts.directory, f)))
.then(string => {
- return component.build(string, opts, readFile).then(string => {
+ return component
+ .build(string, opts, mkReadFile(path.join(opts.directory, f)))
+ .then(string => {
const file = path.join(
opts.output,
f.replace(ext, opts.outputExtension || '.js')
@@ -98,7 +103,7 @@ const commands = {
.readToString(opts.input)
.then(string => {
return component
- .build(string, opts, readFile)
+ .build(string, opts, mkReadFile(opts.input))
.then(string => util.writeToStream(opts.output, string));
})
.then(null, err => {
| 4 |
diff --git a/edit.html b/edit.html <div class="ftu-phase ftu-phase-1">
<div class=wrap>
<div class=label><div class=background></div><div class=content>Call me...</div></div>
- <input type=text value="Anonymous">
+ <input type=text value="Anonymous" id=ftu-username>
</div>
<div class=buttons>
<div class="button next-phase-button">Next</div>
| 0 |
diff --git a/aura-impl/src/main/resources/aura/AuraComponentService.js b/aura-impl/src/main/resources/aura/AuraComponentService.js @@ -677,7 +677,13 @@ AuraComponentService.prototype.createComponentInstance = function(config, localC
// Always comes back as a function to execute, which defines the component classes.
var componentClassDef = config["componentClass"] || config["componentDef"][Json.ApplicationKey.COMPONENTCLASS];
if(componentClassDef && !this.hasComponentClass(desc)) {
+ try {
componentClassDef = $A.util.globalEval(componentClassDef, $A.clientService.getSourceMapsUrl(desc));
+ } catch (e) {
+ var e1 = new AuraError(e);
+ e1.setComponent(desc);
+ throw e1;
+ }
componentClassDef();
}
@@ -686,10 +692,18 @@ AuraComponentService.prototype.createComponentInstance = function(config, localC
this.createFromSavedComponentConfigs(desc);
}
- var classConstructor = this.getComponentClass(desc, def);
+ var classConstructor;
+ try {
+ classConstructor = this.getComponentClass(desc, def);
+ } catch (e) {
+ var e2 = new AuraError(e);
+ e2.setComponent(desc);
+ throw e2;
+ }
if (!classConstructor) {
throw new $A.auraError("Component class not found: " + desc, null, $A.severity.QUIET);
}
+
return new classConstructor(config, localCreation);
};
| 12 |
diff --git a/token-metadata/0x557B933a7C2c45672B610F8954A3deB39a51A8Ca/metadata.json b/token-metadata/0x557B933a7C2c45672B610F8954A3deB39a51A8Ca/metadata.json "symbol": "REVV",
"address": "0x557B933a7C2c45672B610F8954A3deB39a51A8Ca",
"decimals": 18,
- "dharmaVerificationStatus": {
"dharmaVerificationStatus": "VERIFIED"
}
\ No newline at end of file
-}
\ No newline at end of file
| 3 |
diff --git a/src/deploy/NVA_build/first_install_diaglog.sh b/src/deploy/NVA_build/first_install_diaglog.sh @@ -154,9 +154,6 @@ function configure_dns_dialog {
local dns1=$(head -1 answer_dns)
local dns2=$(tail -1 answer_dns)
- sudo sed -i "s/.*NooBaa Configured Primary DNS Server//" /etc/resolv.conf
- sudo sed -i "s/.*NooBaa Configured Secondary DNS Server//" /etc/resolv.conf
-
while [ "${dns1}" == "" ]; do
dialog --colors --nocancel --backtitle "NooBaa First Install" --title "DNS Configuration" --form "\nPlease supply a primary and secodnary DNS servers (Use \Z4\ZbUp/Down\Zn to navigate)." 12 65 4 "Primary DNS:" 1 1 "${dns1}" 1 25 25 30 "Secondary DNS:" 2 1 "${dns2}" 2 25 25 30 2> answer_dns
dns1=$(head -1 answer_dns)
@@ -164,6 +161,9 @@ function configure_dns_dialog {
dns2=$(tail -1 answer_dns)
done
+ sudo sed -i "s/.*NooBaa Configured Primary DNS Server//" /etc/resolv.conf
+ sudo sed -i "s/.*NooBaa Configured Secondary DNS Server//" /etc/resolv.conf
+
sudo bash -c "echo 'search localhost.localdomain' > /etc/resolv.conf"
sudo bash -c "echo 'nameserver ${dns1} #NooBaa Configured Primary DNS Server' >> /etc/resolv.conf"
if [ "${dns2}" != "" ]; then
| 2 |
diff --git a/app/models/daos/UserDAOImpl.scala b/app/models/daos/UserDAOImpl.scala @@ -132,8 +132,8 @@ object UserDAOImpl {
"""SELECT COUNT(DISTINCT(audit_task.user_id))
|FROM sidewalk.audit_task
|INNER JOIN sidewalk_user ON sidewalk_user.user_id = audit_task.user_id
- |INNER JOIN sidewalk_user_role ON sidewalk_user.user_id = sidewalk_user_role.user_id
- |INNER JOIN sidewalk.role ON sidewalk_user_role.role_id = sidewalk.role.role_id
+ |INNER JOIN user_role ON sidewalk_user.user_id = user_role.user_id
+ |INNER JOIN sidewalk.role ON user_role.role_id = sidewalk.role.role_id
|WHERE audit_task.task_end::date = now()::date
| AND sidewalk_user.username <> 'anonymous'
| AND role.role = ?
@@ -178,8 +178,8 @@ object UserDAOImpl {
"""SELECT COUNT(DISTINCT(audit_task.user_id))
|FROM sidewalk.audit_task
|INNER JOIN sidewalk_user ON sidewalk_user.user_id = audit_task.user_id
- |INNER JOIN sidewalk_user_role ON sidewalk_user.user_id = sidewalk_user_role.user_id
- |INNER JOIN sidewalk.role ON sidewalk_user_role.role_id = sidewalk.role.role_id
+ |INNER JOIN user_role ON sidewalk_user.user_id = user_role.user_id
+ |INNER JOIN sidewalk.role ON user_role.role_id = sidewalk.role.role_id
|WHERE audit_task.task_end::date = now()::date - interval '1' day
| AND sidewalk_user.username <> 'anonymous'
| AND role.role = ?
| 13 |
diff --git a/src/components/Menu/Menu.js b/src/components/Menu/Menu.js @@ -187,11 +187,13 @@ const Menu = ({ menuOpen, toggleOpen }) => {
columns: 2;
max-width: 155px;
margin: 0 auto;
+ height: 85px;
${mediaQueries.phoneLarge} {
columns: unset;
max-width: none;
margin: 0 auto;
+ height: auto;
}
`;
| 12 |
diff --git a/lib/shared/addon/oauth/service.js b/lib/shared/addon/oauth/service.js @@ -4,7 +4,6 @@ import { get, set } from '@ember/object';
import C from 'shared/utils/constants';
const googleOauthScope = 'openid profile email';
-const githubOauthScope = 'read:org';
export default Service.extend({
access: service(),
@@ -42,7 +41,6 @@ export default Service.extend({
if (isGithub) {
url = addQueryParams(get(auth, 'redirectUrl'), {
- scope: githubOauthScope,
redirect_uri: `${ window.location.origin }/verify-auth`,
authProvider: 'github',
state,
@@ -68,7 +66,7 @@ export default Service.extend({
}
let url = addQueryParams(authRedirect, {
- scope: authType === 'github' ? githubOauthScope : googleOauthScope,
+ scope: authType === 'googleoauth' ? googleOauthScope : undefined,
state: this.generateLoginStateKey(authType),
redirect_uri: redirect,
});
| 2 |
diff --git a/lib/assets/javascripts/dashboard/views/profile/profile-form/profile-form.tpl b/lib/assets/javascripts/dashboard/views/profile/profile-form/profile-form.tpl <label class="CDB-Text CDB-Size-medium is-semibold u-mainTextColor"><%= _t('profile.views.form.role') %></label>
</div>
<div class="FormAccount-rowData">
- <select class="CDB-InputText CDB-Text FormAccount-input FormAccount-input--med" id="user_job_role" name="user[job_role]">
+ <select class="CDB-SelectFake CDB-Text FormAccount-input FormAccount-input--med" id="user_job_role" name="user[job_role]">
<option value="">Select one</option>
<% jobRoles.forEach(function (role) { %>
<div class="FormAccount-row">
<div class="FormAccount-rowLabel">
- <label class="CDB-Text CDB-Size-medium is-semibold u-mainTextColor"><%= _t('profile.views.form.disqus') %></label>
+ <label class="CDB-Text CDB-Size-medium is-semibold u-mainTextColor"><%= _t('profile.views.form.disqus') %>*</label>
</div>
<div class="FormAccount-rowData">
<input class="CDB-InputText CDB-Text FormAccount-input FormAccount-input--med" id="user_disqus_shortname" name="user[disqus_shortname]" placeholder="<%= _t('profile.views.form.disqus_placeholder') %>" size="30" type="text" value="<%= disqus_shortname %>">
| 12 |
diff --git a/lib/rules/storage.js b/lib/rules/storage.js @@ -6,6 +6,16 @@ var RecycleBin = require('./recycle-bin');
var ENCODING = {encoding: 'utf8'};
var RETRY_INTERVAL = 16000;
+var ASCII_RE = /[\x00-\x7f]/g;
+
+function encodeName(name) {
+ try {
+ return name.replace(ASCII_RE, encodeURIComponent);
+ } catch(e) {
+ logger.error(e);
+ }
+ return name;
+}
function readFileSafe(file, retry) {
try {
@@ -91,16 +101,19 @@ function Storage(dir, filters) {
if (filters[filename]) {
return;
}
+ var filePath = path.join(self._files, file);
+ if (files[filename]) {
+ return fs.unlinkSync(filePath);
+ }
if (index > maxIndex) {
maxIndex = index;
}
- fileNames[file] = true;
- var filePath = path.join(self._files, file);
var data = readFileSafe(filePath);
+ var backFile = path.join(backupDir, file);
if (data) {
- fs.writeFileSync(path.join(backupDir, file), data);
+ fs.writeFileSync(backFile, data);
} else {
- data = readFileSafe(path.join(backupDir, file));
+ data = readFileSafe(backFile);
if (data) {
fs.writeFileSync(filePath, data);
}
@@ -110,6 +123,13 @@ function Storage(dir, filters) {
name: filename,
data: data
};
+ var newFile = index + '.' + encodeName(filename);
+ fileNames[newFile] = true;
+ if (file !== newFile) {
+ fs.writeFileSync(path.join(self._files, newFile), data);
+ fs.writeFileSync(path.join(backupDir, newFile), data);
+ fs.unlinkSync(filePath);
+ }
});
var properties = readJsonSafe(self._properties);
@@ -231,13 +251,7 @@ proto._writeFile = function(file) {
proto._getFilePath = function(file, backup) {
file = typeof file == 'string' ? this._cache.files[file] : file;
- var name = file.name;
- try {
- name = encodeURIComponent(file.name);
- } catch(e) {
- logger.error(e);
- }
- name = file.index + '.' + name;
+ var name = file.index + '.' + encodeName(file.name);
return path.join(backup ? this._backupDir : this._files, name);
};
| 1 |
diff --git a/package.json b/package.json "scripts": {
"build": "rm -rf build && mkdir build && rollup -c",
"pretest": "npm run build",
- "test": "env TESTRUNNER='nyc tape' npm run do-test",
+ "test": "env TESTRUNNER='nyc mocha' npm run do-test",
"do-test": "mkdir -p http:; ln -nsf .. http://dummyhost; $TESTRUNNER 'test/**/*-test.js'",
"report": "nyc report --reporter=lcov",
"coverage": "nyc report --reporter=text-lcov > coverage.lcov && codecov",
"prepublishOnly": "env NODE_ENV=production npm run build && terser build/d3-graphviz.js -c -m -o build/d3-graphviz.min.js",
- "prepublishOnlyOriginal": "env NODE_ENV=production npm run build && TESTRUNNER='tape' npm run do-test && terser build/d3-graphviz.js -c -m -o build/d3-graphviz.min.js",
+ "prepublishOnlyOriginal": "env NODE_ENV=production npm run build && TESTRUNNER='mocha' npm run do-test && terser build/d3-graphviz.js -c -m -o build/d3-graphviz.min.js",
"publicbuild": "env NODE_ENV=production npm run build",
"postpublish": "zip -j build/d3-graphviz.zip -- LICENSE README.md build/d3-graphviz.js build/d3-graphviz.min.js"
},
| 14 |
diff --git a/Dockerfile b/Dockerfile @@ -55,5 +55,5 @@ RUN npm install --save form-data
#RUN usermod -d /var/lib/mysql/ mysql
#RUN echo "disable_log_bin" >> /etc/mysql/mysql.conf.d/mysqld.cnf
-RUN service mariadb start && mysql -u root -e "CREATE DATABASE operationaldb /*\!40100 DEFAULT CHARACTER SET utf8 */; UNINSTALL PLUGIN validate_password; SET PASSWORD FOR root@localhost = PASSWORD(''); FLUSH PRIVILEGES;" && npx sequelize --config=./config/sequelizeConfig.js db:migrate
+RUN service mariadb start && mysql -u root -e "CREATE DATABASE operationaldb /*\!40100 DEFAULT CHARACTER SET utf8 */; SET PASSWORD FOR root@localhost = PASSWORD(''); FLUSH PRIVILEGES;" && npx sequelize --config=./config/sequelizeConfig.js db:migrate
| 3 |
diff --git a/react/src/components/card/components/SprkCardHighlightedHeader/SprkCardHighlightedHeader.test.js b/react/src/components/card/components/SprkCardHighlightedHeader/SprkCardHighlightedHeader.test.js @@ -24,7 +24,7 @@ afterEach(() => {
createTestObjects();
});
-describe('SprkHighlightedHeader:', () => {
+describe('SprkCardHighlightedHeader:', () => {
it("should display highlighted header's body text", () => {
const testVariable = 'test';
testHighlightedHeaderConfig.bodyText = testVariable;
| 3 |
diff --git a/packages/@uppy/companion/src/standalone/helper.js b/packages/@uppy/companion/src/standalone/helper.js @@ -174,7 +174,7 @@ exports.buildHelpfulStartupMessage = (uppyOptions) => {
providerName = 'drive'
}
- callbackURLs.push(buildURL(`/${providerName}/callback`, true))
+ callbackURLs.push(buildURL(`/connect/${providerName}/callback`, true))
})
return stripIndent`
| 3 |
diff --git a/stories/theme-customizations/Switch.custom.scss b/stories/theme-customizations/Switch.custom.scss // Switch theme customizations
-$switch-on-accent-color: #3c6e3d;
-$switch-off-accent-color: #b4bdca;
+$switch-accent-color-on: #3c6e3d;
+$switch-accent-color-off: #b4bdca;
$switch-thumb-accent-color: #ffffff;
$switch-track-height: 10px;
$switch-track-length: 50px;
| 10 |
diff --git a/articles/quickstart/spa/react/_includes/_centralized_login.md b/articles/quickstart/spa/react/_includes/_centralized_login.md @@ -9,11 +9,10 @@ Create a service and instantiate `auth0.WebAuth`. Provide a method called `login
```js
// src/Auth/Auth.js
-import { EventEmitter } from 'events';
import history from '../history';
import auth0 from 'auth0-js';
-export default class Auth extends EventEmitter {
+export default class Auth {
auth0 = new auth0.WebAuth({
domain: '${account.namespace}',
clientID: '${account.clientId}',
@@ -43,10 +42,9 @@ Add some additional methods to the `Auth` service to fully handle authentication
// src/Auth/Auth.js
// ...
-export default class Auth extends EventEmitter {
+export default class Auth {
// ...
constructor() {
- super();
this.login = this.login.bind(this);
this.logout = this.logout.bind(this);
this.handleAuthentication = this.handleAuthentication.bind(this);
@@ -182,7 +180,7 @@ const auth = new Auth();
const handleAuthentication = (nextState, replace) => {
if (/access_token|id_token|error/.test(nextState.location.hash)) {
- auth.handleAuthentication(nextState.location.hash);
+ auth.handleAuthentication();
}
}
| 2 |
diff --git a/assets/js/modules/analytics/datastore/setup.test.js b/assets/js/modules/analytics/datastore/setup.test.js @@ -48,6 +48,11 @@ describe( 'modules/analytics setup', () => {
trackingDisabled: [],
anonymizeIP: true,
};
+ const tagWithPermission = {
+ accountID: '12345',
+ propertyID: 'UA-12345-1',
+ permission: true,
+ };
beforeAll( () => {
API.setUsingCache( false );
@@ -198,6 +203,7 @@ describe( 'modules/analytics setup', () => {
describe( 'canSubmitChanges', () => {
it( 'requires a valid accountID', () => {
registry.dispatch( STORE_NAME ).setSettings( validSettings );
+ registry.dispatch( STORE_NAME ).receiveTagPermission( tagWithPermission );
expect( registry.select( STORE_NAME ).canSubmitChanges() ).toBe( true );
@@ -208,6 +214,7 @@ describe( 'modules/analytics setup', () => {
it( 'requires a valid propertyID', () => {
registry.dispatch( STORE_NAME ).setSettings( validSettings );
+ registry.dispatch( STORE_NAME ).receiveTagPermission( tagWithPermission );
expect( registry.select( STORE_NAME ).canSubmitChanges() ).toBe( true );
@@ -218,6 +225,7 @@ describe( 'modules/analytics setup', () => {
it( 'requires a valid profileID', () => {
registry.dispatch( STORE_NAME ).setSettings( validSettings );
+ registry.dispatch( STORE_NAME ).receiveTagPermission( tagWithPermission );
expect( registry.select( STORE_NAME ).canSubmitChanges() ).toBe( true );
| 12 |
diff --git a/dist/uPlot.d.ts b/dist/uPlot.d.ts @@ -126,7 +126,8 @@ declare class uPlot {
static assign(targ: object, ...srcs: object[]): object;
/** re-ranges a given min/max by a multiple of the range's magnitude (used internally to expand/snap/pad numeric y scales) */
- static rangeNum: ((min: number, max: number, mult: number, extra: boolean) => uPlot.Range.MinMax) | ((min: number, max: number, cfg: uPlot.Range.Config) => uPlot.Range.MinMax);
+ static rangeNum(min: number, max: number, mult: number, extra: boolean): uPlot.Range.MinMax;
+ static rangeNum(min: number, max: number, cfg: uPlot.Range.Config): uPlot.Range.MinMax;
/** re-ranges a given min/max outwards to nearest 10% of given min/max's magnitudes, unless fullMags = true */
static rangeLog(min: number, max: number, base: uPlot.Scale.LogBase, fullMags: boolean): uPlot.Range.MinMax;
@@ -151,10 +152,10 @@ declare class uPlot {
static clipGaps: uPlot.Series.ClipPathBuilder;
/** helper function for grabbing proper drawing orientation vars and fns for a plot instance (all dims in canvas pixels) */
- static orient: (u: uPlot, seriesIdx: number, callback: uPlot.OrientCallback) => any;
+ static orient(u: uPlot, seriesIdx: number, callback: uPlot.OrientCallback): any;
/** returns a pub/sub instance shared by all plots usng the provided key */
- static sync: (key: string) => uPlot.SyncPubSub;
+ static sync(key: string): uPlot.SyncPubSub;
}
export = uPlot;
| 7 |
diff --git a/Source/DataSources/KmlTourFlyTo.js b/Source/DataSources/KmlTourFlyTo.js @@ -3,12 +3,18 @@ import combine from "../Core/combine.js";
import defined from "../Core/defined.js";
import EasingFunction from "../Core/EasingFunction.js";
/**
+ * Transitions the KmlTour to the next destination. This transition is facilitated
+ * using a specified flyToMode over a given number of seconds.
+ *
* @alias KmlTourFlyTo
* @constructor
*
* @param {Number} duration entry duration
* @param {String} flyToMode KML fly to mode: bounce, smooth, etc
* @param {KmlCamera|KmlLookAt} view KmlCamera or KmlLookAt
+ *
+ * @see KmlTour
+ * @see KmlTourWait
*/
function KmlTourFlyTo(duration, flyToMode, view) {
this.type = "KmlTourFlyTo";
| 3 |
diff --git a/ReviewQueueHelper.user.js b/ReviewQueueHelper.user.js @@ -836,8 +836,6 @@ function doPageLoad() {
processReview = processReopenReview; break;
case 'suggested-edits':
processReview = processCloseReview; break;
- case 'helper':
- processReview = processCloseReview; break;
case 'low-quality-posts':
processReview = processLowQualityPostsReview; break;
case 'triage':
@@ -1176,7 +1174,7 @@ function listenToPageUpdates() {
// If first-posts or late-answers queue, and not already reviewed (no Next button)
const reviewStatus = $('.review-status').text();
- if ((queueType == 'first-posts' || queueType == 'late-answers' || queueType == 'helper') &&
+ if ((queueType == 'first-posts' || queueType == 'late-answers') &&
!reviewStatus.includes('This item is no longer reviewable.') && !reviewStatus.includes('This item is not reviewable.') && !reviewStatus.includes('Review completed')) {
// If question, insert "Close" option
@@ -1202,32 +1200,7 @@ function listenToPageUpdates() {
}
return false;
});
- $('.js-review-actions button').first().after(delBtn);
- }
-
- // Show post menu if in the H&I queue
- if (location.pathname.includes('/review/helper/')) {
- $('.close-question-link').show();
- }
- }
-
- // If we are in H&I
- if (queueType == 'helper') {
-
- // If H&I review has been completed
- if (responseJson.isUnavailable) {
- // Remove edit button so only "Next" is displayed
- $('.js-review-actions button').first().remove();
- }
-
- // Display link to triage review if not already shown
- if ($('.reviewable-post-stats .js-triage-link').length === 0) {
- $.get(`https://${location.hostname}/posts/${responseJson.postId}/timeline`)
- .done(function (data) {
- const triageLink = $('[data-eventtype="review"] a', data).filter((i, el) => el.href.includes('/triage/')).attr('href');
- $('.reviewable-post-stats')
- .append(`<a href="${triageLink}" class="s-btn s-btn__sm s-btn__primary mt16 js-triage-link" title="see who voted for requires editing" target="_blank">view triage</a>`);
- });
+ $('.js-review-actions button').first().after(delBtn).after('<span> </span>');
}
}
@@ -1299,7 +1272,7 @@ function listenToPageUpdates() {
}
}
- // finally remove sidebar table links
+ // Finally remove sidebar table links
$('.reviewable-post-stats').each(function () {
const table = $(this).children('table').first();
@@ -1315,6 +1288,9 @@ function listenToPageUpdates() {
}
});
+ // Remove mod menu button since we already inserted it in the usual post menu, freeing up more space
+ $('.js-review-actions fieldset > div:last-child .flex--item:last-child').remove();
+
// Remove "Delete" option for suggested-edits queue, if not already reviewed (no Next button)
if (queueType == 'suggested-edits' && !$('.review-status').text().includes('This item is no longer reviewable.')) {
$('.js-review-actions button[title*="delete"]').remove();
| 2 |
diff --git a/includes/Modules/Tag_Manager.php b/includes/Modules/Tag_Manager.php @@ -331,8 +331,7 @@ final class Tag_Manager extends Module
);
case 'GET:tag-permission':
return function () use ( $data ) {
- // TODO: Remove 'tag' fallback once legacy components are refactored.
- $container_id = $data['containerID'] ?: $data['tag'];
+ $container_id = $data['containerID'];
if ( ! $container_id ) {
return new WP_Error(
| 2 |
diff --git a/blockchain.js b/blockchain.js @@ -142,6 +142,19 @@ const getTransactionSignature = async (chainName, contractName, transactionHash)
return null;
};
+const runMainnetTransaction = async (contractName, method, ...args) => {
+ const addresses = await window.ethereum.enable();
+ if (addresses.length > 0) {
+ const [address] = addresses;
+ const m = contracts.front[contractName].methods[method];
+ m.apply(m, args).send({
+ from: address,
+ });
+ } else {
+ throw new Error('no addresses passed by web3');
+ }
+};
+
const _getWalletFromMnemonic = mnemonic => hdkey.fromMasterSeed(bip39.mnemonicToSeedSync(mnemonic))
.derivePath(`m/44'/60'/0'/0/0`)
.getWallet();
@@ -160,6 +173,7 @@ export {
getNetworkName,
getOtherNetworkName,
runSidechainTransaction,
+ runMainnetTransaction,
getTransactionSignature,
getAddressFromMnemonic,
};
\ No newline at end of file
| 0 |
diff --git a/website/api/duk_safe_to_string.yaml b/website/api/duk_safe_to_string.yaml @@ -9,12 +9,20 @@ stack: |
summary: |
<p>Like <code><a href="#duk_to_string">duk_to_string()</a></code> but if
the initial string coercion fails, the error value is coerced to a string.
- If that also fails, a fixed error string is returned.</p>
+ If that also fails, a fixed pre-allocated error string <code>"Error"</code>
+ is used instead (because the string is pre-allocated, this cannot fail due to
+ out-of-memory).</p>
<p>The caller can safely use this function to coerce a value to a string,
which is useful in C code to print out a return value safely with
- <code>printf()</code>. The only uncaught errors possible are out-of-memory
- and other internal errors which trigger fatal error handling anyway.</p>
+ <code>printf()</code>. The only uncaught errors possible are internal
+ errors which trigger fatal error handling anyway.</p>
+
+ <div class="note">
+ While the string coercion is safe from error throws, it may have side
+ effects in the current implementation. In particular, the string coercion
+ may enter an infinite loop and never return.
+ </div>
example: |
/* Coercion causes error. */
| 7 |
diff --git a/assets/sass/components/idea-hub/_googlesitekit-idea-hub-dashboard-ideas-widget.scss b/assets/sass/components/idea-hub/_googlesitekit-idea-hub-dashboard-ideas-widget.scss font-weight: $fw-primary-medium;
line-height: 1.5;
margin: 0 0 12px 8px;
-
- .googlesitekit-idea-hub__title-text {
- padding-right: 12px;
- }
}
.googlesitekit-idea-hub__tabs {
| 2 |
diff --git a/docs-src/tutorials/02-usage.md b/docs-src/tutorials/02-usage.md @@ -84,6 +84,14 @@ event handlers a `tour` key pointing to the instance which fired the event:
- `active`
- `inactive`
+For multiple events, you can use something like:
+
+```javascript
+['close', 'cancel'].forEach(event => shepherd.on(event, () => {
+ // some code here
+}));
+```
+
##### Current Tour
The global `Shepherd` includes a property which is always set to the currently active tour, or null if there is no active tour:
| 0 |
diff --git a/packages/neutrine/src/dashboard/styles/toolbar.scss b/packages/neutrine/src/dashboard/styles/toolbar.scss @@ -6,7 +6,7 @@ $neutrine-layout-toolbar-width: 300px;
$neutrine-layout-toolbar-padding: 15px;
//Neutrine layout toolbar style
-.neutrine-layout-toolbar {
+.neutrine-toolbar {
display: block;
position: fixed;
width: calc(#{$neutrine-layout-toolbar-width} - 2 * #{$neutrine-layout-toolbar-padding});
| 10 |
diff --git a/articles/tokens/access-token.md b/articles/tokens/access-token.md @@ -6,7 +6,11 @@ toc: true
## Overview
-The Access Token, commonly referred to as `access_token` in code samples, is a credential that can be used by a client to access an API. The `access_token` can be any type of token (such as an opaque string, or a JWT) and is meant for the API. The purpose of the `access_token` is to inform the API that the bearer of this token has been authorized to access the API and perform specific actions (as specified by the `scope` that has been granted). The `access_token` should be used as a `Bearer` credential and transmitted in an HTTP `Authorization` header to the API.
+The Access Token, commonly referred to as `access_token` in code samples, is a credential that can be used by a client to access an API.
+
+It can be any type of token (such as an opaque string, or a JWT) and is meant for an API. It's purpose is to inform the API that the bearer of this token has been authorized to access the API and perform specific actions (as specified by the `scope` that has been granted).
+
+The `access_token` should be used as a **Bearer** credential and transmitted in an HTTP **Authorization** header to the API.
## Access Tokens at Auth0
@@ -27,7 +31,7 @@ If you specify more than one audience, then your custom API must use **RS256**.
Both the client and the API will also need to be using the same signing algorithm (RS256/HS256) in order to get and use a properly formed JWT access token.
-The client signing algorithm can be specified in the [Dashboard](${manage_url}) under the client's settings -> Advanced Settings -> Oauth.
+The client signing algorithm can be specified in the [Dashboard](${manage_url}) under the **client's settings > Advanced Settings > Oauth**.

| 0 |
diff --git a/src/components/TextInputFocusable/index.js b/src/components/TextInputFocusable/index.js @@ -110,7 +110,7 @@ class TextInputFocusable extends React.Component {
}
if (prevProps.defaultValue !== this.props.defaultValue) {
this.updateNumberOfLines();
- this.updateSelection();
+ this.moveCursorToEnd();
}
}
@@ -200,9 +200,10 @@ class TextInputFocusable extends React.Component {
}
/**
- * Move cursor to the end.
+ * Move cursor to end by setting start and end
+ * to length of the input value.
*/
- updateSelection() {
+ moveCursorToEnd() {
this.setState({
selection: {
start: this.props.defaultValue.length,
| 10 |
diff --git a/components/illustration/__tests__/illustration.browser-test.jsx b/components/illustration/__tests__/illustration.browser-test.jsx @@ -28,7 +28,7 @@ const DemoIllustration = createReactClass({
});
describe('SLDSIllustration: ', function () {
- describe('Image with text renders', function () {
+ describe('Image with heading and message render', function () {
let svg;
let heading;
let messageBody;
@@ -85,7 +85,7 @@ describe('SLDSIllustration: ', function () {
});
});
- describe('Heading and Message Renders', function () {
+ describe('Heading and message render', function () {
let svg;
let heading;
let messageBody;
@@ -118,7 +118,7 @@ describe('SLDSIllustration: ', function () {
});
});
- describe('Heading Only Renders', function () {
+ describe('Heading only renders', function () {
let svg;
let heading;
let messageBody;
@@ -145,7 +145,7 @@ describe('SLDSIllustration: ', function () {
});
});
- describe('Message Only Renders', function () {
+ describe('Message only renders', function () {
let svg;
let heading;
let messageBody;
| 3 |
diff --git a/voice-endpoint-voicer.js b/voice-endpoint-voicer.js @@ -8,6 +8,18 @@ class VoiceEndpoint {
this.url = new URL(url, import.meta.url);
}
}
+class PreloadMessage {
+ constructor(text, parent) {
+ this.text = text;
+ this.parent = parent;
+
+ this.isPreloadMessage = true;
+ this.loadPromise = this.parent.loadAudioBuffer(this.text);
+ }
+ waitForLoad() {
+ return this.loadPromise;
+ }
+}
class VoiceEndpointVoicer {
constructor(voiceEndpoint, player) {
this.voiceEndpoint = voiceEndpoint;
@@ -19,6 +31,21 @@ class VoiceEndpointVoicer {
this.cancel = null;
this.endPromise = null;
}
+ preloadMessage(text) {
+ return new PreloadMessage(text, this);
+ }
+ async loadAudioBuffer(text) {
+ const u = new URL(this.voiceEndpoint.url.toString());
+ u.searchParams.set('s', text);
+ const res = await fetch(u/*, {
+ mode: 'cors',
+ } */);
+ const arrayBuffer = await res.arrayBuffer();
+
+ const audioContext = Avatar.getAudioContext();
+ const audioBuffer = await audioContext.decodeAudioData(arrayBuffer);
+ return audioBuffer;
+ }
start(text) {
if (!this.endPromise) {
this.endPromise = makePromise();
@@ -30,16 +57,9 @@ class VoiceEndpointVoicer {
this.player.avatar.setAudioEnabled(true);
(async () => {
- const u = new URL(this.voiceEndpoint.url.toString());
- u.searchParams.set('s', text);
- const res = await fetch(u/*, {
- mode: 'cors',
- } */);
- const arrayBuffer = await res.arrayBuffer();
+ const audioBuffer = await (text.isPreloadMessage ? text.waitForLoad() : this.loadAudioBuffer(text));
const audioContext = Avatar.getAudioContext();
- const audioBuffer = await audioContext.decodeAudioData(arrayBuffer);
-
const audioBufferSourceNode = audioContext.createBufferSource();
audioBufferSourceNode.buffer = audioBuffer;
audioBufferSourceNode.addEventListener('ended', () => {
@@ -83,5 +103,6 @@ class VoiceEndpointVoicer {
export {
VoiceEndpoint,
+ PreloadMessage,
VoiceEndpointVoicer,
};
\ No newline at end of file
| 0 |
diff --git a/lib/assets/javascripts/new-dashboard/components/MapCard.vue b/lib/assets/javascripts/new-dashboard/components/MapCard.vue </div>
<span class="checkbox card-select" v-if="!isShared" @mouseover="mouseOverChildElement" @mouseleave="mouseOutChildElement">
- <input class="checkbox-input" :checked="isSelected" @click.prevent.stop="toggleSelection" type="checkBox">
+ <input class="checkbox-input" :checked="isSelected" @click.prevent="toggleSelection" type="checkBox">
<span class="checkbox-decoration">
<img svg-inline src="../assets/icons/common/checkbox.svg">
</span>
<div class="card-header">
<h2 class="card-title title is-caption" :class="{ 'text-overflows': titleOverflow }">
{{ map.name }}
- <span class="card-favorite" :class="{'is-favorite': map.liked}" @click.prevent.stop="toggleFavorite" @mouseover="mouseOverChildElement" @mouseleave="mouseOutChildElement">
+ <span class="card-favorite" :class="{'is-favorite': map.liked}" @click.prevent="toggleFavorite" @mouseover="mouseOverChildElement" @mouseleave="mouseOutChildElement">
<img svg-inline src="../assets/icons/common/favorite.svg">
</span>
</h2>
| 2 |
diff --git a/assets/js/modules/analytics-4/components/dashboard/ActivationBanner/SetupBanner.js b/assets/js/modules/analytics-4/components/dashboard/ActivationBanner/SetupBanner.js @@ -50,10 +50,6 @@ const { useDispatch, useSelect } = Data;
export default function SetupBanner( { onSubmitSuccess } ) {
const [ errorNotice, setErrorNotice ] = useState( null );
- const ga4MeasurementID = useSelect( ( select ) =>
- select( MODULES_ANALYTICS_4 ).getMeasurementID()
- );
-
const hasExistingProperty = useSelect( ( select ) => {
const accountID = select( MODULES_ANALYTICS ).getAccountID();
const properties =
@@ -200,11 +196,9 @@ export default function SetupBanner( { onSubmitSuccess } ) {
className="googlesitekit-ga4-setup-banner"
title={ title }
ctaComponent={
- ! ga4MeasurementID && (
<SpinnerButton onClick={ handleSubmitChanges }>
{ ctaLabel }
</SpinnerButton>
- )
}
footer={ <p>{ footer }</p> }
dismiss={ __( 'Cancel', 'google-site-kit' ) }
| 2 |
diff --git a/src/components/nodes/sequenceFlow/sequenceFlow.vue b/src/components/nodes/sequenceFlow/sequenceFlow.vue @@ -21,7 +21,8 @@ import linkConfig from '@/mixins/linkConfig';
import get from 'lodash/get';
import { namePosition } from './sequenceFlowConfig';
import CrownConfig from '@/components/crown/crownConfig/crownConfig';
-import { isValidSequenceFlowConnection, isValidSource } from '@/components/nodes/sequenceFlow/validFlows';
+import { isValidSource } from '@/components/nodes/sequenceFlow/validFlows';
+import SequenceFlow from '@/components/nodes/genericFlow/SequenceFlow';
export default {
components: {
@@ -48,7 +49,8 @@ export default {
},
computed: {
isValidConnection() {
- return isValidSequenceFlowConnection(this.sourceShape, this.target) && isValidSource(this.sourceShape, this.targetConfig);
+ return SequenceFlow.isValid(this.sourceShape, this.target)
+ && isValidSource(this.sourceShape, this.targetConfig);
},
targetType() {
return get(this.target, 'component.node.type');
| 4 |
diff --git a/modules/service/data-service.js b/modules/service/data-service.js @@ -403,9 +403,9 @@ class DataService {
};
break;
case this.constants.NFT:
- const result = JSON.parse(await axios.get(`https://raw.githubusercontent.com/OriginTrail/ot-node/v6/develop/frameDocuments/${this.constants.NFT}.json`));
- context = result.context;
- frame = result.frame;
+ const result = await axios.get(`https://raw.githubusercontent.com/OriginTrail/ot-node/v6/develop/frameDocuments/${this.constants.NFT}.json`);
+ context = result.data.context;
+ frame = result.data.frame;
break;
default:
context = {
| 3 |
diff --git a/public/resources/ts/calculate-player-stats.ts b/public/resources/ts/calculate-player-stats.ts @@ -24,11 +24,17 @@ export function getPlayerStats() {
pristine: { base: 0 },
};
+ const allowedStats = Object.keys(stats);
+
// Active armor stats
for (const piece of items.armor) {
const bonusStats: ItemStats = helper.getStatsFromItem(piece as Item);
for (const [name, value] of Object.entries(bonusStats)) {
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
stats[name].armor ??= 0;
stats[name].armor += value;
}
@@ -40,6 +46,10 @@ export function getPlayerStats() {
if (activePet) {
for (const [name, value] of Object.entries(activePet.stats)) {
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
stats[name].pet ??= 0;
stats[name].pet += value;
}
@@ -51,6 +61,10 @@ export function getPlayerStats() {
const bonusStats: ItemStats = helper.getStatsFromItem(item as Item);
for (const [name, value] of Object.entries(bonusStats)) {
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
stats[name].accessories ??= 0;
stats[name].accessories += value;
}
@@ -61,6 +75,10 @@ export function getPlayerStats() {
const bonusStats: ItemStats = getBonusStat(data.level, `skill_${skill}` as BonusType, data.maxLevel);
for (const [name, value] of Object.entries(bonusStats)) {
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
stats[name][`skill_${skill}`] ??= 0;
stats[name][`skill_${skill}`] += value;
}
@@ -75,8 +93,12 @@ export function getPlayerStats() {
);
for (const [name, value] of Object.entries(bonusStats)) {
- stats[name]["skill_dungeoneering"] ??= 0;
- stats[name]["skill_dungeoneering"] += value;
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
+ stats[name].skill_dungeoneering ??= 0;
+ stats[name].skill_dungeoneering += value;
}
}
@@ -89,6 +111,10 @@ export function getPlayerStats() {
);
for (const [name, value] of Object.entries(bonusStats)) {
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
stats[name][`slayer_${slayer}`] ??= 0;
stats[name][`slayer_${slayer}`] += value;
}
@@ -99,6 +125,10 @@ export function getPlayerStats() {
const bonusStats: ItemStats = getFairyBonus(calculated.fairy_exchanges);
for (const [name, value] of Object.entries(bonusStats)) {
+ if (!allowedStats.includes(name)) {
+ continue;
+ }
+
stats[name].fairy_souls ??= 0;
stats[name].fairy_souls += value;
}
@@ -119,12 +149,14 @@ export function getPlayerStats() {
if (calculated.century_cakes) {
for (const century_cake of calculated.century_cakes) {
- if (stats[century_cake.stat]) {
+ if (!allowedStats.includes(century_cake.stat)) {
+ continue;
+ }
+
stats[century_cake.stat].cakes ??= 0;
stats[century_cake.stat].cakes += century_cake.amount;
}
}
- }
// Reaper peppers
if (calculated.reaper_peppers_eaten > 0) {
| 11 |
diff --git a/src/components/staking/components/BalanceBreakdown.js b/src/components/staking/components/BalanceBreakdown.js @@ -94,7 +94,9 @@ function BalanceBreakdown({ total, onClickAvailable, availableType, error }) {
const [open, setOpen] = useState(false)
const subtractAmount = nearApiJs.utils.format.parseNearAmount(WALLET_APP_MIN_AMOUNT)
- const available = new BN(total).sub(new BN(subtractAmount)).isNeg() ? '0' : new BN(total).sub(new BN(subtractAmount))
+ const available = total
+ ? new BN(total).sub(new BN(subtractAmount)).isNeg() ? '0' : new BN(total).sub(new BN(subtractAmount))
+ : undefined
return (
<Translate>
| 9 |
diff --git a/package.json b/package.json {
"name": "julia-client",
"main": "./lib/julia-client",
- "version": "0.6.8",
+ "version": "0.6.9",
"description": "Julia Evaluation",
"keywords": [],
"repository": "https://github.com/JunoLab/atom-julia-client",
| 6 |
diff --git a/lib/jiff-client.js b/lib/jiff-client.js op_id = self.jiff.counters.gen_op_id('/', self.holders);
}
- var lZp = share_helpers['ceil'](self.jiff.helpers.bLog(self.Zp, 2));
- if (l == null) {
- l = lZp;
- } else {
- l = l < lZp ? l : lZp;
- }
-
- // Store the result
- var final_deferred = new Deferred();
- var final_promise = final_deferred.promise;
- var result = self.jiff.secret_share(self.jiff, false, final_promise, undefined, self.holders, max(self.threshold, o.threshold), self.Zp, 'share:' + op_id);
-
- var q = self.jiff.server_generate_and_share({number: 0}, self.holders, max(self.threshold, o.threshold), self.Zp, op_id + ':number')[0];
- var a = self; // dividend
-
- (function one_bit(i) {
- if (i >= l) {
- // we did this for all bits, q has the answer
- if (q.ready) {
- final_deferred.resolve(q.value);
- } else {
- q.promise.then(function () {
- final_deferred.resolve(q.value);
- });
- }
- return;
- }
-
- var power = share_helpers['pow'](2, (l - 1) - i);
- var ZpOVERpower = share_helpers['floor/'](o.Zp, power);
- // (2^i + 2^k + ...) * o <= self
- // 2^l * o <= self => q = 2^l, self = self - o * 2^l
- var tmp = o.icmult(power); // this may wrap around, in which case we must ignored it, since the answer MUST fit in the field.
- var tmpFits = o.iclteq(ZpOVERpower, op_id + ':c<=' + i);
- var tmpCmp = tmp.islteq(a, op_id + ':<=' + i);
+ // Convert to bits and compute by long division
+ var dividend_bits = self.bit_decomposition(op_id + ":sdiv");
+ var divisor_bits = o.bit_decomposition(op_id + ":sdiv");
+ var quotient_bits = self.jiff.protocols.bits.sdiv(dividend_bits, divisor_bits, op_id + ":sdiv").quotient;
+ var quotient = self.jiff.protocols.bits.bit_composition(quotient_bits);
- var and = tmpFits.ismult(tmpCmp, op_id + ':smult1:' + i);
- q = q.isadd(and.icmult(power));
- a = a.issub(and.ismult(tmp, op_id + ':smult2:' + i)); // a - tmp > 0 if tmp > 0
-
- Promise.all([q.promise, a.promise]).then(function () {
- one_bit(i + 1);
- });
- })(0);
- return result;
+ return quotient;
};
/**
var opened_bits = [];
for (var i = 0; i < bits.length; i++) {
- opened_bits[i] = bits[0].jiff.open(bits[i], party_ids, op_id + ":openbit" + i.toString());
+ opened_bits[i] = bits[0].jiff.open(bits[i], party_ids, op_id + ":open_bits:" + i.toString());
}
var deferred_number = $.Deferred();
| 14 |
diff --git a/books/serializers.py b/books/serializers.py @@ -33,7 +33,7 @@ class BookCopySerializer(serializers.ModelSerializer):
class Meta:
model = BookCopy
- fields = ('id', 'user', 'borrow_date')
+ fields = ('user', 'borrow_date')
class BookSerializer(serializers.ModelSerializer):
| 2 |
diff --git a/execute_awsbinary.go b/execute_awsbinary.go @@ -65,6 +65,7 @@ func tappedHandler(handlerSymbol interface{},
handlerType := reflect.TypeOf(handlerSymbol)
takesContext := takesContext(handlerType)
+ // TODO - add Context.Timeout handler to ensure orderly exit
return func(ctx context.Context, msg json.RawMessage) (interface{}, error) {
ctx = context.WithValue(ctx, ContextKeyLogger, logger)
| 0 |
diff --git a/lib/device/humidifier.js b/lib/device/humidifier.js @@ -93,6 +93,11 @@ module.exports = class deviceHumidifier {
this.cacheLightState = this.lightService.getCharacteristic(this.hapChar.On).value
// No set handler for brightness as not supported
+ this.lightService.getCharacteristic(this.hapChar.Brightness)
+ .setProps({
+ minStep: 100,
+ validValues: [0, 100]
+ })
this.cacheLightBright = this.lightService.getCharacteristic(this.hapChar.Brightness).value
// Add the set handler to the lightbulb hue characteristic
| 12 |
diff --git a/sirepo/pkcli/db.py b/sirepo/pkcli/db.py @@ -84,7 +84,9 @@ def upgrade_runner_to_job_db(db_dir, sbatch_poll_secs):
c = sim_data.get_class(i.simulationType)
d = PKDict(
computeJid=c.parse_jid(i, u),
- computeJobHash=i.computeJobHash,
+ computeJobHash=i.models.computeJobCacheKey.computeJobHash if
+ i.models.get('computeJobCacheKey') else
+ i.computeJobHash,
computeJobQueued=t,
computeJobStart=t,
error=None,
| 9 |
diff --git a/sirepo/package_data/static/js/radia.js b/sirepo/package_data/static/js/radia.js @@ -1058,11 +1058,11 @@ SIREPO.app.controller('RadiaVisualizationController', function (appState, errorS
self.solution = null;
self.enableKickMaps = function() {
- return (appState.models.simulation || {}).enableKickMaps === '1';
+ return appState.isLoaded() && appState.models.simulation.enableKickMaps === '1';
};
self.isSolvable = function() {
- return (appState.models.geometry || {}).isSolvable == '1';
+ return appState.isLoaded() && appState.models.geometry.isSolvable == '1';
};
self.simHandleStatus = function(data) {
| 4 |
diff --git a/src/commands/status/index.js b/src/commands/status/index.js @@ -22,7 +22,7 @@ class StatusCommand extends Command {
const ghuser = this.netlify.globalConfig.get(`users.${current}.auth.github.user`)
accountData = {
- Name: `${get(user, 'full_name')}`,
+ Name: get(user, 'full_name'),
// 'Account slug': get(personal, 'slug'),
// 'Account id': get(personal, 'id'),
// Name: get(personal, 'billing_name'),
| 2 |
diff --git a/docs/_posts/2020-02-12-pouchdb-7.2.0.md b/docs/_posts/2020-02-12-pouchdb-7.2.0.md ---
layout: post
-title: PouchDB 7.2.0 - New indexeddb adapter
+title: PouchDB 7.2.1 - New indexeddb adapter
author: Gareth Bowen
---
@@ -12,7 +12,7 @@ author: Gareth Bowen
## Other changes
-For a full changelog from 7.1.1 to 7.2.0, please see [the releases page](https://github.com/pouchdb/pouchdb/releases) or view the [latest commits](https://github.com/pouchdb/pouchdb/compare/7.1.1...7.2.0).
+For a full changelog from 7.1.1 to 7.2.1, please see [the releases page](https://github.com/pouchdb/pouchdb/releases) or view the [latest commits](https://github.com/pouchdb/pouchdb/compare/7.1.1...7.2.1).
## Get in touch
| 10 |
diff --git a/lib/shared/addon/components/cluster-driver/driver-eks/component.js b/lib/shared/addon/components/cluster-driver/driver-eks/component.js @@ -14,12 +14,12 @@ import { randomStr } from 'shared/utils/util';
import layout from './template';
const DEFAULT_NODE_GROUP_CONFIG = {
- desiredSize: 1,
+ desiredSize: 2,
diskSize: 20,
gpu: false,
- instanceType: 'm5.large',
- maxSize: 1,
- minSize: 1,
+ instanceType: 't3.medium',
+ maxSize: 2,
+ minSize: 2,
nodegroupName: '',
type: 'nodeGroup',
};
| 3 |
diff --git a/src/core/jpg.js b/src/core/jpg.js @@ -81,14 +81,13 @@ const JpegImage = (function JpegImageClosure() {
function buildHuffmanTable(codeLengths, values) {
let k = 0,
- code = [],
i,
j,
length = 16;
while (length > 0 && !codeLengths[length - 1]) {
length--;
}
- code.push({ children: [], index: 0 });
+ const code = [{ children: [], index: 0 }];
let p = code[0],
q;
for (i = 0; i < length; i++) {
@@ -267,8 +266,8 @@ const JpegImage = (function JpegImageClosure() {
eobrun--;
return;
}
- let k = spectralStart,
- e = spectralEnd;
+ let k = spectralStart;
+ const e = spectralEnd;
while (k <= e) {
const rs = decodeHuffman(component.huffmanTableAC);
const s = rs & 15,
@@ -774,8 +773,8 @@ const JpegImage = (function JpegImageClosure() {
function prepareComponents(frame) {
const mcusPerLine = Math.ceil(frame.samplesPerLine / 8 / frame.maxH);
const mcusPerColumn = Math.ceil(frame.scanLines / 8 / frame.maxV);
- for (let i = 0; i < frame.components.length; i++) {
- component = frame.components[i];
+ for (let i = 0, ii = frame.components.length; i < ii; i++) {
+ const component = frame.components[i];
const blocksPerLine = Math.ceil(
(Math.ceil(frame.samplesPerLine / 8) * component.h) / frame.maxH
);
@@ -795,7 +794,7 @@ const JpegImage = (function JpegImageClosure() {
frame.mcusPerColumn = mcusPerColumn;
}
- var offset = 0;
+ let offset = 0;
let jfif = null;
let adobe = null;
let frame, resetInterval;
@@ -813,7 +812,7 @@ const JpegImage = (function JpegImageClosure() {
offset += 2;
markerLoop: while (fileMarker !== /* EOI (End of Image) = */ 0xffd9) {
- var i, j, l;
+ let i, j, l;
switch (fileMarker) {
case 0xffe0: // APP0 (Application Specific)
case 0xffe1: // APP1
@@ -832,7 +831,7 @@ const JpegImage = (function JpegImageClosure() {
case 0xffee: // APP14
case 0xffef: // APP15
case 0xfffe: // COM (Comment)
- var appData = readDataBlock();
+ const appData = readDataBlock();
if (fileMarker === 0xffe0) {
// 'JFIF\x00'
@@ -880,8 +879,8 @@ const JpegImage = (function JpegImageClosure() {
case 0xffdb: // DQT (Define Quantization Tables)
const quantizationTablesLength = readUint16(data, offset);
offset += 2;
- var quantizationTablesEnd = quantizationTablesLength + offset - 2;
- var z;
+ const quantizationTablesEnd = quantizationTablesLength + offset - 2;
+ let z;
while (offset < quantizationTablesEnd) {
const quantizationTableSpec = data[offset++];
const tableData = new Uint16Array(64);
@@ -924,12 +923,11 @@ const JpegImage = (function JpegImageClosure() {
offset += 2;
frame.components = [];
frame.componentIds = {};
- var componentsCount = data[offset++],
- componentId;
- var maxH = 0,
+ const componentsCount = data[offset++];
+ let maxH = 0,
maxV = 0;
for (i = 0; i < componentsCount; i++) {
- componentId = data[offset];
+ const componentId = data[offset];
const h = data[offset + 1] >> 4;
const v = data[offset + 1] & 15;
if (maxH < h) {
@@ -991,22 +989,21 @@ const JpegImage = (function JpegImageClosure() {
offset += 2; // Skip marker length.
- var selectorsCount = data[offset++];
- var components = [],
- component;
+ const selectorsCount = data[offset++],
+ components = [];
for (i = 0; i < selectorsCount; i++) {
const index = data[offset++];
const componentIndex = frame.componentIds[index];
- component = frame.components[componentIndex];
+ const component = frame.components[componentIndex];
component.index = index;
const tableSpec = data[offset++];
component.huffmanTableDC = huffmanTablesDC[tableSpec >> 4];
component.huffmanTableAC = huffmanTablesAC[tableSpec & 15];
components.push(component);
}
- var spectralStart = data[offset++];
- var spectralEnd = data[offset++];
- var successiveApproximation = data[offset++];
+ const spectralStart = data[offset++],
+ spectralEnd = data[offset++],
+ successiveApproximation = data[offset++];
try {
const processed = decodeScan(
data,
@@ -1082,8 +1079,8 @@ const JpegImage = (function JpegImageClosure() {
this.jfif = jfif;
this.adobe = adobe;
this.components = [];
- for (i = 0; i < frame.components.length; i++) {
- component = frame.components[i];
+ for (let i = 0, ii = frame.components.length; i < ii; i++) {
+ const component = frame.components[i];
// Prevent errors when DQT markers are placed after SOF{n} markers,
// by assigning the `quantizationTable` entry after the entire image
| 1 |
diff --git a/test/builders/launch-sort.test.js b/test/builders/launch-sort.test.js @@ -12,16 +12,14 @@ beforeAll((done) => {
// Launch Sort Test
//------------------------------------------------------------
-test('It should return launches sorted from smallest to greatest', () => {
- return request(app).get('/v2/launches?order=asc').then((response) => {
+test('It should return launches sorted from smallest to greatest', async () => {
+ const response = await request(app).get('/v2/launches?order=asc');
expect(response.statusCode).toBe(200);
expect(response.body[0]).toHaveProperty('flight_number', 1);
});
-});
-test('It should return launches sorted from greatest to smallest', () => {
- return request(app).get('/v2/launches?order=desc').then((response) => {
+test('It should return launches sorted from greatest to smallest', async () => {
+ const response = await request(app).get('/v2/launches?order=desc')
expect(response.statusCode).toBe(200);
expect(response.body[response.body.length - 1]).toHaveProperty('flight_number', 1);
});
-});
| 3 |
diff --git a/src/ui.itembar.js b/src/ui.itembar.js @@ -35,8 +35,6 @@ var _ = Mavo.UI.Itembar = class Itembar {
this.controls = Mavo.UI.Bar.getControls(this.template, controls);
- this.dragHandle = $(".mv-drag-handle", this.element) || this.item.element;
-
$.set(this.element, {
"mv-rel": this.item.property,
contents: this.controls.map(id => {
@@ -45,6 +43,8 @@ var _ = Mavo.UI.Itembar = class Itembar {
return $.create(meta.create.call(this, existing));
})
});
+
+ this.dragHandle = $(".mv-drag-handle", this.element) || this.item.element;
}
this.element.setAttribute("hidden", "");
| 1 |
diff --git a/storybook-utilities/icon-utilities/icon-loader.js b/storybook-utilities/icon-utilities/icon-loader.js -var request = new XMLHttpRequest();
-request.open('GET', 'https://spark-assets.netlify.app/spark-core-icons.svg');
+const request = new XMLHttpRequest();
+request.open('GET', 'https://spark-assets.netlify.app/spark-icons.svg');
request.send();
-request.onload = function () {
+request.onload = () => {
document.querySelector('#sprk-icons').innerHTML = this.response;
let event;
- if (typeof (Event) === 'function') {
+ if (typeof Event === 'function') {
event = new Event('sprk-icons-loaded');
} else {
event = document.createEvent('Event');
| 3 |
diff --git a/src/styles/custom.less b/src/styles/custom.less @font-family-monospace: "WhitneyBold", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
@font-family-base: @font-family-sans-serif;
+@body-background: @white-darker;
+@component-background: @white-darker;
@font-size-base: 14px;
// Buttons
@btn-font-weight: 600;
@btn-primary-color: @white-darker;
-@btn-primary-bg: @purple;
@btn-default-color: @white;
@btn-default-bg: #c2ccd3;
| 2 |
diff --git a/sounds.js b/sounds.js @@ -53,7 +53,7 @@ const waitForLoad = () => loadPromise;
const getSoundFiles = () => soundFiles;
const getSoundFileAudioBuffer = () => soundFileAudioBuffer;
-const playSound = (audioSpec) => {
+const playSound = audioSpec => {
const {offset, duration} = audioSpec;
const audioContext = Avatar.getAudioContext();
const audioBufferSourceNode = audioContext.createBufferSource();
@@ -62,9 +62,20 @@ const playSound = (audioSpec) => {
audioBufferSourceNode.start(0, offset, duration);
return audioBufferSourceNode;
};
+const playSoundName = name => {
+ const snds = soundFiles[name];
+ if (snds) {
+ const sound = snds[Math.floor(Math.random() * snds.length)];
+ playSound(sound);
+ return true;
+ } else {
+ return false;
+ }
+};
export {
waitForLoad,
getSoundFiles,
getSoundFileAudioBuffer,
playSound,
+ playSoundName,
};
\ No newline at end of file
| 0 |
diff --git a/scenes/street.scn b/scenes/street.scn },
{
"position": [0, -60, 0],
- "start_url": "../metaverse_modules/spawner/",
- "components": [
- {
- "key": "appUrls",
- "value": [
- "https://webaverse.github.io/ghost/",
- "https://webaverse.github.io/silkworm-biter/",
- "https://webaverse.github.io/silkworm-bloater/",
- "https://webaverse.github.io/silkworm-queen/",
- "https://webaverse.github.io/silkworm-runner/",
- "https://webaverse.github.io/silkworm-slasher/"
- ]
- }
- ]
+ "start_url": "../metaverse_modules/land/"
}
]
}
\ No newline at end of file
| 0 |
diff --git a/renderer/components/withIntl.js b/renderer/components/withIntl.js /* global require */
import React, {Component} from 'react'
-import { IntlProvider, addLocaleData, injectIntl } from 'react-intl'
+import { IntlProvider, injectIntl } from 'react-intl'
let supportedMessages = {
en: require('../../lang/en.json')
@@ -14,12 +14,6 @@ const getLocale = () => {
return navigatorLang.split('-')[0]
}
-if (typeof window !== 'undefined' && window.ReactIntlLocaleData) {
- Object.keys(window.ReactIntlLocaleData).forEach((lang) => {
- // addLocaleData(window.ReactIntlLocaleData[lang])
- })
-}
-
if (typeof window !== 'undefined' && window.OONITranslations) {
supportedMessages = window.OONITranslations
}
| 2 |
diff --git a/src/kite.js b/src/kite.js @@ -65,6 +65,7 @@ const Kite = {
ctx.subscriptions.push(install);
this.status = status;
+ this.install = install;
server.addRoute('GET', '/check', (req, res) => {
this.checkState();
@@ -407,9 +408,12 @@ const Kite = {
case StateController.STATES.UNINSTALLED:
if (this.shown[state] || !this.isGrammarSupported(vscode.window.activeTextEditor)) { return state; }
this.shown[state] = true;
- this.showErrorMessage('Kite is not installed: Grab the installer from our website', 'Get Kite').then(item => {
- if (item) { opn('https://kite.com/'); }
- });
+ // this.showErrorMessage('Kite is not installed: Grab the installer from our website', 'Get Kite').then(item => {
+ // if (item) { opn('https://kite.com/'); }
+ // });
+ this.install.reset();
+ AccountManager.initClient('alpha.kite.com', -1, true);
+ vscode.commands.executeCommand('vscode.previewHtml', 'kite-vscode-install://install', vscode.ViewColumn.One, 'Kite Install');
break;
case StateController.STATES.INSTALLED:
break;
| 14 |
diff --git a/tests/phpunit/integration/Modules/Site_VerificationTest.php b/tests/phpunit/integration/Modules/Site_VerificationTest.php @@ -105,7 +105,6 @@ class Site_VerificationTest extends TestCase {
$_GET['googlesitekit_verification_token'] = 'testtoken';
$_GET['googlesitekit_verification_token_type'] = 'FILE';
- $_GET['googlesitekit_verification_nonce'] = wp_create_nonce( 'googlesitekit_verification' );
$this->assertEquals( array(), apply_filters( 'googlesitekit_proxy_setup_url_params', array(), '', '' ) );
| 2 |
diff --git a/game.js b/game.js @@ -711,7 +711,7 @@ const _gameUpdate = (timestamp, timeDiff) => {
};
_handlePush();
- const _updateActivateAnimation = (grabUseMeshPosition) => {
+ const _updateActivateAnimation = grabUseMeshPosition => {
let currentDistance = 100;
let currentAnimation = "grab_forward";
@@ -772,7 +772,8 @@ const _gameUpdate = (timestamp, timeDiff) => {
localPlayer.getAction('activate').animationName = currentAnimation;
}
- return (currentDistance < 0.8);
+ // return (currentDistance < 0.8);
+ return true;
};
const _updateGrab = () => {
| 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.