Last commit july 5th

This commit is contained in:
2024-07-05 13:46:23 +02:00
parent dad0d86e8c
commit b0e4dfbb76
24982 changed files with 2621219 additions and 413 deletions

View File

@@ -1,7 +1,54 @@
scenarios: |
#!blackfire-player
group login
visit url('/login')
submit button("Sign in")
param username "admin"
param password "admin"
expect status_code() == 302
scenario
name "Test homepage"
visit url('/')
name "Submit a comment on the Amsterdam conference page"
include login
visit url('/fr/conference/amsterdam-2019')
expect status_code() == 200
submit button("Submit")
param comment[author] 'Fabien'
param comment[email] 'me@example.com'
param comment[text] 'Such a good conference!'
param comment[photo] file(fake('simple_image', '/tmp', 400, 300, 'png', true, true), 'placeholder-image.jpg')
expect status_code() == 302
follow
expect status_code() == 200
expect not(body() matches "/Such a good conference/")
# Wait for the workflow to validate the submissions
wait 5000
when env != "prod"
visit url(webmail_url ~ '/messages')
expect status_code() == 200
set message_ids json("[*].id")
with message_id in message_ids
visit url(webmail_url ~ '/messages/' ~ message_id ~ '.html')
expect status_code() == 200
set accept_url css("table a").first().attr("href")
include login
visit url(accept_url)
# we don't check the status code as we can deal
# with "old" messages which do not exist anymore
# in the DB (would be a 404 then)
when env == "prod"
visit url('/admin')
expect status_code() == 302
follow
click link("Comments")
expect status_code() == 200
set comment_ids css('table.table tbody tr').extract('data-id')
with id in comment_ids
visit url('/admin/comment/review/' ~ id)
# we don't check the status code as we scan all comments,
# including the ones already reviewed
visit url('/fr/')
wait 5000
visit url('/fr/conference/amsterdam-2019')
expect body() matches "/Such a good conference/"

8
.env
View File

@@ -47,3 +47,11 @@ MESSENGER_TRANSPORT_DSN=doctrine://default?auto_setup=0
# BLACKFIRE_SERVER_ID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
# BLACKFIRE_SERVER_TOKEN=yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
###< blackfireio/blackfire-symfony-meta ###
###> symfony/slack-notifier ###
SLACK_DSN=slack://TOKEN@default?channel=CHANNEL
###< symfony/slack-notifier ###
###> nelmio/cors-bundle ###
CORS_ALLOW_ORIGIN='^https?://(localhost|127\.0\.0\.1)(:[0-9]+)?$'
###< nelmio/cors-bundle ###

View File

@@ -1,6 +1,8 @@
# define your env variables for the test env here
# define your env variables for the test env here
KERNEL_CLASS='App\Kernel'
APP_SECRET='$ecretf0rt3st'
SYMFONY_DEPRECATIONS_HELPER=999999
PANTHER_APP_ENV=panther
PANTHER_ERROR_SCREENSHOT_DIR=./var/error-screenshots

17
.gitignore vendored
View File

@@ -1,4 +1,3 @@
###> symfony/framework-bundle ###
/public/uploads
/.env.local
@@ -20,7 +19,15 @@
/phpunit.xml
###< symfony/phpunit-bridge ###
###> symfony/asset-mapper ###
/public/assets/
/assets/vendor/
###< symfony/asset-mapper ###
###> symfony/webpack-encore-bundle ###
/node_modules/
/public/build/
npm-debug.log
yarn-error.log
###< symfony/webpack-encore-bundle ###
/node_modules/
/public/
/npm-debug.log
# used later by Cordova
/app/

18
.idea/guestbook.iml generated
View File

@@ -3,6 +3,7 @@
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" packagePrefix="App\" />
<sourceFolder url="file://$MODULE_DIR$/tests" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/tests" isTestSource="true" packagePrefix="App\Tests\" />
<excludeFolder url="file://$MODULE_DIR$/var" />
<excludeFolder url="file://$MODULE_DIR$/vendor/blackfire/php-sdk" />
@@ -62,7 +63,6 @@
<excludeFolder url="file://$MODULE_DIR$/vendor/sebastian/type" />
<excludeFolder url="file://$MODULE_DIR$/vendor/sebastian/version" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/asset" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/asset-mapper" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/browser-kit" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/cache" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/cache-contracts" />
@@ -139,6 +139,22 @@
<excludeFolder url="file://$MODULE_DIR$/vendor/twig/intl-extra" />
<excludeFolder url="file://$MODULE_DIR$/vendor/twig/twig" />
<excludeFolder url="file://$MODULE_DIR$/vendor/webmozart/assert" />
<excludeFolder url="file://$MODULE_DIR$/vendor/doctrine/data-fixtures" />
<excludeFolder url="file://$MODULE_DIR$/vendor/doctrine/doctrine-fixtures-bundle" />
<excludeFolder url="file://$MODULE_DIR$/vendor/lorenzo/pinky" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/workflow" />
<excludeFolder url="file://$MODULE_DIR$/vendor/tijsverkoyen/css-to-inline-styles" />
<excludeFolder url="file://$MODULE_DIR$/vendor/twig/cssinliner-extra" />
<excludeFolder url="file://$MODULE_DIR$/vendor/twig/inky-extra" />
<excludeFolder url="file://$MODULE_DIR$/vendor/api-platform/core" />
<excludeFolder url="file://$MODULE_DIR$/vendor/imagine/imagine" />
<excludeFolder url="file://$MODULE_DIR$/vendor/nelmio/cors-bundle" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/slack-notifier" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/webpack-encore-bundle" />
<excludeFolder url="file://$MODULE_DIR$/vendor/twig/string-extra" />
<excludeFolder url="file://$MODULE_DIR$/vendor/willdurand/negotiation" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/amqp-messenger" />
<excludeFolder url="file://$MODULE_DIR$/vendor/symfony/apache-pack" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />

