Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import hydefront package #11

Merged
merged 236 commits into from
Jun 8, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
236 commits
Select commit Hold shift + click to select a range
fea80bf
Initial commit
caendesilva Apr 12, 2022
bc3aeed
Update Readme
caendesilva Apr 12, 2022
52246f8
Add .gitignore
caendesilva Apr 12, 2022
4030a04
Set version to 0.4.0
caendesilva Apr 12, 2022
612e3c6
Add package.json
caendesilva Apr 12, 2022
8db4370
Update readme
caendesilva Apr 12, 2022
191fcda
Create codeql.yml
caendesilva Apr 12, 2022
de7eee2
Add build scripts
caendesilva Apr 12, 2022
7f5c2c6
Add build scripts
caendesilva Apr 12, 2022
a132513
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva Apr 12, 2022
c236375
Create devskim.yml
caendesilva Apr 12, 2022
30a9596
Create dependency-review.yml
caendesilva Apr 12, 2022
9e9df80
Update README.md
caendesilva Apr 12, 2022
f61bc31
Add dark mode support
caendesilva Apr 12, 2022
bf44c00
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva Apr 12, 2022
c811dd5
Sync with Framework
caendesilva Apr 12, 2022
8c00e35
Create tailwind.min.css
caendesilva Apr 18, 2022
d38dd40
Add Shield
caendesilva Apr 20, 2022
9ae8945
Update README.md
caendesilva Apr 20, 2022
67c2ec1
Create create-framework-merge-pr.yml
caendesilva Apr 20, 2022
a2ddf59
Update create-framework-merge-pr.yml
caendesilva Apr 20, 2022
e7324ce
Update create-framework-merge-pr.yml
caendesilva Apr 20, 2022
1ee22cf
Update create-framework-merge-pr.yml
caendesilva Apr 20, 2022
302fa6e
Update create-framework-merge-pr.yml
caendesilva Apr 20, 2022
9eb340e
Update create-framework-merge-pr.yml
caendesilva Apr 20, 2022
4b08015
Delete create-framework-merge-pr.yml
caendesilva Apr 20, 2022
c98d14e
Update from https://github.com/hydephp/framework/commit/d0ec4029cdef1…
Apr 20, 2022
d0b7849
Merge pull request #4 from hydephp/framework-merge
caendesilva Apr 20, 2022
0746cf9
Move compiled files into dist
caendesilva Apr 20, 2022
81f93ac
Create node.js.yml
caendesilva Apr 20, 2022
f0db65b
Update node.js.yml
caendesilva Apr 20, 2022
b14a18d
Update node.js.yml
caendesilva Apr 20, 2022
e599cc5
Update node.js.yml
caendesilva Apr 20, 2022
97343b6
Update node.js.yml
caendesilva Apr 20, 2022
e20617f
Update node.js.yml
caendesilva Apr 20, 2022
7c2393e
Update node.js.yml
caendesilva Apr 20, 2022
9e9fd58
Update node.js.yml
caendesilva Apr 21, 2022
da68c31
Update node.js.yml
caendesilva Apr 21, 2022
e898a95
Update node.js.yml
caendesilva Apr 21, 2022
a4aaf26
Update README.md
caendesilva Apr 21, 2022
74f2d76
Update app.css
caendesilva Apr 21, 2022
a062a98
Remove duplicated directory created by CI
caendesilva Apr 21, 2022
e040de4
Clean up readme
caendesilva Apr 21, 2022
860ab59
Use lists instead of H4 headings
caendesilva Apr 21, 2022
34dc2c3
Update from https://github.com/hydephp/framework/commit/33fd581c4fcb1…
Apr 21, 2022
0a82176
Merge pull request #9 from hydephp/framework-merge
caendesilva Apr 21, 2022
5590a2d
Update from https://github.com/hydephp/framework/commit/bd218df813c8f…
Apr 21, 2022
40f43b1
Merge pull request #10 from hydephp/framework-merge
caendesilva Apr 21, 2022
62a9d56
Update from https://github.com/hydephp/framework/commit/75f0aaa195d02…
Apr 27, 2022
ad55b29
Merge pull request #11 from hydephp/framework-merge
caendesilva Apr 27, 2022
aa46990
Remove non-minified files from dist
caendesilva Apr 27, 2022
e9c0794
Update assets
caendesilva Apr 27, 2022
0af2793
Update version
caendesilva Apr 27, 2022
a2eda20
Revert "Update assets"
caendesilva Apr 27, 2022
9a6185c
Update assets
caendesilva Apr 27, 2022
515e3ea
Remove run dev
caendesilva Apr 27, 2022
9a37783
Update lockfile
caendesilva Apr 27, 2022
b3f0fda
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva Apr 27, 2022
9e2c98e
Revert "Update assets"
caendesilva Apr 27, 2022
db7a0bc
Fix output filename
caendesilva Apr 27, 2022
3ed6c6e
Update CDN links to v1.3.1
caendesilva Apr 27, 2022
3f7ae94
Update to Framework v0.15.x
caendesilva Apr 27, 2022
433cff4
Update from https://github.com/hydephp/framework/commit/49cd0456ba83d…
Apr 28, 2022
c15fa8d
Merge pull request #12 from hydephp/framework-merge
caendesilva Apr 28, 2022
aa14c5f
Update assets
caendesilva Apr 28, 2022
09b0cbe
Remove tailwind override https://github.com/hydephp/hyde/issues/120
caendesilva Apr 28, 2022
85001d5
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva Apr 28, 2022
14c5b8a
Add Contributing section
caendesilva Apr 28, 2022
bd9f9d3
Update from https://github.com/hydephp/framework/commit/4775b94290c83…
Apr 28, 2022
82d67f0
Merge pull request #13 from hydephp/framework-merge
caendesilva Apr 28, 2022
f72ede2
Set dependencies as devDependencies
caendesilva Apr 28, 2022
4a9c820
Add main dist/hyde.js
caendesilva Apr 28, 2022
a6659b4
Update from https://github.com/hydephp/framework/commit/29d0e85bbbbf4…
Apr 28, 2022
b0c7cad
Merge pull request #14 from hydephp/framework-merge
caendesilva Apr 28, 2022
ac02f15
Switch to using TypeScript
caendesilva Apr 28, 2022
2682258
Update assets
caendesilva Apr 28, 2022
b7cd2bc
Update from https://github.com/hydephp/framework/commit/f369c4e71c231…
Apr 28, 2022
73f9f5f
Merge pull request #17 from hydephp/framework-merge
caendesilva Apr 28, 2022
94062a6
Update from https://github.com/hydephp/framework/commit/dddb03d17b2cc…
Apr 28, 2022
1a3c5cd
Add action status badges
caendesilva Apr 28, 2022
5ed6dd5
Merge pull request #18 from hydephp/framework-merge
caendesilva Apr 28, 2022
1f7bf0d
Add "About HydePHP" section
caendesilva Apr 29, 2022
c4f3035
Update from https://github.com/hydephp/hyde/commit/c9308e593ae767c369…
Apr 29, 2022
ec3b0d3
Merge pull request #19 from hydephp/hyde-merge
caendesilva Apr 29, 2022
ca492a9
Update from https://github.com/hydephp/framework/commit/22d953565e0ad…
Apr 29, 2022
8b27d6b
Switch CDN links to NPM in Readme
caendesilva Apr 29, 2022
35e1595
Add jsDelivr badge and some links
caendesilva Apr 29, 2022
57cc2b3
Merge pull request #20 from hydephp/framework-merge
caendesilva Apr 29, 2022
c86e4e2
Update from https://github.com/hydephp/framework/commit/372bf15a4cacb…
Apr 29, 2022
9211e1c
Merge pull request #21 from hydephp/framework-merge
caendesilva Apr 29, 2022
f37bedd
Update from https://github.com/hydephp/hyde/commit/7d6862533949a1dc79…
Apr 30, 2022
667dbd2
Merge pull request #22 from hydephp/hyde-merge
caendesilva Apr 30, 2022
db94d17
Update from https://github.com/hydephp/framework/commit/c25196aebb77e…
Apr 30, 2022
de8e843
Merge pull request #23 from hydephp/framework-merge
caendesilva May 1, 2022
76cbae3
Rename workflow
caendesilva May 1, 2022
93cfb8a
[create-pull-request] automated change
caendesilva May 1, 2022
da5f366
Merge pull request #24 from hydephp/create-pull-request/patch
caendesilva May 1, 2022
318772e
Add link to framework subrepo
caendesilva May 1, 2022
64e4979
Add links and shields
caendesilva May 1, 2022
bee3d03
Fix grammar
caendesilva May 1, 2022
60427c9
Add back links
caendesilva May 1, 2022
6050260
Update version
caendesilva May 1, 2022
033a7b3
Add docs on how to load styles from Laravel Mix
caendesilva May 1, 2022
355c29a
Update README.md
caendesilva May 1, 2022
4ed2558
[create-pull-request] automated change
caendesilva May 1, 2022
24ae1fe
Merge pull request #27 from hydephp/create-pull-request/patch
caendesilva May 1, 2022
aad53ff
Delete app.css, fix #25
caendesilva May 1, 2022
aa7f7c5
Merge pull request #30 from hydephp/remove-compiled-tailwind
caendesilva May 1, 2022
42a14b6
Remove app.css
caendesilva May 1, 2022
751369d
Update README.md
caendesilva May 1, 2022
35b3593
Add back info about app.css
caendesilva May 1, 2022
813d22b
Revert "Merge pull request #30 from hydephp/remove-compiled-tailwind"
caendesilva May 1, 2022
6cc0db9
Merge pull request #32 from hydephp/31-add-back-appcss-so-it-can-be-p…
caendesilva May 1, 2022
d9ec837
[create-pull-request] automated change
caendesilva May 1, 2022
a4c6f6b
Merge pull request #33 from hydephp/create-pull-request/patch
caendesilva May 1, 2022
ee0b2fd
Create deploy-preview.yml
caendesilva May 2, 2022
72d6489
Update base HTML to remove outgoing links
caendesilva May 2, 2022
9f4d721
Merge pull request #34 from hydephp/update-deploy-workfloww
caendesilva May 2, 2022
f26eeb2
Create a comment in pull requests about the preview
caendesilva May 2, 2022
4e11c7f
Merge pull request #35 from hydephp/update-preview-action
caendesilva May 2, 2022
7a8e990
Add link to tailwind.config.js
caendesilva May 2, 2022
5165450
[create-pull-request] automated change
caendesilva May 2, 2022
d03ae1f
Merge pull request #36 from hydephp/create-pull-request/patch
caendesilva May 2, 2022
ea2eec2
Use event listeners instead of HTML onclick
caendesilva May 4, 2022
a545c04
[create-pull-request] automated change
caendesilva May 4, 2022
47263c7
Merge pull request #38 from hydephp/create-pull-request/patch
caendesilva May 4, 2022
8d0e9d4
Add the TypeScript compiler
caendesilva May 4, 2022
b048407
Update versions
caendesilva May 4, 2022
db095ca
Add static test files
caendesilva May 4, 2022
296ad9b
Update Readme to reflect decoupling of HydeFront
May 4, 2022
ac4bc1a
Install and initialize Cypress
caendesilva May 4, 2022
02343df
Create .gitattributes
caendesilva May 4, 2022
3c27d46
Compile site with junctioned Hyde/Framework
caendesilva May 4, 2022
4510b39
Create navigation-menu-test.spec.js
caendesilva May 4, 2022
e40684f
Create darkmode-test.spec.js
caendesilva May 4, 2022
c7d6027
Create documentation-sidebar-test.spec.js
caendesilva May 4, 2022
55fbe90
Make variables and functions strongly typed
caendesilva May 4, 2022
f21afaf
Create .gitignore
caendesilva May 4, 2022
0a50864
Merge pull request #39 from hydephp/add-tests
caendesilva May 5, 2022
656e366
Update assets
caendesilva May 5, 2022
94acd44
Create cypress-tests.yml
caendesilva May 5, 2022
5f4e19b
Update cypress-tests.yml
caendesilva May 5, 2022
0a5b4ee
Add cypress.json to export-ignore
caendesilva May 5, 2022
7d14c37
Add /tests to linguist-vendored
caendesilva May 5, 2022
c488f4a
Create npm-publish.yml
caendesilva May 5, 2022
d031455
Update to match Framework 0.23.x
caendesilva May 5, 2022
b8644e9
Add Cypress output files to root .gitignore
caendesilva May 5, 2022
fe6427c
Bump version to 1.6.x
caendesilva May 5, 2022
d4ffa6e
Add dynamic theme toggle icon
caendesilva May 5, 2022
57fee74
Update to use Lagrafo
caendesilva May 5, 2022
f0392a6
Update test specs
caendesilva May 5, 2022
9e51a4c
Merge pull request #40 from hydephp/update-to-lagrafo
caendesilva May 5, 2022
7dd6a77
Add Warranty section
caendesilva May 5, 2022
92be26a
Recompile assets
caendesilva May 5, 2022
6774317
Bundle Lagrafo with Hyde and remove deprecated sidebar functions
caendesilva May 5, 2022
aaffba4
Make hamburger menu bars slimmer
caendesilva May 5, 2022
6373a07
Update assets
caendesilva May 5, 2022
259ba6a
Update dark-mode compat to match the rest of Hyde
caendesilva May 5, 2022
88c02f9
Update assets
caendesilva May 5, 2022
672c51c
De-emphasize sidebar links when not in focus
caendesilva May 5, 2022
1fff9c3
Update assets
caendesilva May 5, 2022
6bf4b16
Merge pull request #42 from hydephp/Bundle-Lagrafo-with-Hyde
caendesilva May 6, 2022
cde0f54
Merge with Hyde
caendesilva May 6, 2022
69e8b5a
Update colors to blend better
caendesilva May 6, 2022
fc3e776
Make icon bars thinner
caendesilva May 6, 2022
bb3d781
Update assets
caendesilva May 6, 2022
fae985b
Remove - run: npm test
caendesilva May 6, 2022
4c9f16a
Update version
caendesilva May 6, 2022
b270863
Delete cypress-tests.yml
caendesilva May 8, 2022
7cb7430
Remove Cypress directory
caendesilva May 8, 2022
c8071ef
Remove tests directory
caendesilva May 8, 2022
44e9e17
Delete cypress.json
caendesilva May 8, 2022
6293c9d
Remove Cypress from .gitignore
caendesilva May 8, 2022
59f1348
Remove Cypress
caendesilva May 8, 2022
c1ae729
Merge pull request #44 from hydephp/remove-cypress-tests
caendesilva May 8, 2022
6ba3628
Style the sidebar layout for sidebars with categories
caendesilva May 11, 2022
d51b1e7
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva May 11, 2022
e69b2bd
Update assets
caendesilva May 11, 2022
3fdd3f5
Update package.json
caendesilva May 11, 2022
fa6b89a
Update versions in usage
caendesilva May 11, 2022
f0445b5
[create-pull-request] automated change
May 16, 2022
b99eba3
Merge pull request #49 from hydephp/create-pull-request/patch
caendesilva May 19, 2022
c728c11
Update version comments to match
caendesilva May 30, 2022
97fd29b
Create the base search stylesheet
caendesilva May 30, 2022
2132a7d
Add auxiliary styles
caendesilva May 30, 2022
543946c
Update comment
caendesilva May 30, 2022
672bca2
Update assets
caendesilva May 30, 2022
2f8b45b
[create-pull-request] automated change
caendesilva May 30, 2022
cae1cf2
1.9.0
caendesilva May 30, 2022
1563e09
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva May 30, 2022
a471c59
Merge pull request #52 from hydephp/create-pull-request/patch
caendesilva May 30, 2022
141a864
Set the meta color scheme when switching theme
caendesilva May 31, 2022
d48a557
Compile assets
caendesilva May 31, 2022
6a9c036
Update base HTML for preview
caendesilva May 31, 2022
bb30721
Add colored blockquotes
caendesilva Jun 2, 2022
0c248f6
Add codeblock filepath styling
caendesilva Jun 2, 2022
59c4375
1.10.1
caendesilva Jun 2, 2022
658d367
Merge pull request #54 from hydephp/add-styles-to-markdown-postprepro…
caendesilva Jun 2, 2022
1cc1a03
Update assets
caendesilva Jun 2, 2022
d2fdd2d
Fix #45: Add spacing between sidebar TOC headings
caendesilva Jun 2, 2022
98ecc1b
1.10.2
caendesilva Jun 2, 2022
4f1b3ab
Merge pull request #55 from hydephp/add-extra-spacing-between-multi-l…
caendesilva Jun 2, 2022
b502acb
Update assets
caendesilva Jun 2, 2022
edd0b81
Create an improved documentation print layout
caendesilva Jun 2, 2022
8837f06
1.10.3
caendesilva Jun 2, 2022
5e68e1e
Merge pull request #56 from hydephp/improve-documentation-print-layout
caendesilva Jun 2, 2022
64fa006
Update assets
caendesilva Jun 2, 2022
139ff03
Fix #57: Style heading permalinks
caendesilva Jun 2, 2022
121b9a2
1.10.4
caendesilva Jun 2, 2022
a22a36c
Merge pull request #58 from hydephp/style-heading-permalinks
caendesilva Jun 2, 2022
e1f6253
Update assets
caendesilva Jun 2, 2022
cd1c849
Add #document-header styles
caendesilva Jun 2, 2022
cde5f4e
Decrease margin for header/footer <p> tags
caendesilva Jun 2, 2022
331f4fb
1.10.5
caendesilva Jun 2, 2022
f910d3c
Update assets
caendesilva Jun 2, 2022
b36f069
Add header h1 styling
caendesilva Jun 2, 2022
3fbed0a
Align items center
caendesilva Jun 2, 2022
3411897
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva Jun 2, 2022
9630982
1.10.6
caendesilva Jun 2, 2022
34133fa
Update assets
caendesilva Jun 2, 2022
24a3c78
Make footer text smaller
caendesilva Jun 2, 2022
615b918
Allow footer/header content to wrap
caendesilva Jun 2, 2022
fd00de5
Merge branch 'master' of github.com:hydephp/hydefront
caendesilva Jun 2, 2022
aad7999
Update assets
caendesilva Jun 2, 2022
58af0f4
Update close button positioning, see https://github.com/hydephp/frame…
caendesilva Jun 2, 2022
3c4aa2f
1.10.7
caendesilva Jun 2, 2022
b321eb9
Update assets
caendesilva Jun 2, 2022
9928e7c
1.11.0
caendesilva Jun 3, 2022
e6e369a
[create-pull-request] automated change
caendesilva Jun 4, 2022
17c3d64
Merge pull request #59 from hydephp/create-pull-request/patch
Jun 4, 2022
37cc899
[create-pull-request] automated change
caendesilva Jun 4, 2022
af2f671
Merge pull request #60 from hydephp/create-pull-request/patch
caendesilva Jun 6, 2022
084f893
Hide filepath label on small screens, see https://github.com/hydephp/…
caendesilva Jun 7, 2022
ef4d36a
Update assets
caendesilva Jun 7, 2022
d447071
Move hydefront into packages/hydefront
caendesilva Jun 8, 2022
c5605e0
Merge branch 'move-to-packages'
caendesilva Jun 8, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions packages/hydefront/.gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
* text=auto

