filename
stringlengths 20
188
| language
stringclasses 3
values | AST-segments
stringlengths 0
204k
|
---|---|---|
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | 3000 );
$.post( {
type: 'POST' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | url: ajaxurl |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | data: data |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | dataType: 'json'
} ).done( function( response ) {
updateDirSizes( response.data || {} );
} ).always( function() {
var delay = ( new Date().getTime() ) - timestamp;
$( '.health-check-wp-paths-sizes.spinner' ).css( 'visibility' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | 'hidden' );
RecalculateProgression();
if ( delay > 3000 ) {
/*
* We have announced that we're waiting.
* Announce that we're ready after giving at least 3 seconds
* for the first announcement to be read out |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | or the two may collide.
*/
if ( delay > 6000 ) {
delay = 0;
} else {
delay = 6500 - delay;
}
window.setTimeout( function() {
wp.a11y.speak( __( 'All site health tests have finished running.' ) );
} |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | delay );
} else {
// Cancel the announcement.
window.clearTimeout( timeout );
}
$( document ).trigger( 'site-health-info-dirsizes-done' );
} );
}
function updateDirSizes( data ) {
var copyButton = $( 'button.button.copy-button' );
var clipboardText = copyButton.attr( 'data-clipboard-text' );
$.each( data |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | function( name |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | value ) {
var text = value.debug || value.size;
if ( typeof text !== 'undefined' ) {
clipboardText = clipboardText.replace( name + ': loading...' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | name + ': ' + text );
}
} );
copyButton.attr( 'data-clipboard-text' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | clipboardText );
pathsSizesSection.find( 'td[class]' ).each( function( i |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js | javascript | element ) {
var td = $( element );
var name = td.attr( 'class' );
if ( data.hasOwnProperty( name ) && data[ name ].size ) {
td.text( data[ name ].size );
}
} );
}
if ( isDebugTab ) {
if ( pathsSizesSection.length ) {
getDirectorySizes();
} else {
RecalculateProgression();
}
}
} ); |
NEARFoundation_trulioo-app_ui_src_App.test.js | javascript | /* eslint-disable no-undef */
/* eslint-disable react/react-in-jsx-scope */
import { render |
NEARFoundation_trulioo-app_ui_src_App.test.js | javascript | screen } from '@testing-library/react';
import App from './App'; |
NEARFoundation_trulioo-app_ui_src_App.test.js | javascript | test('renders learn react link' |
NEARFoundation_trulioo-app_ui_src_App.test.js | javascript | () => {
render(<App />);
const linkElement = screen.getByText(/learn react/iu);
expect(linkElement).toBeInTheDocument();
}); |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* External dependencies
*/
import { __ } from '@wordpress/i18n';
import { InnerBlocks } from '@wordpress/editor';
import { registerBlockType } from '@wordpress/blocks'; |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | import { DEFAULT_HEIGHT } from '@woocommerce/block-settings';
import { IconFolderStar } from '@woocommerce/block-components/icons';
/**
* Internal dependencies
*/
import './style.scss'; |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | import './editor.scss';
import Block from './block';
import { example } from './example';
/**
* Register and run the "Featured Category" block.
*/ |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | registerBlockType( 'woocommerce/featured-category' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | {
title: __( 'Featured Category' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | 'woocommerce' ) |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | icon: {
src: <IconFolderStar /> |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | foreground: '#96588a' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | category: 'woocommerce' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | keywords: [ __( 'WooCommerce' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | 'woocommerce' ) ] |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | description: __(
'Visually highlight a product category and encourage prompt action.' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | 'woocommerce'
) |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | supports: {
align: [ 'wide' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | 'full' ] |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | html: false |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | example |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | attributes: {
/**
* Alignment of content inside block.
*/
contentAlign: {
type: 'string' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: 'center' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Percentage opacity of overlay.
*/
dimRatio: {
type: 'number' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: 50 |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Toggle for edit mode in the block preview.
*/
editMode: {
type: 'boolean' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: true |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Focus point for the background image
*/
focalPoint: {
type: 'object' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* A fixed height for the block.
*/
height: {
type: 'number' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: DEFAULT_HEIGHT |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* ID for a custom image |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | overriding the product's featured image.
*/
mediaId: {
type: 'number' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: 0 |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* URL for a custom image |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | overriding the product's featured image.
*/
mediaSrc: {
type: 'string' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: '' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* The overlay color |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | from the color list.
*/
overlayColor: {
type: 'string' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* The overlay color |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | if a custom color value.
*/
customOverlayColor: {
type: 'string' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Text for the category link.
*/
linkText: {
type: 'string' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: __( 'Shop now' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | 'woocommerce' ) |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* The category ID to display.
*/
categoryId: {
type: 'number' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Show the category description.
*/
showDesc: {
type: 'boolean' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: true |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Category preview.
*/
previewCategory: {
type: 'object' |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | default: null |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Renders and manages the block.
*/
edit( props ) {
return <Block { ...props } />;
} |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | /**
* Block content is rendered in PHP |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | not via save function.
*/
save() {
return <InnerBlocks.Content />;
} |
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-content_plugins_woocommerce_packages_woocommerce-blocks_assets_js_blocks_featured-category_index.js | javascript | } ); |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | /*! ColReorder 1.1.3
* ©2010-2014 SpryMedia Ltd - datatables.net/license
*/ |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | **
* @summary ColReorder
* @description Provide the ability to reorder columns in a DataTable
* @version 1.1.3
* @file dataTables.colReorder.js
* @author SpryMedia Ltd (www.sprymedia.co.uk)
* @contact www.sprymedia.co.uk/contact
* @copyright Copyright 2010-2014 SpryMedia Ltd.
*
* This source file is free software |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | available under the following license:
* MIT license - http://datatables.net/license/mit
*
* This source file is distributed in the hope that it will be useful |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
*
* For details please refer to: http://www.datatables.net
*/ |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | function(window |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | document |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | undefined) {
/**
* Switch the key value pairing of an index array to be value key (i.e. the old value is now the
* key). For example consider [ 2 |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | 0 |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | 1 ] this would be returned as [ 1 |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | 2 |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | 0 ].
* @method fnInvertKeyValues
* @param array aIn Array to switch around
* @returns array
*/
function fnInvertKeyValues( aIn )
{
var aRet=[];
for ( var i=0 |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | iLen=aIn.length ; i<iLen ; i++ )
{
aRet[ aIn[i] ] = i;
}
return aRet;
}
/**
* Modify an array by switching the position of two elements
* @method fnArraySwitch
* @param array aArray Array to consider |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | will be modified by reference (i.e. no return)
* @param int iFrom From point
* @param int iTo Insert point
* @returns void
*/
function fnArraySwitch( aArray |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | iFrom |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | iTo )
{
var mStore = aArray.splice( iFrom |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | 1 )[0];
aArray.splice( iTo |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | 0 |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | mStore );
}
/**
* Switch the positions of nodes in a parent node (note this is specifically designed for
* table rows). Note this function considers all element nodes under the parent!
* @method fnDomSwitch
* @param string sTag Tag to consider
* @param int iFrom Element to move
* @param int Point to element the element to (before this point) |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | can be null for append
* @returns void
*/
function fnDomSwitch( nParent |
miguelacosta84_NEAR-lista-de-precios_web_public_datatables_new_extensions_ColReorder_js_dataTables.colReorder.js | javascript | iFrom |