14
.idea/php-test-framework.xml generated Normal file
View File

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="PhpTestFrameworkVersionCache">
<tools_cache>
<tool tool_name="PHPUnit">
<cache>
<versions>
<info id="Local/home/nkolosnjaj/symfony/guestbook/vendor/autoload.php" version="9.6.19" />
</versions>
</cache>
</tool>
</tools_cache>
</component>
</project>

17
.idea/php.xml generated
View File

@@ -85,7 +85,6 @@
<path value="$PROJECT_DIR$/vendor/symfony/options-resolver" />
<path value="$PROJECT_DIR$/vendor/symfony/doctrine-bridge" />
<path value="$PROJECT_DIR$/vendor/symfony/twig-bundle" />
<path value="$PROJECT_DIR$/vendor/symfony/asset-mapper" />
<path value="$PROJECT_DIR$/vendor/symfony/runtime" />
<path value="$PROJECT_DIR$/vendor/phpdocumentor/type-resolver" />
<path value="$PROJECT_DIR$/vendor/symfony/doctrine-messenger" />
@@ -146,6 +145,22 @@
<path value="$PROJECT_DIR$/vendor/symfony/polyfill-uuid" />
<path value="$PROJECT_DIR$/vendor/symfony/uid" />
<path value="$PROJECT_DIR$/vendor/twig/intl-extra" />
<path value="$PROJECT_DIR$/vendor/doctrine/doctrine-fixtures-bundle" />
<path value="$PROJECT_DIR$/vendor/doctrine/data-fixtures" />
<path value="$PROJECT_DIR$/vendor/symfony/workflow" />
<path value="$PROJECT_DIR$/vendor/tijsverkoyen/css-to-inline-styles" />
<path value="$PROJECT_DIR$/vendor/lorenzo/pinky" />
<path value="$PROJECT_DIR$/vendor/twig/cssinliner-extra" />
<path value="$PROJECT_DIR$/vendor/twig/inky-extra" />
<path value="$PROJECT_DIR$/vendor/symfony/webpack-encore-bundle" />
<path value="$PROJECT_DIR$/vendor/imagine/imagine" />
<path value="$PROJECT_DIR$/vendor/symfony/slack-notifier" />
<path value="$PROJECT_DIR$/vendor/nelmio/cors-bundle" />
<path value="$PROJECT_DIR$/vendor/api-platform/core" />
<path value="$PROJECT_DIR$/vendor/willdurand/negotiation" />
<path value="$PROJECT_DIR$/vendor/twig/string-extra" />
<path value="$PROJECT_DIR$/vendor/symfony/apache-pack" />
<path value="$PROJECT_DIR$/vendor/symfony/amqp-messenger" />
</include_path>
</component>
<component name="PhpProjectSharedConfiguration" php_language_level="8.1" />

9
.idea/phpspec.xml generated
View File

@@ -8,6 +8,15 @@
<PhpSpecSuiteConfiguration>
<option name="myPath" value="$PROJECT_DIR$" />
</PhpSpecSuiteConfiguration>
<PhpSpecSuiteConfiguration>
<option name="myPath" value="$PROJECT_DIR$" />
</PhpSpecSuiteConfiguration>
<PhpSpecSuiteConfiguration>
<option name="myPath" value="$PROJECT_DIR$" />
</PhpSpecSuiteConfiguration>
<PhpSpecSuiteConfiguration>
<option name="myPath" value="$PROJECT_DIR$" />
</PhpSpecSuiteConfiguration>
</suites>
</component>
</project>

View File

@@ -8,12 +8,14 @@ dependencies:
runtime:
extensions:
- amqp
- apcu
- blackfire
- ctype
- iconv
- mbstring
- pdo_pgsql
- redis
- sodium
- xsl
@@ -35,11 +37,13 @@ web:
mounts:
"/var": { source: local, source_path: var }
"/public/uploads": { source: local, source_path: uploads }
"/public/uploads": { source: service, service: files, source_path: uploads }
relationships:
database: "database:postgresql"
redis: "rediscache:redis"
rabbitmq: "queue:rabbitmq"
hooks:
build: |

36
.platform/config.vcl Normal file
View File

@@ -0,0 +1,36 @@
acl profile {
# Authorize the local IP address (replace with the IP found above)
"192.168.0.1";
# Authorize Blackfire servers
"46.51.168.2";
"54.75.240.245";
}
sub vcl_recv {
set req.backend_hint = application.backend();
set req.http.Surrogate-Capability = "abc=ESI/1.0";
if (req.method == "PURGE") {
if (req.http.x-purge-token != "PURGE_NOW") {
return(synth(405));
}
return (purge);
}
# Don't profile ESI requests
if (req.esi_level > 0) {
unset req.http.X-Blackfire-Query;
}
# Bypass Varnish when the profile request comes from a known IP
if (req.http.X-Blackfire-Query && client.ip ~ profile) {
return (pass);
}
}
sub vcl_backend_response {
if (beresp.http.Surrogate-Control ~ "ESI/1.0") {
unset beresp.http.Surrogate-Control;
set beresp.do_esi = true;
}
}