*.css diff=css
*.html diff=html
*.md diff=markdown

/.github export-ignore
/tests export-ignore
/cypress export-ignore
cypress.json export-ignore
.editorconfig export-ignore
.gitattributes export-ignore
.styleci.yml export-ignore
CHANGELOG-* export-ignore
CODE_OF_CONDUCT.md export-ignore
CONTRIBUTING.md export-ignore

/tests linguist-vendored
70 changes: 70 additions & 0 deletions packages/hydefront/.github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
push:
branches: [ master ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ master ]
schedule:
- cron: '15 21 * * 3'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'javascript' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://git.io/codeql-language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
20 changes: 20 additions & 0 deletions packages/hydefront/.github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Dependency Review Action
#
# This Action will scan dependency manifest files that change as part of a Pull Reqest, surfacing known-vulnerable versions of the packages declared or updated in the PR. Once installed, if the workflow run is marked as required, PRs introducing known-vulnerable packages will be blocked from merging.
#
# Source repository: https://github.com/actions/dependency-review-action
# Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement
name: 'Dependency Review'
on: [pull_request]

permissions:
contents: read

jobs:
dependency-review:
runs-on: ubuntu-latest
steps:
- name: 'Checkout Repository'
uses: actions/checkout@v3
- name: 'Dependency Review'
uses: actions/dependency-review-action@v1
75 changes: 75 additions & 0 deletions packages/hydefront/.github/workflows/deploy-preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Build and deploy a static preview of a Hyde site using the triggering commit's assets
# Note that it expects that the assets have been compiled to the dist directory.
name: Build and Deploy Preview

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Download base HTML
run: wget https://raw.githubusercontent.com/caendesilva/hydefront-preview/93fd8be1c604cdfa99c7aca513b3f245c1b313a7/hydefront-preview.html

