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

Create a scroll back to top button #216

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
13 changes: 13 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Contributor Code of Conduct

The Creative Commons team is committed to fostering a welcoming community. This
project and all other Creative Commons open source projects are governed by our
[Code of Conduct][code_of_conduct]. Please report unacceptable behavior to
[[email protected]](mailto:[email protected]) per our
[reporting guidelines][reporting_guide].

For a history of updates, see the [page history here][updates].

[code_of_conduct]: https://opensource.creativecommons.org/community/code-of-conduct/
[reporting_guide]: https://opensource.creativecommons.org/community/code-of-conduct/enforcement/
[updates]: https://github.com/creativecommons/creativecommons.github.io-source/commits/main/content/community/code-of-conduct/contents.lr
34 changes: 34 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Contributing to CC Open Source

Thank you for your interest in contributing to CC Open Source! This document is
a set of guidelines to help you contribute to this project.


## Code of Conduct

By participating in this project, you are expected to uphold our [Code of
Conduct][code_of_conduct].

[code_of_conduct]: https://opensource.creativecommons.org/community/code-of-conduct/


## Project Documentation

The `README` in the root of the repository should contain or link to project
documentation. If you cannot find the documentation you're looking for, please
file a GitHub issue with details of what you'd like to see documented.


## How to Contribute

Please follow the processes in our general [Contributing Code][contributing]
guidelines on the Creative Common Open Source website.

[contributing]: https://opensource.creativecommons.org/contributing-code/


## Questions or Thoughts?

Talk to us on [one of our community forums][community].

[community]: https://opensource.creativecommons.org/community/
2 changes: 1 addition & 1 deletion dev/jekyll/Dockerfile → Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ RUN gem install bundler
WORKDIR /srv/jekyll

# Install site dependencies
COPY Gemfile Gemfile.lock ./
COPY docs/Gemfile docs/Gemfile.lock ./
RUN bundle install