View File

@@ -1,2 +1,2 @@
"https://{all}/": { type: upstream, upstream: "app:http" }
"https://{all}/": { type: upstream, upstream: "varnish:http", cache: { enabled: false } }
"http://{all}/": { type: redirect, to: "https://{all}/" }

View File

@@ -1,6 +1,24 @@
database:
type: postgresql:16
disk: 1024
type: postgresql:16
disk: 1024
varnish:
type: varnish:6.0
relationships:
application: 'app:http'
configuration:
vcl: !include
type: string
path: config.vcl
files:
type: network-storage:2.0
disk: 256
rediscache:
type: redis:5.0
queue:
type: rabbitmq:3.7
disk: 1024
size: S

View File

@@ -1,10 +1,13 @@
import './bootstrap.js';
/*
* Welcome to your app's main JavaScript file!
*
* This file will be included onto the page via the importmap() Twig function,
* which should already be in your base.html.twig.
* We recommend including the built version of this JavaScript file
* (and its CSS file) in your base layout (base.html.twig).
*/
import './styles/app.css';
console.log('This log comes from assets/app.js - welcome to AssetMapper! 🎉');
// any CSS you import will output into a single css file (app.css in this case)
import './styles/app.scss';
import 'bootstrap';
import bsCustomFileInput from 'bs-custom-file-input';
bsCustomFileInput.init();

View File

@@ -0,0 +1 @@
$font-family-title: Georgia, Times, 'New Roman', serif;

View File

@@ -1,3 +0,0 @@
body {
background-color: skyblue;
}

62
assets/styles/app.scss Normal file
View File

