This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// TODO: Replace THEMENAME with the machine name for your theme. | |
use Drupal\Core\Form\FormStateInterface; | |
use Drupal\file\Entity\File; | |
/** | |
* Implements hook_form_FORM_ID_alter(). | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Drupal\my_module_name\Cypress; | |
use Drupal\block\Entity\Block; | |
use Drupal\Component\Serialization\Json; | |
use Drupal\Core\Cache\CacheBackendInterface; | |
use Drupal\Core\DependencyInjection\ContainerInjectionInterface; | |
use Drupal\Core\Entity\EntityRepositoryInterface; | |
use Drupal\Core\Entity\EntityTypeManagerInterface; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {LitElement, html} from 'https://cdn.jsdelivr.net/gh/lit/dist@2/core/lit-core.min.js' | |
import jsonapiParse from 'https://cdn.jsdelivr.net/npm/[email protected]/+esm' | |
import dayjs from 'https://cdn.jsdelivr.net/npm/[email protected]/+esm' | |
class SFEventListing extends LitElement { | |
static properties = { | |
baseUrl: {type: String}, | |
url: {type: String}, | |
imageUrl: {type: String}, | |
imageAlt: {type: String}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
parameters: | |
# Configure Cross-Site HTTP requests (CORS). | |
# Read https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS | |
# for more information about the topic in general. | |
# Note: By default the configuration is disabled. | |
cors.config: | |
enabled: true | |
# Specify allowed headers, like 'x-allowed-header'. | |
allowedHeaders: ['x-csrf-token', 'authorization', 'content-type', 'accept', 'origin', 'x-requested-with'] | |
# Specify allowed request methods, specify ['*'] to allow all possible ones. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
my_lib: | |
js: | |
https://path-to-file/my-script.min.js: {type: external, minified: true} | |
my_lib.test: | |
js: | |
https://path-to-file/my-script-test.min.js: {type: external, minified: true} | |
my_lib.dev: | |
js: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function BasicLoop(props) { | |
const items = props.items; | |
return ( | |
<ul> | |
{items.map((value, index) => { | |
return <li key={index}>{value}</li> | |
})} | |
</ul> | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
article_category_field: field_sf_article_category | |
event_category_field: field_sf_event_type | |
photo_gallery_category_field: field_sf_gallery_category | |
branding_field: field_sf_branding | |
brand_color_field: field_sf_brand_color |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Drupal\custom_theme\Plugin\BlockStyle; | |
use Drupal\block_style_plugins\Plugin\BlockStyleBase; | |
use Drupal\Core\Form\FormStateInterface; | |
/** | |
* Provides a 'FocalLinkIcon' style. | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
langcode: en | |
status: true | |
dependencies: | |
config: | |
- core.entity_view_mode.node.teaser | |
- field.storage.node.body | |
- node.type.sf_article | |
- taxonomy.vocabulary.sf_article_category | |
- taxonomy.vocabulary.sf_article_type | |
content: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Local development services. | |
services: | |
cache.backend.null: | |
class: Drupal\Core\Cache\NullBackendFactory | |
parameters: | |
session.storage.options: | |
# Default ini options for sessions. | |
# | |
# Some distributions of Linux (most notably Debian) ship their PHP |