/*! elementor - v3.18.0 - 20-12-2023 */
.elementor-widget-text-editor.elementor-drop-cap-view-stacked .elementor-drop-cap{background-color:#69727d;color:#fff}.elementor-widget-text-editor.elementor-drop-cap-view-framed .elementor-drop-cap{color:#69727d;border:3px solid;background-color:transparent}.elementor-widget-text-editor:not(.elementor-drop-cap-view-default) .elementor-drop-cap{margin-top:8px}.elementor-widget-text-editor:not(.elementor-drop-cap-view-default) .elementor-drop-cap-letter{width:1em;height:1em}.elementor-widget-text-editor .elementor-drop-cap{float:left;text-align:center;line-height:1;font-size:50px}.elementor-widget-text-editor .elementor-drop-cap-letter{display:inline-block}/**
* Internal dependencies
*/
import { buildTermsTree } from '../utils';
const list = [
{ id: 1, name: 'Apricots', parent: 0 },
{ id: 2, name: 'Clementine', parent: 0 },
{ id: 3, name: 'Elderberry', parent: 2 },
{ id: 4, name: 'Guava', parent: 2 },
{ id: 5, name: 'Lychee', parent: 3 },
{ id: 6, name: 'Mulberry', parent: 0 },
{ id: 7, name: 'Tamarind', parent: 5 },
];
describe( 'buildTermsTree', () => {
test( 'should return an empty array on empty input', () => {
const tree = buildTermsTree( [] );
expect( tree ).toEqual( [] );
} );
test( 'should return a flat array when there are no parent relationships', () => {
const tree = buildTermsTree( [
{ id: 1, name: 'Apricots', parent: 0 },
{ id: 2, name: 'Clementine', parent: 0 },
] );
expect( tree ).toEqual( [
{
id: 1,
name: 'Apricots',
parent: 0,
breadcrumbs: [],
children: [],
},
{
id: 2,
name: 'Clementine',
parent: 0,
breadcrumbs: [],
children: [],
},
] );
} );
test( 'should return a tree of items', () => {
const tree = buildTermsTree( list );
expect( tree ).toEqual( [
{
id: 1,
name: 'Apricots',
parent: 0,
breadcrumbs: [],
children: [],
},
{
id: 2,
name: 'Clementine',
parent: 0,
breadcrumbs: [],
children: [
{
id: 3,
name: 'Elderberry',
parent: 2,
breadcrumbs: [ 'Clementine' ],
children: [
{
id: 5,
name: 'Lychee',
parent: 3,
breadcrumbs: [ 'Clementine', 'Elderberry' ],
children: [
{
id: 7,
name: 'Tamarind',
parent: 5,
breadcrumbs: [
'Clementine',
'Elderberry',
'Lychee',
],
children: [],
},
],
},
],
},
{
id: 4,
name: 'Guava',
parent: 2,
breadcrumbs: [ 'Clementine' ],
children: [],
},
],
},
{
id: 6,
name: 'Mulberry',
parent: 0,
breadcrumbs: [],
children: [],
},
] );
} );
test( 'should return a tree of items, with orphan categories appended to the end', () => {
const filteredList = [
{ id: 1, name: 'Apricots', parent: 0 },
{ id: 2, name: 'Clementine', parent: 0 },
{ id: 4, name: 'Guava', parent: 2 },
{ id: 5, name: 'Lychee', parent: 3 },
{ id: 6, name: 'Mulberry', parent: 0 },
];
const tree = buildTermsTree( filteredList, list );
expect( tree ).toEqual( [
{
id: 1,
name: 'Apricots',
parent: 0,
breadcrumbs: [],
children: [],
},
{
id: 2,
name: 'Clementine',
parent: 0,
breadcrumbs: [],
children: [
{
id: 4,
name: 'Guava',
parent: 2,
breadcrumbs: [ 'Clementine' ],
children: [],
},
],
},
{
id: 6,
name: 'Mulberry',
parent: 0,
breadcrumbs: [],
children: [],
},
{
id: 5,
name: 'Lychee',
parent: 3,
breadcrumbs: [ 'Clementine', 'Elderberry' ],
children: [],
},
] );
} );
test( 'should return a tree of items, with orphan categories appended to the end, with children of thier own', () => {
const filteredList = [
{ id: 1, name: 'Apricots', parent: 0 },
{ id: 3, name: 'Elderberry', parent: 2 },
{ id: 4, name: 'Guava', parent: 2 },
{ id: 5, name: 'Lychee', parent: 3 },
{ id: 6, name: 'Mulberry', parent: 0 },
];
const tree = buildTermsTree( filteredList, list );
expect( tree ).toEqual( [
{
id: 1,
name: 'Apricots',
parent: 0,
breadcrumbs: [],
children: [],
},
{
id: 6,
name: 'Mulberry',
parent: 0,
breadcrumbs: [],
children: [],
},
{
id: 3,
name: 'Elderberry',
parent: 2,
breadcrumbs: [ 'Clementine' ],
children: [
{
id: 5,
name: 'Lychee',
parent: 3,
breadcrumbs: [ 'Clementine', 'Elderberry' ],
children: [],
},
],
},
{
id: 4,
name: 'Guava',
parent: 2,
breadcrumbs: [ 'Clementine' ],
children: [],
},
] );
} );
} );
jQuery( function( $ ) {
'use strict';
/**
* Object to handle PayPal admin functions.
*/
var wc_paypal_admin = {
isTestMode: function() {
return $( '#woocommerce_paypal_testmode' ).is( ':checked' );
},
/**
* Initialize.
*/
init: function() {
$( document.body ).on( 'change', '#woocommerce_paypal_testmode', function() {
var test_api_username = $( '#woocommerce_paypal_sandbox_api_username' ).parents( 'tr' ).eq( 0 ),
test_api_password = $( '#woocommerce_paypal_sandbox_api_password' ).parents( 'tr' ).eq( 0 ),
test_api_signature = $( '#woocommerce_paypal_sandbox_api_signature' ).parents( 'tr' ).eq( 0 ),
live_api_username = $( '#woocommerce_paypal_api_username' ).parents( 'tr' ).eq( 0 ),
live_api_password = $( '#woocommerce_paypal_api_password' ).parents( 'tr' ).eq( 0 ),
live_api_signature = $( '#woocommerce_paypal_api_signature' ).parents( 'tr' ).eq( 0 );
if ( $( this ).is( ':checked' ) ) {
test_api_username.show();
test_api_password.show();
test_api_signature.show();
live_api_username.hide();
live_api_password.hide();
live_api_signature.hide();
} else {
test_api_username.hide();
test_api_password.hide();
test_api_signature.hide();
live_api_username.show();
live_api_password.show();
live_api_signature.show();
}
} );
$( '#woocommerce_paypal_testmode' ).trigger( 'change' );
}
};
wc_paypal_admin.init();
});
Blog archivos - Página 3 de 3 - Zona U Restaurante
It is necessary for all to utilize garments they feel happy in, which include garments that happen to be classy and comfy. Spider Hoodie is renowned for their top quality across the world. There has been a rapid growth in lover adhering to in recent...
About the away probability that Sp5der Hoodie alludes into a distinct factor or manufacturer, you might have a go at hunting via web based via web business websites, web-centered amusement phases, or straightforwardly around the brand’s web site (if Accessible) to track downward a lot...
Sp5der hoodies are functional parts that may lift any casual attire. These hoodies can be found in numerous designs and colors, allowing you to create distinct looks for diverse functions. Here are several styling ideas to help you get the best from your Sp5der hoodies.Relaxed...
The sp5der P*nk V2 Hoodie Black may not be suitable for outdoor activities depending on the material and design of the hoodie. It is important to consider the fabric of the hoodie, as well as its thickness and warmth, when choosing clothing for outdoor activities....
Looking for an escort job? Do you love showcasing yourself in a sexy, feminine manner and know how to skillfully entice men?In this case, an escort job is perfect for you!Would you like to go out in style, meet intriguing gentlemen from upper social circles,...
Entdecke Deutschlands größte Escort-Community: Orhidi.com. Entdecke Deutschlands größte Escort Community: Orhidi.com — egal, ob Du nach einem stilvollen Date suchst oder einfach nur nach einem schnellen erotischen Abenteuer Ausschau hältst, Orhidi.com bietet Dir die perfekte Escort dafür! Seit mehr als einem Jahrzehnt bereits...