@@ -0,0 +1,62 @@
@import '~bootstrap/scss/bootstrap';
@import './variables';
body {
display: flex;
flex-direction: column;
height: 100vh;
}
a {
text-decoration: none;
}
main {
flex: 1;
}
.navbar-brand {
font-family: $font-family-title;
font-weight: $font-weight-normal;
font-size: 1.8rem;
}
.navbar-brand, .nav-link {
transition: all .15s;
}
.nav-conference {
display: inline-block;
padding: 5px 10px;
color: #666;
text-transform: uppercase;
font-size: 0.8rem;
}
.lift {
transition: box-shadow .25s ease,transform .25s ease;
&:focus, &:hover {
box-shadow: 0 1rem 2.5rem rgba(22,28,45,.1),0 .5rem 1rem -.75rem rgba(22,28,45,.1)!important;
transform: translate3d(0, -4px, 0);
}
}
.comment-img {
width: 250px;
height: 150px;
img {
max-width: 250px;
max-height: 150px;
}
}
.comment-text {
font-size: 12px;
line-height: 15px;
}
footer {
background: #18171b;
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

22
assets/vendor/installed.php vendored Normal file
View File

@@ -0,0 +1,22 @@
<?php return array (
'@hotwired/stimulus' =>
array (
'version' => '3.2.2',
'dependencies' =>
array (
),
'extraFiles' =>
array (
),
),
'@hotwired/turbo' =>
array (
'version' => '7.3.0',
'dependencies' =>
array (
),
'extraFiles' =>
array (
),
),
);

BIN
blackfire-player.phar Normal file

Binary file not shown.

View File

@@ -1,7 +1,7 @@
version: '3'
services:
###> doctrine/doctrine-bundle ###
###> doctrine/doctrine-bundle ###
database:
image: postgres:${POSTGRES_VERSION:-16}-alpine
environment:
@@ -13,9 +13,17 @@ services:
- database_data:/var/lib/postgresql/data:rw
# You may use a bind-mounted host directory instead, so that it is harder to accidentally remove the volume and lose all your data!
# - ./docker/db/data:/var/lib/postgresql/data:rw
###< doctrine/doctrine-bundle ###
###< doctrine/doctrine-bundle ###
redis:
image: redis:5-alpine
ports: [ 6379 ]
rabbitmq:
image: rabbitmq:3-management
ports: [ 5672, 15672 ]
volumes:
###> doctrine/doctrine-bundle ###
###> doctrine/doctrine-bundle ###
database_data:
###< doctrine/doctrine-bundle ###

View File

@@ -7,16 +7,20 @@
"php": ">=8.1",
"ext-ctype": "*",
"ext-iconv": "*",
"api-platform/core": "^3.3",
"blackfireio/blackfire-symfony-meta": "^1.0",
"doctrine/dbal": "^3",
"doctrine/doctrine-bundle": "^2.12",
"doctrine/doctrine-migrations-bundle": "^3.0",
"doctrine/orm": "^3.2",
"easycorp/easyadmin-bundle": "4.x-dev",
"imagine/imagine": "^1.2",
"nelmio/cors-bundle": "^2.5",
"phpdocumentor/reflection-docblock": "^5.4",
"phpstan/phpdoc-parser": "^1.29",
"symfony/amqp-messenger": "6.4.*",
"symfony/apache-pack": "^1.0",
"symfony/asset": "6.4.*",
"symfony/asset-mapper": "6.4.*",
"symfony/console": "6.4.*",
"symfony/doctrine-messenger": "6.4.*",
"symfony/dotenv": "6.4.*",
@@ -36,6 +40,7 @@
"symfony/runtime": "6.4.*",
"symfony/security-bundle": "6.4.*",
"symfony/serializer": "6.4.*",
"symfony/slack-notifier": "6.4.*",
"symfony/stimulus-bundle": "^2.18",
"symfony/string": "6.4.*",
"symfony/translation": "6.4.*",
@@ -43,10 +48,15 @@
"symfony/ux-turbo": "^2.18",
"symfony/validator": "6.4.*",
"symfony/web-link": "6.4.*",
"symfony/webpack-encore-bundle": "^2.1",
"symfony/workflow": "6.4.*",
"symfony/yaml": "6.4.*",
"symfonycorp/platformsh-meta": "^1.0",
"twig/cssinliner-extra": "^3",
"twig/extra-bundle": "^2.12|^3.0",
"twig/inky-extra": "^3",
"twig/intl-extra": "^3",
"twig/string-extra": "^3.10",
"twig/twig": "^3.0"
},
"config": {
@@ -79,8 +89,7 @@
"scripts": {
"auto-scripts": {
"cache:clear": "symfony-cmd",
"assets:install %PUBLIC_DIR%": "symfony-cmd",
"importmap:install": "symfony-cmd"
"assets:install %PUBLIC_DIR%": "symfony-cmd"
},
"post-install-cmd": [
"@auto-scripts"
@@ -100,6 +109,7 @@
}
},
"require-dev": {
"doctrine/doctrine-fixtures-bundle": "^3.6",
"phpunit/phpunit": "^9.5",
"symfony/browser-kit": "6.4.*",
"symfony/css-selector": "6.4.*",

1464
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -14,4 +14,8 @@ return [
Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true],
Symfony\Bundle\MakerBundle\MakerBundle::class => ['dev' => true],
EasyCorp\Bundle\EasyAdminBundle\EasyAdminBundle::class => ['all' => true],
Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['dev' => true, 'test' => true],
Symfony\WebpackEncoreBundle\WebpackEncoreBundle::class => ['all' => true],
Nelmio\CorsBundle\NelmioCorsBundle::class => ['all' => true],
ApiPlatform\Symfony\Bundle\ApiPlatformBundle::class => ['all' => true],
];

View File

@@ -0,0 +1,18 @@
api_platform:
title: Hello API Platform
version: 1.0.0
formats:
jsonld: ['application/ld+json']
docs_formats:
jsonld: ['application/ld+json']
jsonopenapi: ['application/vnd.openapi+json']
html: ['text/html']
defaults:
stateless: true
cache_headers:
vary: ['Content-Type', 'Authorization', 'Origin']
extra_properties:
standard_put: true
rfc_7807_compliant_errors: true
keep_legacy_inflector: false
use_symfony_listeners: true

View File

@@ -1,5 +0,0 @@
framework:
asset_mapper:
# The paths to make available to the asset mapper.
paths:
- assets/

View File

@@ -9,11 +9,11 @@ framework:
# Enables session support. Note that the session will ONLY be started if you read or write from it.
# Remove or comment this section to explicitly disable session support.
session:
handler_id: '%env(resolve:DATABASE_URL)%'
handler_id: '%env(REDIS_URL)%'
cookie_secure: auto
cookie_samesite: lax
#esi: true
esi: true
#fragments: true
php_errors:
log: true
@@ -23,3 +23,12 @@ when@test:
test: true
session:
storage_factory_id: session.storage.factory.mock_file
when@dev:
framework:
http_cache: false

View File

@@ -1,3 +1,5 @@
framework:
mailer:
dsn: '%env(MAILER_DSN)%'
envelope:
sender: "%admin_email%"

View File

@@ -5,10 +5,7 @@ framework:
transports:
# https://symfony.com/doc/current/messenger.html#transport-configuration
async:
dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
options:
use_notify: true
check_delayed_interval: 60000
dsn: '%env(RABBITMQ_URL)%'
retry_strategy:
max_retries: 3
multiplier: 2
@@ -26,4 +23,4 @@ framework:
Symfony\Component\Notifier\Message\SmsMessage: async
# Route your messages to the transports
# 'App\Message\YourMessage': async
App\Message\CommentMessage: async

View File

@@ -0,0 +1,10 @@
nelmio_cors:
defaults:
origin_regex: true
allow_origin: ['%env(CORS_ALLOW_ORIGIN)%']
allow_methods: ['GET', 'OPTIONS', 'POST', 'PUT', 'PATCH', 'DELETE']
allow_headers: ['Content-Type', 'Authorization']
expose_headers: ['Link']
max_age: 3600
paths:
'^/': null

View File

@@ -1,6 +1,7 @@
framework:
notifier:
chatter_transports:
slack: '%env(SLACK_DSN)%'
texter_transports:
channel_policy:
# use chat/slack, chat/telegram, sms/twilio or sms/nexmo
@@ -9,4 +10,4 @@ framework:
medium: ['email']
low: ['email']
admin_recipients:
- { email: admin@example.com }
- { email: "%env(string:default:default_admin_email:ADMIN_EMAIL)%" }

View File

@@ -1,5 +1,6 @@
twig:
file_name_pattern: '*.twig'
form_themes: [ 'bootstrap_5_layout.html.twig' ]
when@test:
twig:

View File

@@ -14,4 +14,4 @@ when@test:
intercept_redirects: false
framework:
profiler: { collect: false }
profiler: { collect: false }

View File

@@ -0,0 +1,45 @@
webpack_encore:
# The path where Encore is building the assets - i.e. Encore.setOutputPath()
output_path: '%kernel.project_dir%/public/build'
# If multiple builds are defined (as shown below), you can disable the default build:
# output_path: false
# Set attributes that will be rendered on all script and link tags
script_attributes:
defer: true
# Uncomment (also under link_attributes) if using Turbo Drive
# https://turbo.hotwired.dev/handbook/drive#reloading-when-assets-change
# 'data-turbo-track': reload
# link_attributes:
# Uncomment if using Turbo Drive
# 'data-turbo-track': reload
# If using Encore.enableIntegrityHashes() and need the crossorigin attribute (default: false, or use 'anonymous' or 'use-credentials')
# crossorigin: 'anonymous'
# Preload all rendered script and link tags automatically via the HTTP/2 Link header
# preload: true
# Throw an exception if the entrypoints.json file is missing or an entry is missing from the data
# strict_mode: false
# If you have multiple builds:
# builds:
# frontend: '%kernel.project_dir%/public/frontend/build'
# pass the build name as the 3rd argument to the Twig functions
# {{ encore_entry_script_tags('entry1', null, 'frontend') }}
framework:
assets:
json_manifest_path: '%kernel.project_dir%/public/build/manifest.json'
#when@prod:
# webpack_encore:
# # Cache the entrypoints.json (rebuild Symfony's cache when entrypoints.json changes)
# # Available in version 1.2
# cache: true
#when@test:
# webpack_encore:
# strict_mode: false

View File

@@ -0,0 +1,45 @@
framework:
workflows:
comment:
type: state_machine
audit_trail:
enabled: "%kernel.debug%"
marking_store:
type: 'method'
property: 'state'
supports:
- App\Entity\Comment
initial_marking: submitted
places:
- submitted
- ham
- potential_spam
- spam
- rejected
- ready
- published
transitions:
accept:
from: submitted
to: ham
might_be_spam:
from: submitted
to: potential_spam
reject_spam:
from: submitted
to: spam
publish:
from: potential_spam
to: ready
reject:
from: potential_spam
to: rejected
publish_ham:
from: ham
to: ready
reject_ham:
from: ham
to: rejected
optimize:
from: ready
to: published

View File

@@ -0,0 +1,4 @@
api_platform:
resource: .
type: api_platform
prefix: /api

View File

@@ -0,0 +1,3 @@
<?php // dev.BLACKFIRE_SERVER_ID.6a382d on Fri, 05 Jul 2024 06:47:10 +0000
return "\xAD\x93\xE9\xC5\xD5\xD8\xC4\x3FYv\xB5\xC6\x10E\x9Ea\x22\xFE9\x95\xE8\x2F\xBD\xCE\x21\x80\x29\x21\x95\xB9\x9E\x0B\xC4G\x40\xD7\xC5\x0F\x13\x5Cm\x17\x2F\x10\x90\xC4\x9F.0\xEB\xA9\xE2N\xCB\xA3\x18\xC8\xA0R\xE0\xEF\x3B\xAF\xA8\x02\xF5\xFC\x17\xA0\x81v\x26\xF1\x9A\xBFN\xB8\x5B\x92q\xD5\x2C\xB7\x7D";

View File

@@ -0,0 +1,3 @@
<?php // dev.BLACKFIRE_SERVER_TOKEN.69fd63 on Fri, 05 Jul 2024 06:47:35 +0000
return "\xAC\x02\x06\xE2\x3E\xE3\xE5\x97\xDA\x03\x7CCxf\x3D\xBF\xBF\x0E\xAA\x7C\x23\xBC\xD8x\xF0\xE2\xC1\xA3C\x9B\x29\x09\x0D\xF5\x11\xF4\xC2\x06f\x1A\xFE\xEFN\xF8\xE2\x1CBn\x97~\x21\x18w\xFDQ\xB3ba\xF0\xA9L\x9A\x7F\xDC\xD8\xA9\x20\x1D\x27U\xD8x\x1A\x26\xBF\x04\x86\xC9\x1A\xD8\xFDd\x89\xAE\x5C\x80R\xC3\xD4\xBEF\x60W\xA4.j\x86\x92\x16\xF3-\xB3Be\x9E\x82\x60\x0A\x91\x89\x1C\xAE";

View File

@@ -0,0 +1,3 @@
<?php // dev.SLACK_DSN.b2b579 on Thu, 04 Jul 2024 09:59:28 +0000
return "\x132\xC5\x7FU\x92\xAC\x1D\xCDh\xF7\xD2\x3D\x98\x1D\xDF\xA7\xEDp\xEF\x97\xBE\xF9\x87\x40\x1E\xF4\xBC67\xA5q\xB4\x22\x19\xD66\x9F\xA65\x16\xAC\x0D\x22\x0B\xA1\xF3\x86\x05\x0CB\x9B\x1E\x90\x3B.mF\xF4W\x1F\xBA\xCF\x83E\x3CB\xAFL\x10\xA0\xC5F\xBD\xAF1Z\xB1m\xC8\xA9\x9B4Jq";

View File

@@ -2,4 +2,7 @@
return [
'AKISMET_KEY' => null,
'BLACKFIRE_SERVER_ID' => null,
'BLACKFIRE_SERVER_TOKEN' => null,
'SLACK_DSN' => null,
];

View File

@@ -0,0 +1,3 @@
<?php // prod.BLACKFIRE_SERVER_ID.6a382d on Thu, 04 Jul 2024 14:14:47 +0000
return "\x1B\x0F\x5E\x2C\x21\x14\xAB\x2C\xC2\x82\x25\xBALe\xEA\xAC\xD4\xA6D\xCF~\xF6\xAD\x1F\xD6\x9D\x23w\xFA\xC87D\x20\xF6\xE7\xCBE\xC7w\x81\x92\x15X\x22\x14\x5C\x1E5\x23\xC1\x18\x93\x3CpR\x60l\xC9\x96\xBAF\xEE\x17\x28\xECQ5\x1DI\x1Ai\xE1K\x12\x0D\x92lt\x15\x3F\x96\xD9K\xEE";

View File

@@ -0,0 +1,3 @@
<?php // prod.BLACKFIRE_SERVER_TOKEN.69fd63 on Thu, 04 Jul 2024 14:15:30 +0000
return "X\xBB3\xA7s\xB0\xF2\x01\x95\xB7\x8C\xE2\x09\x17\xED\x25\xB9\xB1\x0F\xB2\x24\x806qd\x5E\x8C\xAA\xC5\xA7\xF7p\xCA\x94\x24\x1E\x12\xFDf\xF2i\x3E\xA2sYeT\xBC\x09\xDAPbD\x96\xA5\x60\xE18\x89\xB9\x0D\xFD\x7BI\x3EvS\x3E\x3B\xFF\x9A\xAE3\x1D\xC2\xD7\x7F\xAC\x8CId\x94\x2B\x81\xF7\xB1\xCF\xEFS\x8F\x11\x60\x1C\xDD\x3B\xDE\x88\x99\xCEo\xCF\x22\xFB1h\xF4\xDB\xF3\x08\x10\xD6\xD2";

View File

@@ -0,0 +1,3 @@
<?php // prod.SLACK_DSN.b2b579 on Thu, 04 Jul 2024 09:59:52 +0000
return "hh\x1B\x164\xA9\x7F\xC0\xF2\x80\xB5\xE0\xA4\x86o\x27RfH\xA6\xEF\x86V\x25\x02\xE3\xFFS\xF6\xF1AF\x5D\x9C\xDA\x9E\xF3\xFA\x21\x8C\xA28\x87\xEE\x1DT\xD0\xDD\x22\xF3\xEA\x9D\xDFW\x82U\xCC\xB5\x7C\x97g\xAC\xA8K\x60\x3E\xE3\xB2\x10Z\xE1\xEA\x0Bt\xF3\xFB\xA6C644\x81A\x97\x5B";

View File

@@ -0,0 +1,7 @@
<?php
return [
'BLACKFIRE_SERVER_ID' => null,
'BLACKFIRE_SERVER_TOKEN' => null,
'SLACK_DSN' => null,
];

View File

@@ -0,0 +1,3 @@
<?php // test.AKISMET_KEY.ca01fb on Wed, 03 Jul 2024 12:19:37 +0000
return "\xE6\xCCY\xBAs\xE4\x8E\x8BP\xD8Ds\xC1\xE4\xDD\xF6.\xDD\x25\xE9\x0B\x2F\xA1\xA2\xCF\x23\xB7\xDC\xFBe\x40w\x0E\xA4\xE7\xA7\xA2\xAD\xB4C\x0A.\x5EFJ\xB5\x3C\xAD2-\xF2\x12\x13\xD8\xB9\xB3\x97\xC6\x7D\x81";

View File

@@ -0,0 +1,4 @@
<?php // test.decrypt.private on Wed, 03 Jul 2024 12:19:37 +0000
// SYMFONY_DECRYPTION_SECRET=ww2tRpi8jFYTQo4R8uWcftDvPuzGdPbv5YMYacbB1JJXmvMhFBggA+o3qXw7zISa1js878Zj8+v3I0xFTetJLQ==
return "\xC3\x0D\xADF\x98\xBC\x8CV\x13B\x8E\x11\xF2\xE5\x9C~\xD0\xEF\x3E\xEC\xC6t\xF6\xEF\xE5\x83\x18i\xC6\xC1\xD4\x92W\x9A\xF3\x21\x14\x18\x20\x03\xEA7\xA9\x7C\x3B\xCC\x84\x9A\xD6\x3B\x3C\xEF\xC6c\xF3\xEB\xF7\x23LEM\xEBI-";

View File

@@ -0,0 +1,3 @@
<?php // test.encrypt.public on Wed, 03 Jul 2024 12:19:37 +0000
return "W\x9A\xF3\x21\x14\x18\x20\x03\xEA7\xA9\x7C\x3B\xCC\x84\x9A\xD6\x3B\x3C\xEF\xC6c\xF3\xEB\xF7\x23LEM\xEBI-";

View File

@@ -0,0 +1,5 @@
<?php
return [
'AKISMET_KEY' => null,
];

View File

@@ -5,6 +5,12 @@
# https://symfony.com/doc/current/best_practices.html#use-parameters-for-application-configuration
parameters:
photo_dir: "%kernel.project_dir%/public/uploads/photos"
default_admin_email: admin@example.com
admin_email: "%env(string:default:default_admin_email:ADMIN_EMAIL)%"
default_base_url: 'http://127.0.0.1'
router.request_context.base_url: '%env(default:default_base_url:SYMFONY_DEFAULT_ROUTE_URL)%'
app.supported_locales: 'en|fr'
services:
# default configuration for services in *this* file
_defaults:

View File

@@ -1,28 +0,0 @@
<?php
/**
* Returns the importmap for this application.
*
* - "path" is a path inside the asset mapper system. Use the
* "debug:asset-map" command to see the full list of paths.
*
* - "entrypoint" (JavaScript only) set to true for any module that will
* be used as an "entrypoint" (and passed to the importmap() Twig function).
*
* The "importmap:require" command can be used to add new entries to this file.
*/
return [
'app' => [
'path' => './assets/app.js',
'entrypoint' => true,
],
'@hotwired/stimulus' => [
'version' => '3.2.2',
],
'@symfony/stimulus-bundle' => [
'path' => './vendor/symfony/stimulus-bundle/assets/dist/loader.js',
],
'@hotwired/turbo' => [
'version' => '7.3.0',
],
];

View File

@@ -0,0 +1,31 @@
<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20240703122751 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('CREATE SCHEMA public');
}
}

