diff --git a/.ddev/commands/host/save b/.ddev/commands/host/save index cc1f0b3..ff06962 100755 --- a/.ddev/commands/host/save +++ b/.ddev/commands/host/save @@ -18,3 +18,7 @@ ddev drush sqlq " \ " ddev export-db --file=_db_main.sql.gz + +# So we can keep working. +ddev drush cr +ddev drush uli diff --git a/.ddev/config.yaml b/.ddev/config.yaml index bf54d80..959cdc2 100644 --- a/.ddev/config.yaml +++ b/.ddev/config.yaml @@ -18,273 +18,3 @@ disable_settings_management: true web_environment: - DRUSH_OPTIONS_URI=https://fs-web.ddev.site:8443 corepack_enable: false - -# Key features of DDEV's config.yaml: - -# name: # Name of the project, automatically provides -# http://projectname.ddev.site and https://projectname.ddev.site - -# type: # backdrop, craftcms, django4, drupal, drupal6, drupal7, laravel, magento, magento2, php, python, shopware6, silverstripe, typo3, wordpress -# See https://ddev.readthedocs.io/en/stable/users/quickstart/ for more -# information on the different project types -# "drupal" covers recent Drupal 8+ - -# docroot: # Relative path to the directory containing index.php. - -# php_version: "8.2" # PHP version to use, "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0", "8.1", "8.2", "8.3", "8.4" - -# You can explicitly specify the webimage but this -# is not recommended, as the images are often closely tied to DDEV's' behavior, -# so this can break upgrades. - -# webimage: # nginx/php docker image. - -# database: -# type: # mysql, mariadb, postgres -# version: # database version, like "10.11" or "8.0" -# MariaDB versions can be 5.5-10.8, 10.11, and 11.4. -# MySQL versions can be 5.5-8.0. -# PostgreSQL versions can be 9-17. - -# router_http_port: # Port to be used for http (defaults to global configuration, usually 80) -# router_https_port: # Port for https (defaults to global configuration, usually 443) - -# xdebug_enabled: false # Set to true to enable Xdebug and "ddev start" or "ddev restart" -# Note that for most people the commands -# "ddev xdebug" to enable Xdebug and "ddev xdebug off" to disable it work better, -# as leaving Xdebug enabled all the time is a big performance hit. - -# xhprof_enabled: false # Set to true to enable Xhprof and "ddev start" or "ddev restart" -# Note that for most people the commands -# "ddev xhprof" to enable Xhprof and "ddev xhprof off" to disable it work better, -# as leaving Xhprof enabled all the time is a big performance hit. - -# webserver_type: nginx-fpm, apache-fpm, or nginx-gunicorn - -# timezone: Europe/Berlin -# If timezone is unset, DDEV will attempt to derive it from the host system timezone -# using the $TZ environment variable or the /etc/localtime symlink. -# This is the timezone used in the containers and by PHP; -# it can be set to any valid timezone, -# see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones -# For example Europe/Dublin or MST7MDT - -# composer_root: -# Relative path to the Composer root directory from the project root. This is -# the directory which contains the composer.json and where all Composer related -# commands are executed. - -# composer_version: "2" -# You can set it to "" or "2" (default) for Composer v2 or "1" for Composer v1 -# to use the latest major version available at the time your container is built. -# It is also possible to use each other Composer version channel. This includes: -# - 2.2 (latest Composer LTS version) -# - stable -# - preview -# - snapshot -# Alternatively, an explicit Composer version may be specified, for example "2.2.18". -# To reinstall Composer after the image was built, run "ddev debug rebuild". - -# nodejs_version: "20" -# change from the default system Node.js version to any other version. -# See https://ddev.readthedocs.io/en/stable/users/configuration/config/#nodejs_version for more information -# and https://www.npmjs.com/package/n#specifying-nodejs-versions for the full documentation, -# Note that using of 'ddev nvm' is discouraged because "nodejs_version" is much easier to use, -# can specify any version, and is more robust than using 'nvm'. - -# corepack_enable: false -# Change to 'true' to 'corepack enable' and gain access to latest versions of yarn/pnpm - -# additional_hostnames: -# - somename -# - someothername -# would provide http and https URLs for "somename.ddev.site" -# and "someothername.ddev.site". - -# additional_fqdns: -# - example.com -# - sub1.example.com -# would provide http and https URLs for "example.com" and "sub1.example.com" -# Please take care with this because it can cause great confusion. - -# upload_dirs: "custom/upload/dir" -# -# upload_dirs: -# - custom/upload/dir -# - ../private -# -# would set the destination paths for ddev import-files to /custom/upload/dir -# When Mutagen is enabled this path is bind-mounted so that all the files -# in the upload_dirs don't have to be synced into Mutagen. - -# disable_upload_dirs_warning: false -# If true, turns off the normal warning that says -# "You have Mutagen enabled and your 'php' project type doesn't have upload_dirs set" - -# ddev_version_constraint: "" -# Example: -# ddev_version_constraint: ">= 1.22.4" -# This will enforce that the running ddev version is within this constraint. -# See https://github.com/Masterminds/semver#checking-version-constraints for -# supported constraint formats - -# working_dir: -# web: /var/www/html -# db: /home -# would set the default working directory for the web and db services. -# These values specify the destination directory for ddev ssh and the -# directory in which commands passed into ddev exec are run. - -# omit_containers: [db, ddev-ssh-agent] -# Currently only these containers are supported. Some containers can also be -# omitted globally in the ~/.ddev/global_config.yaml. Note that if you omit -# the "db" container, several standard features of DDEV that access the -# database container will be unusable. In the global configuration it is also -# possible to omit ddev-router, but not here. - -# performance_mode: "global" -# DDEV offers performance optimization strategies to improve the filesystem -# performance depending on your host system. Should be configured globally. -# -# If set, will override the global config. Possible values are: -# - "global": uses the value from the global config. -# - "none": disables performance optimization for this project. -# - "mutagen": enables Mutagen for this project. -# - "nfs": enables NFS for this project. -# -# See https://ddev.readthedocs.io/en/stable/users/install/performance/#nfs -# See https://ddev.readthedocs.io/en/stable/users/install/performance/#mutagen - -# fail_on_hook_fail: False -# Decide whether 'ddev start' should be interrupted by a failing hook - -# host_https_port: "59002" -# The host port binding for https can be explicitly specified. It is -# dynamic unless otherwise specified. -# This is not used by most people, most people use the *router* instead -# of the localhost port. - -# host_webserver_port: "59001" -# The host port binding for the ddev-webserver can be explicitly specified. It is -# dynamic unless otherwise specified. -# This is not used by most people, most people use the *router* instead -# of the localhost port. - -# host_db_port: "59002" -# The host port binding for the ddev-dbserver can be explicitly specified. It is dynamic -# unless explicitly specified. - -# mailpit_http_port: "8025" -# mailpit_https_port: "8026" -# The Mailpit ports can be changed from the default 8025 and 8026 - -# host_mailpit_port: "8025" -# The mailpit port is not normally bound on the host at all, instead being routed -# through ddev-router, but it can be bound directly to localhost if specified here. - -# webimage_extra_packages: [php7.4-tidy, php-bcmath] -# Extra Debian packages that are needed in the webimage can be added here - -# dbimage_extra_packages: [telnet,netcat] -# Extra Debian packages that are needed in the dbimage can be added here - -# use_dns_when_possible: true -# If the host has internet access and the domain configured can -# successfully be looked up, DNS will be used for hostname resolution -# instead of editing /etc/hosts -# Defaults to true - -# project_tld: ddev.site -# The top-level domain used for project URLs -# The default "ddev.site" allows DNS lookup via a wildcard -# If you prefer you can change this to "ddev.local" to preserve -# pre-v1.9 behavior. - -# ngrok_args: --basic-auth username:pass1234 -# Provide extra flags to the "ngrok http" command, see -# https://ngrok.com/docs/ngrok-agent/config or run "ngrok http -h" - -# disable_settings_management: false -# If true, DDEV will not create CMS-specific settings files like -# Drupal's settings.php/settings.ddev.php or TYPO3's additional.php -# In this case the user must provide all such settings. - -# You can inject environment variables into the web container with: -# web_environment: -# - SOMEENV=somevalue -# - SOMEOTHERENV=someothervalue - -# no_project_mount: false -# (Experimental) If true, DDEV will not mount the project into the web container; -# the user is responsible for mounting it manually or via a script. -# This is to enable experimentation with alternate file mounting strategies. -# For advanced users only! - -# bind_all_interfaces: false -# If true, host ports will be bound on all network interfaces, -# not the localhost interface only. This means that ports -# will be available on the local network if the host firewall -# allows it. - -# default_container_timeout: 120 -# The default time that DDEV waits for all containers to become ready can be increased from -# the default 120. This helps in importing huge databases, for example. - -#web_extra_exposed_ports: -#- name: nodejs -# container_port: 3000 -# http_port: 2999 -# https_port: 3000 -#- name: something -# container_port: 4000 -# https_port: 4000 -# http_port: 3999 -# Allows a set of extra ports to be exposed via ddev-router -# Fill in all three fields even if you don’t intend to use the https_port! -# If you don’t add https_port, then it defaults to 0 and ddev-router will fail to start. -# -# The port behavior on the ddev-webserver must be arranged separately, for example -# using web_extra_daemons. -# For example, with a web app on port 3000 inside the container, this config would -# expose that web app on https://.ddev.site:9999 and http://.ddev.site:9998 -# web_extra_exposed_ports: -# - name: myapp -# container_port: 3000 -# http_port: 9998 -# https_port: 9999 - -#web_extra_daemons: -#- name: "http-1" -# command: "/var/www/html/node_modules/.bin/http-server -p 3000" -# directory: /var/www/html -#- name: "http-2" -# command: "/var/www/html/node_modules/.bin/http-server /var/www/html/sub -p 3000" -# directory: /var/www/html - -# override_config: false -# By default, config.*.yaml files are *merged* into the configuration -# But this means that some things can't be overridden -# For example, if you have 'use_dns_when_possible: true'' you can't override it with a merge -# and you can't erase existing hooks or all environment variables. -# However, with "override_config: true" in a particular config.*.yaml file, -# 'use_dns_when_possible: false' can override the existing values, and -# hooks: -# post-start: [] -# or -# web_environment: [] -# or -# additional_hostnames: [] -# can have their intended affect. 'override_config' affects only behavior of the -# config.*.yaml file it exists in. - -# Many DDEV commands can be extended to run tasks before or after the -# DDEV command is executed, for example "post-start", "post-import-db", -# "pre-composer", "post-composer" -# See https://ddev.readthedocs.io/en/stable/users/extend/custom-commands/ for more -# information on the commands that can be extended and the tasks you can define -# for them. Example: -#hooks: -# post-import-db: -# - exec: drush sql:sanitize -# - exec: drush updatedb -# - exec: drush cache:rebuild diff --git a/composer.json b/composer.json index a7ec09e..3722650 100644 --- a/composer.json +++ b/composer.json @@ -34,6 +34,7 @@ "drupal/oembed_providers": "^2.1", "drupal/pathauto": "^1.12", "drupal/redirect": "^1.9", + "drupal/s3fs": "^3.6", "drupal/search_api_lunr": "^3.0", "drupal/simple_sitemap": "^4.1", "drupal/upgrade_status": "*", diff --git a/composer.lock b/composer.lock index c21b644..4f91e43 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "31333905b5426337bf2a8d3b6de281cf", + "content-hash": "aa849c7c7ef57fbeb964a61efafcca14", "packages": [ { "name": "asm89/stack-cors", @@ -62,6 +62,158 @@ }, "time": "2023-11-14T13:51:46+00:00" }, + { + "name": "aws/aws-crt-php", + "version": "v1.2.7", + "source": { + "type": "git", + "url": "https://github.com/awslabs/aws-crt-php.git", + "reference": "d71d9906c7bb63a28295447ba12e74723bd3730e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/awslabs/aws-crt-php/zipball/d71d9906c7bb63a28295447ba12e74723bd3730e", + "reference": "d71d9906c7bb63a28295447ba12e74723bd3730e", + "shasum": "" + }, + "require": { + "php": ">=5.5" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35||^5.6.3||^9.5", + "yoast/phpunit-polyfills": "^1.0" + }, + "suggest": { + "ext-awscrt": "Make sure you install awscrt native extension to use any of the functionality." + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "AWS SDK Common Runtime Team", + "email": "aws-sdk-common-runtime@amazon.com" + } + ], + "description": "AWS Common Runtime for PHP", + "homepage": "https://github.com/awslabs/aws-crt-php", + "keywords": [ + "amazon", + "aws", + "crt", + "sdk" + ], + "support": { + "issues": "https://github.com/awslabs/aws-crt-php/issues", + "source": "https://github.com/awslabs/aws-crt-php/tree/v1.2.7" + }, + "time": "2024-10-18T22:15:13+00:00" + }, + { + "name": "aws/aws-sdk-php", + "version": "3.325.2", + "source": { + "type": "git", + "url": "https://github.com/aws/aws-sdk-php.git", + "reference": "9e354a5e0cd1d563ec85245e3000e98e16a44fce" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/9e354a5e0cd1d563ec85245e3000e98e16a44fce", + "reference": "9e354a5e0cd1d563ec85245e3000e98e16a44fce", + "shasum": "" + }, + "require": { + "aws/aws-crt-php": "^1.2.3", + "ext-json": "*", + "ext-pcre": "*", + "ext-simplexml": "*", + "guzzlehttp/guzzle": "^6.5.8 || ^7.4.5", + "guzzlehttp/promises": "^1.4.0 || ^2.0", + "guzzlehttp/psr7": "^1.9.1 || ^2.4.5", + "mtdowling/jmespath.php": "^2.6", + "php": ">=7.2.5", + "psr/http-message": "^1.0 || ^2.0" + }, + "require-dev": { + "andrewsville/php-token-reflection": "^1.4", + "aws/aws-php-sns-message-validator": "~1.0", + "behat/behat": "~3.0", + "composer/composer": "^1.10.22", + "dms/phpunit-arraysubset-asserts": "^0.4.0", + "doctrine/cache": "~1.4", + "ext-dom": "*", + "ext-openssl": "*", + "ext-pcntl": "*", + "ext-sockets": "*", + "nette/neon": "^2.3", + "paragonie/random_compat": ">= 2", + "phpunit/phpunit": "^5.6.3 || ^8.5 || ^9.5", + "psr/cache": "^1.0", + "psr/simple-cache": "^1.0", + "sebastian/comparator": "^1.2.3 || ^4.0", + "yoast/phpunit-polyfills": "^1.0" + }, + "suggest": { + "aws/aws-php-sns-message-validator": "To validate incoming SNS notifications", + "doctrine/cache": "To use the DoctrineCacheAdapter", + "ext-curl": "To send requests using cURL", + "ext-openssl": "Allows working with CloudFront private distributions and verifying received SNS messages", + "ext-sockets": "To use client-side monitoring" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "files": [ + "src/functions.php" + ], + "psr-4": { + "Aws\\": "src/" + }, + "exclude-from-classmap": [ + "src/data/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "Apache-2.0" + ], + "authors": [ + { + "name": "Amazon Web Services", + "homepage": "http://aws.amazon.com" + } + ], + "description": "AWS SDK for PHP - Use Amazon Web Services in your PHP project", + "homepage": "http://aws.amazon.com/sdkforphp", + "keywords": [ + "amazon", + "aws", + "cloud", + "dynamodb", + "ec2", + "glacier", + "s3", + "sdk" + ], + "support": { + "forum": "https://forums.aws.amazon.com/forum.jspa?forumID=80", + "issues": "https://github.com/aws/aws-sdk-php/issues", + "source": "https://github.com/aws/aws-sdk-php/tree/3.325.2" + }, + "time": "2024-11-01T18:08:38+00:00" + }, { "name": "chi-teck/drupal-code-generator", "version": "3.6.1", @@ -3174,6 +3326,89 @@ "source": "https://git.drupalcode.org/project/redirect" } }, + { + "name": "drupal/s3fs", + "version": "3.6.0", + "source": { + "type": "git", + "url": "https://git.drupalcode.org/project/s3fs.git", + "reference": "8.x-3.6" + }, + "dist": { + "type": "zip", + "url": "https://ftp.drupal.org/files/projects/s3fs-8.x-3.6.zip", + "reference": "8.x-3.6", + "shasum": "b422cef4ed8f32c287b3e09ddac22c8d087dcd58" + }, + "require": { + "aws/aws-sdk-php": "^3.18", + "drupal/core": "^8.8 || ^9 || ~10.0.0 || ~10.1.0 || ~10.2.0 || ~10.3.0 || ~11.0.0" + }, + "require-dev": { + "drupal/key": "^1", + "drush/drush": "^10 || ^11 || ^12 || ^13", + "mglaman/phpstan-drupal": "^1.1", + "phpstan/extension-installer": "^1.2", + "phpstan/phpstan": "^1.9", + "phpstan/phpstan-deprecation-rules": "^1.1", + "phpstan/phpstan-phpunit": "^1.3" + }, + "suggest": { + "doctrine/cache": "~1.4" + }, + "type": "drupal-module", + "extra": { + "drupal": { + "version": "8.x-3.6", + "datestamp": "1723007914", + "security-coverage": { + "status": "covered", + "message": "Covered by Drupal's security advisory policy" + } + } + }, + "notification-url": "https://packages.drupal.org/8/downloads", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "Abhishek Anand", + "homepage": "https://www.drupal.org/user/1790054", + "email": "fly2abhishek@gmail.com" + }, + { + "name": "Juanen Bernal", + "homepage": "https://www.drupal.org/u/jansete" + }, + { + "name": "Manuel Garcia", + "homepage": "https://www.drupal.org/user/213194" + }, + { + "name": "naveenvalecha", + "homepage": "https://www.drupal.org/user/2665733" + }, + { + "name": "ram4nd", + "homepage": "https://www.drupal.org/user/601534" + }, + { + "name": "Rhane", + "homepage": "https://www.drupal.org/user/2655479" + }, + { + "name": "ron_s", + "homepage": "https://www.drupal.org/user/184990" + } + ], + "description": "Adds an Amazon Simple Storage Service-based remote file system to Drupal.", + "homepage": "https://www.drupal.org/project/s3fs", + "support": { + "source": "https://git.drupalcode.org/project/s3fs", + "issues": "https://www.drupal.org/project/issues/s3fs" + } + }, { "name": "drupal/search_api", "version": "1.35.0", @@ -4691,6 +4926,72 @@ ], "time": "2024-09-27T08:54:16+00:00" }, + { + "name": "mtdowling/jmespath.php", + "version": "2.8.0", + "source": { + "type": "git", + "url": "https://github.com/jmespath/jmespath.php.git", + "reference": "a2a865e05d5f420b50cc2f85bb78d565db12a6bc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/jmespath/jmespath.php/zipball/a2a865e05d5f420b50cc2f85bb78d565db12a6bc", + "reference": "a2a865e05d5f420b50cc2f85bb78d565db12a6bc", + "shasum": "" + }, + "require": { + "php": "^7.2.5 || ^8.0", + "symfony/polyfill-mbstring": "^1.17" + }, + "require-dev": { + "composer/xdebug-handler": "^3.0.3", + "phpunit/phpunit": "^8.5.33" + }, + "bin": [ + "bin/jp.php" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.8-dev" + } + }, + "autoload": { + "files": [ + "src/JmesPath.php" + ], + "psr-4": { + "JmesPath\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + } + ], + "description": "Declaratively specify how to extract elements from a JSON document", + "keywords": [ + "json", + "jsonpath" + ], + "support": { + "issues": "https://github.com/jmespath/jmespath.php/issues", + "source": "https://github.com/jmespath/jmespath.php/tree/2.8.0" + }, + "time": "2024-09-04T18:46:31+00:00" + }, { "name": "nikic/php-parser", "version": "v5.3.1", diff --git a/web/modules/custom/fs/fs.module b/web/modules/custom/fs/fs.module index 6c6e5ab..77075d0 100644 --- a/web/modules/custom/fs/fs.module +++ b/web/modules/custom/fs/fs.module @@ -11,6 +11,6 @@ declare(strict_types=1); * Implements hook_requirements_alter(). */ function fs_requirements_alter(array &$requirements): void { - // Decrease the 'update status' requirement severity from warning to informational. Platform.sh hosting makes this all read-only. + // Decrease the 'update status' requirement severity from warning to informational. $requirements['update status']['severity'] = REQUIREMENT_INFO; } diff --git a/web/modules/custom/fs/fs.routing.yml b/web/modules/custom/fs/fs.routing.yml deleted file mode 100644 index 7c8bef8..0000000 --- a/web/modules/custom/fs/fs.routing.yml +++ /dev/null @@ -1,8 +0,0 @@ -fs.home: - path: '/home-route' - defaults: - _controller: '\Drupal\fs\Controller\HomePageController::redirectThatSauce' - # For testing this should have a match in ./web/modules/custom/fs_content/content/node. - node_uuid: 'b7f09742-ec1f-4a8e-b594-59ef9980937a' - requirements: - _access: 'TRUE' diff --git a/web/modules/custom/fs/src/Controller/HomePageController.php b/web/modules/custom/fs/src/Controller/HomePageController.php deleted file mode 100644 index 1e2fa0f..0000000 --- a/web/modules/custom/fs/src/Controller/HomePageController.php +++ /dev/null @@ -1,37 +0,0 @@ -entityTypeManager()->getStorage('node')->loadByProperties(['uuid' => $node_uuid]); - if (count($nodes) === 0) { - throw new \Exception('Node route UUID doesn\'t appear to match any nodes: ' . $node_uuid); - } - $redirect_url = Url::fromRoute('entity.node.canonical', ['node' => reset($nodes)->id()]); - return new RedirectResponse($redirect_url->toString()); - } - -} diff --git a/web/modules/custom/fs_content/content/file/1e6985f9-d429-44a1-910c-c32f62b475ac.yml b/web/modules/custom/fs_content/content/file/1e6985f9-d429-44a1-910c-c32f62b475ac.yml deleted file mode 100644 index 51cd419..0000000 --- a/web/modules/custom/fs_content/content/file/1e6985f9-d429-44a1-910c-c32f62b475ac.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 1e6985f9-d429-44a1-910c-c32f62b475ac - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: no-thumbnail.png - uri: - - - value: 'public://media-icons/generic/no-thumbnail.png' - filemime: - - - value: image/png - filesize: - - - value: 7318 - status: - - - value: true - created: - - - value: 1728454590 diff --git a/web/modules/custom/fs_content/content/file/60a49ee1-4694-4619-9b0f-372438fa80a0.yml b/web/modules/custom/fs_content/content/file/60a49ee1-4694-4619-9b0f-372438fa80a0.yml deleted file mode 100644 index bb15716..0000000 --- a/web/modules/custom/fs_content/content/file/60a49ee1-4694-4619-9b0f-372438fa80a0.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: 60a49ee1-4694-4619-9b0f-372438fa80a0 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: 'screenshot 427.png' - uri: - - - value: 'public://2024-02/screenshot 427_50_0_0.png' - filemime: - - - value: image/png - filesize: - - - value: 1428427 - status: - - - value: true - created: - - - value: 1709115295 diff --git a/web/modules/custom/fs_content/content/file/a26b4a0e-ddb4-4913-a892-75a2c25e5026.yml b/web/modules/custom/fs_content/content/file/a26b4a0e-ddb4-4913-a892-75a2c25e5026.yml deleted file mode 100644 index a772660..0000000 --- a/web/modules/custom/fs_content/content/file/a26b4a0e-ddb4-4913-a892-75a2c25e5026.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: a26b4a0e-ddb4-4913-a892-75a2c25e5026 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: no-thumbnail.png - uri: - - - value: 'public://media-icons/generic/no-thumbnail.png' - filemime: - - - value: image/png - filesize: - - - value: 7318 - status: - - - value: true - created: - - - value: 1728389716 diff --git a/web/modules/custom/fs_content/content/file/a971a73c-0473-4d72-909e-b4ced94969e4.yml b/web/modules/custom/fs_content/content/file/a971a73c-0473-4d72-909e-b4ced94969e4.yml deleted file mode 100644 index ab44479..0000000 --- a/web/modules/custom/fs_content/content/file/a971a73c-0473-4d72-909e-b4ced94969e4.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: a971a73c-0473-4d72-909e-b4ced94969e4 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: gippity-sauce-factory.jpeg - uri: - - - value: 'public://2024-02/gippity-sauce-factory_50_0_0.jpeg' - filemime: - - - value: image/jpeg - filesize: - - - value: 583299 - status: - - - value: true - created: - - - value: 1708371865 diff --git a/web/modules/custom/fs_content/content/file/aa7074de-06a8-496f-95d8-e100f478d66b.yml b/web/modules/custom/fs_content/content/file/aa7074de-06a8-496f-95d8-e100f478d66b.yml deleted file mode 100644 index 878eba4..0000000 --- a/web/modules/custom/fs_content/content/file/aa7074de-06a8-496f-95d8-e100f478d66b.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: aa7074de-06a8-496f-95d8-e100f478d66b - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: no-thumbnail.png - uri: - - - value: 'public://media-icons/generic/no-thumbnail.png' - filemime: - - - value: image/png - filesize: - - - value: 7318 - status: - - - value: true - created: - - - value: 1728218089 diff --git a/web/modules/custom/fs_content/content/file/fc6e3c19-06e5-4317-8833-7246c27cd624.yml b/web/modules/custom/fs_content/content/file/fc6e3c19-06e5-4317-8833-7246c27cd624.yml deleted file mode 100644 index c19616e..0000000 --- a/web/modules/custom/fs_content/content/file/fc6e3c19-06e5-4317-8833-7246c27cd624.yml +++ /dev/null @@ -1,27 +0,0 @@ -_meta: - version: '1.0' - entity_type: file - uuid: fc6e3c19-06e5-4317-8833-7246c27cd624 - default_langcode: en -default: - uid: - - - target_id: 1 - filename: - - - value: stock-skiier.jpeg - uri: - - - value: 'public://2024-02/stock-skiier_50_0_0.jpeg' - filemime: - - - value: image/jpeg - filesize: - - - value: 302164 - status: - - - value: true - created: - - - value: 1709115444 diff --git a/web/modules/custom/fs_content/content/file/gippity-sauce-factory.jpeg b/web/modules/custom/fs_content/content/file/gippity-sauce-factory.jpeg deleted file mode 100644 index 2a30f81..0000000 Binary files a/web/modules/custom/fs_content/content/file/gippity-sauce-factory.jpeg and /dev/null differ diff --git a/web/modules/custom/fs_content/content/file/no-thumbnail.png b/web/modules/custom/fs_content/content/file/no-thumbnail.png deleted file mode 100644 index 926c531..0000000 Binary files a/web/modules/custom/fs_content/content/file/no-thumbnail.png and /dev/null differ diff --git a/web/modules/custom/fs_content/content/file/screenshot 427.png b/web/modules/custom/fs_content/content/file/screenshot 427.png deleted file mode 100644 index 6bbbba9..0000000 Binary files a/web/modules/custom/fs_content/content/file/screenshot 427.png and /dev/null differ diff --git a/web/modules/custom/fs_content/content/file/stock-skiier.jpeg b/web/modules/custom/fs_content/content/file/stock-skiier.jpeg deleted file mode 100644 index 2ba1a1d..0000000 Binary files a/web/modules/custom/fs_content/content/file/stock-skiier.jpeg and /dev/null differ diff --git a/web/modules/custom/fs_content/content/media/09019edf-47ce-4f79-b795-d2d85d714c63.yml b/web/modules/custom/fs_content/content/media/09019edf-47ce-4f79-b795-d2d85d714c63.yml deleted file mode 100644 index 2e789ff..0000000 --- a/web/modules/custom/fs_content/content/media/09019edf-47ce-4f79-b795-d2d85d714c63.yml +++ /dev/null @@ -1,47 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 09019edf-47ce-4f79-b795-d2d85d714c63 - bundle: image - default_langcode: en - depends: - a971a73c-0473-4d72-909e-b4ced94969e4: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: 'Sauce factory AI image' - created: - - - value: 1708371768 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 0 - media_image: - - - entity: a971a73c-0473-4d72-909e-b4ced94969e4 - alt: 'People making sauce in a facotry in a 1930s art style' - title: '' - width: 1024 - height: 1024 diff --git a/web/modules/custom/fs_content/content/media/874d9c51-f2fb-476f-94cb-c41861eed575.yml b/web/modules/custom/fs_content/content/media/874d9c51-f2fb-476f-94cb-c41861eed575.yml deleted file mode 100644 index 9f749fb..0000000 --- a/web/modules/custom/fs_content/content/media/874d9c51-f2fb-476f-94cb-c41861eed575.yml +++ /dev/null @@ -1,47 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: 874d9c51-f2fb-476f-94cb-c41861eed575 - bundle: image - default_langcode: en - depends: - fc6e3c19-06e5-4317-8833-7246c27cd624: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: stock-skiier.jpeg - created: - - - value: 1709115444 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 0 - media_image: - - - entity: fc6e3c19-06e5-4317-8833-7246c27cd624 - alt: Cheers - title: '' - width: 1185 - height: 670 diff --git a/web/modules/custom/fs_content/content/media/a25d5f6e-edef-4e17-a9fe-dfba0db89897.yml b/web/modules/custom/fs_content/content/media/a25d5f6e-edef-4e17-a9fe-dfba0db89897.yml deleted file mode 100644 index c756350..0000000 --- a/web/modules/custom/fs_content/content/media/a25d5f6e-edef-4e17-a9fe-dfba0db89897.yml +++ /dev/null @@ -1,47 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: a25d5f6e-edef-4e17-a9fe-dfba0db89897 - bundle: image - default_langcode: en - depends: - 60a49ee1-4694-4619-9b0f-372438fa80a0: file -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: Alice - created: - - - value: 1709115304 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 0 - media_image: - - - entity: 60a49ee1-4694-4619-9b0f-372438fa80a0 - alt: 'Alice grown in the house' - title: '' - width: 1204 - height: 916 diff --git a/web/modules/custom/fs_content/content/media/e7de467c-73d2-43dd-9a84-8a4a1a5b3925.yml b/web/modules/custom/fs_content/content/media/e7de467c-73d2-43dd-9a84-8a4a1a5b3925.yml deleted file mode 100644 index 77e7229..0000000 --- a/web/modules/custom/fs_content/content/media/e7de467c-73d2-43dd-9a84-8a4a1a5b3925.yml +++ /dev/null @@ -1,38 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: e7de467c-73d2-43dd-9a84-8a4a1a5b3925 - bundle: image - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: ice-cream-on-hot-roof.webp - created: - - - value: 1709342175 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 0 diff --git a/web/modules/custom/fs_content/content/media/fe6b7593-6461-4baa-b8b6-2a3847f090d5.yml b/web/modules/custom/fs_content/content/media/fe6b7593-6461-4baa-b8b6-2a3847f090d5.yml deleted file mode 100644 index 0403712..0000000 --- a/web/modules/custom/fs_content/content/media/fe6b7593-6461-4baa-b8b6-2a3847f090d5.yml +++ /dev/null @@ -1,38 +0,0 @@ -_meta: - version: '1.0' - entity_type: media - uuid: fe6b7593-6461-4baa-b8b6-2a3847f090d5 - bundle: image - default_langcode: en -default: - status: - - - value: true - uid: - - - target_id: 1 - name: - - - value: deer-running-through-bazaar.webp - created: - - - value: 1709342081 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 0 diff --git a/web/modules/custom/fs_content/content/menu_link_content/3e6b7f1a-b957-44c2-94da-79e202e214ac.yml b/web/modules/custom/fs_content/content/menu_link_content/3e6b7f1a-b957-44c2-94da-79e202e214ac.yml deleted file mode 100644 index b60676c..0000000 --- a/web/modules/custom/fs_content/content/menu_link_content/3e6b7f1a-b957-44c2-94da-79e202e214ac.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 3e6b7f1a-b957-44c2-94da-79e202e214ac - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: 'From the pen' - menu_name: - - - value: main - link: - - - uri: 'internal:/ce/from-the-pen' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: true - weight: - - - value: -48 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/web/modules/custom/fs_content/content/menu_link_content/64d6b125-7c44-4149-876b-184489a0364a.yml b/web/modules/custom/fs_content/content/menu_link_content/64d6b125-7c44-4149-876b-184489a0364a.yml deleted file mode 100644 index 222fa2c..0000000 --- a/web/modules/custom/fs_content/content/menu_link_content/64d6b125-7c44-4149-876b-184489a0364a.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: 64d6b125-7c44-4149-876b-184489a0364a - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: 'Back to front' - menu_name: - - - value: main - link: - - - uri: 'internal:/node/3' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: true - weight: - - - value: -49 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/web/modules/custom/fs_content/content/menu_link_content/e78fc4f8-6de8-4fc3-8a02-5f52b1660c1a.yml b/web/modules/custom/fs_content/content/menu_link_content/e78fc4f8-6de8-4fc3-8a02-5f52b1660c1a.yml deleted file mode 100644 index 5d0195b..0000000 --- a/web/modules/custom/fs_content/content/menu_link_content/e78fc4f8-6de8-4fc3-8a02-5f52b1660c1a.yml +++ /dev/null @@ -1,36 +0,0 @@ -_meta: - version: '1.0' - entity_type: menu_link_content - uuid: e78fc4f8-6de8-4fc3-8a02-5f52b1660c1a - bundle: menu_link_content - default_langcode: en -default: - enabled: - - - value: true - title: - - - value: 'Throw some shade' - menu_name: - - - value: main - link: - - - uri: 'internal:/ce/free-as-in-speech' - title: '' - options: { } - external: - - - value: false - rediscover: - - - value: true - weight: - - - value: -47 - expanded: - - - value: false - revision_translation_affected: - - - value: true diff --git a/web/modules/custom/fs_content/content/node/7881e70e-7e16-49f4-a96b-9408d1e4cbaa.yml b/web/modules/custom/fs_content/content/node/7881e70e-7e16-49f4-a96b-9408d1e4cbaa.yml deleted file mode 100644 index faaf0cc..0000000 --- a/web/modules/custom/fs_content/content/node/7881e70e-7e16-49f4-a96b-9408d1e4cbaa.yml +++ /dev/null @@ -1,55 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: 7881e70e-7e16-49f4-a96b-9408d1e4cbaa - bundle: page - default_langcode: en -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Adding PHPStan to a Drupal site' - created: - - - value: 1709819679 - promote: - - - value: false - sticky: - - - value: false - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: 'Adding PHPStan to a Drupal site | frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/ce/phpstan-article' - path: - - - alias: /ce/phpstan-article - langcode: en - pathauto: 0 - lead: - - - value: "

