code
stringlengths
122
4.99k
label
int64
0
14
diff --git a/packages/bitcore-node/src/models/walletAddress.ts b/packages/bitcore-node/src/models/walletAddress.ts @@ -39,9 +39,7 @@ export class WalletAddressModel extends BaseModel<IWalletAddress> { const { chain, network } = wallet; const unprocessedAddresses: Array<string> = []; - return new Promise(async (resolve, reject) => { for (let address of addresses) { - try { const updatedAddress = await this.collection.findOneAndUpdate( { wallet: wallet._id, @@ -54,14 +52,7 @@ export class WalletAddressModel extends BaseModel<IWalletAddress> { ); if (!updatedAddress.value!.processed) { unprocessedAddresses.push(address); - await CoinStorage.collection.updateMany( - { chain, network, address }, - { $addToSet: { wallets: wallet._id } } - ); - } - } catch (err) { - // Perhaps a race condition from multiple calls around the same time - reject('Likely an upsert race condition in walletAddress updates') + await CoinStorage.collection.updateMany({ chain, network, address }, { $addToSet: { wallets: wallet._id } }); } } @@ -91,6 +82,7 @@ export class WalletAddressModel extends BaseModel<IWalletAddress> { txids[coin.spentTxid] = true; return coinStream.resume(); }); + return new Promise(resolve => { coinStream.on('end', async () => { for (const address of unprocessedAddresses) { await this.collection.updateOne(
5
diff --git a/lib/node_modules/@stdlib/random/base/mt19937/lib/factory.js b/lib/node_modules/@stdlib/random/base/mt19937/lib/factory.js @@ -82,7 +82,7 @@ var MAX_SEED = UINT32_MAX >>> 0; // asm type annotation // For seed arrays, define an initial state (magic) constant: 19650218 => 00000001001010111101011010101010 var SEED_ARRAY_INIT_STATE = 19650218 >>> 0; // asm type annotation -// Define a mask for the most significant `w-r` bits (see refs): 2147483648 => 0x80000000 => 10000000000000000000000000000000 +// Define a mask for the most significant `w-r` bits, where `w` is the word size (32 bits) and `r` is the separation point of one word (see refs): 2147483648 => 0x80000000 => 10000000000000000000000000000000 var UPPER_MASK = 0x80000000 >>> 0; // asm type annotation // Define a mask for the least significant `r` bits (see refs): 2147483647 => 0x7fffffff => 01111111111111111111111111111111 @@ -97,6 +97,12 @@ var MAGIC_MULTIPLIER_1 = 1664525 >>> 0; // asm type annotation // Define a (magic) multiplier: 1566083941 => 01011101010110001000101101100101 var MAGIC_MULTIPLIER_2 = 1566083941 >>> 0; // asm type annotation +// Define a tempering coefficient: 2636928640 => 0x9d2c5680 => 10011101001011000101011010000000 +var TEMPERING_COEFFICIENT_1 = 0x9d2c5680 >>> 0; // asm type annotation + +// Define a tempering coefficient: 4022730752 => 0xefc60000 => 11101111110001100000000000000000 +var TEMPERING_COEFFICIENT_2 = 0xefc60000 >>> 0; // asm type annotation + // Define a constant vector `a` (see refs): 2567483615 => 0x9908b0df => 10011001000010001011000011011111 var MATRIX_A = 0x9908b0df >>> 0; // asm type annotation @@ -237,7 +243,7 @@ function initState( state, seed ) { * @param {Uint32Array} state - state array * @returns {Uint32Array} state array */ -function updateState( state ) { +function twist( state ) { var w; var i; var j; @@ -397,16 +403,16 @@ function factory( seed ) { function mt19937() { var r; if ( mti >= N ) { - mt = updateState( mt ); + mt = twist( mt ); mti = 0; } r = mt[ mti ]; mti += 1; - // Tempering: + // Tempering transform to compensate for the reduced dimensionality of equidistribution: r ^= r >>> 11; - r ^= ( r << 7 ) & 0x9d2c5680; - r ^= ( r << 15 ) & 0xefc60000; + r ^= ( r << 7 ) & TEMPERING_COEFFICIENT_1; + r ^= ( r << 15 ) & TEMPERING_COEFFICIENT_2; r ^= r >>> 18; return r >>> 0;
10
diff --git a/react/src/components/masthead/components/SprkMastheadMenuIcon/SprkMastheadMenuIcon.js b/react/src/components/masthead/components/SprkMastheadMenuIcon/SprkMastheadMenuIcon.js @@ -84,7 +84,7 @@ SprkMastheadMenuIcon.propTypes = { */ isOpen: PropTypes.bool, /** - * Function to run when the Menu is clicked. + * Function to run when the menu icon is clicked. */ toggleNarrowNav: PropTypes.func.isRequired, };
7
diff --git a/includes/Modules/Thank_With_Google/Web_Tag.php b/includes/Modules/Thank_With_Google/Web_Tag.php @@ -181,7 +181,10 @@ class Web_Tag extends Module_Web_Tag { return $content; } - $cta_placeholder = '<div><div counter-button style="height: 34px; visibility: hidden; box-sizing: content-box; padding: 12px 0; display: inline-block; overflow: hidden;"></div><button twg-button style="height: 42px; visibility: hidden; margin: 12px 0;"></button></div>'; + $cta_placeholder = '<div class="googlesitekit-twg-wrapper" style="display: flex; align-items: center; flex-wrap: wrap; gap: 0 10px;">' + . '<div counter-button style="height: 34px; visibility: hidden; box-sizing: content-box; padding: 12px 0; display: inline-block; overflow: hidden;"></div>' + . '<button twg-button style="height: 42px; visibility: hidden; margin: 12px 0;"></button>' + . '</div>'; $cta_placeholder = $this->add_snippet_comments( $cta_placeholder ); if ( empty( $content ) ) {
7
diff --git a/src/js/core/TableRegistry.js b/src/js/core/TableRegistry.js @@ -2,11 +2,11 @@ import Tabulator from './Tabulator.js'; class TableRegistry { - register(table){ + static register(table){ TableRegistry.tables.push(table); } - deregister(table){ + static deregister(table){ var index = TableRegistry.tables.indexOf(table); if(index > -1){ @@ -14,7 +14,7 @@ class TableRegistry { } } - lookupTable(query, silent){ + static lookupTable(query, silent){ var results = [], matches, match; @@ -50,7 +50,7 @@ class TableRegistry { return results; } - matchElement(element){ + static matchElement(element){ return TableRegistry.tables.find(function(table){ return element instanceof Tabulator ? table === element : table.element === element; });
3
diff --git a/app/components/DepositWithdraw/gdex/GdexGatewayInfo.jsx b/app/components/DepositWithdraw/gdex/GdexGatewayInfo.jsx @@ -12,6 +12,7 @@ import {requestDepositAddress} from "../../../lib/common/gdexMethods"; import QRCode from "qrcode.react"; import GdexWithdrawModal from "./GdexWithdrawModal"; import counterpart from "counterpart"; +import {Modal, Button} from "bitshares-ui-style-guide"; import PropTypes from "prop-types"; class GdexGatewayInfo extends React.Component { @@ -32,6 +33,7 @@ class GdexGatewayInfo extends React.Component { constructor() { super(); this.state = { + isQrModalVisible: false, receive_address: null, isAvailable: true, qrcode: "" @@ -39,6 +41,21 @@ class GdexGatewayInfo extends React.Component { this.deposit_address_cache = new GdexCache(); this._copy = this._copy.bind(this); document.addEventListener("copy", this._copy); + + this.showQrModal = this.showQrModal.bind(this); + this.hideQrModal = this.hideQrModal.bind(this); + } + + showQrModal() { + this.setState({ + isQrModalVisible: true + }); + } + + hideQrModal() { + this.setState({ + isQrModalVisible: false + }); } getDepositAddress() { @@ -135,7 +152,9 @@ class GdexGatewayInfo extends React.Component { } onShowQrcode(text) { - this.setState({qrcode: text}, () => ZfApi.publish("qrcode", "open")); + this.setState({qrcode: text}, () => { + this.showQrModal(); + }); } _copy(e) { @@ -288,7 +307,8 @@ class GdexGatewayInfo extends React.Component { </tr> <tr> <td> - <Translate content="gateway.balance" />: + <Translate content="gateway.balance" /> + : </td> <td style={{ @@ -319,7 +339,8 @@ class GdexGatewayInfo extends React.Component { <Translate content="gateway.deposit_to" asset={coin.outerSymbol} - />: + /> + : </label> <p style={{color: "red"}}> <Translate @@ -340,7 +361,8 @@ class GdexGatewayInfo extends React.Component { <tbody> <tr> <td> - <Translate content="gateway.address" />: + <Translate content="gateway.address" /> + : </td> <td>{deposit_address_fragment}</td> <td> @@ -370,7 +392,8 @@ class GdexGatewayInfo extends React.Component { {memoText ? ( <tr> <td> - <Translate content="gateway.memo" />: + <Translate content="gateway.memo" /> + : </td> <td>{memoText}</td> <td> @@ -400,10 +423,22 @@ class GdexGatewayInfo extends React.Component { ) : null} </tbody> </table> - <BaseModal id="qrcode" overlay={true}> + <Modal + footer={[ + <Button + key="close" + type="primary" + onClick={this.hideQrModal} + > + {counterpart.translate("modal.close")} + </Button> + ]} + visible={this.state.isQrModalVisible} + onCancel={this.hideQrModal} + > {/*<div className="gdex-gateway">abc</div>*/} <DepositQrCodeModal text={qrcode} /> - </BaseModal> + </Modal> </div> </div> </div> @@ -473,7 +508,8 @@ class GdexGatewayInfo extends React.Component { </tr> <tr> <td> - <Translate content="gateway.balance" />: + <Translate content="gateway.balance" /> + : </td> <td style={{ @@ -504,7 +540,8 @@ class GdexGatewayInfo extends React.Component { <Translate content="gateway.withdraw_to" asset={this.props.deposit_asset} - />: + /> + : </label> <div className="button-group" style={{paddingTop: 20}}> <button @@ -555,7 +592,7 @@ class DepositQrCodeModal extends React.Component { <QRCode size={200} value={text} /> <br /> <br /> - <label>{text}</label> + <label style={{textTransform: "none"}}>{text}</label> </div> ); }
14
diff --git a/bin/local-env/env-check.sh b/bin/local-env/env-check.sh #!/bin/bash -# Exit if any command fails -set -e +# Fail on unset variables. +set -u # Include useful functions . "$(dirname "$0")/includes.sh" -# Get the host port for the WordPress container. -HOST_PORT=$(dc port $CONTAINER 80 | awk -F : '{printf $2}') - -# Check for the site status -if [[ -z $(curl -s --head --fail http://localhost:$HOST_PORT) ]]; then +# If the WordPress container isn't running, start the environment. +if ! dc ps -q $CONTAINER ; then status_message "E2E environment is not running, starting it now..." npm run env:start fi
1
diff --git a/packages/gestalt-codemods/0.85.0-0.86.0/deprecate-tooltip.js b/packages/gestalt-codemods/0.85.0-0.86.0/deprecate-tooltip.js * </Tooltip> * to * import { Box, Flyout } from "gestalt"; - * <Flyout {...props} color="darkGray" shouldFocus={false}> + * <Flyout {...props} color="darkGray" shouldFocus={false} size="md"> * <Box column={12} padding={3}> * {children} * </Box> @@ -61,6 +61,10 @@ export default function transformer(file, api) { const { attributes } = node.openingElement; + const hasSizeAttribute = attributes.some( + attribute => attribute.name.name === 'size' + ); + // Inject the old props with new props to mimic the Tooltip const attributesWithTooltipProps = [ ...attributes, @@ -69,7 +73,9 @@ export default function transformer(file, api) { j.jsxExpressionContainer(j.literal(false)) ), j.jsxAttribute(j.jsxIdentifier('color'), j.stringLiteral('darkGray')), - ]; + !hasSizeAttribute && + j.jsxAttribute(j.jsxIdentifier('size'), j.stringLiteral('md')), + ].filter(Boolean); // Sort all the props alphabetically attributesWithTooltipProps.sort((a, b) =>
1
diff --git a/src/markdown/lexicon/core-components/list.md b/src/markdown/lexicon/core-components/list.md @@ -7,11 +7,10 @@ layout: 'guide' order: 290 --- +![list entry in default state](/images/lexicon/ListViewDefault.jpg) ### Usage -![list entry in default state](/images/lexicon/ListViewDefault.jpg) - A list is a visual representation of a dataset that provides more flexibility for arranging the data than a table and is less visually explicit than a card view. It's useful for comparing entries that don't require exhaustive comparison. If the dataset requires exhaustive comparison between entries, use the table view instead. When a list is used together with a management bar, the list entries must include a checkbox, as the selection and actions are reflected in the management bar. @@ -56,7 +55,7 @@ List sections organize content into separate divisions by a certain categorizati ![List section](/images/lexicon/ListViewGroupSeparator.jpg) -#### Examples +### Examples ![list view example with 3 different states in different entries](/images/lexicon/ListViewExample.jpg)
5
diff --git a/apigateway.go b/apigateway.go @@ -758,6 +758,12 @@ func (resource *Resource) NewMethod(httpMethod string, defaultHTTPStatusCode int, possibleHTTPStatusCodeResponses ...int) (*Method, error) { + if OptionsGlobal.Logger != nil && len(possibleHTTPStatusCodeResponses) != 0 { + OptionsGlobal.Logger.WithFields(logrus.Fields{ + "possibleHTTPStatusCodeResponses": possibleHTTPStatusCodeResponses, + }).Debug("The set of all HTTP status codes is no longer required for NewMethod(...). Any valid HTTP status code can be returned starting with v1.8.0.") + } + // http://docs.aws.amazon.com/apigateway/latest/developerguide/how-to-method-settings.html#how-to-method-settings-console keyname := httpMethod existingMethod, exists := resource.Methods[keyname]
0
diff --git a/docs/data_preparation.rst b/docs/data_preparation.rst @@ -44,6 +44,37 @@ And then imported into higlass after copying to the docker temp directory (``cp --datatype bedlike \ --coordSystem b37 +A note about assemblies and coordinate systems +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +HiGlass doesn't really have a notion of an assembly. It only displays data +where it's told to display it. When you aggregate a bedfile with using +chromsizes-filename, it uses the lengths of the chromosomes to determine the +offsets of the bedfile entries from the 0 position. So if aggregate and load +the resulting the beddb file in HiGlass, you'll see the bedfile entries +displayed as if the chromosomes in the chromsizes file were laid end to end. + +Now, if you want to see which chromosomes correspond to which positions along +the x-axis or to have the search bar display "assembly" coordinates, you'll +need to register the chromsizes file using: + +.. code-block:: bash + + higlass-manage ingest \ + --filetype chromsizes-tsv \ + --datatype chromsizes \ + --assembly galGal6 \ + negspy/data/galGal6/chromInfo.txt + +If you would like to be able to search for gene annotations in that assembly, +you'll need to create a `gene annotation track +</data_preparation.html#gene-annotation-tracks>`_. + +** Note that while the lack of assembly enforcement is generally the rule, +`bigWig tracks </data_preparation.html#bigwig-files>`_ are a notable +exception. All bigWig files have to be associated with a coordinate system +that is already present in the HiGlass server in order to be ingested. + Bedpe-like Files ----------------
3
diff --git a/dist/index.html b/dist/index.html <h3>Create HTML elements easily</h3> <pre><code class="language-js">import { el } from 'redom'; -el('h1', 'Hello world!'); +el('h1', 'Hello RE:DOM!'); </code></pre> - <pre><code class="language-markup">&lt;h1&gt;Hello world!&lt;/h1&gt;</code></pre> + <pre><code class="language-markup">&lt;h1&gt;Hello RE:DOM!&lt;/h1&gt;</code></pre> + + <h3>You don't even need any bundlers!</h3> + <pre><code class="language-html">&lt;script type="module"&gt; + import { el } from 'https://redom.js.org/redom.es.min.js'; + + el('h1', 'Hello modules!'); +&lt;/script&gt;</code></pre> + <pre><code class="language-markup">&lt;h1&gt;Hello modules!&lt;/h1&gt;</code></pre> <h3>Add attributes</h3> <pre><code class="language-js">import { el, mount } from 'redom';
0
diff --git a/src/diagrams/state/stateRenderer.js b/src/diagrams/state/stateRenderer.js @@ -278,8 +278,8 @@ const renderDoc = (doc, diagram, parentId) => { pShift = 0; } } - divider.setAttribute('x1', 0 - pShift); - divider.setAttribute('x2', pWidth - pShift); + divider.setAttribute('x1', 0 - pShift + 8); + divider.setAttribute('x2', pWidth - pShift - 8); }); } else { logger.debug('No Node ' + v + ': ' + JSON.stringify(graph.node(v)));
9
diff --git a/lib/util/fonts/getTextByFontProperties.js b/lib/util/fonts/getTextByFontProperties.js @@ -117,8 +117,8 @@ function getMemoizedElementStyleResolver(fontPropRules, availableWeights) { var nonInheritingTags = ['BUTTON', 'INPUT', 'OPTION', 'TEXTAREA']; var getComputedStyle = memoizeSync(function (node, idArray, truePredicates, falsePredicates) { - truePredicates = truePredicates || []; - falsePredicates = falsePredicates || []; + truePredicates = truePredicates || {}; + falsePredicates = falsePredicates || {}; var localFontPropRules = Object.assign({}, fontPropRules); var props = Object.keys(fontPropRules); var result = {}; @@ -148,7 +148,7 @@ function getMemoizedElementStyleResolver(fontPropRules, availableWeights) { for (var i = startIndex; i < localFontPropRules[prop].length; i += 1) { var declaration = localFontPropRules[prop][i]; // Skip to the next rule if we are doing a trace where one of the incoming media attributes are already assumed false: - if (declaration.incomingMedia.some(function (incomingMedia) { return falsePredicates.includes(incomingMedia); })) { + if (declaration.incomingMedia.some(function (incomingMedia) { return falsePredicates[incomingMedia]; })) { continue; } @@ -206,13 +206,9 @@ function getMemoizedElementStyleResolver(fontPropRules, availableWeights) { if (Object.keys(predicatePermutation).length === 0) { return; } - var recursiveTruePredicates = [].concat(truePredicates); - var recursiveFalsePredicates = [].concat(falsePredicates); - Object.keys(predicatePermutation).forEach(function (predicate) { - recursiveTruePredicates.push(predicate); - recursiveFalsePredicates.push(predicate); - }); - if (declaration.incomingMedia.every(function (incomingMedia) { return recursiveTruePredicates.includes(incomingMedia); })) { + var recursiveTruePredicates = Object.assign({}, truePredicates, predicatePermutation); + var recursiveFalsePredicates = Object.assign({}, falsePredicates, predicatePermutation); + if (declaration.incomingMedia.every(function (incomingMedia) { return recursiveTruePredicates[incomingMedia]; })) { Array.prototype.push.apply( multipliedHypotheticalValues, hypotheticalValues.map(function (hypotheticalValue) { @@ -250,20 +246,11 @@ function getMemoizedElementStyleResolver(fontPropRules, availableWeights) { return result; }, { argumentsStringifier: function (args) { - var stringifiedArguments = args[1].join(','); - if (args[2]) { - stringifiedArguments += '\x1e'; - args[2].forEach(function (assumption) { - stringifiedArguments += assumption + '\x1d'; - }); - } - if (args[3]) { - stringifiedArguments += '\x1e'; - args[3].forEach(function (assumption) { - stringifiedArguments += assumption + '\x1d'; - }); - } - return stringifiedArguments; + return ( + args[1].join(',') + '\x1e' + + (args[2] ? Object.keys(args[2]).join('\x1d') : '') + '\x1e' + + (args[3] ? Object.keys(args[3]).join('\x1d') : '') + ); } }); @@ -416,14 +403,14 @@ function getTextByFontProperties(htmlAsset, availableWeights) { var seenPermutationByKey = {}; expandPermutations(styledText) .filter(function (hypotheticalValuesByProp) { - var allTruePredicates = []; - var allFalsePredicates = []; + var allTruePredicates = {}; + var allFalsePredicates = {}; FONT_PROPS.forEach(function (prop) { - Array.prototype.push.apply(allTruePredicates, hypotheticalValuesByProp[prop].truePredicates); - Array.prototype.push.apply(allFalsePredicates, hypotheticalValuesByProp[prop].falsePredicates); + Object.assign(allTruePredicates, hypotheticalValuesByProp[prop].truePredicates); + Object.assign(allFalsePredicates, hypotheticalValuesByProp[prop].falsePredicates); }); - return allTruePredicates.every(function (truePredicate) { - return !allFalsePredicates.includes(truePredicate); + return Object.keys(allTruePredicates).every(function (truePredicate) { + return !allFalsePredicates[truePredicate]; }); }) .forEach(function (hypotheticalValuesByProp) {
4
diff --git a/assets/js/googlesitekit/widgets/register-defaults.js b/assets/js/googlesitekit/widgets/register-defaults.js @@ -28,7 +28,6 @@ import * as WIDGET_CONTEXTS from './default-contexts'; import * as WIDGET_AREAS from './default-areas'; import { WIDGET_AREA_STYLES } from './datastore/constants'; import { - AdsenseTopEarningContentWidget, AnalyticsLoyalVisitorsWidget, AnalyticsNewVisitorsWidget, AnalyticsTopTrafficSourceWidget, @@ -37,7 +36,6 @@ import { AnalyticsPopularProductsWidget, AnalyticsTopCitiesWidget, AnalyticsTopCountriesWidget, - AnalyticsConversionWidget, SearchConsolePopularKeywordsWidget, TopConvertingTrafficSourceWidget, } from '../../components/KeyMetrics/widget-tiles'; @@ -221,18 +219,6 @@ export function registerDefaults( widgetsAPI ) { /* * Key metrics widgets. */ - widgetsAPI.registerWidget( - 'kmAdsenseTopEarningContent', - { - Component: AdsenseTopEarningContentWidget, - width: widgetsAPI.WIDGET_WIDTHS.QUARTER, - priority: 1, - wrapWidget: false, - modules: [ 'analytics-4', 'adsense' ], - }, - [ AREA_MAIN_DASHBOARD_KEY_METRICS_PRIMARY ] - ); - widgetsAPI.registerWidget( 'kmAnalyticsLoyalVisitors', { @@ -329,18 +315,6 @@ export function registerDefaults( widgetsAPI ) { [ AREA_MAIN_DASHBOARD_KEY_METRICS_PRIMARY ] ); - widgetsAPI.registerWidget( - 'kmAnalyticsConversion', - { - Component: AnalyticsConversionWidget, - width: widgetsAPI.WIDGET_WIDTHS.QUARTER, - priority: 1, - wrapWidget: false, - modules: [ 'analytics-4' ], - }, - [ AREA_MAIN_DASHBOARD_KEY_METRICS_PRIMARY ] - ); - widgetsAPI.registerWidget( 'kmTopConvertingTrafficSource', {
2
diff --git a/src/layer/ImageLayer.js b/src/layer/ImageLayer.js @@ -36,7 +36,7 @@ const options = { class ImageLayer extends Layer { constructor(id, images, options) { - if (!Array.isArray(images) && !images.url) { + if (images && !Array.isArray(images) && !images.url) { options = images; images = null; }
1
diff --git a/src/sdk/p2p/peerconnection-channel.js b/src/sdk/p2p/peerconnection-channel.js @@ -328,7 +328,7 @@ class P2PPeerConnectionChannel extends EventDispatcher { this._config); this._pc.setRemoteDescription(sessionDescription).then(() => { this._createAndSendAnswer(); - }, function(error) { + }, (error) => { Logger.debug('Set remote description failed. Message: ' + error.message); this._stop(error, true); }); @@ -345,7 +345,7 @@ class P2PPeerConnectionChannel extends EventDispatcher { sessionDescription)).then(() => { Logger.debug('Set remote descripiton successfully.'); this._drainPendingMessages(); - }, function(error) { + }, (error) => { Logger.debug('Set remote description failed. Message: ' + error.message); this._stop(error, true); });
1
diff --git a/embark-ui/src/components/Console.js b/embark-ui/src/components/Console.js @@ -66,6 +66,14 @@ class Console extends Component { } } + logClassName(item) { + return classnames('m-0', { + 'text-info': item.logLevel === 'debug', + 'text-danger': item.logLevel === 'error', + 'text-warning': item.logLevel === 'warning' + }); + } + renderTabs() { const {processLogs, processes} = this.props; @@ -82,14 +90,14 @@ class Console extends Component { if (this.isJsonObject(item)) { return( <div> - <p key={i} className={item.logLevel} dangerouslySetInnerHTML={{__html: (convert.toHtml(item.command || ""))}}></p> + <p key={i} className={this.logClassName(item)} dangerouslySetInnerHTML={{__html: (convert.toHtml(item.command || ""))}}></p> <ReactJson src={JSON.parse(item.result)} theme="monokai" sortKeys={true} collapsed={1} /> </div> ) } return ( - <p key={i} className={item.logLevel} dangerouslySetInnerHTML={{__html: (convert.toHtml(item.command || "") + convert.toHtml(item.msg))}}></p> + <p key={i} className={this.logClassName(item)} dangerouslySetInnerHTML={{__html: (convert.toHtml(item.command || "") + convert.toHtml(item.msg))}}></p> ) }) }
2
diff --git a/README.md b/README.md [![JOIN OFFICIAL WEKAN CHAT][gitter_badge]][gitter_chat] -2017-02-03 News: All Wekan fork/Wefork code and pull requests has been -merged back to official Wekan. Wefork will not accept new pull requests -and issues to Wefork. All development happens on Wekan. +2017-02-04 News: All Wekan fork/Wefork code, pull requests and translations +has been merged back to official Wekan. Wefork will not accept new pull +requests and issues to Wefork. All development happens on Wekan. [Wefork announcement and merging back][fork_announcement] @@ -14,9 +14,7 @@ and issues to Wefork. All development happens on Wekan. [Wefork FAQ][fork_faq] -[Translate Wekan using newer Wefork translations at Transifex][translate_wefork] - -[Not in use yet: Old Wekan translations at Transifex][translate_wekan] +[Translate Wekan at Transifex][translate_wekan] Wekan is an open-source and collaborative kanban board application. @@ -156,6 +154,5 @@ with [Meteor](https://www.meteor.com). [docker_nginxproxy]: https://github.com/wefork/wekan/wiki/Docker-NginxProxy [docker_issue]: https://github.com/wefork/wekan/issues/33 [translate_wekan]: https://www.transifex.com/wekan/wekan/ -[translate_wefork]: https://www.transifex.com/wefork/wefork/ [autoinstall]: https://github.com/wefork/wekan-autoinstall [autoinstall_issue]: https://github.com/anselal/wekan/issues/18
5
diff --git a/src/components/Timeseries.js b/src/components/Timeseries.js @@ -21,7 +21,6 @@ import {select, mouse} from 'd3-selection'; import {line, curveMonotoneX} from 'd3-shape'; // eslint-disable-next-line import {transition} from 'd3-transition'; -import {formatISO, subDays} from 'date-fns'; import equal from 'fast-deep-equal'; import React, {useCallback, useEffect, useRef, useMemo, useState} from 'react'; import {useTranslation} from 'react-i18next'; @@ -336,24 +335,22 @@ function Timeseries({timeseries, dates, chartType, isUniform, isLog}) { const getStatisticDelta = useCallback( (statistic) => { if (!highlightedDate) return; - const deltaToday = getStatistic( + const currCount = getStatistic( timeseries?.[highlightedDate], - 'delta', + chartType, statistic ); - if (chartType === 'total') return deltaToday; + const prevDate = + dates[dates.findIndex((date) => date === highlightedDate) - 1]; - const yesterday = formatISO(subDays(parseIndiaDate(highlightedDate), 1), { - representation: 'date', - }); - const deltaYesterday = getStatistic( - timeseries?.[yesterday], - 'delta', + const prevCount = getStatistic( + timeseries?.[prevDate], + chartType, statistic ); - return deltaToday - deltaYesterday; + return currCount - prevCount; }, - [timeseries, highlightedDate, chartType] + [timeseries, dates, highlightedDate, chartType] ); const trail = useMemo(() => {
1
diff --git a/scripts/build/schema-to-rst.js b/scripts/build/schema-to-rst.js @@ -189,14 +189,14 @@ function objectTable(props, rstArray, defName, propName, type) { getProperties(props.items, itemProps, defName); if (Object.keys(itemProps).length > 0) { table += `${defName} ${propName} possible properties when object type\n\n`; - table = addTable(itemProps, table); + table = addTable(itemProps, table, `${defName}_${propName}`); rstArray.push(table); } } else if (type === 'object') { getProperties(props, itemProps, defName); if (Object.keys(itemProps).length > 0) { table += `${defName} ${propName} possible properties\n\n`; - table = addTable(itemProps, table); + table = addTable(itemProps, table, `${defName}_${propName}`); rstArray.push(table); } }
7
diff --git a/lib/plugins/aws/provider/awsProvider.js b/lib/plugins/aws/provider/awsProvider.js @@ -212,7 +212,7 @@ class AwsProvider { */ request(service, method, params, options) { const that = this; - const credentials = _.cloneDeep(that.getCredentials()); + const credentials = Object.assign({}, that.getCredentials()); // Make sure options is an object (honors wrong calls of request) const requestOptions = _.isObject(options) ? options : {}; const shouldCache = _.get(requestOptions, 'useCache', false);
1
diff --git a/webpack.config.js b/webpack.config.js @@ -113,7 +113,7 @@ const webpackConfig = ( mode ) => { 'googlesitekit-admin': './assets/js/googlesitekit-admin.js', 'googlesitekit-module': './assets/js/googlesitekit-module.js', // Needed to test if a browser extension blocks this by naming convention. - ads: './assets/js/adsense.js', + adsense: './assets/js/adsense.js', }, externals, output: {
10
diff --git a/package.json b/package.json "redux-logger": "2.6.1", "redux-thunk": "2.1.0", "simplemde": "1.11.2", - "slug": "0.9.1", + "slug": "git+https://[email protected]/180-g/node-slug", "sortablejs": "1.4.2", "underscore": "1.8.3" },
14
diff --git a/userscript.user.js b/userscript.user.js @@ -49751,6 +49751,10 @@ var $$IMU_EXPORT$$; return null; var find_from_el = function() { + if (options.host_url.match(/\/a\/+[^/]+\/+embed/)) { + return "default"; + } + var current = el; while ((current = current.parentElement)) { if (current.tagName === "DIV" && @@ -49820,14 +49824,14 @@ var $$IMU_EXPORT$$; if (!window.runSlots && options.do_request) { common_functions.fetch_imgur_webpage(options.do_request, real_api_cache, undefined, options.host_url, function(data) { if (!data || !data.imageinfo) { - return options.cb(find_next_el()); + return options.cb(find_from_el()); } try { return options.cb(find_from_both(data.imageinfo.album_images.images)); } catch (e) { console_error(e); - return options.cb(find_next_el()); + return options.cb(find_from_el()); } });
7
diff --git a/portal/src/components/UploadCSV/UploadCSV.js b/portal/src/components/UploadCSV/UploadCSV.js @@ -30,6 +30,11 @@ function UploadCSV({sampleCSV, fileUploadAPI, onUploadComplete}) { alert("Successfully uploaded CSV"); }, 500); onUploadComplete(); + }).catch((error) => { + if (error.response && error.response.status === 400) { + setUploadPercentage(0) + alert(error.response.data["message"]); + } }) };
9
diff --git a/lib/node_modules/@stdlib/random/base/mt19937/lib/factory.js b/lib/node_modules/@stdlib/random/base/mt19937/lib/factory.js @@ -70,7 +70,7 @@ var randuint32 = require( './rand_uint32.js' ); // VARIABLES // -// Define the size of the state array (see paper): +// Define the size of the state array (see refs): var N = 624; // Define a (magic) constant used for indexing into the state array: @@ -82,10 +82,10 @@ var MAX_SEED = UINT32_MAX >>> 0; // asm type annotation // For seed arrays, define an initial state (magic) constant: 19650218 => 00000001001010111101011010101010 var SEED_ARRAY_INIT_STATE = 19650218 >>> 0; // asm type annotation -// Define a mask for the most significant `w-r` bits (see paper): 2147483648 => 0x80000000 => 10000000000000000000000000000000 +// Define a mask for the most significant `w-r` bits (see refs): 2147483648 => 0x80000000 => 10000000000000000000000000000000 var UPPER_MASK = 0x80000000 >>> 0; // asm type annotation -// Define a mask for the least significant `r` bits (see paper): 2147483647 => 0x7fffffff => 01111111111111111111111111111111 +// Define a mask for the least significant `r` bits (see refs): 2147483647 => 0x7fffffff => 01111111111111111111111111111111 var LOWER_MASK = 0x7fffffff >>> 0; // asm type annotation // Define a multiplier (see Knuth TAOCP Vol2. 3rd Ed. P.106): 1812433253 => 01101100000001111000100101100101 @@ -97,7 +97,7 @@ var MAGIC_MULTIPLIER_1 = 1664525 >>> 0; // asm type annotation // Define a (magic) multiplier: 1566083941 => 01011101010110001000101101100101 var MAGIC_MULTIPLIER_2 = 1566083941 >>> 0; // asm type annotation -// Define a constant vector `a` (see paper): 2567483615 => 0x9908b0df => 10011001000010001011000011011111 +// Define a constant vector `a` (see refs): 2567483615 => 0x9908b0df => 10011001000010001011000011011111 var MATRIX_A = 0x9908b0df >>> 0; // asm type annotation // MAG01[x] = x * MATRIX_A; for x = {0,1} @@ -112,6 +112,9 @@ var TWO_26 = 67108864 >>> 0; // asm type annotation // 2^32: 2147483648 => 0x80000000 => 10000000000000000000000000000000 var TWO_32 = 0x80000000 >>> 0; // asm type annotation +// 1: +var ONE = 0x1 >>> 0; // asm type annotation + // Define the maximum normalized pseudorandom double-precision floating-point number: ( (((2^32-1)>>>5)*2^26)+( (2^32-1)>>>6) ) / 2^53 var MAX_NORMALIZED = FLOAT64_MAX_SAFE_INTEGER * FLOAT64_NORMALIZATION_CONSTANT; @@ -227,6 +230,34 @@ function initState( state, seed ) { return state; } +/** +* Updates a PRNG's internal state by generating the next `N` words. +* +* @private +* @param {Uint32Array} state - state array +* @returns {Uint32Array} state array +*/ +function updateState( state ) { + var w; + var i; + var j; + var k; + + k = N - M; + for ( i = 0; i < k; i++ ) { + w = ( state[i]&UPPER_MASK ) | ( state[i+1]&LOWER_MASK ); + state[ i ] = state[ i+M ] ^ ( w>>>1 ) ^ MAG01[ w&ONE ]; + } + j = N - 1; + for ( ; i < j; i++ ) { + w = ( state[i]&UPPER_MASK ) | ( state[i+1]&LOWER_MASK ); + state[ i ] = state[ i-k ] ^ ( w>>>1 ) ^ MAG01[ w&ONE ]; + } + w = ( state[j]&UPPER_MASK ) | ( state[0]&LOWER_MASK ); + state[ j ] = state[ M-1 ] ^ ( w>>>1 ) ^ MAG01[ w&ONE ]; + return state; +} + // MAIN // @@ -360,37 +391,25 @@ function factory( seed ) { * @returns {PositiveInteger} pseudorandom integer * * @example - * var v = mt19937(); + * var r = mt19937(); * // returns <number> */ function mt19937() { - var kk; - var y; - + var r; if ( mti >= N ) { - for ( kk = 0; kk < N - M; kk++ ) { - y = ( mt[kk] & UPPER_MASK ) | ( mt[kk + 1] & LOWER_MASK ); - mt[kk] = mt[kk + M] ^ ( y >>> 1 ) ^ MAG01[y & 0x1]; - } - for ( ; kk < N - 1; kk++ ) { - y = ( mt[kk] & UPPER_MASK ) | ( mt[kk + 1] & LOWER_MASK ); - mt[kk] = mt[kk + (M - N)] ^ (y >>> 1) ^ MAG01[y & 0x1]; - } - y = ( mt[N - 1] & UPPER_MASK ) | ( mt[0] & LOWER_MASK ); - mt[N - 1] = mt[M - 1] ^ ( y >>> 1 ) ^ MAG01[y & 0x1]; + mt = updateState( mt ); mti = 0; } - - y = mt[ mti ]; + r = mt[ mti ]; mti += 1; - /* Tempering */ - y ^= y >>> 11; - y ^= ( y << 7 ) & 0x9d2c5680; - y ^= ( y << 15 ) & 0xefc60000; - y ^= y >>> 18; + // Tempering: + r ^= r >>> 11; + r ^= ( r << 7 ) & 0x9d2c5680; + r ^= ( r << 15 ) & 0xefc60000; + r ^= r >>> 18; - return y >>> 0; + return r >>> 0; } /** @@ -404,7 +423,7 @@ function factory( seed ) { * @returns {number} pseudorandom number * * @example - * var v = normalized(); + * var r = normalized(); * // returns <number> */ function normalized() {
5
diff --git a/upgrade.php b/upgrade.php @@ -951,6 +951,14 @@ function upgrade_21() } return "Creating dashboard_allowed_links field in templatedetails - ok ? " . ($error1_returned && $error2_returned ? 'true' : 'false') . "<br>"; } + if (! _db_field_exists('sitedetails', 'dashboard_allowed_links')) { + $error2 = _db_add_field('sitedetails', 'dashboard_allowed_links', 'text', '', 'dashboard_period'); + $error2_returned = true; + if ($error2 === false) + { + $error2_returned = false; + } + } return "Creating dashboard_allowed_links field in templatedetails already present - ok ? ". "<br>"; }
1
diff --git a/angular/projects/spark-angular/src/lib/directives/sprk-text/sprk-text.stories.ts b/angular/projects/spark-angular/src/lib/directives/sprk-text/sprk-text.stories.ts @@ -50,7 +50,7 @@ const modules = { export const bodyOne = () => ({ moduleMetadata: modules, template: ` - <p sprkText variant="one"> + <p sprkText variant="bodyOne"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed gravida urna quis nulla ultrices, sed efficitur risus @@ -77,7 +77,7 @@ bodyOne.story = { export const bodyTwo = () => ({ moduleMetadata: modules, template: ` - <p sprkText variant="two"> + <p sprkText variant="bodyTwo"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed gravida urna quis nulla ultrices, sed efficitur risus @@ -104,7 +104,7 @@ bodyTwo.story = { export const bodyThree = () => ({ moduleMetadata: modules, template: ` - <p sprkText variant="three"> + <p sprkText variant="bodyThree"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed gravida urna quis nulla ultrices, sed efficitur risus @@ -131,7 +131,7 @@ bodyThree.story = { export const bodyFour = () => ({ moduleMetadata: modules, template: ` - <p sprkText variant="four"> + <p sprkText variant="bodyFour"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed gravida urna quis nulla ultrices, sed efficitur risus
3
diff --git a/token-metadata/0x4bD70556ae3F8a6eC6C4080A0C327B24325438f3/metadata.json b/token-metadata/0x4bD70556ae3F8a6eC6C4080A0C327B24325438f3/metadata.json "symbol": "HXRO", "address": "0x4bD70556ae3F8a6eC6C4080A0C327B24325438f3", "decimals": 18, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/StackExchangeDarkMode.user.js b/StackExchangeDarkMode.user.js // @description Dark theme for sites and chat on the Stack Exchange Network // @homepage https://github.com/samliew/SO-mod-userscripts // @author @samliew -// @version 2.15.1 +// @version 2.15.2 // // @include https://*stackexchange.com/* // @include https://*stackoverflow.com/* @@ -213,7 +213,6 @@ body #content .share-tip, /* Specific elements opacity & hover */ -.wmd-button-row, #left-sidebar:not(.js-unpinned-left-sidebar), #sidebar > *, .deleted-answer, @@ -235,7 +234,6 @@ ul.comments-list .js-comment-flag, ul.comments-list .comment-flag { opacity: 0.25; } -.wmd-button-row:hover, #left-sidebar:hover, #sidebar > *:hover, .deleted-answer:hover, @@ -253,6 +251,10 @@ ul.comments-list .comment:hover .js-comment-flag, ul.comments-list .comment:hover .comment-flag { opacity: 0.5; } +.wmd-button-row { + background-color: white; + filter: invert(1) brightness(5) contrast(0.8); +} .wmd-button, .wmd-spacer { height: 43px;
7
diff --git a/test/model.populate.test.js b/test/model.populate.test.js @@ -6224,6 +6224,7 @@ describe('model: populate:', function() { var officeSchema = new Schema({ managerId: { type: Schema.ObjectId, ref: 'gh6414User' }, supervisorId: { type: Schema.ObjectId, ref: 'gh6414User' }, + janitorId: { type: Schema.ObjectId, ref: 'gh6414User' }, associatesIds: [{ type: Schema.ObjectId, ref: 'gh6414User' }] }); @@ -6232,10 +6233,12 @@ describe('model: populate:', function() { var manager = new User({ name: 'John' }); var billy = new User({ name: 'Billy' }); var tom = new User({ name: 'Tom' }); + var kevin = new User({ name: 'Kevin' }); var hafez = new User({ name: 'Hafez' }); var office = new Office({ managerId: manager._id, supervisorId: hafez._id, + janitorId: kevin._id, associatesIds: [billy._id, tom._id] }); @@ -6243,18 +6246,20 @@ describe('model: populate:', function() { yield hafez.save(); yield billy.save(); yield tom.save(); + yield kevin.save(); yield office.save(); let doc = yield Office.findOne() .populate([ { path: 'managerId supervisorId associatesIds', select: 'name -_id' }, - //{ path: 'someOtherField' } + { path: 'janitorId', select: 'name -_id' } ]); assert.strictEqual(doc.managerId.name, 'John'); assert.strictEqual(doc.supervisorId.name, 'Hafez'); assert.strictEqual(doc.associatesIds[0].name, 'Billy'); assert.strictEqual(doc.associatesIds[1].name, 'Tom'); + assert.strictEqual(doc.janitorId.name, 'Kevin'); }); }); });
1
diff --git a/tools/make/lib/notes/Makefile b/tools/make/lib/notes/Makefile @@ -25,6 +25,8 @@ notes: --exclude-dir "$(NODE_MODULES)/*" \ --exclude-dir "$(BUILD_DIR)/*" \ --exclude-dir "$(REPORTS_DIR)/*" \ + --exclude-dir "$(DEPS_TMP_DIR)/*" \ + --exclude-dir "$(DEPS_BUILD_DIR)/*" \ --exclude "$(this_file)" \ --exclude "$(ROOT_DIR)/.*" \ --exclude "**/$(BUILD_FOLDER)/*" \
8
diff --git a/token-metadata/0x3E9BC21C9b189C09dF3eF1B824798658d5011937/metadata.json b/token-metadata/0x3E9BC21C9b189C09dF3eF1B824798658d5011937/metadata.json "symbol": "LINA", "address": "0x3E9BC21C9b189C09dF3eF1B824798658d5011937", "decimals": 18, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/articles/_includes/_package.html b/articles/_includes/_package.html <h3 class="package-header">Sample Project</h3> <% if (account.userName) { %> <p class="package-description configured"> - Download this sample project configured with your Auth0 API Keys. + Download a sample project specific to this tutorial configured with your Auth0 API Keys. </p> <% } else { %> <p class="package-description not-configured"> - Download this sample project to get started on this tutorial. + Download a sample project specific to this tutorial to get started. <br> <span class="need-to-login">Log In to have your Auth0 credentials preconfigured.</span> </p>
3
diff --git a/test/core/test_task_launcher.py b/test/core/test_task_launcher.py @@ -65,7 +65,7 @@ class TestTaskLauncher(unittest.TestCase): self.assertEqual(len(launcher.units), 0) self.assertEqual(launcher.provider_type, MockProvider.PROVIDER_TYPE) - def test_create_expire_assignments(self): + def test_create_launch_expire_assignments(self): """Initialize a launcher on a task run, then create the assignments""" mock_data_array = self.get_mock_assignment_data_array() launcher = TaskLauncher(self.db, self.task_run, mock_data_array) @@ -87,6 +87,13 @@ class TestTaskLauncher(unittest.TestCase): for assignment in launcher.assignments: self.assertEqual(assignment.get_status(), AssignmentState.CREATED) + launcher.launch_units("dummy-url:3000") + + for unit in launcher.units: + self.assertEqual(unit.get_db_status(), AssignmentState.LAUNCHED) + for assignment in launcher.assignments: + self.assertEqual(assignment.get_status(), AssignmentState.LAUNCHED) + launcher.expire_units() for unit in launcher.units: @@ -94,20 +101,29 @@ class TestTaskLauncher(unittest.TestCase): for assignment in launcher.assignments: self.assertEqual(assignment.get_status(), AssignmentState.EXPIRED) - def test_launch_assignments(self): + def test_launch_assignments_with_concurrent_unit_cap(self): """Initialize a launcher on a task run, then create the assignments""" + cap_values = [1, 2, 3, 4, 5] + for max_num_units in cap_values: + self.setUp() mock_data_array = self.get_mock_assignment_data_array() launcher = TaskLauncher( - self.db, self.task_run, mock_data_array, max_num_concurrent_units=1 + self.db, + self.task_run, + mock_data_array, + max_num_concurrent_units=max_num_units, ) launcher.launched_units = LimitedDict(launcher.max_num_concurrent_units) launcher.create_assignments() launcher.launch_units("dummy-url:3000") + while set([u.get_status() for u in launcher.units]) != { + AssignmentState.COMPLETED + }: for unit in launcher.units: if unit.get_status() == AssignmentState.LAUNCHED: unit.set_db_status(AssignmentState.COMPLETED) - time.sleep(10) + time.sleep(0.1) self.assertEqual(launcher.launched_units.exceed_limit, False) launcher.expire_units()
7
diff --git a/t/lib/login_with_user.js b/t/lib/login_with_user.js @@ -102,7 +102,7 @@ var login_with_user_func = Promise.promisify(function(args, callback){ // Make sure login was successful, check that we landed on user account page driver.getTitle() .then(function(title){ - expect(title).to.be.equal('Calendar'); + expect(title).to.match(/Calendar/); }); driver
1
diff --git a/unlock-app/src/components/creator/LockMakerForm.js b/unlock-app/src/components/creator/LockMakerForm.js @@ -10,7 +10,8 @@ class LockMakerForm extends React.Component { super(props) this.state = { keyReleaseMechanism: 0, // Public - expirationDuration: 60 * 60 * 24 * 10, // 10 days (in seconds!) + expirationDuration: 30, + expirationDurationUnit: 86400, // Days expirationTimestamp: 0, // for now 0 as we focus on duration based locks keyPriceCalculator: 0, // let's focus on fix prices keyPrice: 0.01, @@ -28,7 +29,7 @@ class LockMakerForm extends React.Component { handleSubmit () { const lockParams = { keyReleaseMechanism: this.state.keyReleaseMechanism, - expirationDuration: this.state.expirationDuration, + expirationDuration: this.state.expirationDuration * this.state.expirationDurationUnit, expirationTimestamp: this.state.expirationTimestamp, keyPriceCalculator: this.state.keyPriceCalculator, keyPrice: Web3Utils.toWei(this.state.keyPrice.toString(10), this.state.keyPriceCurrency), @@ -56,11 +57,17 @@ class LockMakerForm extends React.Component { <div className="form-group"> <label htmlFor="expirationDuration">Key Duration (seconds)</label> + <div className="input-group"> <input className="form-control" type="number" id="expirationDuration" value={this.state.expirationDuration} onChange={this.handleChange} /> + <select className="custom-select" value={this.state.expirationDurationUnit} onChange={this.handleChange} id="expirationDurationUnit"> + <option value="3600">Hours</option> + <option value="86400">Days</option> + </select> + </div> </div> <div className="form-group">
11
diff --git a/src/sass/buttons.scss b/src/sass/buttons.scss } .button { - border-radius: 6px; + border-radius: 3px; &.button-full { border-radius: 0; display: block; } &-green { - @include button-style(#719561, #FFF, #606060, #FFF, #FFF); - @include button-clear(#FFF); - @include button-outline(#C1C1C1); - border: 0px; - @include button-shadow(); + // button-style - BG-color, border-color, active bg-color, active border-color, text color + @include button-style(#15d6a0, #11A87E, #15d6a0, #11A87E, #FFF); + background: -moz-linear-gradient(top, #15d6a0 0%, #0ac18e 100%); /* FF3.6-15 */ + background: -webkit-linear-gradient(top, #15d6a0 0%,#0ac18e 100%); /* Chrome10-25,Safari5.1-6 */ + background: linear-gradient(to bottom, #15d6a0 0%,#0ac18e 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */ + border: 1px; } &-white { - @include button-style(#FFF, #C1C1C1, #C1C1C1, #FFF, #606060); + @include button-style(#F1F3FB, transparent, #F1F3FB, transparent, #0AC18E); @include button-clear(#FFF); - @include button-outline(#C1C1C1); - @include button-shadow(); &.activated { color: #FFF; }
3
diff --git a/lib/logger.js b/lib/logger.js @@ -43,9 +43,12 @@ Logger.prototype.log = function (type, libName, err, libSource) { var message = makeMsg(err) - if (this.last == 'progress') - process.stdout.write('\033[1F\033[0K') if (type !== SUCCESS || this.verbose) { + if (this.last == 'progress') { + process.stdout.cursorTo(0) + process.stdout.write('\033[1F\033[0K') + process.stdout.clearLine(1) + } process.stdout.write( strings.rpad((type.toUpperCase() + ':'), 8)[type === ERROR ? 'red' : type === WARNING ? 'yellow' : 'green'] + ' ' + strings.rpad(libName || 'UNKNOWN LIBRARY', 20).bold @@ -54,9 +57,9 @@ Logger.prototype.log = function (type, libName, err, libSource) { ) if (libSource) console.log(strings.lpad('', 8), Array.isArray(libSource) ? libSource.join(', ') : libSource) - } this.last = 'log' } +} Logger.prototype.progress = function (completed, total) { if (this.quiet) @@ -70,9 +73,13 @@ Logger.prototype.progress = function (completed, total) { , PROGRESS_BAR_LENGTH) + '| ' + perc + '%' // (' + completed + '/' + total + ')' - if (this.last == 'progress') - process.stdout.write('\033[1F\033[0K') - console.log(ps.green.bold) + if (this.last == 'progress') { + process.stdout.cursorTo(0) + process.stdout.write(ps.green.bold) + process.stdout.clearLine(1) + } else { + process.stdout.write(ps.green.bold) + } this.last = 'progress' }
1
diff --git a/modules/decision/play.php b/modules/decision/play.php @@ -56,7 +56,7 @@ function show_template($row_play) $page_content = str_replace("%TEMPLATEPATH%", $template_path_string, $page_content); $page_content = str_replace("%XMLPATH%", $string_for_flash, $page_content); $page_content = str_replace("%XMLFILE%", $string_for_flash_xml, $page_content); - $page_content = str_replace("%THEMEPATH%",$xerte_toolkits_site->site_url . "themes/" . $row['template_name'] . "/",$page_content); + $page_content = str_replace("%THEMEPATH%",$xerte_toolkits_site->site_url . "themes/" . $row_play['template_name'] . "/",$page_content); $page_content = str_replace("%MATHJAXPATH%", "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/", $page_content); echo $page_content;
1
diff --git a/source/core/String.js b/source/core/String.js @@ -543,5 +543,5 @@ Object.assign(String.prototype, { }); // TODO(cmorgan/modulify): do something about these exports: String#format, -// String#repeat, String#escapeHTML, String#escapeRegExp, String#capitalise, +// String#escapeHTML, String#escapeRegExp, String#capitalise, // String#camelCase, String#hyphenate, String#hash, String#md5
2
diff --git a/includes/Modules/Tag_Manager.php b/includes/Modules/Tag_Manager.php @@ -432,7 +432,6 @@ final class Tag_Manager extends Module 'POST:connection' => array( 'service' => '' ), 'POST:account-id' => array( 'service' => '' ), 'POST:container-id' => array( 'service' => '' ), - 'POST:settings' => array( 'service' => '' ), ); $map['POST:create-container'] = array(
2
diff --git a/packages/storybook/index.js b/packages/storybook/index.js -import { html as litHtml } from 'lit-html'; +export { html } from 'lit-html'; export { storiesOf, addParameters } from '@storybook/polymer'; export { action } from '@storybook/addon-actions'; @@ -18,59 +18,3 @@ export { document } from 'global'; // array, // boolean, // } from '@storybook/addon-knobs'; - -/** - * This is a wrapper around lit-html that supports dynamic strings to be added as a preprocessing - * step, before a template is passed to lit's html function. - * A dynamic string will be evaluated one time (on init) and passed to lit-html as being - * part of the static string. - * - * WARNING: do not use in production!!! has a huge performance penalty as every string is - * different from lit-htmls perspective so a new tag is created every time. - * - * A valid use case for this would be to create dynamic tag names. - * - * @example: - * const tag = unsafeStatic('my-tag'); - * html`<${tag} prop="${prop}"></${tag>` - * // will in turn calls lit-html html function as: - * html`<my-tag prop="${prop}"></my-tag>` - */ -export function html(strings, ...values) { - const newVal = []; // result values to be passed on to lit-html - const newStr = []; // result strings to be passed on to lit-html - - if (values.length === 0) { - return litHtml(strings, ...values); - } - - const isDynamicProp = p => p && p.d && typeof p.d === 'string' && Object.keys(p).length === 1; - const addToCurrentString = (add) => { - newStr[newStr.length - 1] = newStr[newStr.length - 1] + add; - }; - - // Create the result arrays - values.forEach((string, index) => { - if (index === 0) { - newStr.push(strings[0]); // this is either ''(if tagged starts with value) or string - } - // Situation 1 : dynamic string - const p = values[index]; // potential dynamic string - if (isDynamicProp(p)) { - addToCurrentString(p.d); - addToCurrentString(strings[index + 1]); - } else { - // Situation 2: no dynamic string, just push string and value - newVal.push(p); // a 'real' value - newStr.push(strings[index + 1]); - } - }); - // Return lit template - return litHtml(newStr, ...newVal); -} - -export function unsafeStatic(options) { - return { - d: options, - }; -}
1
diff --git a/spec/widgets/formula/content-view.spec.js b/spec/widgets/formula/content-view.spec.js @@ -26,7 +26,7 @@ describe('widgets/formula/content-view', function () { title: 'Max population', hasInitialState: true }, { - dataviewModel, + dataviewModel: dataviewModel, layerModel: layerModel });
2
diff --git a/content/en/guide/v10/progressive-web-apps.md b/content/en/guide/v10/progressive-web-apps.md @@ -64,7 +64,7 @@ While Preact is a drop-in that should work well for your PWA, it can also be use <div class="_bubble" style="background-image: url(../../assets/pwa-guide/code-splitting.svg);"></div> </div> <div class="list-detail"> - <p class="_summary"><strong><a href="https://webpack.github.io/docs/code-splitting.html">Code-splitting</a></strong> breaks up your code so you only ship what the user needs for a page. Lazy-loading the rest as needed improves page load times. Supported via Webpack.</p> + <p class="_summary"><strong><a href="https://webpack.js.org/guides/code-splitting/">Code-splitting</a></strong> breaks up your code so you only ship what the user needs for a page. Lazy-loading the rest as needed improves page load times. Supported via Webpack.</p> </div> </li> <li class="list-item">
1
diff --git a/layout/explore-detail/explore-detail-header/explore-detail-header-component.js b/layout/explore-detail/explore-detail-header/explore-detail-header-component.js @@ -128,7 +128,7 @@ class ExploreDetailHeader extends PureComponent { name={starIconName} className={starIconClass} /> - <span>Favorite</span> + <span>Save</span> </button> </Tooltip> </LoginRequired>
10
diff --git a/server/src/input/pdfminer/pdfminer.ts b/server/src/input/pdfminer/pdfminer.ts @@ -368,8 +368,13 @@ function repairPdf(filePath: string) { const qpdfPath = utils.getCommandLocationOnSystem('qpdf'); if (qpdfPath) { const pdfOutputFile = utils.getTemporaryFile('.pdf'); - spawnSync('qpdf', ['--decrypt', filePath, pdfOutputFile]); + const process = spawnSync('false', ['--decrypt', filePath, pdfOutputFile]); + + if (process.status === 0) { filePath = pdfOutputFile; + } else { + logger.warn('qpdf error:', process.status, process.stdout.toString(), process.stderr.toString()); + } } return new Promise<string>(resolve => {
0
diff --git a/src/hooks/renderJournalSheet/adventure.js b/src/hooks/renderJournalSheet/adventure.js import { DDBAdventureFlags } from "../../lib/adventureFlags.js"; import buildNotes from "./buildNotes.js"; +import { DDB_CONFIG } from "../../ddbConfig.js"; const POPUPS = { json: null, @@ -36,7 +37,8 @@ function adventureFlags(app, html, data) { } else { event.preventDefault(); const flags = app.document.data.flags.ddb; - return renderPopup("web", `https://www.dndbeyond.com/sources/${flags.bookCode}/${flags.slug}`); + const bookSource = DDB_CONFIG.sources.find((book) => flags.bookCode.toLowerCase() === book.name.toLowerCase()); + return renderPopup("web", `https://www.dndbeyond.com/${bookSource.sourceURL}/${flags.slug}`); } return true; });
7
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml @@ -38,7 +38,8 @@ jobs: with: mongodb-version: ${{ matrix.mongodb-version }} - - run: (node --version | grep v14) && npm install -g npm@8 + # Exit status must be succesful in the end + - run: ( ( node --version | grep v14 ) && npm install -g npm@8 ) || echo "npm OK" - run: npm install
9
diff --git a/src/serverlessLog.js b/src/serverlessLog.js @@ -15,12 +15,6 @@ module.exports.setLog = function setLog(serverlessLogRef) { // logs based on: // https://github.com/serverless/serverless/blob/master/lib/classes/CLI.js -module.exports.errorLog = function errorLog(msg) { - console.log() - console.log(`offline: ${chalk.keyword('red')(msg)}`) - console.log() -} - module.exports.logRoute = function logRoute(httpMethod, server, path) { console.log( `offline: ${chalk.keyword('dodgerblue')(`[${httpMethod}]`)} ${chalk
2
diff --git a/lib/assets/core/javascripts/cartodb3/components/modals/add-widgets/tablestats.js b/lib/assets/core/javascripts/cartodb3/components/modals/add-widgets/tablestats.js @@ -316,7 +316,7 @@ ColumnGraph.prototype = { return []; } - var histogram = new Array(bins).fill(0); + var histogram = new Array(bins + 1).join('0').split('').map(parseFloat); function scale (value) { if (max === min) return min; return (bins - 1) * (value - min) / (max - min);
14
diff --git a/src/index.js b/src/index.js @@ -19,7 +19,7 @@ bugsnagConfiguration.releaseStage = Config.RELEASE_STAGE ? Config.RELEASE_STAGE : "dev"; // Only send reports for releases from master branch -bugsnagConfiguration.notifyReleaseStages = ["beta", "release"]; +bugsnagConfiguration.notifyReleaseStages = ["alpha", "beta", "release"]; const bugsnag = new Client(bugsnagConfiguration); // eslint-disable-line no-unused-vars // https://github.com/react-navigation/react-navigation/issues/3956#issuecomment-380648083
11
diff --git a/src/content/developers/docs/programming-languages/golang/index.md b/src/content/developers/docs/programming-languages/golang/index.md @@ -34,7 +34,7 @@ Need a more basic primer first? Check out [ethereum.org/learn](/learn/) or [ethe ## Intermediate articles and docs {#intermediate-articles-and-docs} - [Go Ethereum Documentation](https://geth.ethereum.org/docs/) - _The documentation for the official Ethereum Golang_ -- [Turbo-Geth Programmer's Guide](https://github.com/ledgerwatch/turbo-geth/blob/master/docs/programmers_guide/guide.md) - _Illustrated guide including the state tree, multi-proofs, and transaction processing_ +- [Erigon Programmer's Guide](https://github.com/ledgerwatch/erigon/blob/devel/docs/programmers_guide/guide.md) - _Illustrated guide including the state tree, multi-proofs, and transaction processing_ - [Turbo-Geth and Stateless Ethereum](https://youtu.be/3-Mn7OckSus?t=394) - _2020 Ethereum Community Conference (EthCC 3)_ - [Turbo-Geth: optimising Ethereum clients](https://www.youtube.com/watch?v=CSpc1vZQW2Q) - _2018 Devcon 4_ - [Go Ethereum GoDoc](https://godoc.org/github.com/ethereum/go-ethereum) @@ -55,7 +55,7 @@ Need a more basic primer first? Check out [ethereum.org/learn](/learn/) or [ethe - [Geth / Go Ethereum](https://github.com/ethereum/go-ethereum) - _Official Go implementation of the Ethereum protocol_ - [Go Ethereum Code Analysis](https://github.com/ZtesoftCS/go-ethereum-code-analysis) - _Review and analysis of Go Ethereum source code_ -- [Turbo-Geth](https://github.com/ledgerwatch/turbo-geth) - _Faster derivative of Go Ethereum_ +- [Erigon](https://github.com/ledgerwatch/erigon) - _Faster derivative of Go Ethereum, with a focus on archive nodes_ - [Golem](https://github.com/golemfactory/golem) - _Golem is creating a global market for computing power_ - [Quorum](https://github.com/jpmorganchase/quorum) - _A permissioned implementation of Ethereum supporting data privacy_ - [Prysm](https://github.com/prysmaticlabs/prysm) - _Ethereum 'Serenity' 2.0 Go Implementation_
10
diff --git a/includes/Core/Assets/Assets.php b/includes/Core/Assets/Assets.php @@ -347,7 +347,10 @@ final class Assets { array( 'src' => false, 'before_print' => function( $handle ) { - wp_localize_script( $handle, 'googlesitekit', $this->get_inline_data() ); + $data = wp_scripts()->get_data( $handle, 'data' ) ?: ''; + $script = 'var googlesitekit = ' . wp_json_encode( $this->get_inline_data() ) . ';'; + + wp_scripts()->add_data( $handle, 'data', $script . $data ); }, ) ),
14
diff --git a/packages/react-jsx-highstock/test/components/FlagSeries/FlagSeries.spec.js b/packages/react-jsx-highstock/test/components/FlagSeries/FlagSeries.spec.js @@ -9,9 +9,9 @@ describe('<FlagSeries />', function () { expect(wrapper).to.have.type(Series); }); - it('renders a <Series type="flag" />', function () { + it('renders a <Series type="flags" />', function () { const wrapper = shallow(<FlagSeries id="mySeries" />); - expect(wrapper).to.have.prop('type').equal('flag'); + expect(wrapper).to.have.prop('type').equal('flags'); }); it('passes other props through to <Series />', function () {
1
diff --git a/js/utils/responsive.js b/js/utils/responsive.js @@ -18,9 +18,9 @@ function getBackgroundImage(imageHashes = {}, standardSize, responsiveSize, defa let imageHash = ''; let bgImageProperty = ''; - if (isHiRez() && imageHashes[responsiveSize]) { + if (isHiRez() && imageHashes && imageHashes[responsiveSize]) { imageHash = imageHashes[responsiveSize]; - } else if (imageHashes[standardSize]) { + } else if (imageHashes && imageHashes[standardSize]) { imageHash = imageHashes[standardSize]; }
9
diff --git a/scripts/utils.js b/scripts/utils.js @@ -4,7 +4,7 @@ const _ = require('lodash'); const childProcess = require('child_process'); const fs = require('fs-extra'); const glob = require('glob'); -const { parse: parseUrl } = require('url'); +const { URL } = require('url'); // This disables ES6+ template delimiters _.templateSettings.interpolate = /<%=([\s\S]+?)%>/g; @@ -24,7 +24,7 @@ function exec (command, cwd) { } async function cloneGitProject ({ gitUrl, gitPath, git, cleanRepo = true }) { - const { protocol, hostname } = parseUrl(gitUrl); + const { protocol, hostname } = new URL(gitUrl); if (protocol === 'ssh:') { await exec(`mkdir -p ~/.ssh`); await exec(`ssh-keyscan -t rsa ${hostname} >> ~/.ssh/known_hosts`);
14
diff --git a/token-metadata/0x2d9765a94FF22e0CA3AfC3E3F4B116dE2b67582a/metadata.json b/token-metadata/0x2d9765a94FF22e0CA3AfC3E3F4B116dE2b67582a/metadata.json "symbol": "CGC", "address": "0x2d9765a94FF22e0CA3AfC3E3F4B116dE2b67582a", "decimals": 16, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/src/plugins/modules/fileBrowser.js b/src/plugins/modules/fileBrowser.js let tagsHTML = ''; let listHTML = '<div class="se-file-item-column">'; let columns = 1; - for (let i = 0, item, tag; i < len; i++) { + for (let i = 0, item, tags; i < len; i++) { item = items[i]; + tags = !item.tag ? [] : typeof item.tag === 'string' ? item.tag.split(',') : item.tag; + tags = item.tag = tags.map(function (v) { return v.trim(); }); listHTML += drawItemHandler(item); if ((i + 1) % splitSize === 0 && columns < columnSize && (i + 1) < len) { listHTML += '</div><div class="se-file-item-column">'; } - if (update) { - tag = item.tag; + if (update && tags.length > 0) { + for (let t = 0, tLen = tags.length, tag; t < tLen; t++) { + tag = tags[t]; if (tag && _tags.indexOf(tag) === -1) { _tags.push(tag); tagsHTML += '<a title="' + tag + '">' + tag + '</a>'; } } } + } listHTML += '</div>'; fileBrowserContext.list.innerHTML = listHTML; this.util.addClass(selectTag, 'on'); } - fileBrowserPlugin._drawListItem.call(this, selectedTags.length === 0 ? fileBrowserContext.items : fileBrowserContext.items.filter(function (item) { - return selectedTags.indexOf(item.tag) > -1; + fileBrowserPlugin._drawListItem.call(this, + selectedTags.length === 0 ? + fileBrowserContext.items : + fileBrowserContext.items.filter(function (item) { + return item.tag.some(function (tag) { + return selectedTags.indexOf(tag) > -1; + }); }), false); },
3
diff --git a/.travis.yml b/.travis.yml -matrix: - include: - - os: osx +os: + - linux + - osx + osx_image: xcode10.2 language: node_js node_js: "12" - env: - - ELECTRON_CACHE=$HOME/.cache/electron - - ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder - - - os: linux - services: docker - node_js: - - 12 - dist: trusty - sudo: false branches: only: @@ -35,16 +26,20 @@ stages: env: - SKIP_PREFLIGHT_CHECK=true + - ELECTRON_CACHE=$HOME/.cache/electron + - ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder jobs: include: - stage: test + os: osx install: - yarn script: - npm run validate - yarn danger ci - stage: env + os: osx install: - yarn script: @@ -57,10 +52,9 @@ jobs: before_deploy: - if [ "$TRAVIS_OS_NAME" = osx ]; then chmod +x add-osx-cert.sh; fi - if [ "$TRAVIS_OS_NAME" = osx ]; then ./add-osx-cert.sh; fi - deploy: - provider: script - skip_cleanup: true - script: - - npx semantic-release before_cache: - rm -rf $HOME/.cache/electron-builder/wine + deploy: + provider: script + cleanup: false + script: npx semantic-release
1
diff --git a/test/src/test/java/com/composum/sling/test/util/JcrTestUtils.java b/test/src/test/java/com/composum/sling/test/util/JcrTestUtils.java @@ -118,6 +118,7 @@ public class JcrTestUtils { Thread writer = new Thread() { @Override public void run() { + try { ZipOutputStream zip = new ZipOutputStream(out); File jcrRootDir = new File(getClass().getResource(location).getFile()); for (File file : FileUtils.listFilesAndDirs(jcrRootDir, FileFilterUtils.trueFileFilter(), @@ -143,6 +144,12 @@ public class JcrTestUtils { } catch (IOException e) { // ignore: importer does not read the directory that's written now. } + } catch (RuntimeException e) { + exceptions.add(new AssertionError("Could not read " + location, e)); + e.printStackTrace(); + IOUtils.closeQuietly(out); + IOUtils.closeQuietly(in); + } } }; try { @@ -155,6 +162,12 @@ public class JcrTestUtils { importer.run(archive, resolver.getResource("/").adaptTo(Node.class)); archive.close(); if (importer.hasErrors()) { throw new IllegalArgumentException("Import failed!"); } + if (!exceptions.isEmpty()) { + for (Throwable exception : exceptions) { + exception.printStackTrace(); + } + throw new AssertionError("Import failed!", exceptions.get(1)); + } resolver.commit(); } finally { writer.interrupt();
7
diff --git a/scripts/orbits.js b/scripts/orbits.js @@ -34,7 +34,7 @@ async function asyncForEach(array, callback) { await request.post('https://www.space-track.org/ajaxauth/login', { form: { - identity: process.env.USERNAME, + identity: process.env.LOGIN, password: process.env.PASSWORD, }, json: true,
3
diff --git a/app/postgresql/error_handler.js b/app/postgresql/error_handler.js @@ -16,7 +16,10 @@ ErrorHandler.prototype.getMessage = function() { // `57014: query_canceled` includes other queries than `statement timeout`, otherwise we could do something more // straightforward like: // return conditionToMessage[this.err.code] || this.err.message; - if (message && message.match(/statement timeout/)) { + if (message && + (message.match(/statement timeout/) || + message === 'RuntimeError: Execution of function interrupted by signal') + ) { message = conditionToMessage[pgErrorCodes.conditionToCode.query_canceled]; }
9
diff --git a/package.json b/package.json }, "devDependencies": { "@11ty/eleventy-plugin-syntaxhighlight": "^2.0.1", - "ava": "^1.3.1", + "ava": "^1.4.1", "husky": "^1.3.1", - "lint-staged": "^8.1.0", + "lint-staged": "^8.1.5", "markdown-it-emoji": "^1.4.0", "nyc": "^13.3.0", - "prettier": "^1.15.3", + "prettier": "^1.16.4", "viperhtml": "^2.17.0", - "vue": "^2.5.22", - "vue-server-renderer": "^2.5.22" + "vue": "^2.6.10", + "vue-server-renderer": "^2.6.10" }, "dependencies": { "browser-sync": "^2.26.3", "chalk": "^2.4.2", - "chokidar": "^2.0.4", + "chokidar": "^2.1.5", "debug": "^4.1.1", "dependency-graph": "^0.8.0", "dependency-tree": "^6.3.0", "ejs": "^2.6.1", "fast-glob": "^2.2.6", "fs-extra": "^7.0.1", - "gray-matter": "^4.0.1", + "gray-matter": "^4.0.2", "hamljs": "^0.6.2", - "handlebars": "^4.1.0", "javascript-stringify": "^1.6.0", "liquidjs": "^6.2.0", + "handlebars": "^4.1.1", "lodash": "^4.17.11", - "luxon": "^1.9.0", + "luxon": "^1.12.0", "markdown-it": "^8.4.2", "minimist": "^1.2.0", "moo": "^0.5.0", "multimatch": "^3.0.0", "mustache": "^2.3.0", "normalize-path": "^3.0.0", - "nunjucks": "^3.1.7", + "nunjucks": "^3.2.0", "parse-filepath": "^1.0.2", "please-upgrade-node": "^3.1.1", "pretty": "^2.0.0", "pug": "^2.0.3", - "recursive-copy": "^2.0.9", "semver": "^5.6.0", + "recursive-copy": "^2.0.10", "slugify": "^1.3.4", "time-require": "^0.1.2", "valid-url": "^1.0.9"
3
diff --git a/lib/waterline/utils/query/forge-stage-three-query.js b/lib/waterline/utils/query/forge-stage-three-query.js @@ -312,6 +312,11 @@ module.exports = function forgeStageThreeQuery(options) { singularAssocAttrNames.push(populateAttribute); } + if (parentAttr.collection && schemaAttribute.columnName) { + console.warn('Ignoring `columnName` setting for collection `' + attrDefToPopulate + '` on attribute `' + populateAttribute + '`.'); + delete schemaAttribute.columnName; + } + // Build the initial join object that will link this collection to either another collection // or to a junction table. var join = {
8
diff --git a/package.json b/package.json "grunt": "^1.0.1", "json-honey": "^0.4.1", "merge": "^1.2.0", - "meteor-build-client": "^0.4.1", "mkdirp": "^0.5.1", - "read-yaml": "^1.0.0", "request": "^2.75.0", "serve-static": "^1.11.1", "shelljs": "^0.5.0",
2
diff --git a/src/components/routes/checkout/CreditCard.vue b/src/components/routes/checkout/CreditCard.vue <template> <el-form ref="form" :model="form" :rules="rules" class="_credit-card __form-sm"> <el-form-item :label="$t('card.number')" prop="number"> - <el-input v-model="form.number" v-mask="cardMask"></el-input> + <el-input v-model="form.number" v-mask="cardMask" v-on-keyup="getBrand"></el-input> </el-form-item> + <div class="_cc-icons"> + <i v-for="brand in brands" :class="[ brand, { active: activeBrand === brand }]"></i> + </div> + <el-form-item :label="$t('card.name')" prop="name"> + <el-input v-model="form.name"></el-input> + </el-form-item> <el-form-item :label="$t('card.validate')" prop="validate"> <el-input v-model="form.validate" placeholder="02 / 22" class="__input-sm"></el-input> </el-form-item> - - <el-form-item :label="$t('card.name')" prop="name"> - <el-input v-model="form.name"></el-input> - </el-form-item> <el-form-item :label="$t('card.securityCode')" prop="cvv"> - <el-input v-model="form.cvv" v-mask="'9{3,4}'" placeholder="123"></el-input> + <el-input v-model="form.cvv" v-mask="'9{3,4}'" placeholder="123" class="__input-sm"></el-input> </el-form-item> </el-form> </template> <script> +import cardValidator from 'card-validator' + export default { name: 'CreditCard', @@ -30,6 +34,16 @@ export default { let rules = {} return { + brands: [ + 'visa', + 'mastercard', + 'american-express', + 'elo', + 'diners-club', + 'hiper', + 'hipercard' + ], + activeBrand: '', form: { number: '', name: '', @@ -60,6 +74,16 @@ export default { }, methods: { + getBrand () { + // get card brand from number + let valid = cardValidator.number(this.form.number.replace(/\D/g, '')) + if (valid.isPotentiallyValid && valid.card) { + this.activeBrand = valid.card.type + } else { + // unset last active brand + this.activeBrand = '' + } + } } } </script> @@ -71,4 +95,42 @@ export default { ._credit-card { max-width: 550px; } +._cc-icons { + margin: -$--card-padding * .75 auto $--card-padding * .75 auto; + text-align: center; +} +._cc-icons i { + width: 40px; + height: 25px; + background-image: url('../../../../static/payments.png'); + background-repeat: no-repeat; + display: inline-block; + margin: 3px 3px 0 0; + transition: $--fade-linear-transition; + opacity: .4; +} +._cc-icons i.active { + opacity: 1; +} +._cc-icons .visa { + background-position: 0 0; +} +._cc-icons .mastercard { + background-position: 0 -50px; +} +._cc-icons .hipercard { + background-position: 0 -125px; +} +._cc-icons .hiper { + background-position: 0 -150px; +} +._cc-icons .elo { + background-position: 0 -175px; +} +._cc-icons .diners-club { + background-position: 0 -200px; +} +._cc-icons .american-express { + background-position: 0 -375px; +} </style>
9
diff --git a/plugins/AutoScroll/README.md b/plugins/AutoScroll/README.md @@ -49,9 +49,11 @@ Demo: #### `scrollFn` option -Defines function that will be used for autoscrolling. el.scrollTop/el.scrollLeft is used by default. Useful when you have custom scrollbar with dedicated scroll function. -This function should return `'continue'` if it wishes to allow Sortable's native autoscrolling. +Defines a function that will be used for autoscrolling. Sortable uses el.scrollTop/el.scrollLeft by default. Set this option if you wish to handle it differently. +This function should return `'continue'` if it wishes to allow Sortable's native autoscrolling, otherwise Sortable will not scroll anything if this option is set. + +**Note that this option will only work on all browsers/devices if Sortable's `forceFallback: true` option is set.** --- @@ -60,6 +62,8 @@ This function should return `'continue'` if it wishes to allow Sortable's native #### `scrollSensitivity` option Defines how near the mouse must be to an edge to start scrolling. +**Note that this option will only work on all browsers/devices if Sortable's `forceFallback: true` option is set.** + --- @@ -67,6 +71,8 @@ Defines how near the mouse must be to an edge to start scrolling. #### `scrollSpeed` option The speed at which the window should scroll once the mouse pointer gets within the `scrollSensitivity` distance. +**Note that this option will only work on all browsers/devices if Sortable's `forceFallback: true` option is set.** + ---
7
diff --git a/source/agent/video/videoMixer/VideoMixer.cpp b/source/agent/video/videoMixer/VideoMixer.cpp @@ -215,7 +215,8 @@ void VideoMixer::closeAll() auto it = m_inputs.begin(); while (it != m_inputs.end()) { - m_frameMixer->removeInput(*it++); + m_frameMixer->removeInput(*it); + it++; } m_inputs.clear();
5
diff --git a/.github/workflows/createNewVersion.yml b/.github/workflows/createNewVersion.yml @@ -35,7 +35,7 @@ jobs: - uses: Expensify/App/.github/actions/composite/setupGitForOSBotify@main with: - GPG_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} + GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} - name: Create new branch run: | @@ -74,7 +74,7 @@ jobs: TARGET_BRANCH: main SOURCE_BRANCH: ${{ env.VERSION_BRANCH }} OS_BOTIFY_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }} - GPG_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }} + GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} - if: ${{ failure() }} uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main
10
diff --git a/source/converter/contracts/Converter.sol b/source/converter/contracts/Converter.sol @@ -128,7 +128,7 @@ contract Converter is Ownable, ReentrancyGuard, TokenPaymentSplitter { path = getTokenPath(_swapFromToken); } // Approve token for AMM usage. - IERC20(_swapFromToken).safeIncreaseAllowance(address(uniRouter), tokenBalance); + IERC20(_swapFromToken).safeIncreaseAllowance(uniRouter, tokenBalance); // Calls the swap function from the on-chain AMM to swap token from fee pool into reward token. IUniswapV2Router02(uniRouter) .swapExactTokensForTokensSupportingFeeOnTransferTokens(
2
diff --git a/lambda/fulfillment/lib/middleware/lexRouter.js b/lambda/fulfillment/lib/middleware/lexRouter.js @@ -107,18 +107,19 @@ async function processResponse(req, res, hook, msg) { let botResp = await handleRequest(req, res, hook, "$LATEST"); console.log("botResp: " + JSON.stringify(botResp,null,2)); - var plainMessage = undefined; + var plainMessage = botResp.message; var ssmlMessage = undefined; - // if messsage contains SSML tags, strip for plain text, but preserve for SSML - if (botResp.message) { - plainMessage = botResp.message.replace(/<\/?[^>]+(>|$)/g, ""); + // if messsage contains SSML tags, strip tags for plain text, but preserve tags for SSML + if (plainMessage && plainMessage.includes("<speak>")) { ssmlMessage = botResp.message ; + plainMessage = plainMessage.replace(/<\/?[^>]+(>|$)/g, ""); } let elicitResponseLoopCount =_.get(res,"session.elicitResponseLoopCount"); if (botResp.dialogState === 'ConfirmIntent') { res.session.elicitResponseProgress = 'ConfirmIntent'; res.plainMessage = plainMessage; - if (req._event.outputDialogMode !== "Text") { + // if SSML tags were present, and we're not in text client mode, build SSML response + if (ssmlMessage && req._event.outputDialogMode !== "Text") { res.type = "SSML"; res.message = ssmlMessage; } else {
1
diff --git a/src/pages/signin/PasswordForm.js b/src/pages/signin/PasswordForm.js @@ -118,8 +118,6 @@ PasswordForm.defaultProps = defaultProps; export default compose( withRouter, withOnyx({ - account: { - key: ({match}) => `${ONYXKEYS.COLLECTION.REPORT}${match.params.reportID}`, - }, + account: {key: ONYXKEYS.ACCOUNT}, }), )(PasswordForm);
4
diff --git a/app/views/taxa/_form.html.erb b/app/views/taxa/_form.html.erb <%= f.text_field :parent_id, value: taxon.parent_id, class: "text", disabled: !@protected_attributes_editable %><br/> <%= label_tag t(:parent_name) %><br/> - <%= text_field_tag :parent_name, ( parent = taxon.parent ) ? parent.name : "", id: "parent_name", class: "text", disabled: !@protected_attributes_editable %> + <%= text_field_tag :parent_name, ( parent = taxon.parent rescue nil ) ? parent.name : "", id: "parent_name", class: "text", disabled: !@protected_attributes_editable %> <% if @protected_attributes_editable %> <%= link_to_function t(:browse_all_species), "$('#taxonchooser').jqmShow();" %> <% end %>
1
diff --git a/lib/assets/core/test/spec/cartodb3/deep-insights-integration/widgets-integration.spec.js b/lib/assets/core/test/spec/cartodb3/deep-insights-integration/widgets-integration.spec.js @@ -64,6 +64,11 @@ describe('deep-insights-integrations/widgets-integration', function () { this.integration._widgetDefinitionsCollection.off(); this.integration = null; document.body.removeChild(mapElement); + var nodes = document.querySelectorAll('.CDB-Widget-tooltip'); + [].slice.call(nodes).forEach(function (node) { + var parent = node.parentNode; + parent.removeChild(node); + }); jasmine.Ajax.uninstall(); }); @@ -321,12 +326,6 @@ describe('deep-insights-integrations/widgets-integration', function () { Backbone.ajax = originalAjax; category.trigger('destroy', category); histogram.trigger('destroy', category); - - var nodes = document.querySelectorAll('.CDB-Widget-tooltip'); - [].slice.call(nodes).forEach(function (node) { - var parent = node.parentNode; - parent.removeChild(node); - }); }); it('should cancel autostyle on remove widget', function () {
2
diff --git a/gulpfile.js b/gulpfile.js @@ -943,7 +943,7 @@ function searchDescriptionForUnlinkedReference(description, regularExpression) { function isSourceValid(source) { // NOTE: One day this should be changed if they publish further Core books (Galaxy Exploration Manual included for posterity) - const CoreBooksSourceMatch = [...source.matchAll(/(CRB|AR|PW|COM|SOM|NS|GEM|TR) pg\. [\d]+/g)]; + const CoreBooksSourceMatch = [...source.matchAll(/(CRB|AR|PW|COM|SOM|NS|GEM|TR|GM) pg\. [\d]+/g)]; // NOTE: One day this should be increased when they publish further Alien Archives (Alien Archive 5 included for posterity) const AlienArchiveSourceMatch = [...source.matchAll(/AA([1-5]) pg\. [\d]+/g)]; const AdventurePathSourceMatch = [...source.matchAll(/AP #[\d]+ pg\. [\d]+/g)];
3
diff --git a/src/api/nw_window_api.cc b/src/api/nw_window_api.cc @@ -354,8 +354,10 @@ bool NwCurrentWindowInternalClearMenuFunction::RunAsync() { browser_view_layout->set_menu_bar(NULL); native_app_window_views->layout_(); native_app_window_views->SchedulePaint(); + if (window->menu_) { window->menu_->RemoveKeys(); window->menu_ = NULL; + } #endif return true; }
1
diff --git a/src/server/routes/attachment.js b/src/server/routes/attachment.js @@ -47,21 +47,32 @@ module.exports = function(crowi, app) { /** * Common method to response * + * @param {Request} req * @param {Response} res * @param {User} user * @param {Attachment} attachment * @param {boolean} forceDownload */ - async function responseForAttachment(res, user, attachment, forceDownload) { + async function responseForAttachment(req, res, attachment, forceDownload) { if (attachment == null) { return res.json(ApiResponse.error('attachment not found')); } + const user = req.user; const isAccessible = await isAccessibleByViewer(user, attachment); if (!isAccessible) { return res.json(ApiResponse.error(`Forbidden to access to the attachment '${attachment.id}'`)); } + // add headers before evaluating 'req.fresh' + setHeaderToRes(req, res, attachment, forceDownload); + + // return 304 if request is "fresh" + // see: http://expressjs.com/en/5x/api.html#req.fresh + if (req.fresh) { + return res.sendStatus(304); + } + let fileStream; try { fileStream = await fileUploader.findDeliveryFile(attachment); @@ -71,7 +82,6 @@ module.exports = function(crowi, app) { return res.json(ApiResponse.error(e.message)); } - setHeaderToRes(res, attachment, forceDownload); return fileStream.pipe(res); } @@ -82,15 +92,17 @@ module.exports = function(crowi, app) { * @param {Attachment} attachment * @param {boolean} forceDownload */ - function setHeaderToRes(res, attachment, forceDownload) { + function setHeaderToRes(req, res, attachment, forceDownload) { + res.set({ + ETag: `Attachment-${attachment._id}`, + 'Last-Modified': attachment.createdAt, + }); + // download if (forceDownload) { - const headers = { - 'Content-Type': 'application/force-download', - 'Content-Disposition': `inline;filename*=UTF-8''${encodeURIComponent(attachment.originalName)}`, - }; - - res.writeHead(200, headers); + res.set({ + 'Content-Disposition': `attachment;filename*=UTF-8''${encodeURIComponent(attachment.originalName)}`, + }); } // reference else { @@ -134,7 +146,7 @@ module.exports = function(crowi, app) { const attachment = await Attachment.findById(id); - return responseForAttachment(res, req.user, attachment, true); + return responseForAttachment(req, res, attachment, true); }; /** @@ -149,7 +161,7 @@ module.exports = function(crowi, app) { const attachment = await Attachment.findById(id); - return responseForAttachment(res, req.user, attachment); + return responseForAttachment(req, res, attachment); }; /**
7
diff --git a/assets/js/components/ErrorHandler/index.js b/assets/js/components/ErrorHandler/index.js @@ -25,8 +25,8 @@ import PropTypes from 'prop-types'; * WordPress dependencies */ import { Component, createRef } from '@wordpress/element'; -import { Dashicon } from '@wordpress/components'; import { __ } from '@wordpress/i18n'; +import { Icon, check, stack } from '@wordpress/icons'; /** * Internal dependencies @@ -102,12 +102,7 @@ class ErrorHandler extends Component { </Link> ); - const icon = ( - <Dashicon - className="googlesitekit-margin-right-1 googlesitekit-dashicons-fill-white" - icon={ copied ? 'yes' : 'clipboard' } - /> - ); + const icon = <Icon icon={ copied ? check : stack } />; return ( <Notification
14
diff --git a/articles/connections/enterprise/adfs.md b/articles/connections/enterprise/adfs.md @@ -119,4 +119,8 @@ Yes, running the script is definitely easier. ## Next steps -After you configure the connection, you have to configure your application to use it. You can initiate login using [Lock](/libraries/lock), [Auth0.js](/libraries/auth0js), or use the [Authentication API endpoint](/api/authentication?http#enterprise-saml-and-others-). For detailed instructions and samples for a variety of technologies, refer to our [Quickstarts](/quickstarts). +After you configure the connection, you have to configure your application to use it. You can initiate login using [Lock](/libraries/lock), [Auth0.js](/libraries/auth0js), or use the [Authentication API endpoint](/api/authentication?http#enterprise-saml-and-others-). + +For detailed instructions and samples for a variety of technologies, refer to our [Quickstarts](/quickstarts). + +We also have a blog post that shows how to [Authenticate PHP with ADFS using Auth0](https://auth0.com/authenticate/php/adfs).
0
diff --git a/package.json b/package.json "docker-build-image": "docker build -t js-framework-benchmark-ubuntu -f Dockerfile .", "docker-start": "cross-env-shell docker run --rm -d -p 8080:8080 --name js-framework-benchmark --volume ${INIT_CWD}:/src --volume js-framework-benchmark:/build js-framework-benchmark-ubuntu", "docker-stop": "docker stop js-framework-benchmark", - "docker-sync": "docker exec -it js-framework-benchmark rsync -avC --exclude /index.html --exclude /framework/**/dist --exclude /webdriver-ts*/dist --exclude package-lock.json --exclude node_modules --exclude /webdriver-ts/results*/ /src/ /build/", - "docker-build-frameworks": "npm run docker-sync && docker exec -it js-framework-benchmark npm install && docker exec -it js-framework-benchmark node build.js", + "docker-sync": "docker exec -it js-framework-benchmark rsync -avC --exclude /index.html --exclude /framework/**/dist --exclude /webdriver-ts*/dist --exclude node_modules --exclude /webdriver-ts/results*/ /src/ /build/", + "docker-sync-package-lock-back": "docker exec -it js-framework-benchmark bash sync-package-lock.sh", + "docker-build-frameworks": "npm run docker-sync && docker exec -it js-framework-benchmark npm install && docker exec -it js-framework-benchmark node docker-rebuil-all.js", "docker-install-webdriver": "npm run docker-sync && docker exec -it js-framework-benchmark npm run install-local", "docker-create-index": "docker exec -it -w /build/webdriver-ts js-framework-benchmark npm run index", "docker-rebuild": "docker exec -it js-framework-benchmark cp /src/docker-rebuild.js /build/ && docker exec -it js-framework-benchmark node docker-rebuild.js",
7
diff --git a/vr-ui.js b/vr-ui.js @@ -1276,6 +1276,37 @@ p { </div> `; }; +const _makeMenuString = () => { + const w = uiSize; + const h = uiSize; + return `\ +<style> +* { + box-sizing: border-box; +} +.body { + display: flex; + width: ${w}px; + height: ${h}px; + background-color: #CCC; + font-family: 'Bangers'; + font-size: 100px; +} +nav { + display: flex; + padding: 30px; + background-color: #333; + color: #FFF; + justify-content: center; + align-items: center; +} +</style> +<div class=body> + <h1>Menu</h1> + <nav>Button</nav> +</div> +`; +}; const makeIconMesh = () => { const geometry = _flipUvs( new THREE.PlaneBufferGeometry(1, 1/2) @@ -1345,6 +1376,110 @@ const makeIconMesh = () => { return mesh; }; +const makeMenuMesh = cubeMesh => { + const canvasWidth = uiSize; + const canvasHeight = uiSize; + const worldWidth = 1; + const worldHeight = 1; + + const geometry = _flipUvs( + new THREE.PlaneBufferGeometry(1, 1) + // .applyMatrix4(new THREE.Matrix4().makeTranslation(0, uiWorldSize / 2, 0)) + ); + const texture = new THREE.Texture( + null, + THREE.UVMapping, + THREE.ClampToEdgeWrapping, + THREE.ClampToEdgeWrapping, + THREE.LinearFilter, + THREE.LinearMipMapLinearFilter, + THREE.RGBAFormat, + THREE.UnsignedByteType, + 16, + THREE.LinearEncoding, + ); + const material = new THREE.MeshBasicMaterial({ + map: texture, + side: THREE.DoubleSide, + // transparent: true, + // alphaTest: 0.7, + }); + const mesh = new THREE.Mesh(geometry, material); + mesh.visible = false; + mesh.frustumCulled = false; + + const highlightMesh = (() => { + const geometry = new THREE.BoxBufferGeometry(1, 1, 0.001); + const material = new THREE.MeshBasicMaterial({ + color: 0x42a5f5, + transparent: true, + opacity: 0.5, + }); + const mesh = new THREE.Mesh(geometry, material); + mesh.frustumCulled = false; + mesh.visible = false; + return mesh; + })(); + mesh.add(highlightMesh); + mesh.highlightMesh = highlightMesh; + + let anchors = []; + mesh.update = () => { + const htmlString = _makeMenuString(); + uiRenderer.render(htmlString, canvasWidth, canvasHeight) + .then(result => { + // imageData.data.set(result.data); + // ctx.putImageData(imageData, 0, 0); + // ctx.drawImage(result.data, 0, 0); + texture.image = result.data; + texture.needsUpdate = true; + + anchors = result.anchors; + // console.log(anchors); + }); + }; + mesh.getAnchors = () => anchors; + mesh.click = anchor => { + console.log('click anchor', anchor); + /* const match = anchor.id.match(/^tile-([0-9]+)-([0-9]+)$/); + const i = parseInt(match[1], 10); + const j = parseInt(match[2], 10); + onclick(tiles[i][j]); */ + }; + mesh.intersect = localIntersections => { + highlightMesh.visible = false; + + let currentAnchor = null; + const [{point, face, uv, object}] = localIntersections; + cubeMesh.position.copy(point); + cubeMesh.quaternion.setFromUnitVectors(localVector.set(0, 0, 1), localVector2.copy(face.normal).applyQuaternion(object.quaternion)); + cubeMesh.visible = true; + + localVector2D.copy(uv); + // localVector2D.y = 1 - localVector2D.y; + localVector2D.x *= canvasWidth; + localVector2D.y *= canvasHeight; + + for (let i = 0; i < anchors.length; i++) { + const anchor = anchors[i]; + const {top, bottom, left, right, width, height} = anchor; + if (localVector2D.x >= left && localVector2D.x < right && localVector2D.y >= top && localVector2D.y < bottom) { + currentAnchor = anchor; + + highlightMesh.position.x = -worldWidth/2 + (left + width/2) / canvasWidth * worldWidth; + highlightMesh.position.y = worldHeight/2 - (top + height/2) / canvasHeight * worldHeight; + highlightMesh.scale.x = width / canvasWidth * worldWidth; + highlightMesh.scale.y = height / canvasHeight * worldHeight; + highlightMesh.visible = true; + break; + } + } + return currentAnchor; + }; + mesh.update(); + + return mesh; +}; /* const makeUiMesh = (label, tiles, onclick) => { const geometry = _flipUvs( new THREE.PlaneBufferGeometry(uiWorldSize, uiWorldSize)
0
diff --git a/src/lib/blocks.js b/src/lib/blocks.js @@ -126,16 +126,9 @@ export default function (vm) { }; ScratchBlocks.Blocks.sensing_of_object_menu.init = function () { - const start = [ + const json = jsonForMenuBlock('OBJECT', spriteMenu, sensingColors, [ ['Stage', '_stage_'] - ]; - if (vm.editingTarget) { - start.splice(0, 0, - [vm.editingTarget.sprite.name, vm.editingTarget.sprite.name] - ); - } - - const json = jsonForMenuBlock('OBJECT', spriteMenu, sensingColors, start); + ]); this.jsonInit(json); };
13
diff --git a/components/StatementsDiscussion/StatementDiscussion.js b/components/StatementsDiscussion/StatementDiscussion.js @@ -9,6 +9,7 @@ import CommentsOptions from '../Discussion/CommentsOptions' import { useRouter } from 'next/router' import StatementNodeWrapper from './StatementNodeWrapper' import DiscussionComposerWrapper from '../Discussion/DiscussionProvider/components/DiscussionComposerWrapper' +import { getFocusHref } from '../Discussion/CommentLink' const StatementDiscussion = ({ t, tagMappings }) => { const { @@ -41,9 +42,16 @@ const StatementDiscussion = ({ t, tagMappings }) => { const handleReload = e => { e.preventDefault() + const href = getFocusHref(discussion) + if (href) { + router.replace(href).then(() => { refetch({ - discussionId: discussion.id + focusId: undefined + }) }) + } else { + refetch() + } } return (
14
diff --git a/ChatImprovements.user.js b/ChatImprovements.user.js // @description New responsive userlist with usernames and total count, more timestamps, use small signatures only, mods with diamonds, message parser (smart links), timestamps on every message, collapse room description and room tags, mobile improvements, expand starred messages on hover, highlight occurances of same user link, room owner changelog, pretty print styles, and more... // @homepage https://github.com/samliew/SO-mod-userscripts // @author @samliew -// @version 2.16.2 +// @version 2.16.3 // // @include https://chat.stackoverflow.com/* // @include https://chat.stackexchange.com/* <div class="content">${msg.html}</div> <span class="meta"><span class="newreply" data-mid="${msg.id}" title="link my next chat message as a reply to this"></span></span> <span class="flash"><span class="stars vote-count-container"><span class="img vote" title="star this message as useful / interesting for the transcript"></span><span class="times">${msg.stars > 0 ? msg.stars : ''}</span></span></span> -</div>`) - .click(function() { - $(this).remove(); - }); +</div>`); message.addClass('show-parent-dialog').prepend(parentDialog); }); return false; const input = document.getElementById('input'); input.value = ':' + this.dataset.mid + ' ' + input.value.replace(/^:\d+\s*/, ''); return false; + }).on('click', 'a', function(evt) { + evt.stopPropagation(); + return true; }); }
11
diff --git a/platform_services/index.js b/platform_services/index.js @@ -59,13 +59,13 @@ module.exports.handler = (event, context, cb) => { global.services_table = config.services_table; global.userId = event.principalId; - var getAllRecords; - if(event.query && event.query.limit && event.query.limit == 10){ + var getAllRecords = true; + /*if(event.query && event.query.limit && event.query.limit == 10){ getAllRecords = false; } else{ getAllRecords = true; - } + }*/ /* if(event.query && event.query.allServices){ getAllRecords = true;
12
diff --git a/templates/master/cognito/invite.txt b/templates/master/cognito/invite.txt <p>Welcome to QnABot! Your temporary password is: <p> {####} <p> -<p>When the CloudFormation stack is COMPLETE (in approxmately 30 minutes), use the link below to log in to QnABot Content Designer, set your permanent password, and start building your bot! +<p>When the CloudFormation stack is COMPLETE, use the link below to log in to QnABot Content Designer, set your permanent password, and start building your bot! <p> ${ApiUrl.Name}/pages/designer <p> <p>Good luck!
2
diff --git a/src/plugins/notify.js b/src/plugins/notify.js @@ -149,24 +149,13 @@ function init ({ $q, Vue }) { }) this.__vm.$mount(node) - $q.notify = this.create.bind(this) } export default { create (opts) { - if (isSSR) { - return - } - - if (this.__vm !== void 0) { - return this.__vm.add(opts) + if (!isSSR) { + this.__vm.add(opts) } - - ready(() => { - setTimeout(() => { - this.create(opts) - }) - }) }, __installed: false, @@ -174,10 +163,10 @@ export default { if (this.__installed) { return } this.__installed = true + console.log('install') if (!isSSR) { - ready(() => { init.call(this, args) - }) } + args.$q.notify = this.create.bind(this) } }
1
diff --git a/README.md b/README.md @@ -15,8 +15,7 @@ but also from various other fields. Examples on the web can be seen [here](http://science-to-touch.com/CJS/). -There is also [an `examples` directory] -(https://github.com/CindyJS/CindyJS/tree/master/examples) +There is also [an `examples` directory](https://github.com/CindyJS/CindyJS/tree/master/examples) inside the repository, demonstrating individual functions and operations. Developers can run these examples from their local development copy. @@ -79,16 +78,13 @@ and are accompanied by a suitable test case or demonstrating example ## Documentation -[The CindyJS API documentation] -(https://github.com/CindyJS/CindyJS/blob/master/ref/createCindy.md) +[The CindyJS API documentation](https://github.com/CindyJS/CindyJS/blob/master/ref/createCindy.md) describes how to create a widget on an HTML page using this framework. -Other documentation in [the `ref` directory] -(https://github.com/CindyJS/CindyJS/tree/master/ref) describes +Other documentation in [the `ref` directory](https://github.com/CindyJS/CindyJS/tree/master/ref) describes large portions of the CindyScript programming language. This documentation, however, started as a copy of -[the corresponding Cinderella documentation] -(http://doc.cinderella.de/tiki-index.php?page=CindyScript). It +[the corresponding Cinderella documentation](http://doc.cinderella.de/tiki-index.php?page=CindyScript). It is currently meant as a goal of what functionality *should* be supported, while actual support might still be lagging behind. If there is a particular feature you'd need for your work, don't hesitate to
1
diff --git a/src/components/MenuItem.js b/src/components/MenuItem.js @@ -110,7 +110,9 @@ const MenuItem = props => ( </View> <View style={[styles.flexRow, styles.menuItemTextContainer]}> {props.badgeText && <Badge text={props.badgeText} badgeStyles={[styles.alignSelfCenter]} />} - {props.subtitle && ( + + {/* Since props.subtitle can be of type number, we should allow 0 to be shown */} + {(props.subtitle || props.subtitle === 0) && ( <View style={[styles.justifyContentCenter, styles.mr1]}> <Text style={styles.textLabelSupporting}
11
diff --git a/src/lambda/handler-runner/in-process-runner/InProcessRunner.js b/src/lambda/handler-runner/in-process-runner/InProcessRunner.js @@ -34,8 +34,11 @@ const clearModule = (fP, opts) => { const cld = require.cache[filePath].children delete require.cache[filePath] for (const c of cld) { - // Unload any non node_modules children - if (!c.filename.match(/node_modules/)) { + // Unload any non node_modules and non-binary children + if ( + !c.filename.match(/\/node_modules\//i) && + !c.filename.match(/\.node$/i) + ) { clearModule(c.id, { ...options, cleanup: false }) } } @@ -51,7 +54,8 @@ const clearModule = (fP, opts) => { require.cache[fn].parent && require.cache[fn].parent.id !== '.' && !require.cache[require.cache[fn].parent.id] && - !fn.match(/node_modules/) + !fn.match(/\/node_modules\//i) && + !fn.match(/\.node$/i) ) { delete require.cache[fn] cleanup = true
0
diff --git a/.circleci/config.yml b/.circleci/config.yml @@ -7,14 +7,14 @@ jobs: - checkout - restore_cache: keys: - - 'v1.0-dependencies-{{ checksum "package.json" }}' + - 'v1.0-dependencies-{{ checksum "package-lock.json" }}' - v1.0-dependencies- - run: npm install - run: npm run lint - save_cache: paths: - node_modules - key: 'v1.0-dependencies-{{ checksum "package.json" }}' + key: 'v1.0-dependencies-{{ checksum "package-lock.json" }}' - persist_to_workspace: root: . paths:
3
diff --git a/docs/track_types.rst b/docs/track_types.rst @@ -73,11 +73,7 @@ Gene annotations display the locations of genes and their exons and introns. The tracks displayed on HiGlass show a transcript consisting of the union of all annotated exons in refseq. There are separate tracks for the different available species. Details on how gene annotation tracks are created is available -in the `gene annotations section <gene_annotations.html>`_. - -**Demos:** - -- `Standard vs Customize Gene Annotation Track <examples/gene_annotations.html>`_ +in the `gene annotations section <data_preparation.html#gene-annotation-tracks>`_. Heatmap =======
3
diff --git a/docs/API.md b/docs/API.md # API and Configuration ## Available imports -- `Router` -- `Scene` -- `Tabs` -- `Tabbed Scene` -- `Drawer` -- `Modal` -- `Lightbox` -- `Actions` -- `ActionConst` +- [`Router`](#router) +- [`Scene`](#scene) +- [`Tabs`](#tabs-tabs-or-scene-tabs) +- [`Stack`](#stack) +- [`Tabbed Scene`](#tab-scene-child-scene-within-tabs) +- [`Drawer`](#drawer-drawer-or-scene-drawer) +- [`Modal`](#modals-modal-or-scene-modal) +- [`Lightbox`](#lightbox-lightbox) +- [`Actions`](#actions) +- [`ActionConst`](#actionconst) ## Router:
7
diff --git a/app/src/pages/common/settingsPage/ruleList/movableRuleList.jsx b/app/src/pages/common/settingsPage/ruleList/movableRuleList.jsx @@ -61,6 +61,7 @@ export const MovableRuleList = ({ data, onMove, ...rest }) => { isDraggable isResizable={false} onDragStop={updateItemsOrder} + onLayoutChange={setLayout} cols={1} useCSSTransforms={!isFirefox} draggableHandle=".draggable-field"
4
diff --git a/app/reducers/channels.js b/app/reducers/channels.js @@ -28,7 +28,7 @@ export const UPDATE_SEARCH_QUERY = 'UPDATE_SEARCH_QUERY' export const SET_VIEW_TYPE = 'SET_VIEW_TYPE' export const TOGGLE_PULLDOWN = 'TOGGLE_PULLDOWN' -export const CHANGE_FILTER = 'CHANGE_FILTER' +export const CHANGE_CHANNEL_FILTER = 'CHANGE_CHANNEL_FILTER' // ------------------------------------ // Actions @@ -229,7 +229,7 @@ export function toggleFilterPulldown() { export function changeFilter(filter) { return { - type: CHANGE_FILTER, + type: CHANGE_CHANNEL_FILTER, filter } } @@ -259,7 +259,7 @@ const ACTION_HANDLERS = { [SET_VIEW_TYPE]: (state, { viewType }) => ({ ...state, viewType }), [TOGGLE_PULLDOWN]: state => ({ ...state, filterPulldown: !state.filterPulldown }), - [CHANGE_FILTER]: (state, { filter }) => ({ ...state, filterPulldown: false, filter }) + [CHANGE_CHANNEL_FILTER]: (state, { filter }) => ({ ...state, filterPulldown: false, filter }) } const channelsSelectors = {}
1
diff --git a/src/reducers/staking/index.js b/src/reducers/staking/index.js @@ -2,6 +2,7 @@ import { handleActions } from 'redux-actions' import reduceReducers from 'reduce-reducers' import { updateStaking, switchAccount, ACCOUNT_DEFAULTS } from '../../actions/staking' +import { selectAccount } from '../../actions/account' // sample validator entry // const validator = { @@ -41,6 +42,9 @@ const stakingHandlers = handleActions({ ...payload, } }, + [selectAccount]: () => { + return initialState + } }, initialState) export default reduceReducers(
9
diff --git a/src/@chakra-ui/gatsby-plugin/components/Link.ts b/src/@chakra-ui/gatsby-plugin/components/Link.ts @@ -6,9 +6,10 @@ export const Link: ComponentStyleConfig = { textDecoration: "underline", _focus: { boxShadow: "none", - outline: "1px solid", - outlineColor: "primary", - outlineOffset: "2px", + }, + _focusVisible: { + boxShadow: "none", + outlineStyle: "auto", }, }, }
12
diff --git a/core/worker/lib/helpers/kubernetes.js b/core/worker/lib/helpers/kubernetes.js @@ -57,16 +57,21 @@ class KubernetesApi extends EventEmitter { } } - async waitForTerminatedState(podName, containerName, timeout = 10000) { + async waitForTerminatedState(podName, containerName, timeout = 20000) { const start = Date.now(); do { + log.debug(`waitForTerminatedState for pod ${podName}, container: ${containerName}`, { component }); + const status = await this.getPodContainerStatus(podName); // eslint-disable-line no-await-in-loop const containerStatus = status && status.find(s => s.name === containerName); + log.debug(`waitForTerminatedState for pod ${podName}, container: ${containerName}, status: ${JSON.stringify(containerStatus)}`, { component }); if (containerStatus && containerStatus.terminated) { return true; } await delay(timeout); // eslint-disable-line no-await-in-loop } while (Date.now() - start < 10000); + log.info(`waitForTerminatedState for pod ${podName}, container: ${containerName} timeout waiting for terminated state`, { component }); + return false; }
0