View File

@@ -0,0 +1,33 @@
<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20240703132629 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE comment ADD state VARCHAR(255) DEFAULT \'submitted\' NOT NULL');
$this->addSql("UPDATE comment SET state='published'");
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('CREATE SCHEMA public');
$this->addSql('ALTER TABLE comment DROP state');
}
}

17941
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

30
package.json Normal file
View File

@@ -0,0 +1,30 @@
{
"devDependencies": {
"@babel/core": "^7.17.0",
"@babel/preset-env": "^7.16.0",
"@hotwired/stimulus": "^3.0.0",
"@hotwired/turbo": "^7.1.1 || ^8.0",
"@popperjs/core": "^2.11.8",
"@symfony/stimulus-bridge": "^3.2.0",
"@symfony/ux-turbo": "file:vendor/symfony/ux-turbo/assets",
"@symfony/webpack-encore": "^4.0.0",
"bootstrap": "^5.3.3",
"bs-custom-file-input": "^1.3.4",
"core-js": "^3.23.0",
"node-sass": "^9.0.0",
"regenerator-runtime": "^0.13.9",
"sass": "^1.77.6",
"sass-loader": "^13.3.3",
"webpack": "^5.74.0",
"webpack-cli": "^4.10.0",
"webpack-notifier": "^1.15.0"
},
"license": "UNLICENSED",
"private": true,
"scripts": {
"dev-server": "encore dev-server",
"dev": "encore dev",
"watch": "encore dev --watch",
"build": "encore production --progress"
}
}

