code
stringlengths
122
4.99k
label
int64
0
14
diff --git a/docs/components/openapi.md b/docs/components/openapi.md @@ -10,8 +10,6 @@ The top level class. - [OpenApi.prototype.request()](#openapiprototyperequest) - - [OpenApi.prototype.response()](#openapiprototyperequest) - ### OpenApi.prototype.path Get path parameters and operation from a method and path. @@ -92,7 +90,7 @@ Deserialize and validate a request. - *query* - An `object` map of query parameter names and deserialized and validated values. -- *response* - The `function` [Operation.prototype.reponse()](./operation.md#operationprototyperesponse) +- *response* - A small wrapper around the `function` [Operation.prototype.reponse()](./operation.md#operationprototyperesponse). This will automatically set the response header `content-type` based on the request `accept` header unless you specifically set a response `content-type`. ```js const OpenAPI = require('openapi-enforcer').v3_0.OpenApi @@ -107,7 +105,3 @@ const req = openapi.request({ path: '/path/abc?x=1', }) ``` - -### OpenApi.prototype.response - -This is a pointer to the [Operation.prototype.reponse()](./operation.md#operationprototyperesponse) function.
3
diff --git a/src/encoded/schemas/analysis_step.json b/src/encoded/schemas/analysis_step.json "predicted transcription start sites", "optimal idr thresholded peaks", "conservative idr thresholded peaks", + "pseudoreplicated idr thresholded peaks", "signal p-value", "fold change over control", "replicated peaks", "predicted transcription start sites", "optimal idr thresholded peaks", "conservative idr thresholded peaks", + "pseudoreplicated idr thresholded peaks", "signal p-value", "fold change over control", "replicated peaks",
0
diff --git a/src/assets/stylesheets/index.scss b/src/assets/stylesheets/index.scss @@ -691,6 +691,7 @@ footer { transform: translate(-50%, 20px); box-shadow: 0 0 8px rgba(0, 0, 0, 0.1), 0 -20px 10px rgba(44, 44, 44, 0.04); padding: 10px; + font-size: 14px; } .nav > li > .dropdown-menu:before {
4
diff --git a/docs/introduction/developing-with-threejs.md b/docs/introduction/developing-with-threejs.md @@ -61,7 +61,7 @@ scene graph. ### Accessing the three.js Scene -[scene]: https://threejs.org/docs/#Reference/Scenes/Scene +[scene]: https://threejs.org/docs/#api/scenes/Scene The [three.js scene][scene] is accessible from the `<a-scene>` element as `.object3D`: @@ -90,8 +90,8 @@ AFRAME.registerComponent('foo', { ### Accessing an Entity's three.js Objects -[group]: https://threejs.org/docs/#Reference/Objects/Group -[object3d]: https://threejs.org/docs/#Reference/Core/Object3D +[group]: https://threejs.org/docs/#api/objects/Group +[object3d]: https://threejs.org/docs/#api/core/Object3D Every A-Frame entity (e.g., `<a-entity>`) has its own [`THREE.Object3D`][object3d], more specifically a [`THREE.Group`][group] that @@ -227,8 +227,6 @@ To get the world rotation of an `Object3D`: entityEl.object3D.getWorldRotation(); ``` -[object3d]: https://threejs.org/docs/#api/core/Object3D - three.js `Object3D` has [more functions available for local-to-world transforms][object3d]: - `.localToWorld (vector)`
1
diff --git a/src/kiri/main.js b/src/kiri/main.js currentPrint = kiri.newPrint(settings, WIDGETS); currentPrint.setup(true, function(update, status) { - setProgress(update, status); + API.show.progress(update, status); }, function() { if (!currentPrint) { return setViewMode(VIEWS.ARRANGE); } - setProgress(0); + API.show.progress(0); if (!isCam) setOpacity(0); currentPrint.render(); } // on the last exit, update ui and call the callback if (--countdown === 0 || error || errored) { - setProgress(0); + API.show.progress(0); showSlices(preserveLayer); SPACE.scene.active(); API.event.emit('slice.end', getMode()); forAllWidgets(function(w) { totalProgress += (track[w.id] || 0); }); - setProgress((totalProgress / WIDGETS.length), msg); + API.show.progress((totalProgress / WIDGETS.length), msg); }, true); }); }
11
diff --git a/test/jasmine/tests/config_test.js b/test/jasmine/tests/config_test.js var Plotly = require('@lib/index'); var Plots = Plotly.Plots; +var Lib = require('@src/lib'); var createGraphDiv = require('../assets/create_graph_div'); var destroyGraphDiv = require('../assets/destroy_graph_div'); +var click = require('../assets/click'); var mouseEvent = require('../assets/mouse_event'); describe('config argument', function() { @@ -269,4 +271,119 @@ describe('config argument', function() { }); }); + + describe('axis drag handles attribute', function() { + var mock = require('@mocks/14.json'); + + var gd; + var mockCopy; + + beforeEach(function(done) { + gd = createGraphDiv(); + mockCopy = Lib.extendDeep({}, mock); + done(); + }); + + afterEach(destroyGraphDiv); + + it('should have drag rectangles cursors by default', function() { + Plotly.plot(gd, mockCopy.data, {}); + + var nwdrag = document.getElementsByClassName('drag nwdrag'); + expect(nwdrag.length).toBe(1); + var nedrag = document.getElementsByClassName('drag nedrag'); + expect(nedrag.length).toBe(1); + var swdrag = document.getElementsByClassName('drag swdrag'); + expect(swdrag.length).toBe(1); + var sedrag = document.getElementsByClassName('drag sedrag'); + expect(sedrag.length).toBe(1); + var ewdrag = document.getElementsByClassName('drag ewdrag'); + expect(ewdrag.length).toBe(1); + var wdrag = document.getElementsByClassName('drag wdrag'); + expect(wdrag.length).toBe(1); + var edrag = document.getElementsByClassName('drag edrag'); + expect(edrag.length).toBe(1); + var nsdrag = document.getElementsByClassName('drag nsdrag'); + expect(nsdrag.length).toBe(1); + var sdrag = document.getElementsByClassName('drag sdrag'); + expect(sdrag.length).toBe(1); + var ndrag = document.getElementsByClassName('drag ndrag'); + expect(ndrag.length).toBe(1); + + }); + + it('should not have drag rectangles when disabled', function() { + Plotly.plot(gd, mockCopy.data, {}, { showAxisDragHandles: false }); + + var nwdrag = document.getElementsByClassName('drag nwdrag'); + expect(nwdrag.length).toBe(0); + var nedrag = document.getElementsByClassName('drag nedrag'); + expect(nedrag.length).toBe(0); + var swdrag = document.getElementsByClassName('drag swdrag'); + expect(swdrag.length).toBe(0); + var sedrag = document.getElementsByClassName('drag sedrag'); + expect(sedrag.length).toBe(0); + var ewdrag = document.getElementsByClassName('drag ewdrag'); + expect(ewdrag.length).toBe(0); + var wdrag = document.getElementsByClassName('drag wdrag'); + expect(wdrag.length).toBe(0); + var edrag = document.getElementsByClassName('drag edrag'); + expect(edrag.length).toBe(0); + var nsdrag = document.getElementsByClassName('drag nsdrag'); + expect(nsdrag.length).toBe(0); + var sdrag = document.getElementsByClassName('drag sdrag'); + expect(sdrag.length).toBe(0); + var ndrag = document.getElementsByClassName('drag ndrag'); + expect(ndrag.length).toBe(0); + }); + + }); + + describe('axis range entry attribute', function() { + var mock = require('@mocks/14.json'); + + var gd; + var mockCopy; + + beforeEach(function(done) { + gd = createGraphDiv(); + mockCopy = Lib.extendDeep({}, mock); + done(); + }); + + afterEach(destroyGraphDiv); + + it('show allow axis range entry by default', function() { + Plotly.plot(gd, mockCopy.data, {}); + + var corner = document.getElementsByClassName('edrag')[0]; + + var cornerBox = corner.getBoundingClientRect(), + cornerX = cornerBox.left + cornerBox.width / 2, + cornerY = cornerBox.top + cornerBox.height / 2; + + click(cornerX, cornerY); + + var editBox = document.getElementsByClassName('plugin-editable editable')[0]; + expect(editBox).toBeDefined(); + expect(editBox.getAttribute('contenteditable')).toBe('true'); + }); + + it('show not allow axis range entry when', function() { + Plotly.plot(gd, mockCopy.data, {}, { showAxisRangeEntryBoxes: false }); + + var corner = document.getElementsByClassName('edrag')[0]; + + var cornerBox = corner.getBoundingClientRect(), + cornerX = cornerBox.left + cornerBox.width / 2, + cornerY = cornerBox.top + cornerBox.height / 2; + + click(cornerX, cornerY); + + var editBox = document.getElementsByClassName('plugin-editable editable')[0]; + expect(editBox).toBeUndefined(); + }); + + + }); });
0
diff --git a/lib/node_modules/@stdlib/repl/lib/main.js b/lib/node_modules/@stdlib/repl/lib/main.js @@ -158,7 +158,7 @@ function REPL( options ) { // Initialize an internal data store: setNonEnumerableReadOnly( this, '_internal', {} ); setNonEnumerableReadOnly( this._internal, 'presentation', {} ); - setNonEnumerableReadOnly( this._internal.presentation, 'ids', {} ); + setNonEnumerableReadOnly( this._internal.presentation, 'cache', {} ); setNonEnumerable( this._internal.presentation, 'counter', 0 ); // Initialize an internal command queue:
10
diff --git a/articles/appliance/custom-domains/index.md b/articles/appliance/custom-domains/index.md @@ -8,7 +8,7 @@ description: How to set up custom domains for your PSaaS Appliance If you are using **PSaaS Appliance Build 5XXX** or later, you may configure custom domains using the Management Dashboard. -Custom domains allow you to expose one or more arbitrary DNS names for a tenant. Conventionally, the PSaaS Appliance uses a three-part domain name for access, and it is the first portion of the domain name that varies depending on the tenant. +Custom domains allow you to expose one arbitrary DNS name for a tenant. Conventionally, the PSaaS Appliance uses a three-part domain name for access, and it is the first portion of the domain name that varies depending on the tenant. The root tenant authority (RTA) is a special domain that is configured when the PSaaS Appliance cluster(s) are first set up. It is a privileged tenant from which certain manage operations for the cluster are available. The RTA is sometimes called the configuration domain, and all users that have access to the Management Dashboard belong to an application in the RTA.
2
diff --git a/examples/realitytabs.html b/examples/realitytabs.html @@ -2340,9 +2340,9 @@ function animate(time, frame) { controllerMesh.rayMesh.scale.z = distance; controllerMesh.updateMatrixWorld(); - controllerMesh.rayDot.position.z = -distance; + controllerMesh.dotMesh.position.z = -distance; controllerMesh.updateMatrixWorld(); - controllerMesh.rayDot.visible = true; + controllerMesh.dotMesh.visible = true; const gamepads = navigator.getGamepads(); const gamepad = gamepads[i]; @@ -2369,9 +2369,9 @@ function animate(time, frame) { controllerMesh.rayMesh.scale.z = distance; controllerMesh.updateMatrixWorld(); - controllerMesh.rayDot.position.z = -distance; + controllerMesh.dotMesh.position.z = -distance; controllerMesh.updateMatrixWorld(); - controllerMesh.rayDot.visible = true; + controllerMesh.dotMesh.visible = true; const gamepads = navigator.getGamepads(); const gamepad = gamepads[i];
10
diff --git a/src/MeshBVH.js b/src/MeshBVH.js @@ -52,6 +52,18 @@ export default class MeshBVH { } + // Computes the set of { offset, count } ranges which need independent BVH roots. Each + // region in the geometry index that belongs to a different set of material groups requires + // a separate BVH root, so that triangles indices belonging to one group never get swapped + // with triangle indices belongs to another group. For example, if the groups were like this: + // + // [-------------------------------------------------------------] + // |__________________| + // g0 = [0, 20] |______________________||_____________________| + // g1 = [16, 40] g2 = [41, 60] + // + // we would need four BVH roots: [0, 15], [16, 20], [21, 40], [41, 60]. + // _getRootIndexRanges( geo ) { if ( !geo.groups || !geo.groups.length ) {
0
diff --git a/spec/models/synchronization/member_spec.rb b/spec/models/synchronization/member_spec.rb @@ -208,14 +208,15 @@ describe Synchronization::Member do end it 'keeps indices' do - url = 'https://wadus.com/guess_country.csv' + url = 'https://wadus.com/clubbing.csv' - path = fake_data_path('guess_country.csv') + path = fake_data_path('clubbing.csv') stub_download(url: url, filepath: path, content_disposition: false) - attrs = random_attributes(user_id: @user2.id).merge(service_item_id: url, url: url, name: 'guess_country') + attrs = random_attributes(user_id: @user2.id).merge(service_item_id: url, url: url, name: 'clubbing') member = Synchronization::Member.new(attrs).store + # Create table with index DataImport.create( user_id: @user2.id, data_source: path, @@ -224,13 +225,16 @@ describe Synchronization::Member do service_item_id: url, updated_at: Time.now ).run_import! + @user2.in_database.execute('CREATE INDEX ON clubbing (nombre)') - @user2.in_database.execute('CREATE INDEX ON guess_country (country)') - + # Sync the table member.run expect(member.state).to eq 'success' - indexed_columns = UserTable.first.service.pg_indexes.map { |x| x[:column] } - expected_indices = ['cartodb_id', 'the_geom', 'the_geom_webmercator', 'country'] + + # Expect custom and default indices to still exist + table = UserTable.where(user: @user2, name: 'clubbing').first + indexed_columns = table.service.pg_indexes.map { |x| x[:column] } + expected_indices = ['cartodb_id', 'the_geom', 'the_geom_webmercator', 'nombre'] expect(indexed_columns.sort).to eq(expected_indices.sort) end
7
diff --git a/public/javascripts/Choropleth.js b/public/javascripts/Choropleth.js @@ -133,7 +133,7 @@ function Choropleth(_, $, difficultRegionIds, params, layers, polygonData, polyg i18next.t("common:map.distance-left", { n: distanceLeft }) + "<br>" + advancedMessage + i18next.t("common:map.click-to-help", { url: url, regionId: regionId }); } - if (params.choroplethType === 'results') popupContent += setAccessibilityChoroplethPopupContent(rates[i]) + if (params.choroplethType === 'results') popupContent += setRegionPopupContent(rates[i]) break; } } @@ -282,12 +282,12 @@ function Choropleth(_, $, difficultRegionIds, params, layers, polygonData, polyg } /** - * This function sets the specific popup content of each region of the accessibility choropleth. + * Gets issue count HTML to add to popups on the results page. * - * @param {*} rate Object from which information about labels is retrieved. + * @param {*} polygonData Object from which information about labels is retrieved. */ - function setAccessibilityChoroplethPopupContent(rate) { - var labels = rate.labels; + function setRegionPopupContent(polygonData) { + var labels = polygonData.labels; var counts = {}; for (var j in labelText) { if (typeof labels[j] != 'undefined')
3
diff --git a/js/browser.js b/js/browser.js @@ -191,7 +191,10 @@ var igv = (function (igv) { loadedTracks = []; _.each(configList, function (config) { - loadedTracks.push(self.loadTrack(config)); + var track = self.loadTrack(config); + if (track) { + loadedTracks.push( track ); + } }); // Really we should just resize the new trackViews, but currently there is no way to get a handle on those @@ -226,8 +229,10 @@ var igv = (function (igv) { } newTrack = createTrackWithConfiguration(config); + if (undefined === newTrack) { igv.presentAlert("Unknown file type: " + config.url); + return newTrack; } // Set order field of track here. Otherwise track order might get shuffled during asynchronous load @@ -426,7 +431,7 @@ var igv = (function (igv) { } - }; + } };
8
diff --git a/docs/content/migration-guide.md b/docs/content/migration-guide.md @@ -149,7 +149,7 @@ the [Bootstrap grid docs](https://getbootstrap.com/docs/5.0/layout/grid/#row-col - Added `navbar_scroll` property. This enables vertical scrolling within the toggleable contents of the nav when used inside a collapsed `Navbar`. ### Navbar -- <span class="badge bg-danger">Breaking</span> Bootstrap navbars now must be constructed with a container. If you're using `NavbarSimple` you don't need to make any changes! If you are using `Navbar` with a custom layout you probably will need to make changes. See the [docs](/docs/components/list_group/) for updated examples. +- <span class="badge bg-danger">Breaking</span> Bootstrap navbars now must be constructed with a container. If you're using `NavbarSimple` you don't need to make any changes! If you are using `Navbar` with a custom layout you probably will need to make changes. See the [docs](/docs/components/navbar/) for updated examples. ### Offcanvas <span class="badge bg-success">New</span> - Added the new offcanvas component. See the [docs](/docs/components/offcanvas) for more information.
1
diff --git a/src/client/js/services/AdminGeneralSecurityContainer.js b/src/client/js/services/AdminGeneralSecurityContainer.js @@ -50,6 +50,9 @@ export default class AdminGeneralSecurityContainer extends Container { isHideRestrictedByOwner: generalSetting.hideRestrictedByOwner || false, isHideRestrictedByGroup: generalSetting.hideRestrictedByGroup || false, wikiMode: generalSetting.wikiMode || '', + isLocalEnabled: generalSetting.registrationMode || 'true', + registrationMode: generalSetting.registrationMode || 'open', + registrationWhiteList: generalSetting.registrationWhiteList || '', }); }
12
diff --git a/src/backend.github.js b/src/backend.github.js @@ -195,7 +195,7 @@ let _ = Mavo.Backend.register(class Github extends Mavo.Backend { if (!repoInfo || repoInfo.owner.login !== this.username || repoInfo.name !== this.repo) { // No repo info available, or out of date, fetch it try { - repoInfo = await this.request(`repos/${this.username}/${this.repo}`) + repoInfo = await this.request(repoCall) this.branch ??= repoInfo.default_branch; } catch (e) {
4
diff --git a/core/server/services/auth/authorize.js b/core/server/services/auth/authorize.js const errors = require('@tryghost/errors'); -const i18n = require('../../../shared/i18n'); +const tpl = require('@tryghost/tpl'); + +const messages = { + authorizationFailed: 'Authorization failed', + missingContentMemberOrIntegration: 'Unable to determine the authenticated member or integration. Check the supplied Content API Key and ensure cookies are being passed through if member auth is failing.', + missingAdminUserOrIntegration: 'Unable to determine the authenticated user or integration. Check that cookies are being passed through if using session authentication.' +}; const authorize = { authorizeContentApi(req, res, next) { @@ -12,8 +18,8 @@ const authorize = { return next(); } return next(new errors.NoPermissionError({ - message: i18n.t('errors.middleware.auth.authorizationFailed'), - context: i18n.t('errors.middleware.auth.missingContentMemberOrIntegration') + message: tpl(messages.authorizationFailed), + context: tpl(messages.missingContentMemberOrIntegration) })); }, @@ -25,8 +31,8 @@ const authorize = { return next(); } else { return next(new errors.NoPermissionError({ - message: i18n.t('errors.middleware.auth.authorizationFailed'), - context: i18n.t('errors.middleware.auth.missingAdminUserOrIntegration') + message: tpl(messages.authorizationFailed), + context: tpl(messages.missingAdminUserOrIntegration) })); } }
14
diff --git a/src/core/operations/CharEnc.js b/src/core/operations/CharEnc.js @@ -67,6 +67,7 @@ const CharEnc = { /** * Encode text operation. + * @author tlwr [[email protected]] * * @param {string} input * @param {Object[]} args @@ -81,6 +82,7 @@ const CharEnc = { /** * Decode text operation. + * @author tlwr [[email protected]] * * @param {byteArray} input * @param {Object[]} args
0
diff --git a/tests/e2e/specs/modules/search-console/dashboard-date-range.test.js b/tests/e2e/specs/modules/search-console/dashboard-date-range.test.js @@ -115,8 +115,6 @@ describe( 'date range filtering on dashboard views', () => { mockBatchResponse = last28Days; - await page.waitFor( 250 ); // Delay the next steps. - await Promise.all( [ page.waitForNavigation(), expect( postSearcher ).toClick( 'button', { text: /view data/i } ),
2
diff --git a/generators/server/templates/build.gradle.ejs b/generators/server/templates/build.gradle.ejs See the License for the specific language governing permissions and limitations under the License. -%> -import org.gradle.internal.os.OperatingSystem - buildscript { repositories { mavenLocal() @@ -103,26 +101,6 @@ eclipse { } } -// See https://virgo47.wordpress.com/2018/09/14/classpath-too-long-with-spring-boot-and-gradle/ for details -// https://github.com/jhipster/generator-jhipster/issues/9713 -if (OperatingSystem.current().isWindows()) { - task classpathJar(type: Jar) { - inputs.files sourceSets.main.runtimeClasspath - - archiveName = "runboot-classpath.jar" - doFirst { - manifest { - def classpath = sourceSets.main.runtimeClasspath.files - attributes "Class-Path": classpath.collect {f -> f.toURI().toString()}.join(" ") - } - } - } - - bootRun { - classpath = classpathJar.outputs.files - } -} - defaultTasks "bootRun" springBoot {
2
diff --git a/framer/SVGPath.coffee b/framer/SVGPath.coffee @@ -37,12 +37,12 @@ class exports.SVGPath extends SVGBaseLayer @define "strokeOpacity", layerProperty(@, "strokeOpacity", "strokeOpacity", null, _.isNumber) @define "strokeDasharray", layerProperty(@, "strokeDasharray", "strokeDasharray", [], _.isArray, dashArrayTransform) @define "strokeDashoffset", layerProperty(@, "strokeDashoffset", "strokeDashoffset", null, _.isNumber, parseFloat) - @define "strokeLength", layerProperty @, "strokeLength", null, null, _.isNumber, null, {}, (path, value) -> + @define "strokeLength", layerProperty @, "strokeLength", null, undefined, _.isNumber, null, {}, (path, value) -> path._properties.strokeFraction = value / path.length if _.isEmpty path.strokeDasharray path.strokeDasharray = [path.length] path.strokeDashoffset = path.length - value - @define "strokeFraction", layerProperty @, "strokeFraction", null, null, _.isNumber, null, {}, (path, value) -> + @define "strokeFraction", layerProperty @, "strokeFraction", null, undefined, _.isNumber, null, {}, (path, value) -> path.strokeLength = path.length * value @define "length", get: -> @_length
12
diff --git a/exampleSite/config.toml b/exampleSite/config.toml @@ -20,6 +20,11 @@ googleAnalytics = "" date = ["date", "lastmod"] lastmod = ["lastmod", ":git", "date"] +[markup] + [markup.goldmark] + [markup.goldmark.renderer] + unsafe = true + [params] name = "Okkur Labs" description = "Open Source Theme for your next project"
0
diff --git a/token-metadata/0x587E276Dc7F2C97d986E8AdF9b82D3F14D6cd8d2/metadata.json b/token-metadata/0x587E276Dc7F2C97d986E8AdF9b82D3F14D6cd8d2/metadata.json "symbol": "FYS", "address": "0x587E276Dc7F2C97d986E8AdF9b82D3F14D6cd8d2", "decimals": 9, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/local_modules/SendFundsTab/Views/SendFundsView_Base.web.js b/local_modules/SendFundsTab/Views/SendFundsView_Base.web.js @@ -333,7 +333,7 @@ class SendFundsView extends View const labelLayer = commonComponents_forms.New_fieldTitle_labelLayer("TO", self.context) labelLayer.style.marginTop = "17px" // to square with MEMO field on Send Funds { - const tooltipText = `Please double-check the<br/>accuracy of your recipient<br/>information because Monero<br/>transfers are irreversible.` + const tooltipText = `Drag & drop QR codes<br/>to auto-fill.<br/><br/>Please double-check<br/>your recipient info as<br/>Monero transfers are<br/>not yet&nbsp;reversible.` const view = commonComponents_tooltips.New_TooltipSpawningButtonView(tooltipText, self.context) const layer = view.layer labelLayer.appendChild(layer) // we can append straight to labelLayer as we don't ever change its innerHTML
3
diff --git a/docs/guide.md b/docs/guide.md @@ -252,7 +252,7 @@ Animal.findOne().byName('fido').exec((err, animal) => { <h3 id="indexes"><a href="#indexes">Indexes</a></h3> MongoDB supports [secondary indexes](http://docs.mongodb.org/manual/indexes/). -With mongoose, we define these indexes within our `Schema` [at](./api.html#schematype_SchemaType-index) [the](./api.html#schematype_SchemaType-unique) [path](./api.html#schematype_SchemaType-sparse) [level](./api.html#schema_date_SchemaDate-expires) or the `schema` level. +With mongoose, we define these indexes within our `Schema` [at](./api.html#schematype_SchemaType-index) [the](./api.html#schematype_SchemaType-unique) [path](./api.html#schematype_SchemaType-sparse) [level](./api.html#schemadateoptions_SchemaDateOptions-expires) or the `schema` level. Defining indexes at the schema level is necessary when creating [compound indexes](https://docs.mongodb.com/manual/core/index-compound/).
1
diff --git a/token-metadata/0x261EfCdD24CeA98652B9700800a13DfBca4103fF/metadata.json b/token-metadata/0x261EfCdD24CeA98652B9700800a13DfBca4103fF/metadata.json "symbol": "SXAU", "address": "0x261EfCdD24CeA98652B9700800a13DfBca4103fF", "decimals": 18, - "dharmaVerificationStatus": { "dharmaVerificationStatus": "VERIFIED" } \ No newline at end of file -} \ No newline at end of file
3
diff --git a/lib/cartodb/controllers/layergroup/tile.js b/lib/cartodb/controllers/layergroup/tile.js @@ -41,10 +41,11 @@ module.exports = class TileLayergroupController { } register (mapRouter) { - const number = (param) => `${param}(-?\\d+)`; + const number = () => `(-?\\d+)`; + const not = (val) => `(?!${val})([^\/]+?)`; mapRouter.get( - `/:token/:${number('z')}/:${number('x')}/:${number('y')}@:${number('scale_factor')}?x.:format`, + `/:token/:z${number()}/:x${number()}/:y${number()}@:scale_factor${number()}?x.:format`, layergroupToken(), credentials(), authorize(this.authApi), @@ -69,7 +70,7 @@ module.exports = class TileLayergroupController { ); mapRouter.get( - `/:token/:${number('z')}/:${number('x')}/:${number('y')}.:format`, + `/:token/:z${number()}/:x${number()}/:y${number()}.:format`, layergroupToken(), credentials(), authorize(this.authApi), @@ -94,8 +95,7 @@ module.exports = class TileLayergroupController { ); mapRouter.get( - `/:token/:layer/:${number('z')}/:${number('x')}/:${number('y')}.(:format)`, - distinguishLayergroupFromStaticRoute(), + `/:token${not('static')}/:layer/:z${number()}/:x${number()}/:y${number()}.(:format)`, layergroupToken(), credentials(), authorize(this.authApi), @@ -121,16 +121,6 @@ module.exports = class TileLayergroupController { } }; -function distinguishLayergroupFromStaticRoute () { - return function distinguishLayergroupFromStaticRouteMiddleware(req, res, next) { - if (req.params.token === 'static') { - return next('route'); - } - - next(); - }; -} - function parseFormat (format = '') { const prettyFormat = format.replace('.', '_'); return SUPPORTED_FORMATS[prettyFormat] ? prettyFormat : 'invalid';
7
diff --git a/assets/sass/components/settings/_googlesitekit-settings-notice.scss b/assets/sass/components/settings/_googlesitekit-settings-notice.scss color: $c-text-notice-info; } - .mdc-select__dropdown-icon { - background-image: url("data:image/svg+xml,%3Csvg%20width%3D%2210px%22%20height%3D%225px%22%20viewBox%3D%227%2010%2010%205%22%20version%3D%221.1%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%3E%0A%20%20%20%20%3Cpolygon%20id%3D%22Shape%22%20stroke%3D%22none%22%20fill%3D%22%231a73e8%22%20fill-rule%3D%22evenodd%22%20opacity%3D%221%22%20points%3D%227%2010%2012%2015%2017%2010%22%3E%3C%2Fpolygon%3E%0A%3C%2Fsvg%3E"); - } - &:not(.mdc-select--focused) { .mdc-select__selected-text:hover ~ .mdc-notched-outline {
2
diff --git a/bl-plugins/sitemap/plugin.php b/bl-plugins/sitemap/plugin.php @@ -66,7 +66,6 @@ class pluginSitemap extends Plugin { $xml .= '<url>'; $xml .= '<loc>'.$page->permalink().'</loc>'; $xml .= '<lastmod>'.$page->date(SITEMAP_DATE_FORMAT).'</lastmod>'; - $xml .= '<changefreq>daily</changefreq>'; $xml .= '</url>'; } } catch (Exception $e) {
2
diff --git a/app/shared/actions/system/claimairgrab.js b/app/shared/actions/system/claimairgrab.js @@ -3,7 +3,7 @@ import eos from '../helpers/eos'; import { getTable } from '../table'; const blackListedMethodAttributes = ['to', 'from']; -const whiteListedMethods = ['open', 'signup']; +const whiteListedMethods = ['claim', 'open', 'signup']; export function claimairgrab(airgrab) { return (dispatch: () => void, getState) => {
11
diff --git a/src/actions/channels.js b/src/actions/channels.js @@ -958,29 +958,34 @@ export function markChannelAsRead(channelId, prevChannelId) { // Decrement mention_count and msg_count by the number that was read in the channel. // Note that this works because the values in channelMember are what was unread before this. + if (teamMember && channelMember) { const teamUnread = { team_id: channel.team_id, mention_count: teamMember.mention_count - channelMember.mention_count, msg_count: teamMember.msg_count - (channel.total_msg_count - channelMember.msg_count) }; - if (prevChannel && channel.team_id === prevChannel.team_id) { + if (prevChannel && prevChannelMember && channel.team_id === prevChannel.team_id) { teamUnread.mention_count -= prevChannelMember.mention_count; teamUnread.msg_count -= (prevChannel.total_msg_count - prevChannelMember.msg_count); } teamUnreads.push(teamUnread); } + } if (channel && prevChannel && prevChannel.team_id && channel.team_id !== prevChannel.team_id) { const prevTeamMember = teamState.myMembers[prevChannel.team_id]; + // We need to make sure that the user hasn't left the team + if (prevTeamMember) { teamUnreads.push({ team_id: prevChannel.team_id, mention_count: prevTeamMember.mention_count - prevChannelMember.mention_count, msg_count: prevTeamMember.msg_count - (prevChannel.total_msg_count - prevChannelMember.msg_count) }); } + } if (teamUnreads.length > 0) { actions.push({
9
diff --git a/lib/assets/javascripts/unpoly/proxy.coffee b/lib/assets/javascripts/unpoly/proxy.coffee @@ -159,7 +159,7 @@ up.proxy = (($) -> up.request('/search', data: { query: 'sunshine' }).then(function(response) { console.log('The response text is %o', response.text); - }).fail(function() { + }).catch(function() { console.error('The request failed'); }); @@ -266,7 +266,7 @@ up.proxy = (($) -> up.request('/search', data: { query: 'sunshine' }).then(function(text) { console.log('The response text is %o', text); - }).fail(function() { + }).catch(function() { console.error('The request failed'); });
14
diff --git a/web/bisweb-sw.js b/web/bisweb-sw.js @@ -243,11 +243,11 @@ self.addEventListener('fetch', event => { if (response) { return response; } - return fetch(event.request).then( (response) => { + return fetch(event.request);/*.then( (response) => { caches.open(internal.name).then( (cache) => { cache.put(event.request, response); }); - }); + }*/ }).catch( (e) => { console.log('bisweb-sw: Cache fetch failed; returning online version for', event.request.url,e); })
2
diff --git a/edit.js b/edit.js @@ -779,6 +779,9 @@ const _makeChunkMesh = (seedString, parcelSize, subparcelSize) => { let chunksNeedUpdate = false; let buildMeshesNeedUpdate = false; let packagesNeedUpdate = false; + mesh.updateChunks = () => { + chunksNeedUpdate = true; + }; mesh.updateBuildMeshes = () => { buildMeshesNeedUpdate = true; };
0
diff --git a/react/src/base/inputs/SprkErrorContainer/SprkErrorContainer.js b/react/src/base/inputs/SprkErrorContainer/SprkErrorContainer.js @@ -43,8 +43,10 @@ SprkErrorContainer.propTypes = { */ analyticsString: PropTypes.string, /** - * Configured by parent and - * assigned to the `id` attribute. + * Assigned to the `id` attribute + * of the rendered input element. + * A custom ID will + * be added if this is not supplied. */ id: PropTypes.string, /**
3
diff --git a/src/web/BindingsWaiter.mjs b/src/web/BindingsWaiter.mjs @@ -98,11 +98,11 @@ class BindingsWaiter { break; case "Space": // Bake e.preventDefault(); - this.app.bake(); + this.manager.controls.bakeClick(); break; case "Quote": // Step through e.preventDefault(); - this.app.bake(true); + this.manager.controls.stepClick(); break; case "KeyC": // Clear recipe e.preventDefault(); @@ -120,6 +120,22 @@ class BindingsWaiter { e.preventDefault(); this.manager.output.switchClick(); break; + case "KeyT": // New tab + e.preventDefault(); + this.manager.input.addInputClick(); + break; + case "KeyW": // Close tab + e.preventDefault(); + this.manager.input.removeInput(this.manager.input.getActiveTab()); + break; + case "ArrowLeft": // Go to previous tab + e.preventDefault(); + this.manager.input.changeTabLeft(); + break; + case "ArrowRight": // Go to next tab + e.preventDefault(); + this.manager.input.changeTabRight(); + break; default: if (e.code.match(/Digit[0-9]/g)) { // Select nth operation e.preventDefault(); @@ -216,6 +232,26 @@ class BindingsWaiter { <td>Ctrl+${modWinLin}+m</td> <td>Ctrl+${modMac}+m</td> </tr> + <tr> + <td>Create a new tab</td> + <td>Ctrl+${modWinLin}+t</td> + <td>Ctrl+${modMac}+t</td> + </tr> + <tr> + <td>Close the current tab</td> + <td>Ctrl+${modWinLin}+w</td> + <td>Ctrl+${modMac}+w</td> + </tr> + <tr> + <td>Go to next tab</td> + <td>Ctrl+${modWinLin}+RightArrow</td> + <td>Ctrl+${modMac}+RightArrow</td> + </tr> + <tr> + <td>Go to previous tab</td> + <td>Ctrl+${modWinLin}+LeftArrow</td> + <td>Ctrl+${modMac}+LeftArrow</td> + </tr> `; }
0
diff --git a/js/preload/keywordExtractor.js b/js/preload/keywordExtractor.js @@ -55,7 +55,7 @@ ipc.on('getKeywordsData', function (e) { var thisKeyword = [] for (var i = 0; i < words.length; i++) { // skip the first word after a sentence - if (words[i - 1] && words[i - 1].length > 1 && sentenceEndingCharacters.includes(words[i - 1][words[i - 1].length - 1])) { + if (words[i - 1] && words[i - 1].length > 2 && sentenceEndingCharacters.includes(words[i - 1][words[i - 1].length - 1])) { thisKeyword = [] continue } @@ -65,7 +65,7 @@ ipc.on('getKeywordsData', function (e) { thisKeyword.push(words[i]) // if this word ends with a phrase-ending character, we should jump to saving or discarding - if (words[i].length > 1 && phraseEndingCharcters.includes(words[i][words[i].length - 1])) { + if (words[i].length > 2 && phraseEndingCharcters.includes(words[i][words[i].length - 1])) { } else { // otherwise, we should skip the save-or-discard and continue adding words continue
1
diff --git a/website/site/static/admin/index.html b/website/site/static/admin/index.html <title>Content Manager</title> <!-- Include the stylesheets from your site here --> - <link rel="stylesheet" href="https://unpkg.com/netlify-cms@^0.7/dist/cms.css" /> + <link rel="stylesheet" href="https://unpkg.com/netlify-cms/dist/cms.css" /> <!-- Include a CMS specific stylesheet here --> </head> <body> - <script src="https://unpkg.com/netlify-cms@^0.7/dist/cms.js"></script> + <script src="https://unpkg.com/netlify-cms/dist/cms.js"></script> </body> </html>
4
diff --git a/src/components/modeler/Modeler.vue b/src/components/modeler/Modeler.vue @@ -125,7 +125,8 @@ import { id as laneId } from '../nodes/poolLane'; import { id as sequenceFlowId } from '../nodes/sequenceFlow'; import { id as associationId } from '../nodes/association'; import { id as messageFlowId } from '../nodes/messageFlow'; -import { id as dataAssociationFlowId } from '../nodes/dataOutputAssociation'; +import { id as dataOutputAssociationFlowId } from '../nodes/dataOutputAssociation/config'; +import { id as dataInputAssociationFlowId } from '../nodes/dataInputAssociation/config'; import PaperManager from '../paperManager'; import registerInspectorExtension from '@/components/InspectorExtensionManager'; @@ -746,7 +747,7 @@ export default { store.commit('addNode', node); this.poolTarget = null; - if ([sequenceFlowId, laneId, associationId, messageFlowId, dataAssociationFlowId].includes(node.type)) { + if ([sequenceFlowId, laneId, associationId, messageFlowId, dataOutputAssociationFlowId, dataInputAssociationFlowId].includes(node.type)) { return; }
3
diff --git a/csharp_dotnetcore/6.Using-Cards/Using_Cards/Program.cs b/csharp_dotnetcore/6.Using-Cards/Using_Cards/Program.cs namespace Using_Cards { + /// <summary> + /// This is an ASP.NET Core app that creates a webserver. + /// </summary> public class Program { + /// <summary> + /// This is the entry point for your application. + /// It is run first once your application is started. + /// This method creates a web server. + /// </summary> + /// <param name="args">Arguments for this method.</param> public static void Main(string[] args) { BuildWebHost(args).Run(); } + /// <summary> + /// Initializes a new instance of the <see cref="T:Microsoft.AspNetCore.Hosting.WebHostBuilder" /> + /// class with pre-configured defaults. + /// The UseStartup method on WebHost specifies the Startup class for your app. + /// </summary> + /// <param name="args">Arguments for this method.</param> + /// <returns>A web server.</returns> public static IWebHost BuildWebHost(string[] args) => WebHost.CreateDefaultBuilder(args) .UseStartup<Startup>()
0
diff --git a/ui/js/actions/file_info.js b/ui/js/actions/file_info.js @@ -160,7 +160,7 @@ export function doFetchPublishedDate(height) { return function(dispatch, getState) { lbry.block_show({ height }).then(block => { - const relativeTime = new Date(block.time * 1000).toLocaleDateString(); + const relativeTime = new Date(block.time * 1000).toLocaleString(); dispatch({ type: types.FETCH_DATE, data: { time: relativeTime },
4
diff --git a/components/admin/AssignPlayersRoleForm.js b/components/admin/AssignPlayersRoleForm.js import React from 'react' -import gql from 'graphql-tag' import { withApollo } from 'react-apollo' import { Form, Grid, Select } from 'semantic-ui-react' import RolesQuery from 'components/queries/RolesQuery' @@ -7,6 +6,7 @@ import PlayerSelector from './PlayerSelector' import GraphQLErrorMessage from 'components/GraphQLErrorMessage' class AssignPlayersRoleForm extends React.Component { + static defaultProps = { servers: [] } state = { loading: false, error: null } handlePlayerChange = (value) => { @@ -20,8 +20,14 @@ class AssignPlayersRoleForm extends React.Component { this.setState({ loading: true, error: null }) + const variables = { players, role: parseInt(role, 10) } + + if (this.props.servers.length) { + variables.serverId = this.state.server + } + try { - await this.props.client.mutate({ mutation, variables: { players, role: parseInt(role, 10) } }) + await this.props.client.mutate({ mutation: this.props.mutation, variables }) } catch (error) { this.setState({ error }) } @@ -31,15 +37,16 @@ class AssignPlayersRoleForm extends React.Component { render() { const { error, loading } = this.state + const servers = this.props.servers.map(server => ({ key: server.id, value: server.id, text: server.name })) return ( - <Grid> - <Grid.Row columns={3}> - <Grid.Column width={10}> + <Grid doubling> + <Grid.Row> + <Grid.Column width={4} mobile={16}> <GraphQLErrorMessage error={error} /> <PlayerSelector handleChange={this.handlePlayerChange} /> </Grid.Column> - <Grid.Column width={4}> + <Grid.Column width={4} mobile={16}> <RolesQuery> {({ roles }) => { const data = roles.map(role => ({ key: role.id, text: role.name, value: role.id })) @@ -52,13 +59,36 @@ class AssignPlayersRoleForm extends React.Component { options={data} placeholder='Role' onChange={this.handleChange} + fluid /> ) }} </RolesQuery> </Grid.Column> - <Grid.Column width={2}> - <Form.Button loading={loading} disabled={loading} fluid primary size='large' content='Add' onClick={this.onSubmit} /> + {!!servers.length && + <Grid.Column width={4} mobile={16}> + <Form.Field + required + name='server' + control={Select} + options={servers} + placeholder='Server' + onChange={this.handleChange} + defaultValue={servers.length ? servers[0].value : null} + fluid + /> + </Grid.Column> + } + <Grid.Column width={2} mobile={6}> + <Form.Button + loading={loading} + disabled={loading} + fluid + primary + size='large' + content='Add' + onClick={this.onSubmit} + /> </Grid.Column> </Grid.Row> </Grid> @@ -67,11 +97,3 @@ class AssignPlayersRoleForm extends React.Component { } export default withApollo(AssignPlayersRoleForm) - -export const mutation = gql` - mutation assignRole($players: [UUID!], $role: Int!) { - assignRole(players: $players, role: $role) { - id - } - } -`
7
diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml @@ -38,8 +38,6 @@ jobs: working-directory: ./stack run: | sleep 120; - docker logs stack_relaysetup_1; - docker logs alice.sphinx; docker wait stack_relaysetup_1; - name: copy file uses: canastro/copy-file-action@master
2
diff --git a/src/libs/actions/Network.js b/src/libs/actions/Network.js import Onyx from 'react-native-onyx'; +import NetInfo from '@react-native-community/netinfo'; import ONYXKEYS from '../../ONYXKEYS'; /** @@ -13,7 +14,14 @@ function setIsOffline(isOffline) { * @param {Boolean} shouldForceOffline */ function setShouldForceOffline(shouldForceOffline) { + if (shouldForceOffline) { Onyx.merge(ONYXKEYS.NETWORK, {shouldForceOffline, isOffline: shouldForceOffline}); + } else { + Onyx.merge(ONYXKEYS.NETWORK, {shouldForceOffline}); + + // If we are no longer forcing offline, refresh the NetInfo to trigger a state change which will set isOffline appropriately + NetInfo.refresh(); + } } /**
12
diff --git a/src/Modal/events.js b/src/Modal/events.js @@ -6,6 +6,7 @@ import { getUidStr } from '../utils/uid' import { modalClass } from '../styles' import Panel from './Panel' import { getLocale } from '../locale' +import { getParent } from '../utils/dom/element' const containers = {} const DURATION = 300 @@ -110,7 +111,7 @@ export function open(props, isPortal) { ) if (isPortal) return ReactDOM.createPortal(panel, div) - if (document.activeElement) document.activeElement.blur() + if (document.activeElement && !getParent(document.activeElement, div)) document.activeElement.blur() ReactDOM.render(panel, div) return null
1
diff --git a/js/views/site.es6.js b/js/views/site.es6.js @@ -21,29 +21,28 @@ function Site (ops) { // FIXME should be moved to the right place --- model? // _rerender() below should probably not be called directly but via a model change event var thisSite = this; + var thisTab = null; - backgroundPage.utils.getCurrentTab(function(tab) { - if(tab){ - console.log(tab); - let siteDomain = backgroundPage.utils.extractHostFromURL(tab.url); - thisSite.model.domain = siteDomain; - - let tabObj = backgroundPage.tabs[tab.id]; - + function updateTrackerCount(){ + let tabObj = backgroundPage.tabs[thisTab]; if(tabObj){ thisSite.model.trackerCount = tabObj.dispTotal; - tabObj.thisSite = thisSite; + } } + backgroundPage.utils.getCurrentTab(function(tab) { + if(tab){ + thisTab = tab.id; + let siteDomain = backgroundPage.utils.extractHostFromURL(tab.url); + thisSite.model.domain = siteDomain; + updateTrackerCount(); thisSite._rerender(); } }); chrome.runtime.onMessage.addListener(function(req, sender, res){ - console.log("Request ", req); if(req.rerenderPopup){ - console.log("Rerender in view from message"); - console.log(thisSite); + updateTrackerCount(); thisSite._rerender(); } });
3
diff --git a/userscript.user.js b/userscript.user.js @@ -57106,7 +57106,13 @@ var $$IMU_EXPORT$$; if (domain === "m.gjcdn.net") { // https://m.gjcdn.net/screenshot-thumbnail/300x2000/828783-v4.jpg // https://m.gjcdn.net/screenshot-thumbnail/999999999x999999999/828783-v4.jpg - return src.replace(/\/screenshot-thumbnail\/+[0-9]+x[0-9]+\/+/, "/screenshot-thumbnail/999999999x999999999/"); + // https://m.gjcdn.net/game-header/2000/479495-crop0_63_1500_438-euam8zeu-v4.jpg + // https://m.gjcdn.net/game-header/999999999/479495-euam8zeu-v4.jpg + // https://m.gjcdn.net/game-thumbnail/200/451063-crop464_491_1512_1080-cxiru8mh-v4.png + // https://m.gjcdn.net/game-thumbnail/999999999/451063-cxiru8mh-v4.png + return src + .replace(/\/screenshot-thumbnail\/+[0-9]+x[0-9]+\/+/, "/screenshot-thumbnail/999999999x999999999/") + .replace(/\/(game-(?:header|thumbnail))\/+[0-9]+\/+([0-9]+-)(?:crop[0-9]+(?:_[0-9]+){3}-)?/, "/$1/999999999/$2"); }
7
diff --git a/test/jasmine/tests/treemap_test.js b/test/jasmine/tests/treemap_test.js var Plotly = require('@lib'); var Plots = require('@src/plots/plots'); var Lib = require('@src/lib'); +var Drawing = require('@src/components/drawing'); var constants = require('@src/traces/treemap/constants'); var d3 = require('d3'); @@ -1113,6 +1114,7 @@ describe('Test treemap tweening:', function() { return s.replace(/\s/g, ''); } + function _assert(msg, attrName, id, exp) { var lookup = {d: pathTweenFnLookup, transform: textTweenFnLookup}[attrName]; var fn = lookup[id]; @@ -1120,18 +1122,18 @@ describe('Test treemap tweening:', function() { // asserting at the mid point *should be* representative enough var t = 0.5; var actual = trim(fn(t)); + var msg2 = msg + ' | node ' + id + ' @t=' + t; - // do not assert textBB translate piece, - // which isn't tweened and has OS-dependent results if(attrName === 'transform') { - actual = actual.split('translate').slice(0, 2).join('translate'); - } - + var fake = {attr: function() { return actual; }}; + var xy = Drawing.getTranslate(fake); + expect([xy.x, xy.y]).toBeWithinArray(exp, 1, msg2); + } else { // we could maybe to bring in: // https://github.com/hughsk/svg-path-parser // to make these assertions more readable - - expect(actual).toBe(trim(exp), msg + ' | node ' + id + ' @t=' + t); + expect(actual).toBe(trim(exp), msg2); + } } it('should tween sector exit/update (case: click on branch, no maxdepth)', function(done) { @@ -1158,12 +1160,8 @@ describe('Test treemap tweening:', function() { _assert('update b to new position', 'd', 'b', 'M221.75,136L611,136L611,361L221.75,361Z' ); - _assert('move B text to new position', 'transform', 'B', - 'translate(221.75126)' - ); - _assert('move b text to new position', 'transform', 'b', - 'translate(224.75150)' - ); + _assert('move B text to new position', 'transform', 'B', [221.75126, 0]); + _assert('move b text to new position', 'transform', 'b', [224.75150, 0]); }) .catch(failTest) .then(done); @@ -1194,12 +1192,8 @@ describe('Test treemap tweening:', function() { _assert('update b to new position', 'd', 'b', 'M221.75,136L611,136L611,361L221.75,361Z' ); - _assert('move B text to new position', 'transform', 'B', - 'translate(221.75126)' - ); - _assert('move b text to new position', 'transform', 'b', - 'translate(224.75150)' - ); + _assert('move B text to new position', 'transform', 'B', [221.75126, 0]); + _assert('move b text to new position', 'transform', 'b', [224.75150, 0]); }) .catch(failTest) .then(done); @@ -1230,12 +1224,8 @@ describe('Test treemap tweening:', function() { _assert('enter b for parent position', 'd', 'b', 'M284.375,188.5L548.375,188.5L548.375,308.5L284.375,308.5Z' ); - _assert('move B text to new position', 'transform', 'B', - 'translate(220.25126)' - ); - _assert('enter b text to new position', 'transform', 'b', - 'translate(287.375195.5)scale(0.5)' - ); + _assert('move B text to new position', 'transform', 'B', [220.25126, 0]); + _assert('enter b text to new position', 'transform', 'b', [287.375195, 5]); }) .catch(failTest) .then(done);
0
diff --git a/components/ui/Tabs.js b/components/ui/Tabs.js @@ -39,7 +39,7 @@ export default class Tabs extends React.Component { <div className="row l-row"> {options.map((option) => { const btnClasses = classnames({ - '-active': option.value.includes(selected), + '-active': option.value === selected, '-desktopOnly': option.desktopOnly, });
13
diff --git a/lib/model.js b/lib/model.js @@ -233,18 +233,17 @@ Model.prototype.$__handleSave = function(options, callback) { } applyWriteConcern(this.$__schema, options); - if (typeof options.writeConcern != 'undefined') { + saveOptions.writeConcern = {}; if ('w' in options.writeConcern) { - saveOptions.w = options.writeConcern.w; + saveOptions.writeConcern.w = options.writeConcern.w; } if ('j' in options.writeConcern) { - saveOptions.j = options.writeConcern.j; + saveOptions.writeConcern.j = options.writeConcern.j; } if ('wtimeout' in options.writeConcern) { - saveOptions.wtimeout = options.writeConcern.wtimeout; + saveOptions.writeConcern.wtimeout = options.writeConcern.wtimeout; } - saveOptions.writeConcern = Object.assign({}, options.writeConcern); } else { if ('w' in options) { saveOptions.w = options.w;
1
diff --git a/closure/goog/dom/animationframe/animationframe.js b/closure/goog/dom/animationframe/animationframe.js * * Programmatic: * <pre> - * var animationTask = goog.dom.animationFrame.createTask({ + * let animationTask = goog.dom.animationFrame.createTask( + * { * measure: function(state) { * state.width = goog.style.getSize(elem).width; * this.animationTask(); * }, * mutate: function(state) { * goog.style.setWidth(elem, Math.floor(state.width / 2)); - * } - * }, this); - * }); + * }, + * }, + * this); * </pre> * * See also
1
diff --git a/packages/bitcore-lib-doge/test/script/interpreter.js b/packages/bitcore-lib-doge/test/script/interpreter.js @@ -124,17 +124,17 @@ describe('Interpreter', function() { it('should verify these simple transaction', function() { // first we create a transaction - var privateKey = new PrivateKey('cSBnVM4xvxarwGQuAfQFwqDg9k5tErHUHzgWsEfD4zdwUasvqRVY'); + var privateKey = new PrivateKey('QRnivs36yg7VgWZZ3kqZzofXEaLh27X46zzAupJUpcqqybvHSjra'); var publicKey = privateKey.publicKey; var fromAddress = publicKey.toAddress(); - var toAddress = 'mrU9pEmAx26HcbKVrABvgL7AwA5fjNFoDc'; + var toAddress = 'DS1csbTjWURfExDwVKg12p9c8Vha6CGsG3'; var scriptPubkey = Script.buildPublicKeyHashOut(fromAddress); var utxo = { - address: fromAddress, - txId: 'a477af6b2667c29670467e4e0728b685ee07b240235771862318e29ddbe58458', - outputIndex: 0, - script: scriptPubkey, - satoshis: 100000 + "txid" : "fd1d3baa6c7f35fc8f176a9fb180487ddf462a27c1707d24af0100fed41d5221", + "vout" : 0, + "address" : "DE1wEbm9D6JqEhqGtyD52BkHQmQ5N18J84", + "scriptPubKey" : "76a914615e740f1219a7b7b84530accdf6722bb255e5cf88ac", + "amount" : 75.000 }; var tx = new Transaction() .from(utxo)
3
diff --git a/bl-kernel/js/bludit-ajax.php b/bl-kernel/js/bludit-ajax.php @@ -8,7 +8,7 @@ class bluditAjax { ajaxRequest.abort(); } - if (content.length<100) { + if ((content.length<100) && callBack) { return false; } @@ -25,12 +25,16 @@ class bluditAjax { ajaxRequest.done(function (response, textStatus, jqXHR) { console.log("Bludit AJAX: autosave(): done handler"); + if (callBack) { callBack("Autosave success"); + } }); ajaxRequest.fail(function (jqXHR, textStatus, errorThrown) { console.log("Bludit AJAX: autosave(): fail handler"); + if (callBack) { callBack("Autosave failure"); + } }); ajaxRequest.always(function () {
2
diff --git a/docs/components_page/list_group_content.py b/docs/components_page/list_group_content.py @@ -16,10 +16,10 @@ from .metadata import get_component_metadata HERE = Path(__file__).parent LISTGROUP = HERE / "components" / "list_group" -list_group_simple_source = (LISTGROUP / "simple.py").open().read() -list_group_links_source = (LISTGROUP / "links.py").open().read() -list_group_colors_source = (LISTGROUP / "colors.py").open().read() -list_group_content_source = (LISTGROUP / "content.py").open().read() +list_group_simple_source = (LISTGROUP / "simple.py").read_text() +list_group_links_source = (LISTGROUP / "links.py").read_text() +list_group_colors_source = (LISTGROUP / "colors.py").read_text() +list_group_content_source = (LISTGROUP / "content.py").read_text() links_explainer = html.P( [
4
diff --git a/test/EleventyWatchTargetsTest.js b/test/EleventyWatchTargetsTest.js const test = require("ava"); const EleventyWatchTargets = require("../src/EleventyWatchTargets"); +const JavaScriptDependencies = require("../src/Util/JavaScriptDependencies"); test("Basic", (t) => { let targets = new EleventyWatchTargets(); @@ -34,9 +35,8 @@ test("Add and make glob", (t) => { }); test("JavaScript get dependencies", (t) => { - let targets = new EleventyWatchTargets(); t.deepEqual( - targets.getJavaScriptDependenciesFromList(["./test/stubs/config-deps.js"]), + JavaScriptDependencies.getDependencies(["./test/stubs/config-deps.js"]), ["./test/stubs/config-deps-upstream.js"] ); });
1
diff --git a/src/tree/TextureSource.mjs b/src/tree/TextureSource.mjs @@ -374,7 +374,15 @@ export default class TextureSource { } _isNativeTexture(source) { - return ((Utils.isNode ? source.constructor.name === "WebGLTexture" : source instanceof WebGLTexture)); + if (Utils.isNode) { + return source.constructor.name === "WebGLTexture"; + } + + if ('WebGLTexture' in window) { + return source instanceof WebGLTexture; + } + + return false; } }
0
diff --git a/packages/idyll-components/src/equation.js b/packages/idyll-components/src/equation.js @@ -167,9 +167,16 @@ class Equation extends React.PureComponent { Equation._idyll = { name: 'Equation', - tagType: 'open', - children: 'y = x^2', + tagType: 'closed', props: [ + { + name: 'latex', + type: 'expression', + example: '`"x = " + x`', + defaultValue: '"x"', + description: + 'Set the latex to be shown. Can be driven by an expression to allow for dynamically updated equations.' + }, { name: 'display', type: 'boolean',
3
diff --git a/app/components/modal-edit-registry/template.hbs b/app/components/modal-edit-registry/template.hbs </div> </div> - <div class="row inline-form"> - <div class="col span-2 col-inline"> - <label>{{t 'editRegistry.email.label'}}{{field-required}}</label> - </div> - <div class="col span-8"> - {{input type="text" class="form-control email" value=model.credential.email placeholder=(t 'editRegistry.email.placeholder')}} - </div> - </div> - <div class="row inline-form"> <div class="col span-2 col-inline"> <label>{{t 'editRegistry.username.label'}}</label>
2
diff --git a/src/utils/serve-functions.js b/src/utils/serve-functions.js @@ -128,14 +128,14 @@ function createHandler(dir) { .pop() .trim() - let path = request.path + let requestPath = request.path if (request.headers['x-netlify-original-pathname']) { - path = request.headers['x-netlify-original-pathname'] + requestPath = request.headers['x-netlify-original-pathname'] delete request.headers['x-netlify-original-pathname'] } const event = { - path: path, + path: requestPath, httpMethod: request.method, queryStringParameters: queryString.parse(request.url.split(/\?(.+)/)[1]), headers: Object.assign({}, request.headers, { 'client-ip': remoteAddress }),
1
diff --git a/package.json b/package.json { "name": "@commercetools-frontend/ui-kit", - "version": "10.0.1", + "version": "10.0.0", "description": "UI component library based on our Design System", "homepage": "https://uikit.commercetools.com/", "bugs": "https://github.com/commercetools/ui-kit/issues",
13
diff --git a/src/traces/isosurface/convert.js b/src/traces/isosurface/convert.js @@ -378,6 +378,15 @@ function generateIsosurfaceMesh(data) { ); } + + function almostInFinalRange(value) { + var vErr = 0.01 * (vMax - vMin); + return ( + value >= vMin - vErr && + value <= vMax + vErr + ); + } + function getXYZV(indecies) { var xyzv = []; for(var q = 0; q < 4; q++) { @@ -407,14 +416,14 @@ function generateIsosurfaceMesh(data) { // bug of gl-mesh3d. But don't worry this would run faster! var tryDrawTri = function(debug, xyzv, abc) { - if( - inRange(xyzv[0][3], vMin, vMax) && - inRange(xyzv[1][3], vMin, vMax) && - inRange(xyzv[2][3], vMin, vMax) + if( // we check here if the points are in `real` iso-min/max range + almostInFinalRange(xyzv[0][3]) && + almostInFinalRange(xyzv[1][3]) && + almostInFinalRange(xyzv[2][3]) ) { drawTri(debug, xyzv, abc); } else if(!isSecondPass) { - tryCreateTri(xyzv, abc, vMin, vMax, debug, true); + tryCreateTri(xyzv, abc, vMin, vMax, debug, true); // i.e. second pass } }; @@ -740,7 +749,6 @@ function generateIsosurfaceMesh(data) { return range; } - function insertGridPoints() { for(var k = 0; k < depth; k++) { for(var j = 0; j < height; j++) { @@ -770,13 +778,12 @@ function generateIsosurfaceMesh(data) { } var setupMinMax = [ - [ vMin, vMax ], [ vMin, maxValues ], [ minValues, vMax ] ]; ['x', 'y', 'z'].forEach(function(e) { - for(var s = 0; s < 3; s++) { + for(var s = 0; s < setupMinMax.length; s++) { drawingEdge = (s === 0) ? false : true;
7
diff --git a/src/utils/config.ts b/src/utils/config.ts @@ -25,9 +25,9 @@ const DEFAULT_SCHEDULER_TLS_LOCATION = './creds/scheduler_creds/ca.pem' const DEFAULT_SCHEDULER_KEY_LOCATION = './creds/scheduler_creds/device-key.pem' const DEFAULT_SCHEDULER_CHAIN_LOCATION = './creds/scheduler_creds/device.crt' const DEFAULT_TRANSPORT_PUBLIC_KEY_LOCATION = - './creds/transport_token_creds/transportTokenPublicKey.pem' + './creds/transportTokenPublicKey.pem' const DEFAULT_TRANSPORT_PRIVATE_KEY_LOCATION = - './creds/transport_token_creds/transportTokenPrivateKey.pem' + './creds/transportTokenPrivateKey.pem' const DEFAULT_LENGTH_DELAY_FOR_TRANSPORT_TOKEN_DB_CLEARING = 1 export function loadConfig() {
3
diff --git a/mods/core/src/common/resource_builder.js b/mods/core/src/common/resource_builder.js @@ -119,7 +119,8 @@ class ResourceBuilder { delete this.spec.context.accessControlList.allow if (!deny || deny.length === 0) delete this.spec.context.accessControlList.deny - if (!allow && !deny) delete this.spec.context.accessControlList + if ((!allow && !deny) || (allow.length === 0 && allow.length === 0)) + delete this.spec.context.accessControlList return this }
7
diff --git a/app/src/components/AddPodcastModal.js b/app/src/components/AddPodcastModal.js -import exitIcon from '../images/buttons/exit.svg'; -import config from '../config'; import React from 'react'; import PropTypes from 'prop-types'; import ReactModal from 'react-modal'; import Img from 'react-image'; -import axios from 'axios'; -import fetch from '../util/fetch'; -import saveIcon from '../images/icons/save.svg'; import { connect } from 'react-redux'; import { withRouter } from 'react-router-dom'; +import fetch from '../util/fetch'; + +import saveIcon from '../images/icons/save.svg'; +import exitIcon from '../images/buttons/exit.svg'; + class AddPodcastModal extends React.Component { constructor(props) { super(props); - this.state = { + + this.resetState = { checkedPodcastsToFollow: [], errorMessage: '', errored: false, @@ -24,12 +25,14 @@ class AddPodcastModal extends React.Component { success: false, }; - this.submitPodcastURL = this.submitPodcastURL.bind(this); - this.resetModal = this.resetModal.bind(this); - this.submitPodcastSelections = this.submitPodcastSelections.bind(this); + this.state = { ...this.resetState }; } - submitPodcastURL(e) { + resetModal = () => { + this.setState({ ...this.resetState }); + }; + + submitPodcastURL = (e) => { e.preventDefault(); this.setState({ @@ -39,16 +42,7 @@ class AddPodcastModal extends React.Component { success: false, }); - axios({ - baseURL: config.api.url, - data: { feedUrl: this.state.podcastInputValue }, - headers: { - 'Authorization': `Bearer ${localStorage['jwt']}`, - 'Content-Type': 'application/json', - }, - method: 'POST', - url: '/podcasts', - }) + fetch('POST', '/podcasts', { feedUrl: this.state.podcastInputValue }) .then((res) => { for (let podcast of res.data) { this.props.dispatch({ @@ -69,9 +63,9 @@ class AddPodcastModal extends React.Component { submitting: false, }); }); - } + }; - submitPodcastSelections(e) { + submitPodcastSelections = (e) => { e.preventDefault(); this.setState({ @@ -90,7 +84,6 @@ class AddPodcastModal extends React.Component { this.props.dispatch({ podcastID: res.data.podcast, type: 'FOLLOW_PODCAST', - userID: res.data.user, }); return res.data.podcast; }); @@ -104,33 +97,14 @@ class AddPodcastModal extends React.Component { setTimeout(() => { this.resetModal(); this.props.done(); - }, 5000); - }); - } - - resetModal() { - this.setState({ - checkedPodcastsToFollow: [], - errorMessage: '', - errored: false, - feedsToFollow: [], - podcastInputValue: '', - stage: 'submit-podcast-url', - submitting: false, - success: false, + }, 1500); }); - } + }; render() { - let buttonText; - - if (this.state.submitting) { - buttonText = 'Submitting...'; - } else if (this.state.success) { - buttonText = 'Success!'; - } else { - buttonText = 'Submit'; - } + let buttonText = 'Submit'; + if (this.state.submitting) buttonText = 'Submitting...'; + else if (this.state.success) buttonText = 'Success!'; let currentView = null; if (this.state.stage === 'submit-podcast-url') { @@ -139,11 +113,9 @@ class AddPodcastModal extends React.Component { <div className="input-box"> <input autoComplete="false" - onChange={(e) => { - this.setState({ - podcastInputValue: e.target.value, - }); - }} + onChange={(e) => + this.setState({ podcastInputValue: e.target.value }) + } placeholder="Enter URL" type="text" value={this.state.podcastInputValue} @@ -156,7 +128,11 @@ class AddPodcastModal extends React.Component { <div className="buttons"> <button className="btn primary alt with-circular-icon" - disabled={this.state.submitting || this.state.success} + disabled={ + this.state.submitting || + this.state.success || + this.state.podcastInputValue.trim() === '' + } type="submit" > <Img decode={false} src={saveIcon} /> @@ -186,9 +162,9 @@ class AddPodcastModal extends React.Component { /> </div> <div className="info"> - { - 'We found a few podcasts with that URL. Once your selection has been made, we will begin to process the podcasts. They will be ready shortly after.' - } + We found a few podcasts with that URL. Once your selection has + been made, we will begin to process the podcasts. They will be + ready shortly after. </div> {this.state.podcastsToFollow.map((podcastToFollow) => { return ( @@ -233,7 +209,11 @@ class AddPodcastModal extends React.Component { <div className="buttons"> <button className="btn primary alt with-circular-icon" - disabled={this.state.submitting || this.state.success} + disabled={ + this.state.submitting || + this.state.success || + !this.state.checkedPodcastsToFollow.length + } type="submit" > <Img src={saveIcon} />
7
diff --git a/lib/plugins/browsertime/filmstrip.js b/lib/plugins/browsertime/filmstrip.js @@ -74,7 +74,7 @@ function getMetricsFromBrowsertime(data) { ) { metrics.push({ metric: 'first-contentful-paint', - name: 'FCP', + name: 'First Contentful Paint', value: data.timings.paintTiming['first-contentful-paint'] }); } @@ -85,7 +85,7 @@ function getMetricsFromBrowsertime(data) { ) { metrics.push({ metric: 'largestContentfulPaint', - name: 'LCP', + name: 'Largest Contentful Paint', value: data.timings.largestContentfulPaint.renderTime }); }
10
diff --git a/articles/api/authentication/api-authz/_authz-client.md b/articles/api/authentication/api-authz/_authz-client.md @@ -158,7 +158,7 @@ This is the OAuth 2.0 grant that mobile apps utilize in order to access an API. GET https://${account.namespace}/authorize? audience=API_IDENTIFIER& scope=SCOPE& - response_type=token|id_token token& + response_type=token|id_token|id_token token& client_id=${account.clientId}& redirect_uri=${account.callback}& state=STATE& @@ -187,7 +187,7 @@ This is the OAuth 2.0 grant that Client-side web apps utilize in order to access |:-----------------|:------------| | `audience` <br/> | The unique identifier of the target API you want to access. | | `scope` | The scopes which you want to request authorization for. These must be separated by a space. You can request any of the [standard OIDC scopes](https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims) about users, such as `profile` and `email`, custom claims that must conform to a namespaced format, or any scopes supported by the target API (for example, `read:contacts`). | -| `response_type` <br/><span class="label label-danger">Required</span> | This will specify the type of token you will receive at the end of the flow. Use `token` to get only an `access_token`, `id_token` to get only an `id_token`, or `id_token token` to get both an `id_token` and an `access_token`. | +| `response_type` <br/><span class="label label-danger">Required</span> | This will specify the type of token you will receive at the end of the flow. Use `token` to get only an `access_token`, `id_token` to get only an `id_token` (if you don't plan on accessing an API), or `id_token token` to get both an `id_token` and an `access_token`. | | `client_id` <br/><span class="label label-danger">Required</span> | Your application's Client ID. | | `state` <br/><span class="label label-primary">Recommended</span> | An opaque value the clients adds to the initial request that Auth0 includes when redirecting the back to the client. This value must be used by the client to prevent CSRF attacks. | | `redirect_uri` | The URL to which Auth0 will redirect the browser after authorization has been granted by the user. |
0
diff --git a/templates/index.html b/templates/index.html @@ -530,6 +530,7 @@ $(function () { </div> <div class="modal-body"> <form id="addProgramForm"> + {% csrf_token %} <div class="form-group"> <label for="programName">Program Name</label> <input type="text" id="programName" name="program_name" class="form-control"
0
diff --git a/test/unit/ui.js b/test/unit/ui.js @@ -55,6 +55,7 @@ describe('ui class', () => { }); afterEach(() => { + ui = null; resizeSpy.restore(); hostClickSpy.restore(); escSpy.restore(); @@ -127,6 +128,10 @@ describe('ui class', () => { ui = new UI(client, integrations); }); + afterEach(() => { + ui = null; + }); + describe('createCart', () => { let initStub;
12
diff --git a/writer.js b/writer.js @@ -482,8 +482,8 @@ function saveJoint(objJoint, objValidationState, preCommitCallback, onDone) { is_free: 1, is_stable: bGenesis ? 1 : 0, witnessed_level: bGenesis ? 0 : null, - headers_commission: objUnit.headers_commission, - payload_commission: objUnit.payload_commission, + headers_commission: objUnit.headers_commission || 0, + payload_commission: objUnit.payload_commission || 0, sequence: objValidationState.sequence, author_addresses: arrAuthorAddresses, witness_list_unit: (objUnit.witness_list_unit || objUnit.unit)
12
diff --git a/package.json b/package.json "express": "^4.17.1", "forever": "^4.0.1", "gpt-3-encoder": "^1.1.3", + "json-6": "^1.1.4", "key-did-provider-ed25519": "^1.1.0", "key-did-resolver": "^1.4.0", "metaversefile": "./packages/metaversefile",
0
diff --git a/nerdamer.core.js b/nerdamer.core.js @@ -490,6 +490,15 @@ var nerdamer = (function (imports) { } return obj.lessThan(0); }; + /** + * Safely stringify object + * @param o + */ + var stringify = function(o) { + if(!o) + return o; + return String(o); + }; /** * @param {String} str @@ -5529,8 +5538,24 @@ var nerdamer = (function (imports) { } return o.toString(); }; + this.peekers = { + pre_operator: [], + post_operator: [], + pre_function: [], + post_function: [] + } + + this.callPeekers = function(name) { + var peekers = this.peekers[name]; + //remove the first items and stringify + var args = arguments2Array(arguments).slice(1).map(stringify); + //call each one of the peekers + for(var i=0; i<peekers.length; i++) { + peekers[i].apply(null, args); + } + }; /* - * Tokneizes the string + * Tokenizes the string * @param {String} e * @returns {Token[]} */ @@ -5988,7 +6013,15 @@ var nerdamer = (function (imports) { if(b instanceof Set && !is_comma) b = Vector.fromSet(b); - Q.push(_[e.action](a, b)); + //call all the pre-operators + this.callPeekers('pre_operator', a, b, e); + + var ans = _[e.action](a, b); + + //call all the pre-operators + this.callPeekers('post_operator', ans, a, b, e); + + Q.push(ans); } } else if (e.type === Token.FUNCTION) { @@ -6001,7 +6034,18 @@ var nerdamer = (function (imports) { //with an "getter" object and return the requested values //call the function. This is the _.callfunction method in nerdamer - var ret = _.callfunction(e.value, args.getItems()); + //call the function. This is the _.callfunction method in nerdamer + var fn_name = e.value; + var fn_args = args.getItems(); + + //call the pre-function peekers + this.callPeekers('pre_function', fn_name, fn_args); + + var ret = _.callfunction(fn_name, fn_args); + + //call the post-function peekers + this.callPeekers('post_function', ret, fn_name, fn_args); + var last = Q[Q.length - 1]; var next = rpn[i + 1]; var next_is_comma = next && next.type === Token.OPERATOR && next.value === ','; @@ -10929,6 +10973,14 @@ var nerdamer = (function (imports) { '</div>'; }; + libExports.addPeeker = function(name, f) { + if(_.peekers[name]) + _.peekers[name].push(f); + }; + + libExports.removePeeker = function(name, f) { + remove(_.peekers[name], f); + }; libExports.api(); @@ -10949,3 +11001,16 @@ if ((typeof module) !== 'undefined') { module.exports = nerdamer; } +var expression = 'x+y-cos(x+1)';; +var pre_operator = function(a, b, o) { + console.log('Pre-operator: '+' ('+a+') '+o+' ('+b+') '); +}; +var post_operator = function(ans) { + console.log('Post-operator: '+ans); +}; +var pre_function = function(fn, args) { + console.log('Pre-function: '+fn+' '+args); +}; +var post_function = function(called) { + console.log('Post-function: '+called); +};
0
diff --git a/sirepo/package_data/static/js/sirepo-plotting.js b/sirepo/package_data/static/js/sirepo-plotting.js @@ -766,7 +766,11 @@ SIREPO.app.directive('plot2d', function(plotting) { points = []; xAxisScale.domain(xdom); } - yDomain = [d3.min(json.points), d3.max(json.points)]; + var ymin = d3.min(json.points); + if (ymin > 0) { + ymin = 0; + } + yDomain = [ymin, d3.max(json.points)]; yAxisScale.domain(yDomain).nice(); points = plotting.addConvergencePoints(select, '.plot-viewport', points, d3.zip(xPoints, json.points)); focusPoint.load(points[0], true);
12
diff --git a/src/reducers/selectors/balance.js b/src/reducers/selectors/balance.js @@ -3,7 +3,7 @@ import BN from 'bn.js' import { LOCKUP_MIN_BALANCE } from '../../utils/account-with-lockup' export const selectProfileBalance = (balance) => { - if (!balance?.account?.totalAvailable) { + if (!balance) { return false } @@ -17,22 +17,19 @@ export const selectProfileBalance = (balance) => { stakedBalanceMainAccount, balanceAvailable, stakedBalanceLockup, - account: { - totalAvailable, - totalPending, - totalStaked - }, - lockupIdExists + account } = balance + const lockupIdExists = !!lockedAmount + const walletBalance = { walletBalance: stakedBalanceMainAccount.add(new BN(balanceAvailable)).add(new BN(stateStaked)).toString(), reservedForStorage: stateStaked.toString(), inStakingPools: { sum: stakedBalanceMainAccount.toString(), - staked: totalStaked, - pendingRelease: totalPending, - availableForWithdraw: totalAvailable + staked: account?.totalStaked, + pendingRelease: account?.totalPending, + availableForWithdraw: account?.totalAvailable }, available: balanceAvailable } @@ -48,9 +45,9 @@ export const selectProfileBalance = (balance) => { reservedForStorage: LOCKUP_MIN_BALANCE.toString(), inStakingPools: { sum: stakedBalanceLockup.toString(), - staked: lockupAccount.totalStaked, - pendingRelease: new BN(lockupAccount.totalPending).toString(), - availableForWithdraw: new BN(lockupAccount.totalAvailable).toString() + staked: lockupAccount?.totalStaked, + pendingRelease: lockupAccount?.totalPending && new BN(lockupAccount.totalPending).toString(), + availableForWithdraw: lockupAccount?.totalAvailable && new BN(lockupAccount.totalAvailable).toString() }, locked: lockedAmount.toString(), unlocked: {
9
diff --git a/src/_less/utilities/misc.less b/src/_less/utilities/misc.less } } -.no-wrap { - white-space: nowrap; -} - -.box-shadow { - box-shadow: 0 2px 4px rgba(0,0,0,0.1); -} - -.box-shadow-soft { - box-shadow: 0 2px 4px rgba(0,0,0,0.02); -} - -.box-shadow-z2 { - box-shadow: 0 15px 35px hsla(240, 10%, 28%, 0.15), 0 5px 15px rgba(0,0,0,.07); -} - -.responsive({ - &box-shadow-z2 { .box-shadow-z2; } -}); - -.inset-shadow { - box-shadow: inset 0 1px 2px rgba(0,0,0,0.05); -} - .tab-focus { // Default outline: thin dotted; outline-offset: -2px; } -.full-height { - min-height: 100vh; -} - -.full-width { - width: 100%; -} - .clickable { cursor: pointer; user-select: none; border: 0; } -.mask { overflow: hidden; } - .aspect-2\:1 { padding-bottom: 50%; } opacity: 1; } } - -.responsive({ - &hover-only { .hover-only; } -}); - -.bg-cover { - background-size: cover; - background-position: center; -}
2
diff --git a/README.md b/README.md @@ -117,7 +117,7 @@ You can easily navigate through it with the sidebar directory in order to run th ## Mainnet -### v2.0.0 +### v2.1.0 | Contract | Address | | ---------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------- | @@ -127,15 +127,15 @@ You can easily navigate through it with the sidebar directory in order to run th | Feature Registry: | [0xa3eacb03622bf1513880892b7270d965f693ffb5](https://etherscan.io/address/0xa3eacb03622bf1513880892b7270d965f693ffb5) | | ETHOracle: | [0x60055e9a93aae267da5a052e95846fa9469c0e7a](https://etherscan.io/address/0x60055e9a93aae267da5a052e95846fa9469c0e7a) | | POLYOracle: | [0x52cb4616E191Ff664B0bff247469ce7b74579D1B](https://etherscan.io/address/0x52cb4616E191Ff664B0bff247469ce7b74579D1B) | -| General Transfer Manager Factory: | [0xdc95598ef2bbfdb66d02d5f3eea98ea39fbc8b26](https://etherscan.io/address/0xdc95598ef2bbfdb66d02d5f3eea98ea39fbc8b26) | +| General Transfer Manager Factory (2.0.0): | [0xdc95598ef2bbfdb66d02d5f3eea98ea39fbc8b26](https://etherscan.io/address/0xdc95598ef2bbfdb66d02d5f3eea98ea39fbc8b26) | +| General Transfer Manager Factory (2.1.0): | [0xa8b60c9b7054782f46931e35e7012037a574ecee](https://etherscan.io/address/0xa8b60c9b7054782f46931e35e7012037a574ecee) | | General Permission Manager Factory: | [0xf0aa1856360277c60052d6095c5b787b01388cdd](https://etherscan.io/address/0xf0aa1856360277c60052d6095c5b787b01388cdd) | -| CappedSTOFactory: | [0x77d89663e8819023a87bfe2bc9baaa6922c0e57c](https://etherscan.io/address/0x77d89663e8819023a87bfe2bc9baaa6922c0e57c) | -| USDTieredSTO Factory: | [0x5a3a30bddae1f857a19b1aed93b5cdb3c3da809a](https://etherscan.io/address/0x5a3a30bddae1f857a19b1aed93b5cdb3c3da809a) | -| EthDividendsCheckpointFactory: | [0x968c74c52f15b2de323eca8c677f6c9266bfefd6](https://etherscan.io/address/0x968c74c52f15b2de323eca8c677f6c9266bfefd6) | -| ERC20 Dividends Checkpoint Factory: | [0x82f9f1ab41bacb1433c79492e54bf13bccd7f9ae](https://etherscan.io/address/0x82f9f1ab41bacb1433c79492e54bf13bccd7f9ae) | -| Count Transfer Manager Factory: | [0xd9fd7e34d6e2c47a69e02131cf8554d52c3445d5](https://etherscan.io/address/0xd9fd7e34d6e2c47a69e02131cf8554d52c3445d5) | +| CappedSTOFactory (2.1.0): | [0x26bcd18a748ade7fafb250bb014c7121a412870c](https://etherscan.io/address/0x26bcd18a748ade7fafb250bb014c7121a412870c) | +| USDTieredSTO Factory (2.1.0): | [0x0148ed61ffa8e0da7908a62aa2d1f266688656c4](https://etherscan.io/address/0x0148ed61ffa8e0da7908a62aa2d1f266688656c4) | +| ERC20 Dividends Checkpoint Factory (2.1.0): | [0x855152c9b98babadc996a0dd71c8b3682b8f4786](https://etherscan.io/address/0x855152c9b98babadc996a0dd71c8b3682b8f4786) | +| Count Transfer Manager Factory (2.1.0): | [0x575ed30ec5700f369115b079be8059001e79eb7b](https://etherscan.io/address/0x575ed30ec5700f369115b079be8059001e79eb7b) | | Percentage Transfer Manager Factory: | [0xe6267a9c0a227d21c95b782b1bd32bb41fc3b43b](https://etherscan.io/address/0xe6267a9c0a227d21c95b782b1bd32bb41fc3b43b) | -| Manual Approval Transfer Manager Factory (2.0.1): | [0x6af2afad53cb334e62b90ddbdcf3a086f654c298](https://etherscan.io/address/0x6af2afad53cb334e62b90ddbdcf3a086f654c298) | +| Manual Approval Transfer Manager Factory (2.1.0): | [0xe5b21cf83f5e49aba4601e8d8cf182f889208cfd](https://etherscan.io/address/0xe5b21cf83f5e49aba4601e8d8cf182f889208cfd) | New SecurityTokenRegistry (2.0.1): 0x538136ed73011a766bf0a126a27300c3a7a2e6a6 @@ -144,12 +144,9 @@ New SecurityTokenRegistry (2.0.1): 0x538136ed73011a766bf0a126a27300c3a7a2e6a6 New ModuleRegistry (2.0.1): 0xbc18f144ccf87f2d98e6fa0661799fcdc3170119 (fixed bug with missing transferOwnership function) -New ManualApprovalTransferManager 0x6af2afad53cb334e62b90ddbdcf3a086f654c298 -(Fixed 0x0 from bug) - ## KOVAN -### v2.0.0 +### v2.1.0 New Kovan PolyTokenFaucet: 0xb347b9f5b56b431b2cf4e1d90a5995f7519ca792 | Contract | Address |
3
diff --git a/components/Account/UpdateMe.js b/components/Account/UpdateMe.js @@ -28,7 +28,7 @@ import { Hint } from './Elements' const { H2, P } = Interaction const birthdayFormat = '%d.%m.%Y' -const birthdayParse = swissTime.parse(birthdayFormat) +export const birthdayParse = swissTime.parse(birthdayFormat) const fields = t => [ {
4
diff --git a/package.json b/package.json "mojangson": "^0.2.1", "prismarine-biome": "^1.0.1", "prismarine-block": "^1.0.1", - "prismarine-chunk": "Flynnn/prismarine-chunk#master", + "prismarine-chunk": "^1.4.0", "prismarine-entity": "^0.2.0", "prismarine-item": "^1.0.1", "prismarine-recipe": "^1.0.1",
4
diff --git a/tests/e2e/specs/modules/tagmanager/setup.test.js b/tests/e2e/specs/modules/tagmanager/setup.test.js @@ -181,6 +181,7 @@ describe( 'Tag Manager module setup', () => { await activatePlugin( 'amp' ); await activatePlugin( 'e2e-tests-module-setup-tagmanager-api-mock' ); } ); + afterEach( async () => { await deactivatePlugin( 'amp' ); } ); @@ -214,11 +215,19 @@ describe( 'Tag Manager module setup', () => { await expect( page ).toMatchElement( '.googlesitekit-tagmanager__select-container--amp' ); await expect( page ).toMatchElement( '.googlesitekit-tagmanager__select-container--amp .mdc-floating-label', { text: 'AMP Container' } ); } ); - it( 'validates for logged-in users', async () => { - await expect( '/' ).toHaveValidAMPForUser(); + it( 'validates homepage AMP for logged-in users', async () => { + await expect( page ).toClick( 'button', { text: /confirm \& continue/i } ); + await page.waitForSelector( '.googlesitekit-publisher-win--win-success' ); + await expect( page ).toMatchElement( '.googlesitekit-publisher-win__title', { text: /Congrats on completing the setup for Tag Manager!/i } ); + await page.goto( createURL( '/', 'amp' ), { waitUntil: 'load' } ); + await expect( page ).toHaveValidAMPForUser(); } ); - it( 'validates for non-logged-in users', async () => { - await expect( '/' ).toHaveValidAMPForVisitor(); + it( 'validates homepage AMP for non-logged-in users', async () => { + await expect( page ).toClick( 'button', { text: /confirm \& continue/i } ); + await page.waitForSelector( '.googlesitekit-publisher-win--win-success' ); + await expect( page ).toMatchElement( '.googlesitekit-publisher-win__title', { text: /Congrats on completing the setup for Tag Manager!/i } ); + await page.goto( createURL( '/', 'amp' ), { waitUntil: 'load' } ); + await expect( page ).toHaveValidAMPForVisitor(); } ); } );
12
diff --git a/packages/embark-ui/src/components/Communication.js b/packages/embark-ui/src/components/Communication.js @@ -38,7 +38,7 @@ class Communication extends Component { } handleEnter(e, cb) { - if (e.which === 13) { + if (e.key === 'Enter') { e.preventDefault(); cb(e); }
4
diff --git a/app-template/bitcoincom/appConfig.json b/app-template/bitcoincom/appConfig.json "windowsAppId": "804636ee-b017-4cad-8719-e58ac97ffa5c", "pushSenderId": "1036948132229", "description": "A Secure Bitcoin Wallet", - "version": "4.0.2", - "androidVersion": "400201", + "version": "4.0.3", + "androidVersion": "400301", "_extraCSS": "", "_enabledExtensions": { "coinbase": false,
3
diff --git a/src/libs/API.js b/src/libs/API.js @@ -55,13 +55,11 @@ export default function API(network) { || parameters[parameterName] === null || parameters[parameterName] === undefined ) { - const parametersCopy = _.clone(parameters); - if (_(parametersCopy).has('authToken')) { - parametersCopy.authToken = '<redacted>'; - } - if (_(parametersCopy).has('password')) { - parametersCopy.password = '<redacted>'; - } + const propertiesToRedact = ['authToken', 'password', 'partnerUserSecret', 'twoFactorAuthCode']; + const parametersCopy = _.chain(parameters) + .clone() + .mapObject((val, key) => (_.contains(propertiesToRedact, key) ? '<redacted>' : val)) + .value(); const keys = _(parametersCopy).keys().join(', ') || 'none'; // eslint-disable-next-line max-len throw new Error(`Parameter ${parameterName} is required for "${commandName}". Supplied parameters: ${keys}`);
7
diff --git a/src/utils/detect-server.js b/src/utils/detect-server.js @@ -15,7 +15,7 @@ module.exports.serverSettings = async (devConfig, flags, projectDir, log) => { if (flags.dir) { settings = await getStaticServerSettings(settings, flags, projectDir, log) if (['command','targetPort'].some(p => devConfig.hasOwnProperty(p))) { - throw new Error('"command" or "targetPort" options cannot be used in conjunction with "dir" flag') + throw new Error('"command" or "targetPort" options cannot be used in conjunction with "dir" flag which is used to run a static server') } } else if (devConfig.framework === '#auto' && !(devConfig.command && devConfig.targetPort)) { let settingsArr = []
7
diff --git a/src/client/js/components/Admin/Export/ExportPage.jsx b/src/client/js/components/Admin/Export/ExportPage.jsx @@ -156,6 +156,7 @@ class ExportPage extends React.Component { zipFileStats, isExporting, isZipping: false, + isExported: !isExporting, progressList, }); } @@ -180,7 +181,7 @@ class ExportPage extends React.Component { const zipCol = ( <div className="col-md-12" key="progressBarForZipping"> <ExportingProgressBar - header="Zip" + header="Zip Files" currentCount={1} totalCount={1} isInProgress={isZipping} @@ -200,14 +201,17 @@ class ExportPage extends React.Component { render() { const { t } = this.props; + const { isExporting, isExported, progressList } = this.state; - const showExportingData = (this.state.isExported || this.state.isExporting) && (this.state.progressList != null); + const showExportingData = (isExported || isExporting) && (progressList != null); return ( <Fragment> <h2>{t('Export Data')}</h2> - <button type="button" className="btn btn-default" onClick={this.openExportModal}>{t('export_management.create_new_exported_data')}</button> + <button type="button" className="btn btn-default" disabled={isExporting} onClick={this.openExportModal}> + {t('export_management.create_new_exported_data')} + </button> { showExportingData && ( <div className="mt-5">
7
diff --git a/spark/components/stepper/vanilla/stepper.stories.js b/spark/components/stepper/vanilla/stepper.stories.js @@ -462,8 +462,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-content sprk-c-Stepper__step-content--has-description"> <span class="sprk-c-Stepper__step-header sprk-b-Link sprk-b-Link--plain" - aria-controls="target-1" - id="step-1" + aria-controls="sc-target-1" + id="sc-step-1" > <span class="sprk-c-Stepper__step-icon"></span> <h3 class="sprk-c-Stepper__step-heading" data-sprk-stepper="heading"> @@ -474,8 +474,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-description" data-sprk-stepper="description" - id="target-1" - aria-labelledby="step-1" + id="sc-target-1" + aria-labelledby="sc-step-1" role="tabpanel" > <p class="sprk-b-TypeBodyTwo"> @@ -493,8 +493,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-content sprk-c-Stepper__step-content--has-description"> <span class="sprk-c-Stepper__step-header sprk-b-Link sprk-b-Link--plain" - aria-controls="target-2" - id="step-2" + aria-controls="sc-target-2" + id="sc-step-2" > <span class="sprk-c-Stepper__step-icon"></span> <h3 class="sprk-c-Stepper__step-heading" data-sprk-stepper="heading"> @@ -505,8 +505,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-description sprk-u-HideWhenJs" data-sprk-stepper="description" - aria-labelledby="step-2" - id="target-2" + aria-labelledby="sc-step-2" + id="sc-target-2" role="tabpanel" > <p class="sprk-b-TypeBodyTwo"> @@ -524,8 +524,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-content sprk-c-Stepper__step-content--has-description"> <span class="sprk-c-Stepper__step-header sprk-b-Link sprk-b-Link--plain" - aria-controls="target-3" - id="step-3" + aria-controls="sc-target-3" + id="sc-step-3" > <span class="sprk-c-Stepper__step-icon"></span> <h3 class="sprk-c-Stepper__step-heading" data-sprk-stepper="heading"> @@ -536,8 +536,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-description sprk-u-HideWhenJs" data-sprk-stepper="description" - aria-labelledby="step-3" - id="target-3" + aria-labelledby="sc-step-3" + id="sc-target-3" role="tabpanel" > <p class="sprk-b-TypeBodyTwo"> @@ -555,8 +555,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-content sprk-c-Stepper__step-content--has-description"> <span class="sprk-c-Stepper__step-header sprk-b-Link sprk-b-Link--plain" - aria-controls="target-4" - id="step-4" + aria-controls="sc-target-4" + id="sc-step-4" > <span class="sprk-c-Stepper__step-icon"></span> <h3 class="sprk-c-Stepper__step-heading" data-sprk-stepper="heading"> @@ -567,8 +567,8 @@ export const stepperWithCarousel = () => { <div class="sprk-c-Stepper__step-description sprk-u-HideWhenJs" data-sprk-stepper="description" - aria-labelledby="step-4" - id="target-4" + aria-labelledby="sc-step-4" + id="sc-target-4" role="tabpanel" > <p class="sprk-b-TypeBodyTwo">
3
diff --git a/.github/libs/GitUtils.js b/.github/libs/GitUtils.js @@ -29,7 +29,7 @@ function getValidMergedPRs(commitMessages) { return mergedPRs; } - const match = commitMessage.match(/Merge pull request #(\d+) from (?!Expensify\/(?:master|main|version-))/); + const match = commitMessage.match(/Merge pull request #(\d+) from (?!Expensify\/(?:master|main|version-|update-staging-from-main|update-production-from-staging))/); if (!_.isNull(match) && match[1]) { mergedPRs.push(match[1]); }
8
diff --git a/Specs/Scene/PostProcessStageLibrarySpec.js b/Specs/Scene/PostProcessStageLibrarySpec.js import { Cartesian3, - HeadingPitchRange, HeadingPitchRoll, - Matrix4, Transforms, Model, PostProcessStageLibrary, @@ -12,10 +10,14 @@ import createCanvas from "../createCanvas.js"; import createScene from "../createScene.js"; import pollToPromise from "../pollToPromise.js"; import ViewportPrimitive from "../ViewportPrimitive.js"; +import loadAndZoomToModel from "./ModelExperimental/loadAndZoomToModel.js"; describe( "Scene/PostProcessStageLibrary", function () { + const boxTexturedUrl = + "./Data/Models/GltfLoader/BoxTextured/glTF/BoxTextured.gltf"; + let scene; beforeAll(function () { @@ -38,46 +40,6 @@ describe( scene.renderForSpecs(); }); - let model; - - function loadModel(url) { - model = scene.primitives.add( - Model.fromGltf({ - modelMatrix: Transforms.eastNorthUpToFixedFrame( - Cartesian3.fromDegrees(0.0, 0.0, 100.0) - ), - url: url, - }) - ); - model.zoomTo = function () { - const camera = scene.camera; - const center = Matrix4.multiplyByPoint( - model.modelMatrix, - model.boundingSphereInternal.center, - new Cartesian3() - ); - const r = - 4.0 * - Math.max(model.boundingSphereInternal.radius, camera.frustum.near); - camera.lookAt(center, new HeadingPitchRange(0.0, 0.0, r)); - }; - - return pollToPromise( - function () { - // Render scene to progressively load the model - scene.renderForSpecs(); - return model.ready; - }, - { timeout: 10000 } - ) - .then(function () { - return model; - }) - .catch(function () { - return Promise.reject(model); - }); - } - it("black and white", function () { const fs = "void main() { \n" + @@ -119,12 +81,13 @@ describe( }); }); - // glTF 1.0 model needs to be converted to 2.0 - xit("per-feature black and white", function () { - return loadModel("./Data/Models/Box/CesiumBoxTest.gltf").then( - function () { - model.zoomTo(); - + it("per-feature black and white", function () { + return loadAndZoomToModel( + { + url: boxTexturedUrl, + }, + scene + ).then(function (model) { const stage = scene.postProcessStages.add( PostProcessStageLibrary.createBlackAndWhiteStage() ); @@ -147,8 +110,7 @@ describe( expect(rgba).not.toEqual(color); }); }); - } - ); + }); }); it("brightness", function () { @@ -327,7 +289,7 @@ describe( expect(blur.uniforms.stepSize).toEqual(2.0); }); - // glTF 1.0 model needs to be converted to 2.0 + // TODO: rewrite this test using loadAndZoomToModel and boxTextured xit("depth of field", function () { if (!scene.context.depthTexture) { return; @@ -460,7 +422,7 @@ describe( expect(ao.uniforms.blurStepSize).toEqual(2.0); }); - // glTF 1.0 model needs to be converted to 2.0 + // TODO: rewrite this test using loadAndZoomToModel and boxTextured xit("bloom", function () { const origin = Cartesian3.fromDegrees(-123.0744619, 44.0503706, 100.0); const modelMatrix = Transforms.headingPitchRollToFixedFrame(
1
diff --git a/README.md b/README.md @@ -40,6 +40,11 @@ Thanks to netlify, you can test the following builds: [Try SVG-edit 5.1.0 here](https://6098683962bf91702907ee33--svgedit.netlify.app/editor/svg-editor.html) +[Try SVG-edit 6.1.0 here](https://60a0000fc9900b0008fd268d--svgedit.netlify.app/editor/index.html) + +/ + + ## Installation
11
diff --git a/core/ui/block_space/block_space_editor.js b/core/ui/block_space/block_space_editor.js @@ -558,7 +558,7 @@ Blockly.BlockSpaceEditor.prototype.detectBrokenControlPoints = function() { */ var container = Blockly.createSvgElement('g', {}, this.svg_); Blockly.createSvgElement('path', - {'d': 'm 0,0 c 0,-5 0,-5 0,0 H 50 V 50 z'}, container); + {'d': 'M 0,50 C 75,-25 75,50 125,0 Z'}, container); if (Blockly.isMsie() || Blockly.isTrident()) { container.style.display = "inline"; /* reqd for IE */
4
diff --git a/lib/node_modules/@stdlib/_tools/search/pkg-index/lib/create.js b/lib/node_modules/@stdlib/_tools/search/pkg-index/lib/create.js @@ -107,7 +107,7 @@ function createIndex( files ) { }); // If a document description matches the search query, we are a little less confident that the document is relevant, as the description could mislead based on its content, but reasonable probability that the document is relevant regardless... - this.field( 'description', { + this.field( 'desc', { 'boost': 5 }); @@ -117,7 +117,7 @@ function createIndex( files ) { }); // A document's introduction could mention something relevant to the search query, but only in passing. Accordingly, the introduction is a signal, but not as important as the title and description... - this.field( 'introduction', { + this.field( 'intro', { 'boost': 1 }); @@ -157,8 +157,8 @@ function createIndex( files ) { blob = { 'title': title, - 'description': desc, - 'introduction': sectionText( file, 'intro' ), + 'desc': desc, + 'intro': sectionText( file, 'intro' ), 'keywords': keywords, 'id': id };
10
diff --git a/README.md b/README.md @@ -5,7 +5,6 @@ with animated digital sketches in order to demonstrate ideas and concepts (espec of a live presentation or conversation. Sketches can display 2D and 3D graphics, move and animate, respond to input and output, and be linked together to allow for more complex logical connections and behaviors. -(PARAPHRASED FROM GABRIEL'S VIDEO) A growing library of sketches--from creatures to math and physics objects--is available, and Chalktalk continues to evolve. @@ -27,6 +26,6 @@ or copy a template (from sketches/templates) into the sketches directory to get In your file, change the value of `this.label` and begin customizing your sketches. ### License -(to come) <- SOON +(to come)
2
diff --git a/assets/js/components/legacy-setup/SetupUsingGCP.js b/assets/js/components/legacy-setup/SetupUsingGCP.js @@ -193,13 +193,13 @@ class SetupUsingGCP extends Component { async onButtonClick() { const { isSiteKitConnected, connectURL } = this.state; - const { proxySetupURL, isUsingProxy } = this.props; + const { proxySetupURL } = this.props; if ( proxySetupURL ) { await trackEvent( VIEW_CONTEXT_DASHBOARD_SPLASH, 'start_user_setup', - isUsingProxy ? 'proxy' : 'custom-oauth' + 'custom-oauth' ); } @@ -207,7 +207,7 @@ class SetupUsingGCP extends Component { await trackEvent( VIEW_CONTEXT_DASHBOARD_SPLASH, 'start_site_setup', - isUsingProxy ? 'proxy' : 'custom-oauth' + 'custom-oauth' ); } @@ -411,7 +411,6 @@ export default compose( notification: 'authentication_success', } ), - isUsingProxy: select( CORE_SITE ).isUsingProxy(), proxySetupURL: select( CORE_SITE ).getProxySetupURL(), }; } )
2
diff --git a/test/jasmine/tests/gl3dlayout_test.js b/test/jasmine/tests/gl3dlayout_test.js @@ -399,12 +399,15 @@ describe('Test Gl3d layout defaults', function() { scene: 'scene' }]); - expect(layoutOut.scene.xaxis.autotypenumbers).toBe('strict'); - expect(layoutOut.scene.yaxis.autotypenumbers).toBe('convert types'); - expect(layoutOut.scene.zaxis.autotypenumbers).toBe('strict'); - expect(layoutOut.scene.xaxis.type).toBe('category'); - expect(layoutOut.scene.yaxis.type).toBe('linear'); - expect(layoutOut.scene.zaxis.type).toBe('category'); + var xaxis = layoutOut.scene.xaxis; + var yaxis = layoutOut.scene.yaxis; + var zaxis = layoutOut.scene.zaxis; + expect(xaxis.autotypenumbers).toBe('strict'); + expect(yaxis.autotypenumbers).toBe('convert types'); + expect(zaxis.autotypenumbers).toBe('strict'); + expect(xaxis.type).toBe('category'); + expect(yaxis.type).toBe('linear'); + expect(zaxis.type).toBe('category'); }); it('should enable converting numeric strings using axis.autotypenumbers and inherit defaults from layout.autotypenumbers', function() { @@ -424,12 +427,112 @@ describe('Test Gl3d layout defaults', function() { scene: 'scene' }]); - expect(layoutOut.scene.xaxis.autotypenumbers).toBe('convert types'); - expect(layoutOut.scene.yaxis.autotypenumbers).toBe('strict'); - expect(layoutOut.scene.zaxis.autotypenumbers).toBe('convert types'); - expect(layoutOut.scene.xaxis.type).toBe('linear'); - expect(layoutOut.scene.yaxis.type).toBe('category'); - expect(layoutOut.scene.zaxis.type).toBe('linear'); + var xaxis = layoutOut.scene.xaxis; + var yaxis = layoutOut.scene.yaxis; + var zaxis = layoutOut.scene.zaxis; + expect(xaxis.autotypenumbers).toBe('convert types'); + expect(yaxis.autotypenumbers).toBe('strict'); + expect(zaxis.autotypenumbers).toBe('convert types'); + expect(xaxis.type).toBe('linear'); + expect(yaxis.type).toBe('category'); + expect(zaxis.type).toBe('linear'); + }); + + ['convert types', 'strict'].forEach(function(autotypenumbers) { + it('with autotypenumbers: *' + autotypenumbers + '* should autotype *linear* case of 2d array', function() { + var typedArray = new Float32Array(2); + typedArray[0] = 0; + typedArray[1] = 1; + + supplyLayoutDefaults({ + scene: { + xaxis: { autotypenumbers: autotypenumbers }, + yaxis: { autotypenumbers: autotypenumbers }, + zaxis: { autotypenumbers: autotypenumbers } + } + }, layoutOut, [{ + scene: 'scene', + type: 'surface', + x: [0, 1], + y: typedArray, + z: [ + typedArray, + [1, 0] + ] + }]); + + var xaxis = layoutOut.scene.xaxis; + var yaxis = layoutOut.scene.yaxis; + var zaxis = layoutOut.scene.zaxis; + expect(xaxis.autotypenumbers).toBe(autotypenumbers); + expect(yaxis.autotypenumbers).toBe(autotypenumbers); + expect(zaxis.autotypenumbers).toBe(autotypenumbers); + expect(xaxis.type).toBe('linear'); + expect(yaxis.type).toBe('linear'); + expect(zaxis.type).toBe('linear'); + }); + }); + + ['convert types', 'strict'].forEach(function(autotypenumbers) { + it('with autotypenumbers: *' + autotypenumbers + '* should autotype *category* case of 2d array', function() { + supplyLayoutDefaults({ + scene: { + xaxis: { autotypenumbers: autotypenumbers }, + yaxis: { autotypenumbers: autotypenumbers }, + zaxis: { autotypenumbers: autotypenumbers } + } + }, layoutOut, [{ + scene: 'scene', + type: 'surface', + x: ['A', 'B'], + y: ['C', 'D'], + z: [ + ['E', 'F'], + ['F', 'E'] + ] + }]); + + var xaxis = layoutOut.scene.xaxis; + var yaxis = layoutOut.scene.yaxis; + var zaxis = layoutOut.scene.zaxis; + expect(xaxis.autotypenumbers).toBe(autotypenumbers); + expect(yaxis.autotypenumbers).toBe(autotypenumbers); + expect(zaxis.autotypenumbers).toBe(autotypenumbers); + expect(xaxis.type).toBe('category'); + expect(yaxis.type).toBe('category'); + expect(zaxis.type).toBe('category'); + }); + }); + + ['convert types', 'strict'].forEach(function(autotypenumbers) { + it('with autotypenumbers: *' + autotypenumbers + '* should autotype *date* case of 2d array', function() { + supplyLayoutDefaults({ + scene: { + xaxis: { autotypenumbers: autotypenumbers }, + yaxis: { autotypenumbers: autotypenumbers }, + zaxis: { autotypenumbers: autotypenumbers } + } + }, layoutOut, [{ + scene: 'scene', + type: 'surface', + x: ['00-01', '00-02'], + y: ['00-01', '00-02'], + z: [ + ['00-01', '00-02'], + ['00-02', '00-01'] + ] + }]); + + var xaxis = layoutOut.scene.xaxis; + var yaxis = layoutOut.scene.yaxis; + var zaxis = layoutOut.scene.zaxis; + expect(xaxis.autotypenumbers).toBe(autotypenumbers); + expect(yaxis.autotypenumbers).toBe(autotypenumbers); + expect(zaxis.autotypenumbers).toBe(autotypenumbers); + expect(xaxis.type).toBe('date'); + expect(yaxis.type).toBe('date'); + expect(zaxis.type).toBe('date'); + }); }); }); });
0
diff --git a/docs/Troubleshooting.md b/docs/Troubleshooting.md @@ -86,3 +86,23 @@ function watchRequestActions() { } } ``` + +### Bundling my Saga with RollupJS fails + +If you want to bundle your ES6 (or JSNext) react project with RollupJS, `rollup-plugin-node-resolve` and the `jsnext:true` option you'll have to import `effects` in a different way to ensure the es6 variant of `redux-saga` will be loaded. + +So instead of importing like this: + +```javascript +import createSagaMiddleware, { takeEvery } from "redux-saga"; +import { call, put } from "redux-saga/effects"; // <-- this will fail +``` + +use this variant which does essentially the same: + +```javascript +import createSagaMiddleware, { takeEvery, effects } from "redux-saga"; +const { call, put } = effects // same thing for utils +``` + +See https://github.com/redux-saga/redux-saga/issues/689 for reference.
3
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml @@ -4,11 +4,46 @@ jobs: build_job: runs-on: ubuntu-latest name: build dockers - if: ${{ + if: | github.event.deployment.environment == 'dev1' || github.event.deployment.environment == 'cicd' || - github.event.deployment.environment == 'test' }} + github.event.deployment.environment == 'test' steps: + - name: get environment + run: | + echo "environment is: $DEPLOY_ENVIRONMENT" + URL='' + case "$DEPLOY_ENVIRONMENT" in + *dev1*) + export URL=$DEV1_URL + export KUBE_CONFIG_DATA=$DEV1_KUBE_CONFIG_DATA + ;; + *test*) + export URL=$TEST_URL + export KUBE_CONFIG_DATA=$TEST_KUBE_CONFIG_DATA + ;; + *cicd*) + export URL=$CICD_URL + export KUBE_CONFIG_DATA=$CICD_KUBE_CONFIG_DATA + ;; + **) + echo "unknown environment. defaulting to cicd" + export URL=$CICD_URL + export KUBE_CONFIG_DATA=$CICD_KUBE_CONFIG_DATA + ;; + esac + echo URL=$URL >> $GITHUB_ENV + # echo KUBE_CONFIG_DATA=$KUBE_CONFIG_DATA >> $GITHUB_ENV + echo "$KUBE_CONFIG_DATA" | base64 --decode > /tmp/config + echo KUBECONFIG=/tmp/config >> $GITHUB_ENV + env: + DEPLOY_ENVIRONMENT: "${{ github.event.deployment.environment }}" + CICD_URL: ${{ secrets.CICD_URL }} + CICD_KUBE_CONFIG_DATA: ${{ secrets.CICD_KUBECONFIG }} + DEV1_URL: ${{ secrets.DEV1_URL }} + DEV1_KUBE_CONFIG_DATA: ${{ secrets.DEV1_KUBECONFIG }} + TEST_URL: ${{ secrets.TEST_KUBERNETES_MASTER_IP }} + TEST_KUBE_CONFIG_DATA: ${{ secrets.TEST_KUBECONFIG }} - name: set deployment status to in progress id: start_deployment uses: octokit/[email protected] @@ -17,7 +52,7 @@ jobs: repository: ${{ github.repository }} deployment: ${{ github.event.deployment.id }} environment: dev - environment_url: https://${{ secrets.DEV1_URL }}/hkube/dashboard/ + environment_url: https://${{ env.URL }}/hkube/dashboard/ log_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} state: in_progress mediaType: '{"previews": ["flash", "ant-man"]}' @@ -93,7 +128,7 @@ jobs: path: /tmp/chart.tgz - name: set values run: | - envsubst < ${{ github.workspace }}/scripts/values-dev1-template.yml > /tmp/dev1.yml + envsubst < ${{ github.workspace }}/scripts/values-${{ github.event.deployment.environment }}-template.yml > /tmp/dev1.yml shell: bash env: DOCKER_BUILD_PUSH_PASSWORD: ${{ secrets.DOCKER_BUILD_PUSH_PASSWORD }} @@ -111,7 +146,7 @@ jobs: repository: ${{ github.repository }} deployment: ${{ github.event.deployment.id }} environment: dev - environment_url: https://${{ secrets.DEV1_URL }}/hkube/dashboard/ + environment_url: https://${{ env.URL }}/hkube/dashboard/ log_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} mediaType: '{"previews": ["ant-man"]}' state: failure @@ -149,8 +184,10 @@ jobs: export KUBE_CONFIG_DATA=$CICD_KUBE_CONFIG_DATA ;; esac + echo "set params:" echo URL=$URL >> $GITHUB_ENV # echo KUBE_CONFIG_DATA=$KUBE_CONFIG_DATA >> $GITHUB_ENV + echo "######## update kubeconfig: #######" echo "$KUBE_CONFIG_DATA" | base64 --decode > /tmp/config echo KUBECONFIG=/tmp/config >> $GITHUB_ENV env: @@ -184,7 +221,7 @@ jobs: repository: ${{ github.repository }} deployment: ${{ github.event.deployment.id }} environment: dev - environment_url: https://${{ secrets.DEV1_URL }}/hkube/dashboard/ + environment_url: https://${{ env.URL }}/hkube/dashboard/ log_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} mediaType: '{"previews": ["ant-man"]}' state: success @@ -200,7 +237,7 @@ jobs: repository: ${{ github.repository }} deployment: ${{ github.event.deployment.id }} environment: dev - environment_url: https://${{ secrets.DEV1_URL }}/hkube/dashboard/ + environment_url: https://${{ env.URL }}/hkube/dashboard/ log_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} mediaType: '{"previews": ["ant-man"]}' state: failure
0
diff --git a/particle-system.js b/particle-system.js @@ -17,7 +17,7 @@ const maxParticles = 256; const canvasSize = 4096; const frameSize = 512; const rowSize = Math.floor(canvasSize/frameSize); -const maxNumFrames = rowSize * rowSize; +// const maxNumFrames = rowSize * rowSize; const planeGeometryNonInstanced = new THREE.PlaneBufferGeometry(1, 1); const planeGeometry = new THREE.InstancedBufferGeometry(); @@ -26,19 +26,25 @@ for (const k in planeGeometryNonInstanced.attributes) { } planeGeometry.index = planeGeometryNonInstanced.index; -let fileSpecs = []; -const fileSpecsLoadPromise = (async () => { - const res = await fetch(`${urlPrefix}fx-files.json`); - fileSpecs = await res.json(); -})(); - -const _makeParticleMaterial = name => { - // console.log('_makeParticleMaterial', texture, numFrames); +class ParticleSet { + constructor(urlPrefix, jsonUrl) { + this.urlPrefix = urlPrefix; + this.fileSpecs = []; + this.loadPromise = (async () => { + const res = await fetch(jsonUrl); + this.fileSpecs = await res.json(); + })(); + this.cache = new Map(); + } + waitForLoad() { + return this.loadPromise; + } + makeParticleMaterial(name) { const promise = (async () => { - await fileSpecsLoadPromise; + await this.waitForLoad(); - const fileSpec = fileSpecs.find(f => f.name === name); + const fileSpec = this.fileSpecs.find(f => f.name === name); const {numFrames} = fileSpec; const texture = await new Promise((accept, reject) => { @@ -182,7 +188,17 @@ const _makeParticleMaterial = name => { }); material.promise = promise; return material; -}; + } + getParticleMaterial(name) { + let entry = this.cache.get(name); + if (entry === undefined) { + entry = this.makeParticleMaterial(name); + this.cache.set(name, entry); + } + return entry; + } +} +const particleSet = new ParticleSet(urlPrefix, `${urlPrefix}fx-files.json`); class Particle extends THREE.Object3D { constructor(index, startTime, endTime, parent) { @@ -206,7 +222,7 @@ class ParticleMesh extends THREE.InstancedMesh { geometry.setAttribute('p', new THREE.InstancedBufferAttribute(new Float32Array(maxParticles * 3), 3)); // geometry.setAttribute('q', new THREE.InstancedBufferAttribute(new Float32Array(maxParticles * 4), 4)); geometry.setAttribute('t', new THREE.InstancedBufferAttribute(new Float32Array(maxParticles * 2), 2)); - const material = _makeParticleMaterial(name); + const material = particleSet.getParticleMaterial(name); material.promise.then(() => { this.visible = true; }); @@ -306,5 +322,10 @@ export const createParticleSystem = e => { } }); + rootParticleMesh.preload = async name => { + const material = particleSet.getParticleMaterial(name); + await material.promise; + }; + return rootParticleMesh; }; \ No newline at end of file
0
diff --git a/src/components/fields/Colorscale.js b/src/components/fields/Colorscale.js @@ -13,7 +13,7 @@ class Colorscale extends Component { onUpdate(colorscale, colorscaleType) { if (Array.isArray(colorscale)) { if (this.context.container.type === 'pie') { - const numPieSlices = this.context.container.labels.length; + const numPieSlices = this.context.graphDiv.calcdata[0].length + 1; const adjustedColorscale = adjustColorscale( colorscale, numPieSlices,
4
diff --git a/quest-manager.js b/quest-manager.js import {scene} from './renderer.js'; +import * as metaverseModules from './metaverse-modules.js'; +import metaversefile from 'metaversefile'; // import {OffscreenEngine} from './offscreen-engine.js'; +const _makePathApp = () => { + const app = metaversefile.createApp(); + // console.log('got metaverse modules', metaverseModules.modules, metaverseModules.modules.path); + app.setComponent('line', [ + [92.5, 0, -33], + [19.5, -4, 59.5], + ]); + app.addModule(metaverseModules.modules.path); + return app; +}; + class Quest { constructor(spec) { this.name = spec.name; @@ -8,7 +21,41 @@ class Quest { this.condition = spec.condition; this.drops = spec.drops; - this.pathApp = null; + /* { + "position": [ + 0, + 0, + 0 + ], + "quaternion": [ + 0, + 0, + 0, + 1 + ], + "components": [ + { + "key": "line", + "value": [ + [92.5, 0, -33], + [19.5, -4, 59.5] + ] + }, + { + "key": "bounds", + "value": [ + [19, -4.5, 57], + [20, 0, 58] + ] + } + ], + "start_url": "../metaverse_modules/quest/", + "dynamic": true + }, */ + + this.pathApp = _makePathApp(); + scene.add(this.pathApp); + this.conditionFn = (() => { switch (this.condition) { case 'clearMobs': { @@ -29,7 +76,9 @@ class Quest { this.conditionFn && this.conditionFn(); } destroy() { - + scene.remove(this.pathApp); + this.pathApp.destroy(); + this.pathApp = null; } }
0
diff --git a/app/modules/main/containers/Wallet.js b/app/modules/main/containers/Wallet.js @@ -10,6 +10,7 @@ import MenuContainer from './Menu'; import SidebarContainer from './Sidebar'; import Notifications from '../../../shared/components/Notifications'; import WelcomeContainer from '../../../shared/containers/Welcome'; +import { setWalletMode } from '../../../shared/actions/wallet'; import * as ValidateActions from '../../../shared/actions/validate'; import background from '../../../renderer/assets/images/geometric-background.svg'; @@ -23,6 +24,9 @@ class WalletContainer extends Component<Props> { validateNode(settings.node, settings.chainId, false, true); this.state = { initialized: false }; } + if (settings.walletInit && settings.walletMode) { + actions.setWalletMode(settings.walletMode); + } } state = { initialized: true }; componentDidUpdate(prevProps) { @@ -136,6 +140,7 @@ function mapStateToProps(state) { function mapDispatchToProps(dispatch) { return { actions: bindActionCreators({ + setWalletMode, ...ValidateActions, }, dispatch) };
12
diff --git a/src/payment-flows/vault-capture.js b/src/payment-flows/vault-capture.js @@ -14,7 +14,7 @@ import { getLogger } from '../lib'; import type { PaymentFlow, PaymentFlowInstance, IsEligibleOptions, IsPaymentEligibleOptions, InitOptions, MenuOptions } from './types'; import { checkout, CHECKOUT_POPUP_DIMENSIONS } from './checkout'; -const VAULT_MIN_WIDTH = 350; +const VAULT_MIN_WIDTH = 0; function setupVaultCapture() { // pass
12
diff --git a/src/schema/deserialize.js b/src/schema/deserialize.js @@ -41,9 +41,9 @@ function runDeserialize(exception, map, schema, originalValue) { if (value === null && (schema.nullable || schema['x-nullable'])) return value; if (schema.allOf) { - const result = {}; const exception2 = exception.at('allOf'); if (schema.allOf[0].type === 'object') { + const result = {}; schema.allOf.forEach((schema, index) => { const v = runDeserialize(exception2.at(index), map, schema, originalValue); Object.assign(result, v)
7