- name: Download compiler
run: wget https://raw.githubusercontent.com/caendesilva/hydefront-preview/4aaa498f341fca0b32df37e20b8f3dd6a0dbeefd/compiler.php

- name: Run the compiler
run: php compiler.php ${{ github.sha }}

- name: Upload the artifact
uses: actions/upload-artifact@v3
with:
name: "output"
path: "hydefront-preview-output.html"

deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: hydefront-preview
url: https://hydephp.github.io/developer-tools/hydefront-previews/${{ github.sha }}

steps:
- name: Download the artifact
uses: actions/download-artifact@v3
with:
name: "output"

- name: Rename file to index.html
run: mv hydefront-preview-output.html index.html

- name: Upload files to GitHub Pages
uses: cpina/github-action-push-to-another-repository@v1.4.2
env:
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
with:
source-directory: "."
destination-github-username: "hydephp"
destination-repository-name: "developer-tools"
target-branch: gh-pages
target-directory: "hydefront-previews/${{ github.sha }}"

- name: Output the URL
run: echo "https://hydephp.github.io/developer-tools/hydefront-previews/${{ github.sha }}"

comment-on-pull-request:
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v5
with:
github-token: ${{secrets.API_TOKEN_GITHUB}}
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: 'A [live preview](https://hydephp.github.io/developer-tools/hydefront-previews/${{ github.sha }}) is being deployed!<br><br>Please note that it may take a few seconds for GitHub Pages to build and deploy. The preview will be removed in a few days.'
})
34 changes: 34 additions & 0 deletions packages/hydefront/.github/workflows/devskim.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.