View File

@@ -5,4 +5,11 @@ max_execution_time=30
session.use_strict_mode=On
realpath_cache_ttl=3600
zend.detect_unicode=Off
xdebug.file_link_format = "phpstorm://open?file=%f&line=%l"
xdebug.file_link_format = "phpstorm://open?file=%f&line=%l"
[blackfire]
# use php_blackfire.dll on Windows
extension=blackfire.so
blackfire.log_level=4
[xdebug]
xdebug.mode=debug
xdebug.start_with_request=yes

27
spa/.platform.app.yaml Normal file
View File

@@ -0,0 +1,27 @@
name: spa
type: nodejs:18
size: S
build:
flavor: none
web:
commands:
start: sleep
locations:
"/":
root: "public"
index:
- "index.html"
scripts: false
expires: 10m
hooks:
build: |
set -x -e
curl -fs https://get.symfony.com/cloud/configurator | bash
NODE_VERSION=18 node-build

26
spa/app/.gitignore vendored Normal file
View File

@@ -0,0 +1,26 @@
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
.DS_Store
# Generated by package manager
node_modules/
# Generated by Cordova
/plugins/
/platforms/

11
spa/app/config.xml Normal file
View File

@@ -0,0 +1,11 @@
<?xml version='1.0' encoding='utf-8'?>
<widget id="io.cordova.hellocordova" version="1.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>HelloCordova</name>
<description>Sample Apache Cordova App</description>
<author email="dev@cordova.apache.org" href="https://cordova.apache.org">
Apache Cordova Team
</author>
<content src="index.html" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" />
</widget>