PHPStan is a static code analysis tool that you can add to your Drupal site. It will pick up issues as you code, so they don't get to production. Parmesan cheese. Zombie.

" - format: basic - markup: - - - value: "

The basics covered in this video are:

  1. Follow the instructions to install it on Drupal.org
  2. Create your phpstan.neon
  3. Talk about some of the issues you might have

A sample settings file, roughly covered in the video, is:

parameters:\r\n    level: 7\r\n    paths:\r\n        - web/modules/custom\r\n        - web/themes/custom\r\n\r\n    checkMissingIterableValueType: false\r\n    reportUnmatchedIgnoredErrors: true
" - format: safe_html diff --git a/web/modules/custom/fs_content/content/node/b7f09742-ec1f-4a8e-b594-59ef9980937a.yml b/web/modules/custom/fs_content/content/node/b7f09742-ec1f-4a8e-b594-59ef9980937a.yml deleted file mode 100644 index 236f60c..0000000 --- a/web/modules/custom/fs_content/content/node/b7f09742-ec1f-4a8e-b594-59ef9980937a.yml +++ /dev/null @@ -1,55 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: b7f09742-ec1f-4a8e-b594-59ef9980937a - bundle: page - default_langcode: en -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Free Sauce' - created: - - - value: 1708370311 - promote: - - - value: false - sticky: - - - value: false - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: 'Free Sauce | frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/ce' - path: - - - alias: /ce - langcode: en - pathauto: 0 - lead: - - - value: '

