further refactoring with TechnologyTile component. More refinements to styling and layout
This commit is contained in:
parent
ef93b55b19
commit
01d648eb46
4 changed files with 91 additions and 84 deletions
|
@ -20,4 +20,8 @@ h1 {
|
|||
}
|
||||
a {
|
||||
text-decoration: none;
|
||||
color: #4054ad;
|
||||
font-weight: bold;
|
||||
}
|
||||
a:hover { color: #1b2c44; }
|
||||
a:visited { color: #437fad; }
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
export let context = 'none';
|
||||
export let filterValues;
|
||||
export let histogram; // an array with key = filter value, val = number of technologies
|
||||
export let colours = []; // an array of colour values with
|
||||
//console.log('Filterable contextFilter: ', filterValues);
|
||||
let activeFiltersString = 'None';
|
||||
|
||||
|
@ -78,8 +79,8 @@
|
|||
console.log('histogram: ', histogram);
|
||||
</script>
|
||||
|
||||
<slot name="h2"><h2>Test Array</h2></slot>
|
||||
|
||||
<slot name="title"><h2>Test Array</h2></slot>
|
||||
<slot name="description"><p>Test Description</p></slot>
|
||||
<div class="actions">
|
||||
<span class="allNone" role="button" tabindex={tabindex++} on:click={() => allNoneActive()}
|
||||
on:keypress={() => allNoneActive()}>select all/none</span><wbr/>
|
||||
|
|
|
@ -35,48 +35,30 @@
|
|||
|
||||
<div class="tile technology">
|
||||
<div class="links">
|
||||
{#if technology.repository}<span class="repository"
|
||||
><a
|
||||
href={technology.repository}
|
||||
title="The source code repository for {technology.name}">R</a
|
||||
></span
|
||||
>{/if}
|
||||
{#if technology.wikipedia}<span class="wikipedia"
|
||||
><a href={technology.wikipedia} title="Wikipedia Page for {technology.name}">W</a
|
||||
></span
|
||||
>{/if}
|
||||
{#if technology.repository}<span class="repository"><a
|
||||
href={technology.repository} title="The source code repository for {technology.name}">R</a></span>{/if}
|
||||
{#if technology.wikipedia}<span class="wikipedia"><a
|
||||
href={technology.wikipedia}
|
||||
title="Wikipedia Page for {technology.name}">W</a></span>{/if}
|
||||
</div>
|
||||
<h2><a href={technology.website}>{technology.name}</a></h2>
|
||||
<p class="description">
|
||||
{technology.description}{#if technology.extended_description}<span
|
||||
title={technology.extended_description}>i</span
|
||||
>{/if}
|
||||
<p class="description">{technology.description}{#if technology.extended_description}<span
|
||||
title={technology.extended_description}>i</span>{/if}
|
||||
</p>
|
||||
{#if technology.categories}<p class="categories">
|
||||
{pluraliser('Category', 'Categories', technology.categories.length)}:
|
||||
<span class="value">{toOxfordCommaString(technology.categories)}</span>
|
||||
</p>{/if}
|
||||
{#if technology.analogues}<p class="analogues">
|
||||
Alternative to <span class="value">{toOxfordCommaString(technology.analogues)}</span>
|
||||
</p>{/if}
|
||||
{#if technology.license}<p
|
||||
class="license"
|
||||
title="The libre license for this project is {technology.license}"
|
||||
>
|
||||
License: <span class="value">{technology.license}</span>
|
||||
</p>{/if}
|
||||
{#if technology.categories}<p class="categories">{pluraliser('Category',
|
||||
'Categories', technology.categories.length)}: <span class="value">{toOxfordCommaString(technology.categories)}</span></p>{/if}
|
||||
{#if technology.analogues}<p class="analogues">Alternative to <span
|
||||
class="value">{toOxfordCommaString(technology.analogues)}</span></p>{/if}
|
||||
{#if technology.license}<p class="license"
|
||||
title="The libre license for this project is {technology.license}">License: <span
|
||||
class="value">{technology.license}</span></p>{/if}
|
||||
{#if hasInstances(technology)}
|
||||
<div class="instances">
|
||||
<p>
|
||||
{#each technology.instances as instance}
|
||||
<a
|
||||
<p>{#each technology.instances as instance}<a
|
||||
href="https://{instance.domain}"
|
||||
title="{technology.name} instance {instance.domain} hosted on '{instance.host}' by {instance.affiliation}"
|
||||
><span
|
||||
class="marker circle"
|
||||
title="{technology.name} instance {instance.domain} hosted on '{instance.host}' by {instance.affiliation}"><span class="marker circle"
|
||||
style="background-color: {affiliate_colours[instance.affiliation].colour}"
|
||||
></span></a
|
||||
>{/each}
|
||||
></span></a>{/each}
|
||||
</p>
|
||||
</div>
|
||||
{:else}
|
|
@ -11,9 +11,9 @@
|
|||
import Filterable from '$lib/components/Filterable.svelte';
|
||||
// collapsible sections
|
||||
import CollapsibleSection from '$lib/components/CollapsibleSection.svelte';
|
||||
import Tile from '$lib/components/Tile.svelte';
|
||||
import TechnologyTile from '$lib/components/TechnologyTile.svelte';
|
||||
|
||||
//console.log('colours: ', colours);
|
||||
let tabindex = 0; // a counter which facilitates keyboard navigation.
|
||||
|
||||
//
|
||||
// digest and return useful info from the Webservices JSON feed
|
||||
|
@ -333,76 +333,88 @@
|
|||
</script>
|
||||
|
||||
<div class="webservices">
|
||||
<div class="header">
|
||||
<div class="introduction">
|
||||
<h1>Web Services</h1>
|
||||
<p>This sites exists to provide an 'always-up-to-date', in-depth description of the <a
|
||||
href="https://tech.oeru.org/foss-libresoftware-its-about-clarity-and-values"
|
||||
title="What do I mean by 'libre' software?">libre software</a> web services <a href="https://davelane.nz" title="Who is this Dave Lane character?">I</a> have set
|
||||
up and maintain.
|
||||
</p>
|
||||
|
||||
</div>
|
||||
<div class="summary-wrapper">
|
||||
<div class="summary">
|
||||
<h2>Statistics</h2>
|
||||
<ul>
|
||||
<li>Number of individual services: {results.stats.instances}</li>
|
||||
<li>Number of individual technologies: {results.stats.current}</li>
|
||||
<li>Number of new technologies to be added: {results.stats.future}</li>
|
||||
<li>Number of libre licenses used by these technologies: {results.stats.licenses}</li>
|
||||
<li> 'weak' corporate-exploitation-friendly open source licenses : {results.stats.weak}</li>
|
||||
<li> 'strong' user-protecting copyleft licenses: {results.stats.copyleft}</li>
|
||||
<li>Total number of services: {results.stats.instances}</li>
|
||||
<li><span class="label">Number of individual services: <span class="number">{results.stats.instances}</span></li>
|
||||
<li><span class="label">Number of individual technologies: <span class="number">{results.stats.current}</span></li>
|
||||
<li><span class="label">Number of new technologies to be added: <span class="number">{results.stats.future}</span></li>
|
||||
<li><span class="label">Number of libre licenses used by these technologies: <span class="number">{results.stats.licenses}</span>
|
||||
<ul>
|
||||
<li><span class="label">'weak' corporate-exploitation-friendly open source licenses : <span class="number">{results.stats.weak}</span></li>
|
||||
<li><span class="label">'strong' user-protecting copyleft licenses: <span class="number">{results.stats.copyleft}</span></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li><span class="label">Total number of services: <span class="number">{results.stats.instances}</span></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<h1>Web Services</h1>
|
||||
<p>This sites exists to provide an 'always-up-to-date', in-depth description of the
|
||||
<a href="https://tech.oeru.org/foss-libresoftware-its-about-clarity-and-values"
|
||||
title="What do I mean by 'libre' software?">libre software</a> web services I (<a href="https://davelane.nz" title="Who is this Dave Lane character?">Dave Lane</a>) have set up and maintain.
|
||||
</p>
|
||||
<p>These services are run primarily on commodity Linux Virtual Private Servers, aka 'hosts', which I also maintain. Some systems are also run on real physical hosts either in my home hosting facility or in commercial hosting facilities. These hosts are based in Aotearoa NZ, Singapore, the US, and in Germany. Almost all run an LTS (Long Term Support) version of Ubuntu Linux although a few hosts run Debian Linux.</p>
|
||||
<p>Almost all the hosts are <a href="https://tech.oeru.org/creating-your-own-oer-foundation-style-libre-self-hosting-infrastructure-docker-compose-and-ubuntu">configured in a particular way</a> which allows multiple services to run harmoniously on the same host. I use a set of somewhere between one and twenty-one Docker containers (which I run via Docker Compose) for each service, to keep different services, each of which has different software dependencies, from interfering with one another. Each service is made available to the Internet via a 'reverse proxy' (for which I use Nginx) and user interactions with them are secured (encrypted) with Let's Encrypt SSL certificates (which renew automatically).
|
||||
</p>
|
||||
<p>To manage the servers and keep them up-to-date, I use SSH to establish secure encrypted connections to them (via key-based authentication). I run updates of the hosts manually, and update individual services when required (urgently if updates are security-related). Some of the Docker containers I run I have built myself, in other cases I use those supplied by the communities developing the service.</p>
|
||||
<p>One huge advantage of the Docker Compose pattern is that I can rapidly move services between different hosts, or even replicate services very rapidly for development or staging purposes. Using them has revolutionised my hosting processes.</p>
|
||||
</div>
|
||||
<CollapsibleSection headerText={'Filters'}>
|
||||
<div class="filters">
|
||||
<CollapsibleSection headerText={'Software Catergory Filter'}>
|
||||
<div class="filter-group categories">
|
||||
<Filterable filterValues={categoryFilter}
|
||||
histogram={results.tech_lists.category_list} context={'categories'}>
|
||||
<h2 slot="h2">Categories</h2>
|
||||
<h2 slot="title">Categories</h2>
|
||||
</Filterable>
|
||||
</div>
|
||||
</CollapsibleSection>
|
||||
<CollapsibleSection headerText={'Software Analogue Filter'}>
|
||||
<div class="filter-group analogues">
|
||||
<Filterable filterValues={analogueFilter}
|
||||
tabindex={tabindex}
|
||||
histogram={results.tech_lists.analogue_list} context={'analogues'}>
|
||||
<h2 slot="h2">Analogues</h2>
|
||||
<h2 slot="title">Analogues</h2>
|
||||
</Filterable>
|
||||
</div>
|
||||
</CollapsibleSection>
|
||||
<CollapsibleSection headerText={'License Filter'}>
|
||||
<div class="filter-group licenses">
|
||||
<Filterable filterValues={licenseFilter}
|
||||
tabindex={tabindex}
|
||||
histogram={results.tech_lists.license_list} context={'licenses'}>
|
||||
<h2 slot="h2">Open Source & Copyleft Licenses</h2>
|
||||
<h2 slot="title">Open Source & Copyleft Licenses</h2>
|
||||
</Filterable>
|
||||
</div>
|
||||
</CollapsibleSection>
|
||||
<CollapsibleSection headerText={'Service Status Filter'}>
|
||||
<div class="filter-group statuses">
|
||||
<Filterable filterValues={statusFilter}
|
||||
tabindex={tabindex}
|
||||
histogram={results.instance_lists.status_list} context={'statuses'}>
|
||||
<h2 slot="h2">Statuses</h2>
|
||||
<h2 slot="title">Statuses</h2>
|
||||
</Filterable>
|
||||
</div>
|
||||
</CollapsibleSection>
|
||||
<CollapsibleSection headerText={'Service Affiliates Filter'}>
|
||||
<div class="filter-group affilates">
|
||||
<Filterable filterValues={affiliateFilter}
|
||||
histogram={results.instance_lists.affiliate_list} context={'affiliates'}>
|
||||
<h2 slot="h2">Affiliates</h2>
|
||||
tabindex={tabindex}
|
||||
histogram={results.instance_lists.affiliate_list}
|
||||
context={'affiliates'}><h2 slot="title">Affiliates</h2>
|
||||
</Filterable>
|
||||
</div>
|
||||
</CollapsibleSection>
|
||||
<CollapsibleSection headerText={'Service Host filter'}>
|
||||
<div class="filter-group hosts">
|
||||
<Filterable filterValues={hostFilter}
|
||||
tabindex={tabindex}
|
||||
histogram={results.instance_lists.host_list} context={'hosts'}>
|
||||
<h2 slot="h2">Hosts</h2>
|
||||
<h2 slot="title">Hosts</h2>
|
||||
</Filterable>
|
||||
</div>
|
||||
</CollapsibleSection>
|
||||
|
@ -410,7 +422,7 @@
|
|||
</CollapsibleSection>
|
||||
<div class="tiles">
|
||||
{#each filteredTechnologies as technology}
|
||||
<Tile technology={technology} affiliate_colours={affiliate_colours} />
|
||||
<TechnologyTile technology={technology} affiliate_colours={affiliate_colours} />
|
||||
{/each}
|
||||
</div>
|
||||
</div>
|
||||
|
@ -423,28 +435,36 @@
|
|||
position: relative;
|
||||
}
|
||||
.introduction {
|
||||
width: 50%;
|
||||
width: 100%;
|
||||
}
|
||||
.summary-wrapper {
|
||||
content: '';
|
||||
display: block;
|
||||
float: right;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
.summary {
|
||||
border-radius: 15px;
|
||||
/*position: absolute;
|
||||
right: 20px;*/
|
||||
float: right;
|
||||
clear: both;
|
||||
/*display: block;*/
|
||||
background-color: #ccc;
|
||||
/*display: block;*/
|
||||
width: 50%;
|
||||
max-width: 30%;
|
||||
min-width: 30em;
|
||||
border: 2px #aaa solid;
|
||||
margin: 0;
|
||||
margin: 0 15px 20px 6px;
|
||||
padding: 0 20px;
|
||||
box-shadow: 6px 6px 20px #999;
|
||||
}
|
||||
.summary .label { color: #666; }
|
||||
.summary .number { color: #000; }
|
||||
@media screen and (max-width: 600px) {
|
||||
.summary {
|
||||
float: none;
|
||||
width: 90%;
|
||||
margin: auto;
|
||||
}
|
||||
/* .filters { margin-bottom: 1em;}
|
||||
.filters .tags {
|
||||
margin: 1em 0;
|
||||
display: block;
|
||||
}*/
|
||||
.tiles {
|
||||
/*display: grid;
|
||||
grid-gap: 15px;
|
||||
grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));*/
|
||||
/*grid-template-columns: repeat(auto-fit);*/
|
||||
}
|
||||
</style>
|
||||
|
|
Loading…
Reference in a new issue