Skip to content

Commit

Permalink
Add dashicons pack
Browse files Browse the repository at this point in the history
  • Loading branch information
aalmiray committed Dec 13, 2017
1 parent cfaa24f commit 5b67994
Show file tree
Hide file tree
Showing 17 changed files with 1,482 additions and 3 deletions.
1 change: 1 addition & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ javadocFooter=Copyright © 2015-2017 Andres Almiray. All rights reserved.
jipsyVersion = 0.4.1
jacocoVersion = 0.7.9
deviconsVersion = 1.8.0
dashiconsVersion = 20171213
elusiveVersion = 2.0
featherVersion = 1.1
fontawesomeVersion = 4.7.0
Expand Down
10 changes: 7 additions & 3 deletions subprojects/guide/guide.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ ext.childProjects = [
':ikonli-core',
':ikonli-javafx',
':ikonli-swing',
':ikonli-dashicons-pack',
':ikonli-devicons-pack',
':ikonli-elusive-pack',
':ikonli-feather-pack',
Expand Down Expand Up @@ -155,13 +156,13 @@ class GenerateIconCheatSheetTask extends DefaultTask {
def iconFontClass = gcl.loadClass(iconClassName, true)

int index = 1
String document = """
The following table shows all available icons. ${packName}
String document = '''
The following table shows all available icons.
[columns="1,3,2,^", options="header"]
|===
| Index | Enum | Name | Icon
""".stripIndent(8)
'''.stripIndent(8)

iconFontClass.values().each { font ->
document += "| ${index++} "
Expand Down Expand Up @@ -206,6 +207,7 @@ def createIconGenerationTask(Map args) {

asciidoctor {
dependsOn createIconGenerationTask(packName: 'devicons', iconClassName: 'org.kordamp.ikonli.devicons.Devicons'),
createIconGenerationTask(packName: 'dashicons', iconClassName: 'org.kordamp.ikonli.dashicons.Dashicons', iconName: 'dashicons', shortNameSize: 10),
createIconGenerationTask(packName: 'elusive', iconClassName: 'org.kordamp.ikonli.elusive.Elusive', iconName: 'el-icon', shortNameSize: 4),
createIconGenerationTask(packName: 'feather', iconClassName: 'org.kordamp.ikonli.feather.Feather', iconName: 'fth', shortNameSize: 4),
createIconGenerationTask(packName: 'fontawesome', iconClassName: 'org.kordamp.ikonli.fontawesome.FontAwesome', iconName: 'fa'),
Expand Down Expand Up @@ -250,6 +252,7 @@ asciidoctor {
'project-vcs' : project.project_scm,
'project-issue-tracker': project.project_issues,
'project-group' : project.group,
dashiconsVersion : project.dashiconsVersion,
deviconsVersion : project.deviconsVersion,
elusiveVersion : project.elusiveVersion,
featherVersion : project.featherVersion,
Expand Down Expand Up @@ -277,6 +280,7 @@ asciidoctor {
}*/
resources {
from file('src/resources')
from project(':ikonli-dashicons-pack').file("src/main/resources/META-INF/resources/dashicons/${dashiconsVersion}")
from project(':ikonli-devicons-pack').file("src/main/resources/META-INF/resources/devicons/${deviconsVersion}")
from project(':ikonli-elusive-pack').file("src/main/resources/META-INF/resources/elusive/${elusiveVersion}")
from project(':ikonli-feather-pack').file("src/main/resources/META-INF/resources/feather/${featherVersion}")
Expand Down
13 changes: 13 additions & 0 deletions subprojects/guide/src/asciidoc/cheat-sheet-dashicons.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
= Dashicons

++++
<link href='./css/dashicons.css' rel='stylesheet'>
<style>
.dashicons {
font-size: 32px;
}
</style>
++++

include::{projectDir}/build/tmp/_dashicons_cheat_sheet.adoc[]

25 changes: 25 additions & 0 deletions subprojects/guide/src/asciidoc/icon-packs.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,31 @@
[[_cheat_sheets]]
= Icon Packs

== DashIcons
* Font version: {dashiconsVersion}
* https://github.com/WordPress/dashicons[]
* link:cheat-sheet-dashicons.html[Cheat-Sheet]

=== Installing

[source,groovy]
[subs="attributes"]
.gradle
----
compile '{project-group}:ikonli-dashicons-pack:{project-version}'
----

[source,xml]
[subs="attributes,verbatim"]
.maven
----
<dependency>
<groupId>{project-group}</groupId>
<artifactId>ikonli-dashicons-pack</artifactId>
<version>{project-version}</version>
</dependency>
----

== DevIcons
* Font version: {deviconsVersion}
* link:http://vorillaz.github.io/devicons/[]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dependencies {
compile project(':ikonli-core')
compileOnly "org.kordamp.jipsy:jipsy:${jipsyVersion}"
}
Loading

0 comments on commit 5b67994

Please sign in to comment.