Free Sauce is a purpose driven agency, free as in source, with a passion for the Drupal project. Our purpose is to support other ethical businesses and enjoy our work.

' - format: basic - markup: - - - value: '

This website is still in development so be gentle, we''re a small team busy on client work. 

In the meantime here are some links to partners and other things we like.

  • We help out on the DrevOps project, which is a Drupal template that incorporates all aspects of CI and testing. We are passionate about this project because Alex Skrypnyk maintains a  strong open source and testing practice to his tooling (it''s all public and CI tested). He provides consulting and support packages for Drupal development and Continuous Integration.
  • We are supporting Design Outlook which is a fresh young design conference and workshop event running in Melbourne in June. It''s a great way to spend training budget on your most valuable humans.
  • We are hosting partners with Platform.sh. We''ve been using this service for years - it''s Netlify for Drupal with a serious footprint in enterprise hosting in Australia. We like to do light support contracts for clients who are using Platform.sh, (but we also have a soft spot for Amazee Lagoon).
' - format: safe_html diff --git a/web/modules/custom/fs_content/content/node/bcdaf5ca-8198-447f-b47f-775de41dfc9c.yml b/web/modules/custom/fs_content/content/node/bcdaf5ca-8198-447f-b47f-775de41dfc9c.yml deleted file mode 100644 index 0d0d0df..0000000 --- a/web/modules/custom/fs_content/content/node/bcdaf5ca-8198-447f-b47f-775de41dfc9c.yml +++ /dev/null @@ -1,51 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: bcdaf5ca-8198-447f-b47f-775de41dfc9c - bundle: page - default_langcode: en -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Thank you' - created: - - - value: 1709426235 - promote: - - - value: false - sticky: - - - value: false - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: 'Thank you | frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/ce/thank-you' - path: - - - alias: /ce/thank-you - langcode: en - pathauto: 0 - lead: - - - value: "

