Skip to content

Commit

Permalink
New Icon Set: DesignSafe-Icons (#1212)
Browse files Browse the repository at this point in the history
* add DesignSafe-Icons font-family; update icon names in AppListingEntry model

* change ".icon" base class to ".ds-icon"

* change ".icon-" classname to ".ds-icon-"
  • Loading branch information
rstijerina authored Apr 22, 2024
1 parent 1e05856 commit d168f1d
Show file tree
Hide file tree
Showing 10 changed files with 249 additions and 19 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Generated by Django 4.2.11 on 2024-04-19 21:49

from django.db import migrations, models


class Migration(migrations.Migration):
dependencies = [
("workspace", "0008_appvariantsplugin"),
]

operations = [
migrations.AlterField(
model_name="applistingentry",
name="icon",
field=models.CharField(
blank=True,
choices=[
("Generic-App", "Generic: Application"),
("Generic-Vis", "Generic: Visualization"),
("Earth", "Element: Earth"),
("Water", "Element: Water"),
("Wind", "Element: Wind"),
("All-Hazards", "All Hazards"),
("adcirc", "ADCIRC"),
("Ansys", "Ansys"),
("Blender", "Blender"),
("Clawpack", "Clawpack"),
("Compress", "Compress"),
("Dakota", "Dakota"),
("Extract", "Extract"),
("GiD", "GiD"),
("Hazmapper", "Hazmapper"),
("HVSR", "HVSR"),
("Jupyter", "Jupyter"),
("LS-DYNA", "LS-DYNA"),
("MATLAB", "MATLAB"),
("MPM", "MPM"),
("NGL-without-text", "NGL"),
("OpenFOAM", "OpenFOAM"),
("OpenSees", "OpenSees"),
("Paraview", "Paraview"),
("Potree", "Potree"),
("QGIS", "QGIS"),
("rWHALE", "rWHALE"),
("STKO", "STKO"),
("SWBatch", "SWBatch"),
],
help_text="The icon associated with this app.",
max_length=64,
),
),
]
47 changes: 28 additions & 19 deletions designsafe/apps/workspace/models/app_entries.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,35 @@
from django.db import models

APP_ICONS = [
("Generic-App", "Generic: Application"),
("Generic-Vis", "Generic: Visualization"),
("Earth", "Element: Earth"),
("Water", "Element: Water"),
("Wind", "Element: Wind"),
("All-Hazards", "All Hazards"),
("adcirc", "ADCIRC"),
("ansys", "Ansys"),
("blender", "Blender"),
("clawpack", "Clawpack"),
("compress", "Compress"),
("dakota", "Dakota"),
("extract", "Extract"),
("hazmapper", "Hazmapper"),
("jupyter", "Jupyter"),
("ls-dyna", "LS-DYNA"),
("matlab", "MATLAB"),
("ngl", "NGL"),
("openfoam", "OpenFOAM"),
("opensees", "OpenSees"),
("paraview", "Paraview"),
("qgis", "QGIS"),
("rwhale", "rWHALE"),
("stko", "STKO"),
("swbatch", "swbatch"),
("visit", "VisIt"),
("Ansys", "Ansys"),
("Blender", "Blender"),
("Clawpack", "Clawpack"),
("Compress", "Compress"),
("Dakota", "Dakota"),
("Extract", "Extract"),
("GiD", "GiD"),
("Hazmapper", "Hazmapper"),
("HVSR", "HVSR"),
("Jupyter", "Jupyter"),
("LS-DYNA", "LS-DYNA"),
("MATLAB", "MATLAB"),
("MPM", "MPM"),
("NGL-without-text", "NGL"),
("OpenFOAM", "OpenFOAM"),
("OpenSees", "OpenSees"),
("Paraview", "Paraview"),
("Potree", "Potree"),
("QGIS", "QGIS"),
("rWHALE", "rWHALE"),
("STKO", "STKO"),
("SWBatch", "SWBatch"),
]

LICENSE_TYPES = [("OS", "Open Source"), ("LS", "Licensed")]
Expand Down
Binary file added designsafe/static/fonts/DesignSafe-Icons.eot
Binary file not shown.
42 changes: 42 additions & 0 deletions designsafe/static/fonts/DesignSafe-Icons.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added designsafe/static/fonts/DesignSafe-Icons.ttf
Binary file not shown.
Binary file added designsafe/static/fonts/DesignSafe-Icons.woff
Binary file not shown.
Binary file added designsafe/static/fonts/DesignSafe-Icons.woff2
Binary file not shown.
125 changes: 125 additions & 0 deletions designsafe/static/styles/DesignSafe-Icons.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
@font-face {
font-family: 'DesignSafe-Icons';
src: url('/static/fonts/DesignSafe-Icons.eot?nvbv6c');
src: url('/static/fonts/DesignSafe-Icons.eot?nvbv6c#iefix') format('embedded-opentype'),
url('/static/fonts/DesignSafe-Icons.ttf?nvbv6c') format('truetype'),
url('/static/fonts/DesignSafe-Icons.woff2') format('woff2'),
url('/static/fonts/DesignSafe-Icons.woff?nvbv6c') format('woff'),
url('/static/fonts/DesignSafe-Icons.svg?nvbv6c#DesignSafe-Icons') format('svg');
font-weight: normal;
font-style: normal;
font-display: block;
}

[class^='ds-icon-'],
[class*=' ds-icon-'] {
/* use !important to prevent issues with browser extensions that change fonts */
font-family: 'DesignSafe-Icons' !important;
speak: never;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;

/* Better Font Rendering =========== */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}

.ds-icon-Contract:before {
content: '\e91d';
}
.ds-icon-Expand:before {
content: '\e923';
}
.ds-icon-Job-Status:before {
content: '\e929';
}
.ds-icon-All-Hazards:before {
content: '\e908';
}
.ds-icon-New-Tab:before {
content: '\ea7e';
}
.ds-icon-NGL-without-text:before {
content: '\e903';
}
.ds-icon-Potree:before {
content: '\e906';
}
.ds-icon-Generic-Vis:before {
content: '\e907';
}
.ds-icon-HVSR:before {
content: '\e90d';
}
.ds-icon-MPM:before {
content: '\e90e';
}
.ds-icon-Generic-App:before {
content: '\e960';
}
.ds-icon-GiD:before {
content: '\e90f';
}
.ds-icon-Earth:before {
content: '\e910';
}
.ds-icon-Water:before {
content: '\e912';
}
.ds-icon-Wind:before {
content: '\e915';
}
.ds-icon-rWHALE:before {
content: '\e905';
}
.ds-icon-Extract:before {
content: '\e959';
}
.ds-icon-Hazmapper:before {
content: '\e904';
}
.ds-icon-Compress:before {
content: '\e958';
}
.ds-icon-STKO:before {
content: '\e91c';
}
.ds-icon-OpenFOAM:before {
content: '\e900';
}
.ds-icon-Blender:before {
content: '\e901';
}
.ds-icon-MATLAB:before {
content: '\e902';
}
.ds-icon-Paraview:before {
content: '\e911';
}
.ds-icon-Jupyter:before {
content: '\e913';
}
.ds-icon-QGIS:before {
content: '\e914';
}
.ds-icon-OpenSees:before {
content: '\e916';
}
.ds-icon-LS-DYNA:before {
content: '\e917';
}
.ds-icon-Dakota:before {
content: '\e918';
}
.ds-icon-Clawpack:before {
content: '\e919';
}
.ds-icon-Ansys:before {
content: '\e91a';
}
.ds-icon-SWBatch:before {
content: '\e91b';
}
1 change: 1 addition & 0 deletions designsafe/templates/base.j2
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
<link href="{% static 'vendor/angular-material/angular-material.css' %}" rel="stylesheet">
<link href="{% static 'styles/ng-designsafe.css' %}" rel="stylesheet">
<link href="{% static 'styles/app-card.css' %}" rel="stylesheet" type="text/css">
<link href="{% static 'styles/DesignSafe-Icons.css' %}" rel="stylesheet" type="text/css">
{% block styles %}{% endblock %}
{% render_block "css" %}
<base href="/">
Expand Down
1 change: 1 addition & 0 deletions designsafe/templates/cms_homepage.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
<link href="{% static 'styles/base.css' %}" rel="stylesheet" type="text/css">
<link href="{% static 'vendor/angular-material/angular-material.css' %}" rel="stylesheet">
<link href="{% static 'styles/ng-designsafe.css' %}" rel="stylesheet">
<link href="{% static 'styles/DesignSafe-Icons.css' %}" rel="stylesheet" type="text/css">
{% render_block "css" %}
</head>
<body>
Expand Down

0 comments on commit d168f1d

Please sign in to comment.