CMD [ "bundle", "exec", "jekyll", "serve", "--force_polling", \
Expand Down
34 changes: 0 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,27 +12,6 @@ general. The live site is at
[resources.creativecommons.org](https://resources.creativecommons.org/).


## Code of conduct

[`CODE_OF_CONDUCT.md`][org-coc]:
> The Creative Commons team is committed to fostering a welcoming community.
> This project and all other Creative Commons open source projects are governed
> by our [Code of Conduct][code_of_conduct]. Please report unacceptable
> behavior to [[email protected]](mailto:[email protected])
> per our [reporting guidelines][reporting_guide].

[org-coc]: https://github.com/creativecommons/.github/blob/main/CODE_OF_CONDUCT.md
[code_of_conduct]: https://opensource.creativecommons.org/community/code-of-conduct/
[reporting_guide]: https://opensource.creativecommons.org/community/code-of-conduct/enforcement/


## Contributing

See [`CONTRIBUTING.md`][org-contrib].

[org-contrib]: https://github.com/creativecommons/.github/blob/main/CONTRIBUTING.md


## How it works

The website is built using [Jekyll](http://jekyllrb.com/docs/home/), a simple
Expand Down Expand Up @@ -144,19 +123,6 @@ think the latter experience is easier to setup with more consistent behavior.
container and type `CTRL + C`


### Formatting with Prettier

- Format specific HTML file using prettier:
```shell
docker compose run --rm node prettier --write docs/index.html
```
- Format all HTML using prettier:
```shell
find docs -name '*.html' -exec docker compose run --rm node prettier --write {} +
```
- [Prettier · Opinionated Code Formatter](https://prettier.io/)


## License


Expand Down
1 change: 0 additions & 1 deletion dev/jekyll/Gemfile

This file was deleted.

1 change: 0 additions & 1 deletion dev/jekyll/Gemfile.lock

This file was deleted.

6 changes: 0 additions & 6 deletions dev/node/Dockerfile

This file was deleted.

19 changes: 4 additions & 15 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,15 @@
# Use docker compose v2 for non swarm deployments
# https://docs.docker.com/compose/compose-file/compose-file-v2/
version: '2.4'
# https://docs.docker.com/compose/compose-file/compose-file-v3/
version: "3.8"

services:

jekyll:
build: dev/jekyll
build: .
container_name: jekyll-cc-resource-archive
ports:
- '4000:4000'
- "4000:4000"
restart: always
tty: true
volumes:
# https://github.com/docker/for-mac/issues/1592
- ./docs:/srv/jekyll

# Example commands using this service:
# docker compose run node prettier --write docs/index.html
node:
build: dev/node
container_name: node-cc-resource-archive
volumes:
# Mount repository to working directory
- ./:/docs
working_dir: /docs
11 changes: 0 additions & 11 deletions docs/_config.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,3 @@
title: CC Resource Archive

repository: creativecommons/cc-resource-archive

include:
- _resources

defaults:
- scope:
path: '_resources'
type: 'pages'
values:
# make URL of pages in the folder _resources as on the root.
permalink: /:basename/
12 changes: 12 additions & 0 deletions docs/_data/languages.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,24 @@
- name: Arabic
string: ar

- name: Mandarin
string: cmn

- name: German
string: de

- name: English
string: en

- name: Spanish
string: es

- name: French
string: fr

- name: Hindi
string: hi

- name: Armenian
string: hy

Expand Down Expand Up @@ -42,3 +51,6 @@

- name: Tagalog
string: tl

- name: Urdu
string: ur
120 changes: 38 additions & 82 deletions docs/_includes/header.html
Original file line number Diff line number Diff line change
@@ -1,86 +1,42 @@
<header>
<div class="masthead">
<h1><a class="identity-logo product" href="/">Resource Archive</a></h1>

<nav class="ancilliary-menu">
<ul>
<!-- uncomment below line, if translation functionality is present on site -->
<!-- <li><button class="locale icon-attach fa-globe">English</button></li> -->
<!-- uncomment below line, if search functionality is present on site -->
<!-- <li><a class="search icon-attach fa-search" href="#">Search</a></li> -->
<li>
<a
class="donate icon-attach fa-heart"
href="https://www.classy.org/give/313412/#!/donation/checkout?c_src=website&c_src2=top-of-page-banner"
target="_blank"
>Donate</a
>
</li>
<li><button class="explore">Explore CC</button></li>
</ul>
</nav>
</div>
<div class="explore-panel">
<!-- (optional main CC logo, p, link on non-home site back to main site) -->
<aside>
<a class="identity-logo" href="https://www.creativecommons.org"
>Creative Commons</a
>
<h2>Our Work Relies On You!</h2>
<p>Help us keep the internet free and open.</p>
</aside>
<!-- CC Global Header -->

<nav class="explore-menu">
<ul>
<li>
<a
id="global-header-link"
href="https://network.creativecommons.org/"
target="_blank"
>Global Network</a
>
<p>Join a global community working to strengthen the Commons</p>
</li>
<li>
<a
id="global-header-link"
href="https://certificate.creativecommons.org/"
target="_blank"
>Certificate</a
>
<p>
Become an expert in creating and engaging with openly licensed
materials
</p>
</li>
<li>
<a href="https://summit.creativecommons.org/" target="_blank"
>Global Summit</a
>
<p>Attend our annual event, promoting the power of open licensing</p>
</li>
<li>
<a href="https://chooser-beta.creativecommons.org/" target="_blank"
>Chooser</a
>
<p>Get help choosing the appropriate license for your work</p>
</li>
<li>
<a href="https://search.creativecommons.org/" target="_blank"></a>
<p>
Find engines to search openly licensed material for creative and
educational reuse
</p>
</li>
<li>
<a href="https://opensource.creativecommons.org/" target="_blank"
>Open Source</a
>
<p>Help us build products that maximize creativity and innovation</p>
</li>
</ul>
</nav>
</div>
</header>
<div class="global-header" id="global-header">
<a id="global-header-btn" onclick="handleExplore()">Explore CC</a>
<div class="container">
<a href="https://www.creativecommons.org"><img id="cc-main" src="../images/assets/cc-main.svg" alt="Creative Commons"></a>
<div id="global-header-content">
<div id="global-header-head">
<h3>OUR WORK RELIES ON YOU!</h3>
<p>Help us keep the internet free and open.</p>
<a href="https://www.classy.org/give/313412/#!/donation/checkout" id="global-header-donate" target="_blank" rel="noopener noreferrer"><img id="cc-heart" src="../images/assets/ccheart_black.svg" alt="cc-heart"> DONATE NOW</a>
</div>
<div id="global-header-list">
<a id="global-header-link" href="https://network.creativecommons.org/" target="_blank" rel="noopener noreferrer"><span id="global-header-title">Global Network</span><br>
<p>Join a global community working to strengthen the Commons</p>
</a>
<a id="global-header-link" href="https://certificate.creativecommons.org/" target="_blank" rel="noopener noreferrer"><span id="global-header-title">Certificate program</span><br>
<p>Become an expert in creating and engaging with openly licensed materials</p>
</a>
<a id="global-header-link" href="https://summit.creativecommons.org/" target="_blank" rel="noopener noreferrer"><span id="global-header-title">Global Summit</span><br>
<p>Attend our annual event, promoting the power of open licensing</p>
</a>
<a id="global-header-link" href="https://chooser-beta.creativecommons.org/" target="_blank" rel="noopener noreferrer"><span id="global-header-title">License Chooser</span><br>
<p>Get help choosing the appropriate license for your work</p>
</a>
<a id="global-header-link" href="https://search.creativecommons.org/" target="_blank" rel="noopener noreferrer"><span id="global-header-title">CC Search</span><br>
<p>Find openly licensed material for creative and educational reuse</p>
</a>
<a id="global-header-link" href="https://opensource.creativecommons.org/" target="_blank" rel="noopener noreferrer"><span id="global-header-title">CC Open Source</span><br>
<p>Help us build products that maximize creativity and innovation</p>
</a>
</div>
</div>
</div>
</div>

<!-- Main Content -->

<a href="//creativecommons.org/">
<div id="bannercc"></div>
</a>
Loading