Thanks for contacting us, we'll get back to you as soon as possible.

" - format: basic diff --git a/web/modules/custom/fs_content/content/node/d0a7ab31-136f-44d5-8d68-91534bc46da6.yml b/web/modules/custom/fs_content/content/node/d0a7ab31-136f-44d5-8d68-91534bc46da6.yml deleted file mode 100644 index 5db73e2..0000000 --- a/web/modules/custom/fs_content/content/node/d0a7ab31-136f-44d5-8d68-91534bc46da6.yml +++ /dev/null @@ -1,67 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: d0a7ab31-136f-44d5-8d68-91534bc46da6 - bundle: article - default_langcode: en - depends: - fe6b7593-6461-4baa-b8b6-2a3847f090d5: media - 440f86ad-aa11-4047-953f-636d42889f84: taxonomy_term - 550f86ad-aa11-4047-953f-636d42889f84: taxonomy_term -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Mastering machine names inside your views' - created: - - - value: 1709204901 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: 'Mastering machine names inside your views | frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/ce/ummm/mastering-machine-names-inside-your-views' - path: - - - alias: /ce/ummm/mastering-machine-names-inside-your-views - langcode: en - pathauto: 1 - hero: - - - entity: fe6b7593-6461-4baa-b8b6-2a3847f090d5 - lead: - - - value: '