name: DevSkim

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '24 18 * * 1'

jobs:
lint:
name: DevSkim
runs-on: ubuntu-20.04
permissions:
actions: read
contents: read
security-events: write
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Run DevSkim scanner
uses: microsoft/DevSkim-Action@v1

- name: Upload DevSkim scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v2
with:
sarif_file: devskim-results.sarif
39 changes: 39 additions & 0 deletions packages/hydefront/.github/workflows/node.js.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the compiled assets, and push them.
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Build Assets

on:
push:
branches: [ master ]

jobs:
build-assets:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Setup Node.js
uses: actions/setup-node@v3
with:
cache: 'npm'

- name: Install Node.js dependencies
run: npm ci

- name: Build assets for production
run: npm run prod

- name: Upload artifacts
uses: actions/upload-artifact@v1
with:
name: 'assets'
path: 'dist'

- name: Push assets to GitHub
uses: EndBug/add-and-commit@v9
with:
add: 'dist'
message: 'Update assets'
32 changes: 32 additions & 0 deletions packages/hydefront/.github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages

name: Node.js Package

on:
release:
types: [created]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- run: npm ci

publish-npm:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
registry-url: https://registry.npmjs.org/
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
3 changes: 3 additions & 0 deletions packages/hydefront/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/node_modules
/tests/hyde
/.idea
74 changes: 74 additions & 0 deletions packages/hydefront/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# HydePHP Frontend Assets
![jsDelivr hits (GitHub)](https://img.shields.io/jsdelivr/gh/hm/hydephp/hydefront)
[![jsDelivr hits (NPM)](https://data.jsdelivr.com/v1/package/npm/hydefront/badge?style=rounded)](https://www.jsdelivr.com/package/npm/hydefront)
![NPM Downloads](https://img.shields.io/npm/dm/hydefront)
[![Build & Push CI](https://github.com/hydephp/hydefront/actions/workflows/node.js.yml/badge.svg)](https://github.com/hydephp/hydefront/actions/workflows/node.js.yml)
[![CodeQL](https://github.com/hydephp/hydefront/actions/workflows/codeql.yml/badge.svg)](https://github.com/hydephp/hydefront/actions/workflows/codeql.yml)

## About this repository

Contains the frontend assets for HydePHP.

### Source files
Source files are stored in the root of the repository. These can be published to your Hyde installation or used to compile into the dist/ directory.

### Compiled files
Compiled files are stored in the dist/ directory and can be loaded through the CDN or NPM.

### About the files

- **Hyde.css**:
The Hyde stylesheet contains the base styles for the Hyde views.

- **Hyde.js**:
This file contains basic scripts to make the navigation menu and sidebars interactive.

- **App.css**:
A compiled and minified file containing the styles for a base Hyde installation using [this configuration file](https://github.com/hydephp/hyde/blob/master/tailwind.config.js).


## Usage
Note that HydeFront is included in Hyde/Hyde through the CDN out of the box.

### Using CDN
See https://www.jsdelivr.com/package/npm/hydefront

```html
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/hydephp/hydefront@v1.8/dist/hyde.css">

<script defer src="https://cdn.jsdelivr.net/gh/hydephp/hydefront@v1.8/dist/hyde.js"></script>
```

### Using NPM (with Laravel Mix)
HydeFront is also available as an [NPM package](https://www.npmjs.com/package/hydefront), if you want to compile all your assets using Laravel Mix. Note that it is recommended to use the CDN as the Framework takes care of versioning.

Install the package
```bash
npm install hydefront
```

Next, add the following import to `resources/assets/app.css`
```css
@import '~hydefront/dist/hyde.css';
```

Then, disable the CDN in your `config/hyde.php` file
```php
'loadHydeAssetsUsingCDN' => false,
```

And compile your assets
```bash
npm run dev/prod
```

## Links:
- GitHub https://github.com/hydephp/hydefront
- NPM https://www.npmjs.com/package/hydefront
- jsDelivr https://www.jsdelivr.com/package/npm/hydefront

## Warranty:
HydeFront is not indended to be used for standalone projects and comes with no warranties. Changes in HydeFront are tied to those in the Hyde Framework and differing versions may be incompatible.

## Beta software notice
HydePHP is currently in beta. Please report any bugs and issues in the appropriate issue tracker. Versions in the 0.x series are not stable and may change at any time. No backwards compatibility guarantees are made and breaking changes are <s>possible</s> <i>expected</i>.
1 change: 1 addition & 0 deletions packages/hydefront/dist/app.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions packages/hydefront/dist/hyde.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions packages/hydefront/dist/hyde.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions packages/hydefront/dist/hyde.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions packages/hydefront/dist/hyde.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading