arbo 1.2.0 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yaml +6 -2
- data/.github/workflows/daily.yaml +7 -3
- data/.github/workflows/pages.yml +69 -0
- data/.gitignore +1 -0
- data/CHANGELOG.md +8 -1
- data/docs/Gemfile +6 -1
- data/docs/_config.yml +7 -4
- data/docs/_includes/nav_footer_custom.html +3 -0
- data/docs/index.md +16 -3
- data/lib/arbo/html/tag.rb +1 -1
- data/lib/arbo/version.rb +1 -1
- metadata +4 -9
- data/docs/_includes/footer.html +0 -8
- data/docs/_includes/google-analytics.html +0 -16
- data/docs/_includes/head.html +0 -7
- data/docs/_includes/toc.html +0 -12
- data/docs/_includes/top-menu.html +0 -8
- data/docs/_layouts/default.html +0 -21
- data/docs/stylesheets/main.css +0 -1152
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c9c0a3eb2a4490fa5d3b138183059102e6d1a15c7847ef5edb04e63e8e1d6fbe
|
4
|
+
data.tar.gz: 17a4bde22b028a37aa8965414e3d0817b746bcc8b2013721094797579248e40b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 93a735d6096c6ba7665e4c6b201ee155d1abae7faf4f5d135dc90ad725800669be7780894a4ce050444989720afe835e6af317dd84d09a8c25fb7891a926288d
|
7
|
+
data.tar.gz: f29cc81e17e22569d4c1030b8dd0e628ed14c52e5aca7d56bf30fbbaa8941938be3e13e957466227f68e2112a02c92d733cad6dc01002ccba0c592d7a8e15f21
|
data/.github/workflows/ci.yaml
CHANGED
@@ -9,12 +9,16 @@ jobs:
|
|
9
9
|
name: test
|
10
10
|
runs-on: ubuntu-latest
|
11
11
|
|
12
|
+
strategy:
|
13
|
+
matrix:
|
14
|
+
ruby: [{ name: 3.2, value: 3.2.2 }, { name: 3.0, value: 3.0.1 }]
|
15
|
+
|
12
16
|
steps:
|
13
|
-
- uses: actions/checkout@
|
17
|
+
- uses: actions/checkout@v4
|
14
18
|
|
15
19
|
- uses: ruby/setup-ruby@v1
|
16
20
|
with:
|
17
|
-
ruby-version:
|
21
|
+
ruby-version: ${{ matrix.ruby.value }}
|
18
22
|
bundler-cache: true
|
19
23
|
|
20
24
|
- name: Run tests
|
@@ -1,6 +1,6 @@
|
|
1
1
|
---
|
2
2
|
|
3
|
-
name:
|
3
|
+
name: daily
|
4
4
|
|
5
5
|
on:
|
6
6
|
schedule:
|
@@ -11,12 +11,16 @@ jobs:
|
|
11
11
|
name: test
|
12
12
|
runs-on: ubuntu-latest
|
13
13
|
|
14
|
+
strategy:
|
15
|
+
matrix:
|
16
|
+
ruby: [{ name: 3.2, value: 3.2.2 }, { name: 3.0, value: 3.0.1 }]
|
17
|
+
|
14
18
|
steps:
|
15
|
-
- uses: actions/checkout@
|
19
|
+
- uses: actions/checkout@v4
|
16
20
|
|
17
21
|
- uses: ruby/setup-ruby@v1
|
18
22
|
with:
|
19
|
-
ruby-version:
|
23
|
+
ruby-version: ${{ matrix.ruby.value }}
|
20
24
|
bundler-cache: true
|
21
25
|
|
22
26
|
- name: Run tests
|
@@ -0,0 +1,69 @@
|
|
1
|
+
# This workflow uses actions that are not certified by GitHub.
|
2
|
+
# They are provided by a third-party and are governed by
|
3
|
+
# separate terms of service, privacy policy, and support
|
4
|
+
# documentation.
|
5
|
+
|
6
|
+
# Sample workflow for building and deploying a Jekyll site to GitHub Pages
|
7
|
+
name: Deploy Jekyll site to Pages
|
8
|
+
|
9
|
+
on:
|
10
|
+
push:
|
11
|
+
branches: ["main"]
|
12
|
+
paths:
|
13
|
+
- "docs/**"
|
14
|
+
|
15
|
+
# Allows you to run this workflow manually from the Actions tab
|
16
|
+
workflow_dispatch:
|
17
|
+
|
18
|
+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
|
19
|
+
permissions:
|
20
|
+
contents: read
|
21
|
+
pages: write
|
22
|
+
id-token: write
|
23
|
+
|
24
|
+
# Allow one concurrent deployment
|
25
|
+
concurrency:
|
26
|
+
group: "pages"
|
27
|
+
cancel-in-progress: true
|
28
|
+
|
29
|
+
jobs:
|
30
|
+
# Build job
|
31
|
+
build:
|
32
|
+
runs-on: ubuntu-latest
|
33
|
+
defaults:
|
34
|
+
run:
|
35
|
+
working-directory: docs
|
36
|
+
steps:
|
37
|
+
- name: Checkout
|
38
|
+
uses: actions/checkout@v3
|
39
|
+
- name: Setup Ruby
|
40
|
+
uses: ruby/setup-ruby@v1
|
41
|
+
with:
|
42
|
+
ruby-version: '3.1' # Not needed with a .ruby-version file
|
43
|
+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
|
44
|
+
cache-version: 0 # Increment this number if you need to re-download cached gems
|
45
|
+
working-directory: '${{ github.workspace }}/docs'
|
46
|
+
- name: Setup Pages
|
47
|
+
id: pages
|
48
|
+
uses: actions/configure-pages@v3
|
49
|
+
- name: Build with Jekyll
|
50
|
+
# Outputs to the './_site' directory by default
|
51
|
+
run: bundle exec jekyll build --baseurl "${{ steps.pages.outputs.base_path }}"
|
52
|
+
env:
|
53
|
+
JEKYLL_ENV: production
|
54
|
+
- name: Upload artifact
|
55
|
+
# Automatically uploads an artifact from the './_site' directory by default
|
56
|
+
uses: actions/upload-pages-artifact@v1
|
57
|
+
with:
|
58
|
+
path: "docs/_site/"
|
59
|
+
# Deployment job
|
60
|
+
deploy:
|
61
|
+
environment:
|
62
|
+
name: github-pages
|
63
|
+
url: ${{ steps.deployment.outputs.page_url }}
|
64
|
+
runs-on: ubuntu-latest
|
65
|
+
needs: build
|
66
|
+
steps:
|
67
|
+
- name: Deploy to GitHub Pages
|
68
|
+
id: deployment
|
69
|
+
uses: actions/deploy-pages@v2
|
data/.gitignore
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,11 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
-
## 1.
|
3
|
+
## 1.3.0 [☰](https://github.com/varyonic/arbo/compare/v1.2.0...v1.3.0)
|
4
|
+
|
5
|
+
* Support Rails 7.1. [#3] by [@varyonic]
|
6
|
+
* Update documentation including fresh theme. [#4] by [@varyonic]
|
7
|
+
|
8
|
+
## 1.2.0 [☰](https://github.com/varyonic/arbo/compare/v1.1.1...v1.2.0)
|
4
9
|
|
5
10
|
* Fix rendering `link_to` with a block in a arbre template. [#64][] by [@varyonic][]
|
6
11
|
* Fix deprecation warning about single arity template handlers on Rails 6. [#110][] by [@aramvisser][]
|
@@ -78,6 +83,8 @@ Initial release and extraction from Active Admin
|
|
78
83
|
|
79
84
|
[#1]: https://github.com/varyonic/arbo/pull/1
|
80
85
|
[#2]: https://github.com/varyonic/arbo/pull/2
|
86
|
+
[#3]: https://github.com/varyonic/arbo/pull/3
|
87
|
+
[#4]: https://github.com/varyonic/arbo/pull/4
|
81
88
|
|
82
89
|
[@aramvisser]: https://github.com/aramvisser
|
83
90
|
[@deivid-rodriguez]: https://github.com/deivid-rodriguez
|
data/docs/Gemfile
CHANGED
data/docs/_config.yml
CHANGED
@@ -1,7 +1,10 @@
|
|
1
1
|
plugins:
|
2
|
+
- jekyll-default-layout
|
2
3
|
- jekyll-redirect-from
|
3
4
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
5
|
+
theme: just-the-docs
|
6
|
+
title: Arbo | HTML Views in Ruby
|
7
|
+
# Aux links for the upper right navigation
|
8
|
+
aux_links:
|
9
|
+
"Get the Code":
|
10
|
+
- "//github.com/varyonic/arbo"
|
data/docs/index.md
CHANGED
@@ -4,6 +4,19 @@ redirect_from: /docs/documentation.html
|
|
4
4
|
# Arbo
|
5
5
|
HTML Views in Ruby
|
6
6
|
|
7
|
+
{: .no_toc }
|
8
|
+
|
9
|
+
<details open markdown="block">
|
10
|
+
<summary>
|
11
|
+
Table of contents
|
12
|
+
</summary>
|
13
|
+
{: .text-delta }
|
14
|
+
- TOC
|
15
|
+
{:toc}
|
16
|
+
</details>
|
17
|
+
|
18
|
+
---
|
19
|
+
|
7
20
|
### Introduction
|
8
21
|
|
9
22
|
Arbo is a alternate template system for [Ruby on Rails Action View](http://guides.rubyonrails.org/action_view_overview.html).
|
@@ -72,17 +85,17 @@ Several examples of Arbo components are [included in Active Admin](https://activ
|
|
72
85
|
|
73
86
|
### Contexts
|
74
87
|
|
75
|
-
An [Arbo::Context](http://www.rubydoc.info/gems/arbo/Arbo/Context) is an object in which Arbo DSL is interpreted, providing a root for the Ruby DOM that can be [searched and manipulated](http://www.rubydoc.info/gems/arbo/Arbo/Element). A context is automatically provided when a `.arb` template or partial is loaded. Contexts can be used when developing or testing a component. Contexts are rendered by calling
|
88
|
+
An [Arbo::Context](http://www.rubydoc.info/gems/arbo/Arbo/Context) is an object in which Arbo DSL is interpreted, providing a root for the Ruby DOM that can be [searched and manipulated](http://www.rubydoc.info/gems/arbo/Arbo/Element). A context is automatically provided when a `.arb` template or partial is loaded. Contexts can be used when developing or testing a component. Contexts are rendered by calling render_in.
|
76
89
|
|
77
90
|
```ruby
|
78
91
|
html = Arbo::Context.new do
|
79
|
-
|
92
|
+
div "Hello World", id: "my-panel" do
|
80
93
|
span "Inside the panel"
|
81
94
|
text_node "Plain text"
|
82
95
|
end
|
83
96
|
end
|
84
97
|
|
85
|
-
puts html.
|
98
|
+
puts html.render_in # =>
|
86
99
|
```
|
87
100
|
|
88
101
|
```html
|
data/lib/arbo/html/tag.rb
CHANGED
data/lib/arbo/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: arbo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Piers Chambers
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-10-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -47,6 +47,7 @@ extra_rdoc_files: []
|
|
47
47
|
files:
|
48
48
|
- ".github/workflows/ci.yaml"
|
49
49
|
- ".github/workflows/daily.yaml"
|
50
|
+
- ".github/workflows/pages.yml"
|
50
51
|
- ".gitignore"
|
51
52
|
- CHANGELOG.md
|
52
53
|
- CONTRIBUTING.md
|
@@ -57,14 +58,8 @@ files:
|
|
57
58
|
- arbo.gemspec
|
58
59
|
- docs/Gemfile
|
59
60
|
- docs/_config.yml
|
60
|
-
- docs/_includes/
|
61
|
-
- docs/_includes/google-analytics.html
|
62
|
-
- docs/_includes/head.html
|
63
|
-
- docs/_includes/toc.html
|
64
|
-
- docs/_includes/top-menu.html
|
65
|
-
- docs/_layouts/default.html
|
61
|
+
- docs/_includes/nav_footer_custom.html
|
66
62
|
- docs/index.md
|
67
|
-
- docs/stylesheets/main.css
|
68
63
|
- lib/arbo.rb
|
69
64
|
- lib/arbo/component.rb
|
70
65
|
- lib/arbo/context.rb
|
data/docs/_includes/footer.html
DELETED
@@ -1,8 +0,0 @@
|
|
1
|
-
<p id="footer">
|
2
|
-
<div class="left">
|
3
|
-
Copyright 2011 <a href="http://gregbell.ca/">Greg Bell</a> and <a href="http://www.versapay.com/">VersaPay</a>
|
4
|
-
</div>
|
5
|
-
<div class="right">
|
6
|
-
<a href="http://twitter.com/share" class="twitter-share-button">Tweet</a></p>
|
7
|
-
</div>
|
8
|
-
</p>
|
@@ -1,16 +0,0 @@
|
|
1
|
-
<script type="text/javascript">
|
2
|
-
|
3
|
-
var _gaq = _gaq || [];
|
4
|
-
_gaq.push(['_setAccount', 'UA-23306458-1']);
|
5
|
-
_gaq.push(['_trackPageview']);
|
6
|
-
|
7
|
-
(function () {
|
8
|
-
var ga = document.createElement('script');
|
9
|
-
ga.type = 'text/javascript';
|
10
|
-
ga.async = true;
|
11
|
-
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
|
12
|
-
var s = document.getElementsByTagName('script')[0];
|
13
|
-
s.parentNode.insertBefore(ga, s);
|
14
|
-
})();
|
15
|
-
|
16
|
-
</script>
|
data/docs/_includes/head.html
DELETED
@@ -1,7 +0,0 @@
|
|
1
|
-
<head>
|
2
|
-
<title>Arbo | HTML Views in Ruby</title>
|
3
|
-
<link href='//fonts.googleapis.com/css?family=Yanone+Kaffeesatz:extralight,light,regular,bold' rel='stylesheet' type='text/css'>
|
4
|
-
<link href='//fonts.googleapis.com/css?family=Droid+Sans+Mono' rel='stylesheet' type='text/css'>
|
5
|
-
<link href="{{ site.baseurl }}/stylesheets/main.css" media="screen" rel="stylesheet" type="text/css" />
|
6
|
-
<script src="//platform.twitter.com/widgets.js" type="text/javascript"></script>
|
7
|
-
</head>
|
data/docs/_includes/toc.html
DELETED
@@ -1,12 +0,0 @@
|
|
1
|
-
<ol class='level-1'>
|
2
|
-
<li><a href='{{ site.baseurl }}'>Contents</a></li>
|
3
|
-
<ol class='level-2'>
|
4
|
-
<li><a href='{{ site.baseurl }}#introduction'>Introduction</a></li>
|
5
|
-
<li><a href='{{ site.baseurl }}#installation'>Installation</a></li>
|
6
|
-
<li><a href='{{ site.baseurl }}#tags'>Tags</a></li>
|
7
|
-
<li><a href='{{ site.baseurl }}#componenets'>Components</a></li>
|
8
|
-
<li><a href='{{ site.baseurl }}#contexts'>Contexts</a></li>
|
9
|
-
<!-- li><a href='{{ site.baseurl }}/documentation.html#layouts'>Layouts</a></li -->
|
10
|
-
<li><a href='{{ site.baseurl }}#background'>Background</a></li>
|
11
|
-
</ol>
|
12
|
-
</ol>
|
data/docs/_layouts/default.html
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
<!DOCTYPE html>
|
2
|
-
<html lang="en">
|
3
|
-
{% include head.html %}
|
4
|
-
<body class="with-sidebar">
|
5
|
-
<div id="wrapper">
|
6
|
-
{% include top-menu.html %}
|
7
|
-
<div id="main-content">
|
8
|
-
<div class='toc'>
|
9
|
-
{% include toc.html %}
|
10
|
-
</div>
|
11
|
-
<div class='toc-content'>
|
12
|
-
<div class='docs-content'>
|
13
|
-
{{ content }}
|
14
|
-
</div>
|
15
|
-
</div>
|
16
|
-
</div>
|
17
|
-
{% include footer.html %}
|
18
|
-
</div>
|
19
|
-
{% include google-analytics.html %}
|
20
|
-
</body>
|
21
|
-
</html>
|