Skip to content

Commit

Permalink
initial commit for v2
Browse files Browse the repository at this point in the history
  • Loading branch information
halfmage committed Apr 5, 2021
1 parent 66aad53 commit 4417a83
Show file tree
Hide file tree
Showing 869 changed files with 484 additions and 492 deletions.
21 changes: 21 additions & 0 deletions _data/iconsNew.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
const fg = require("fast-glob");
const path = require("path");
const fs = require("fs");

module.exports = function () {
return new Promise(async (resolve, reject) => {
const iconFolder = path.resolve(__dirname, "../icons/");
const svgIcons = await fg("**/*.svg", { cwd: iconFolder });
const iconData = await Promise.all(
svgIcons.map(async (name) => {
const nameWithoutExtension = path.parse(name).name;
const source = fs.readFileSync(path.resolve(iconFolder, name), {
encoding: "utf8",
});
const sourceWithClass = source.replace("<svg", '<svg class="icon"');
return { name, source, sourceWithClass, nameWithoutExtension };
})
);
resolve(iconData);
});
};
6 changes: 3 additions & 3 deletions _includes/header.njk
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div
class="bg-gradient-to-r from-primary-200 to-primary-400 dark:from-primary-800 dark:to-primary-900 md:py-16 md:pb-24 py-8 pb-16 text-center md:text-left"
class="bg-gradient-to-r from-primary-200 to-primary-400 dark:from-primary-800 dark:to-primary-900 py-8 text-center md:text-left mb-4"
>
<div class="container mx-auto px-4 md:flex justify-between">
<div class="flex flex-col md:pr-16">
Expand All @@ -11,10 +11,10 @@
</p>
<p class="text-primary-700 dark:text-primary-300">
<a class="inline-flex items-center mr-6 hover:underline" href="https://github.com/halfmage/majesticons/blob/main/LICENSE" target="_blank">
{{ "/icons/line/thumb-up.svg" | svgContents("mr-2 w-6 h-6") | safe }} MIT Licensed
MIT Licensed
</a>
<a class="inline-flex items-center hover:underline" href="https://github.com/halfmage/majesticons#readme" target="_blank">
{{ "/icons/line/book-open.svg" | svgContents("mr-2 w-6 h-6") | safe }} Readme
Readme
</a>
</p>
</div>
Expand Down
1 change: 1 addition & 0 deletions icons/book-attachment.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-block.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-bookmark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-chat.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-check-check.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-clock.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-cloud.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-code.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-cursor.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-download-download.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-edit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-flash.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-image.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-link-link.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-lock.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-minus-minus.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-music.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-attachment.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-block.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-bookmark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-chat.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-check-check.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-clock.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-cloud.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-code.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions icons/book-open-cursor.svg
1 change: 1 addition & 0 deletions icons/book-open-download-download.svg
1 change: 1 addition & 0 deletions icons/book-open-edit.svg
1 change: 1 addition & 0 deletions icons/book-open-flash.svg
1 change: 1 addition & 0 deletions icons/book-open-image.svg
1 change: 1 addition & 0 deletions icons/book-open-link-link.svg
1 change: 1 addition & 0 deletions icons/book-open-lock.svg
1 change: 1 addition & 0 deletions icons/book-open-minus-minus.svg
1 change: 1 addition & 0 deletions icons/book-open-multi.svg
1 change: 1 addition & 0 deletions icons/book-open-music.svg
1 change: 1 addition & 0 deletions icons/book-open-open-open.svg
1 change: 1 addition & 0 deletions icons/book-open-open.svg
1 change: 1 addition & 0 deletions icons/book-open-pin.svg
1 change: 1 addition & 0 deletions icons/book-open-plus-plus.svg
1 change: 1 addition & 0 deletions icons/book-open-print-print.svg
1 change: 1 addition & 0 deletions icons/book-open-reply.svg
1 change: 1 addition & 0 deletions icons/book-open-save.svg
1 change: 1 addition & 0 deletions icons/book-open-search-search.svg
1 change: 1 addition & 0 deletions icons/book-open-settings.svg
1 change: 1 addition & 0 deletions icons/book-open-share-share.svg
1 change: 1 addition & 0 deletions icons/book-open-show.svg
1 change: 1 addition & 0 deletions icons/book-open-stack.svg
1 change: 1 addition & 0 deletions icons/book-open-swap.svg
Loading

0 comments on commit 4417a83

Please sign in to comment.