1711
spa/app/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

23
spa/app/package.json Normal file
View File

@@ -0,0 +1,23 @@
{
"name": "io.cordova.hellocordova",
"displayName": "HelloCordova",
"version": "1.0.0",
"description": "A sample Apache Cordova application that responds to the deviceready event.",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"keywords": [
"ecosystem:cordova"
],
"author": "Apache Cordova Team",
"license": "Apache-2.0",
"devDependencies": {
"cordova-android": "^13.0.0"
},
"cordova": {
"platforms": [
"android"
]
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,13 @@
{
"entrypoints": {
"app": {
"js": [
"/runtime.js",
"/app.js"
],
"css": [
"/app.css"
]
}
}
}

View File

@@ -0,0 +1 @@
<!doctype html><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge"/><meta name="msapplication-tap-highlight" content="no"/><meta name="viewport" content="user-scalable=no,initial-scale=1,maximum-scale=1,minimum-scale=1,width=device-width"/><title>Conference Guestbook application</title><script defer="defer" src="/runtime.js"></script><script defer="defer" src="/app.js"></script><link href="/app.css" rel="stylesheet"></head><body><div id="app"></div></body></html>

View File

@@ -0,0 +1,6 @@
{
"app.css": "/app.css",
"app.js": "/app.js",
"runtime.js": "/runtime.js",
"index.html": "/index.html"
}

View File

@@ -0,0 +1 @@
(()=>{"use strict";var r,e={},o={};function t(r){var n=o[r];if(void 0!==n)return n.exports;var a=o[r]={exports:{}};return e[r](a,a.exports,t),a.exports}t.m=e,r=[],t.O=(e,o,n,a)=>{if(!o){var s=1/0;for(l=0;l<r.length;l++){for(var[o,n,a]=r[l],i=!0,p=0;p<o.length;p++)(!1&a||s>=a)&&Object.keys(t.O).every((r=>t.O[r](o[p])))?o.splice(p--,1):(i=!1,a<s&&(s=a));if(i){r.splice(l--,1);var f=n();void 0!==f&&(e=f)}}return e}a=a||0;for(var l=r.length;l>0&&r[l-1][2]>a;l--)r[l]=r[l-1];r[l]=[o,n,a]},t.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r={121:0};t.O.j=e=>0===r[e];var e=(e,o)=>{var n,a,[s,i,p]=o,f=0;if(s.some((e=>0!==r[e]))){for(n in i)t.o(i,n)&&(t.m[n]=i[n]);if(p)var l=p(t)}for(e&&e(o);f<s.length;f++)a=s[f],t.o(r,a)&&r[a]&&r[a][0](),r[a]=0;return t.O(l)},o=self.webpackChunkspa=self.webpackChunkspa||[];o.forEach(e.bind(null,0)),o.push=e.bind(null,o.push.bind(o))})()})();