Drupal views providers an advanced UI, but sometimes the auto-generated machine names within your views are not ideal. There are ways to improve this.

' - format: basic - markup: - - - value: "

This site is under development and this article is not complete.

I have been creating some content for the new website and thinking about random tips that I have never found time to share.

When you create a view there are a few areas where I like to control generated \"machine name\" values that will lead to cleaner output in the long run.

I wouldn't do this after a site is built, it's too risky to overlook other things that depend on these machine names. I would only use these techniques when I initially create the view.

The view itself

It's common to find that your view wasn't named well, and you're unhappy with the name of the twig file to override.

The easiest way to fix this is to clone the view and customise the machine as you do it, then delete the old view. This is completely safe as views YAML is usually self-contained.

As said above, you usually do this when you are building the view and you realise you gave it a bad name. After a while there are other parts of your site which will be couple to this name, and easy to miss. If you clone a view and change the machine name you will break the following and plenty of other things:

  • Entity reference fields (when you configure the options list) can use a View.
  • Your layouts builder page, where you have embedded a Views block.
  • Your block layout, where you have added a Views block.
  • Twig templates reference the Views machine name
  • Custom code can programmatically load and render a view.
  • Probably a dozen more if you count your contrib module. 

Display names

Below we have a view with multiple displays and they have been neatly named. If you want to control the twig for this view, you can add a template views-view--VIEWNAME--DISPLAYNAME.html.twig. After a site has been built it's common to see templates like this:

[PICTURE]

views-view--mycontentview--page-1.html.twig\r\nviews-view--mycontentview--page-2.html.twig\r\nviews-view--mycontentview--page-3.html.twig

For another developer looking at this code, and trawling through dozens of templates, it's not immediately clear what these views are being used for. This is a DX issue for you and your colleagues. The effort to change this later may not be worth it.

Get into the habit of setting your display machine names as soon as you create them. You will appreciate the resulting systax for creating your twig templates.

[PICTURE]

views-view--mycontentview--all.html.twig\r\nviews-view--mycontentview--articles.html.twig\r\nviews-view--mycontentview--newest-articles.html.twig

Renaming fields

When adding fields, it's common to add the same field twice, you might render a field in different ways or hide one of the fields and use it in a field rewrite later.

The views UI does not allow you to rename the field's machine name. However there is a technique I've been using for a while that works very well. It will allow you to have well named twig tokens. It invokes hacking the views yaml and reimporting it.

Let's say we want to re-use a uid (User ID) field, hide it and, reuse it in a field rewrite in another field.

  1. Create your view, and add your fields.
  2. Create a second UID field.
  3. Add a \"Global: custom text\" field
  4. In the rewrite of this field, you will note that to express this field you will enter {{ uid_2 }} - How can we change this.
  5. Export your site config with Drush, open the new view yaml, and find and replace the instances of uid_2 with you_say_tomatoe
  6. Reimport your site config

Now in your view you can use {{ you_say_tomatoe }} in your rewriting.

Disclaimer #1: I've been told that I hack yaml too much. I like to explore the boundaries of Drupal's config system, it's a masterpiece. However, I'm also aware that I will get no love in the issue queue if I hose my site. That said, I have been using this technique with Views since Drupal 8 and it has never failed me.

Disclaimers #2: I only do fancy twig re-writing in administration views in the backend, especially when I'm using a vanilla uncustomised backend theme. It's a great smart way to make backend tables more user-friendly. On the frontend, you should bring this complexity into the theme layer and keep your views nice and sane.

[VIDEO]

 

" - format: safe_html - tags: - - - entity: 440f86ad-aa11-4047-953f-636d42889f84 - - - entity: 550f86ad-aa11-4047-953f-636d42889f84 diff --git a/web/modules/custom/fs_content/content/node/d7d83d55-dd7d-4a8e-9460-7fb9825dee44.yml b/web/modules/custom/fs_content/content/node/d7d83d55-dd7d-4a8e-9460-7fb9825dee44.yml deleted file mode 100644 index 7b11bdb..0000000 --- a/web/modules/custom/fs_content/content/node/d7d83d55-dd7d-4a8e-9460-7fb9825dee44.yml +++ /dev/null @@ -1,64 +0,0 @@ -_meta: - version: '1.0' - entity_type: node - uuid: d7d83d55-dd7d-4a8e-9460-7fb9825dee44 - bundle: article - default_langcode: en - depends: - e7de467c-73d2-43dd-9a84-8a4a1a5b3925: media - 550f86ad-aa11-4047-953f-636d42889f84: taxonomy_term -default: - revision_uid: - - - target_id: 1 - status: - - - value: true - uid: - - - target_id: 1 - title: - - - value: 'Typography check' - created: - - - value: 1701771892 - promote: - - - value: true - sticky: - - - value: false - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: 'Typography check | frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/ce/ummm/typography-check' - path: - - - alias: /ce/ummm/typography-check - langcode: en - pathauto: 1 - hero: - - - entity: e7de467c-73d2-43dd-9a84-8a4a1a5b3925 - lead: - - - value: '

This page just for reviewing the style of the site as we develop it.

' - format: basic - markup: - - - value: "

In the vastness of space, far and wide, 
Our astronaut drifts, with stars as his guide. 
Exploring new worlds, so bold and so grand, 
In his handbuilt spaceship, across the cosmic land.

Survival Gear (h3, dl)

Space Suit

A suit that's quite tight, for space walks so bright.

Oxygen Tank

For breathing in space, it ranks top in its place.

Food Capsules

Though not quite gourmet, they keep hunger at bay.

Photo of Earth

A reminder of home, wherever I roam.

Galactic Menu (table)

MealDescription
Moon MacaroonsSweet, with a hint of crater crunch.
Asteroid AlmondsCrunchy, with a side of space dust.
Galaxy GelatoCreamy swirls of starlight and nebula nuggets.
Comet CookiesCrumbly, with streaks of cosmic sugar.

Space Supplies Checklist (ul)

  • Stellar Map - For navigating the cosmic seas.
  • Gravity Boots - To keep feet grounded to the ship.
  • Robot Companion - For company during long, lonely voyages.
  • Telescope - To gaze upon distant worlds and dream.

Todo list (ol)

  1. Fluff the space bunnies
  2. Start limboing the space sharks
  3. Assign wrenches to the space monkeys

Some code (pre, h4)

# build the theme\r\ncd web/themes/custom/fstheme\r\nnpm ci

Quote

\"Oh, how I miss the Earth's food, so diverse and so neat, A flavor, a memory, that none can beat. Through the silence, I flies, under infinite skies, A journey of heart, where adventure never dies.\"

" - format: safe_html - tags: - - - entity: 550f86ad-aa11-4047-953f-636d42889f84 diff --git a/web/modules/custom/fs_content/content/taxonomy_term/440f86ad-aa11-4047-953f-636d42889f84.yml b/web/modules/custom/fs_content/content/taxonomy_term/440f86ad-aa11-4047-953f-636d42889f84.yml deleted file mode 100644 index 42de55f..0000000 --- a/web/modules/custom/fs_content/content/taxonomy_term/440f86ad-aa11-4047-953f-636d42889f84.yml +++ /dev/null @@ -1,38 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: 440f86ad-aa11-4047-953f-636d42889f84 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: 'Site Building' - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 1 diff --git a/web/modules/custom/fs_content/content/taxonomy_term/550f86ad-aa11-4047-953f-636d42889f84.yml b/web/modules/custom/fs_content/content/taxonomy_term/550f86ad-aa11-4047-953f-636d42889f84.yml deleted file mode 100644 index 1e40df6..0000000 --- a/web/modules/custom/fs_content/content/taxonomy_term/550f86ad-aa11-4047-953f-636d42889f84.yml +++ /dev/null @@ -1,38 +0,0 @@ -_meta: - version: '1.0' - entity_type: taxonomy_term - uuid: 550f86ad-aa11-4047-953f-636d42889f84 - bundle: tags - default_langcode: en -default: - status: - - - value: true - name: - - - value: Testing - weight: - - - value: 0 - parent: - - - target_id: 0 - revision_translation_affected: - - - value: true - metatag: - - - tag: meta - attributes: - name: title - content: '| frees.au/ce' - - - tag: link - attributes: - rel: canonical - href: 'https://fs-web.ddev.site:8443/home-route' - path: - - - alias: '' - langcode: en - pathauto: 1 diff --git a/web/modules/custom/fs_content/fs_content.info.yml b/web/modules/custom/fs_content/fs_content.info.yml deleted file mode 100644 index 6f04d04..0000000 --- a/web/modules/custom/fs_content/fs_content.info.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: FS Content -type: module -package: 'frees.au/ce' -description: 'Testing support, mainly default_content for e2e testing.' -core_version_requirement: ^10 -dependencies: - - default_content:default_content - -default_content: - node: - - d7d83d55-dd7d-4a8e-9460-7fb9825dee44 - - b7f09742-ec1f-4a8e-b594-59ef9980937a - - d0a7ab31-136f-44d5-8d68-91534bc46da6 - - bcdaf5ca-8198-447f-b47f-775de41dfc9c - - 7881e70e-7e16-49f4-a96b-9408d1e4cbaa - file: - - 60a49ee1-4694-4619-9b0f-372438fa80a0 - - a971a73c-0473-4d72-909e-b4ced94969e4 - - fc6e3c19-06e5-4317-8833-7246c27cd624 - media: - - 09019edf-47ce-4f79-b795-d2d85d714c63 - - a25d5f6e-edef-4e17-a9fe-dfba0db89897 - - 874d9c51-f2fb-476f-94cb-c41861eed575 - - fe6b7593-6461-4baa-b8b6-2a3847f090d5 - - e7de467c-73d2-43dd-9a84-8a4a1a5b3925 - menu_link_content: - - 3e6b7f1a-b957-44c2-94da-79e202e214ac - - e78fc4f8-6de8-4fc3-8a02-5f52b1660c1a - - 64d6b125-7c44-4149-876b-184489a0364a diff --git a/web/themes/custom/fstheme/fstheme.theme b/web/themes/custom/fstheme/fstheme.theme index 016f369..d349195 100755 --- a/web/themes/custom/fstheme/fstheme.theme +++ b/web/themes/custom/fstheme/fstheme.theme @@ -2,11 +2,9 @@ /** * @file - * Free Sauce theme module. + * Free Sauce theme. */ -use Drupal\Component\Utility\Xss; - /** * Implements hook_theme_suggestions_HOOK_alter(). */ @@ -29,41 +27,3 @@ function fstheme_theme_suggestions_field_alter(array &$hooks, array $vars): void break; } } - -/** - * Implements hook_preprocess_page(). - */ -function fstheme_preprocess_page(array &$vars): void { - $site_config = \Drupal::config('system.site'); - $vars['site_name'] = $site_config->get('name'); - $slogan = $site_config->get('slogan'); - assert(is_string($slogan)); - $vars['site_slogan'] = Xss::filter($slogan); -} - -/** - * Implements hook_preprocess_region(). - */ -function fstheme_preprocess_region(array &$vars): void { - try { - $vars['is_front'] = \Drupal::service('path.matcher')->isFrontPage(); - } - catch (Exception $e) { - $vars['is_front'] = FALSE; - } - $vars['#cache']['contexts'][] = 'url.path'; -} - -/** - * Implements hook_preprocess_node(). - */ -function fstheme_preprocess_node(array &$vars): void { - $vars['hero_background_url'] = 'false'; - $node = $vars['node']; - if (!$node->get('hero')->isEmpty()) { - $file = $node->get('hero')->entity->get('media_image')->entity; - if ($file) { - $vars['hero_background_url'] = $file->createFileUrl(); - } - } -}