View File

@@ -0,0 +1 @@
$font-family-title: Georgia, Times, 'New Roman', serif;

View File

@@ -0,0 +1,62 @@
@import '~bootstrap/scss/bootstrap';
@import './variables';
body {
display: flex;
flex-direction: column;
height: 100vh;
}
a {
text-decoration: none;
}
main {
flex: 1;
}
.navbar-brand {
font-family: $font-family-title;
font-weight: $font-weight-normal;
font-size: 1.8rem;
}
.navbar-brand, .nav-link {
transition: all .15s;
}
.nav-conference {
display: inline-block;
padding: 5px 10px;
color: #666;
text-transform: uppercase;
font-size: 0.8rem;
}
.lift {
transition: box-shadow .25s ease,transform .25s ease;
&:focus, &:hover {
box-shadow: 0 1rem 2.5rem rgba(22,28,45,.1),0 .5rem 1rem -.75rem rgba(22,28,45,.1)!important;
transform: translate3d(0, -4px, 0);
}
}
.comment-img {
width: 250px;
height: 150px;
img {
max-width: 250px;
max-height: 150px;
}
}
.comment-text {
font-size: 12px;
line-height: 15px;
}
footer {
background: #18171b;
}

1
spa/node_modules/.bin/acorn generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../acorn/bin/acorn

1
spa/node_modules/.bin/ansi-html generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../ansi-html-community/bin/ansi-html

1
spa/node_modules/.bin/arborist generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../@npmcli/arborist/bin/index.js

1
spa/node_modules/.bin/browserslist generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../browserslist/cli.js

1
spa/node_modules/.bin/color-support generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../color-support/bin.js

1
spa/node_modules/.bin/cordova generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../cordova/bin/cordova

1
spa/node_modules/.bin/cssesc generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../cssesc/bin/cssesc

1
spa/node_modules/.bin/encore generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../@symfony/webpack-encore/bin/encore.js

1
spa/node_modules/.bin/envinfo generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../envinfo/dist/cli.js

1
spa/node_modules/.bin/flat generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../flat/cli.js

1
spa/node_modules/.bin/he generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../he/bin/he

1
spa/node_modules/.bin/html-minifier-terser generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../html-minifier-terser/cli.js

1
spa/node_modules/.bin/import-local-fixture generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../import-local/fixtures/cli.js

1
spa/node_modules/.bin/installed-package-contents generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../@npmcli/installed-package-contents/bin/index.js

1
spa/node_modules/.bin/is-docker generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../is-docker/cli.js

1
spa/node_modules/.bin/jsesc generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../jsesc/bin/jsesc

1
spa/node_modules/.bin/json5 generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../json5/lib/cli.js

1
spa/node_modules/.bin/md5-file generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../md5-file/cli.js

1
spa/node_modules/.bin/mime generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../mime/cli.js

1
spa/node_modules/.bin/mkdirp generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../mkdirp/bin/cmd.js

1
spa/node_modules/.bin/multicast-dns generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../multicast-dns/cli.js

1
spa/node_modules/.bin/nanoid generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../nanoid/bin/nanoid.cjs

1
spa/node_modules/.bin/node-gyp generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../node-gyp/bin/node-gyp.js

1
spa/node_modules/.bin/node-sass generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../node-sass/bin/node-sass

1
spa/node_modules/.bin/node-which generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../which/bin/node-which

1
spa/node_modules/.bin/nopt generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../nopt/bin/nopt.js

1
spa/node_modules/.bin/pacote generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../pacote/lib/bin.js

1
spa/node_modules/.bin/parser generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../@babel/parser/bin/babel-parser.js

1
spa/node_modules/.bin/regjsparser generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../regjsparser/bin/parser

1
spa/node_modules/.bin/resolve generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../resolve/bin/resolve

1
spa/node_modules/.bin/rimraf generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../rimraf/bin.js

1
spa/node_modules/.bin/sassgraph generated vendored Symbolic link
View File

@@ -0,0 +1 @@
../sass-graph/bin/sassgraph

Some files were not shown because too many files have changed in this diff Show More