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

Release 4.3.0 #1387

Merged
merged 74 commits into from
Nov 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
74 commits
Select commit Hold shift + click to select a range
dcac312
Use more flex utilities in ManageServers component
acelaya Oct 19, 2024
9094c1d
Simplify styles in home page with flex utilities
acelaya Oct 19, 2024
18d9ed7
Merge pull request #1352 from acelaya-forks/feature/remove-rows
acelaya Oct 19, 2024
a1a1bc4
Bump node from 23.0-alpine to 23.1-alpine
dependabot[bot] Oct 26, 2024
714474d
Bump @types/react from 18.3.11 to 18.3.12 in the types group
dependabot[bot] Oct 26, 2024
2b77b24
Bump the vite group with 2 updates
dependabot[bot] Oct 26, 2024
3840d4a
Bump sass from 1.80.3 to 1.80.4
dependabot[bot] Oct 26, 2024
c434b54
Bump axe-core from 4.10.1 to 4.10.2
dependabot[bot] Oct 26, 2024
5943d2a
Merge pull request #1358 from shlinkio/dependabot/npm_and_yarn/axe-co…
acelaya Oct 26, 2024
10ba6cb
Merge pull request #1357 from shlinkio/dependabot/npm_and_yarn/sass-1…
acelaya Oct 26, 2024
6a1f25e
Merge pull request #1356 from shlinkio/dependabot/npm_and_yarn/vite-1…
acelaya Oct 26, 2024
7ae8e52
Merge pull request #1355 from shlinkio/dependabot/npm_and_yarn/types-…
acelaya Oct 26, 2024
fad0dfb
Merge pull request #1353 from shlinkio/dependabot/docker/node-23.1-al…
acelaya Oct 26, 2024
fdbf094
Bump the eslint group with 4 updates
dependabot[bot] Oct 26, 2024
61a679b
Merge pull request #1354 from shlinkio/dependabot/npm_and_yarn/eslint…
acelaya Oct 26, 2024
83ca5b2
Add workflow to build docker image during PRs if Dockerfile changed
acelaya Oct 26, 2024
4c74aec
Simplify local dev setup, update CONTRIBUTING.md and recommend runnin…
acelaya Oct 26, 2024
2bbc3e6
Update node version used during ci
acelaya Oct 26, 2024
913264b
Merge pull request #1359 from acelaya-forks/feature/improve-dev-setup
acelaya Oct 26, 2024
9134d07
Extract logic to determine if a list of servers contains duplicates
acelaya Oct 31, 2024
e786f9d
Update CreateServer logic so that it ensures a unique human-friendly …
acelaya Nov 1, 2024
44fb078
Fix remoteServers test
acelaya Nov 1, 2024
88ad2e7
Fix serversReducer test
acelaya Nov 1, 2024
dc8c749
Remove dependency on uuid package
acelaya Nov 1, 2024
9b891c8
Delete unused FormText component
acelaya Nov 1, 2024
c83abc6
Update Bluesky handle
acelaya Nov 1, 2024
7a9209a
Use better names for remoteServers test datasets
acelaya Nov 1, 2024
645abea
Add test for servers helpers
acelaya Nov 1, 2024
b31949b
Ensure generating server IDs work even if server URLs are invalid
acelaya Nov 1, 2024
238cefd
Merge pull request #1361 from acelaya-forks/feature/predictable-serve…
acelaya Nov 1, 2024
a5a0f36
Bump @testing-library/jest-dom in the testing group across 1 directory
dependabot[bot] Nov 2, 2024
ca980b9
Bump the vitest group with 2 updates
dependabot[bot] Nov 2, 2024
3a6ee5e
Bump the workbox group with 5 updates
dependabot[bot] Nov 2, 2024
877d951
Bump sass from 1.80.4 to 1.80.6
dependabot[bot] Nov 2, 2024
d4f8fdb
Merge pull request #1362 from shlinkio/dependabot/npm_and_yarn/testin…
acelaya Nov 2, 2024
31c4192
Merge pull request #1364 from shlinkio/dependabot/npm_and_yarn/vitest…
acelaya Nov 2, 2024
31c3290
Merge pull request #1365 from shlinkio/dependabot/npm_and_yarn/workbo…
acelaya Nov 2, 2024
6646906
Merge pull request #1366 from shlinkio/dependabot/npm_and_yarn/sass-1…
acelaya Nov 2, 2024
32ec9b9
Bump the eslint group with 3 updates
dependabot[bot] Nov 2, 2024
3aeafec
Merge pull request #1363 from shlinkio/dependabot/npm_and_yarn/eslint…
acelaya Nov 2, 2024
049a588
Bump typescript-eslint from 8.12.2 to 8.13.0 in the eslint group
dependabot[bot] Nov 9, 2024
03f826f
Bump react-router-dom from 6.27.0 to 6.28.0
dependabot[bot] Nov 9, 2024
27db353
Merge pull request #1368 from shlinkio/dependabot/npm_and_yarn/react-…
acelaya Nov 9, 2024
d635013
Merge pull request #1367 from shlinkio/dependabot/npm_and_yarn/eslint…
acelaya Nov 9, 2024
03cb2d7
Bump the vitest group with 2 updates
dependabot[bot] Nov 16, 2024
7220bf1
Bump sass from 1.80.6 to 1.81.0
dependabot[bot] Nov 16, 2024
158702b
Bump vite-plugin-pwa from 0.20.5 to 0.21.0
dependabot[bot] Nov 16, 2024
b2205a6
Merge pull request #1373 from shlinkio/dependabot/npm_and_yarn/vite-p…
acelaya Nov 16, 2024
7e8d85c
Merge pull request #1372 from shlinkio/dependabot/npm_and_yarn/sass-1…
acelaya Nov 16, 2024
68126aa
Merge pull request #1371 from shlinkio/dependabot/npm_and_yarn/vitest…
acelaya Nov 16, 2024
62642d8
Bump vite from 5.4.10 to 5.4.11 in the vite group
dependabot[bot] Nov 16, 2024
81434a5
Merge pull request #1370 from shlinkio/dependabot/npm_and_yarn/vite-7…
acelaya Nov 16, 2024
a777edb
Bump the fontawesome group with 5 updates
dependabot[bot] Nov 23, 2024
db1b58e
Bump typescript from 5.6.3 to 5.7.2
dependabot[bot] Nov 23, 2024
e0f5705
Bump node from 23.1-alpine to 23.3-alpine
dependabot[bot] Nov 23, 2024
b1c2b01
Merge pull request #1377 from shlinkio/dependabot/docker/node-23.3-al…
acelaya Nov 23, 2024
a853078
Merge pull request #1376 from shlinkio/dependabot/npm_and_yarn/typesc…
acelaya Nov 23, 2024
a10898f
Bump the eslint group across 1 directory with 3 updates
dependabot[bot] Nov 23, 2024
5aaf911
Merge pull request #1375 from shlinkio/dependabot/npm_and_yarn/fontaw…
acelaya Nov 23, 2024
975807c
Merge pull request #1374 from shlinkio/dependabot/npm_and_yarn/eslint…
acelaya Nov 23, 2024
8c98181
Bump the eslint group with 2 updates
dependabot[bot] Nov 30, 2024
30ee16a
Bump @shlinkio/shlink-js-sdk from 1.2.0 to 1.3.0 in the shlink group
dependabot[bot] Nov 30, 2024
db59d55
Bump the vitest group with 2 updates
dependabot[bot] Nov 30, 2024
8addfbd
Bump @reduxjs/toolkit from 2.3.0 to 2.4.0
dependabot[bot] Nov 30, 2024
8ae6835
Bump vite-plugin-pwa from 0.21.0 to 0.21.1
dependabot[bot] Nov 30, 2024
0bcdcad
Merge pull request #1383 from shlinkio/dependabot/npm_and_yarn/vite-p…
acelaya Nov 30, 2024
584362b
Merge pull request #1382 from shlinkio/dependabot/npm_and_yarn/reduxj…
acelaya Nov 30, 2024
558d2a0
Merge pull request #1381 from shlinkio/dependabot/npm_and_yarn/vitest…
acelaya Nov 30, 2024
742c7b9
Merge pull request #1379 from shlinkio/dependabot/npm_and_yarn/shlink…
acelaya Nov 30, 2024
49ebfdb
Merge pull request #1378 from shlinkio/dependabot/npm_and_yarn/eslint…
acelaya Nov 30, 2024
a325af3
Update to shlink-web-component 0.11
acelaya Nov 30, 2024
8ac347f
Merge pull request #1385 from acelaya-forks/feature/update-shlink-web…
acelaya Nov 30, 2024
44e9a33
Update to vite 6
acelaya Nov 30, 2024
a390e1b
Merge pull request #1386 from acelaya-forks/feature/vite-6
acelaya Nov 30, 2024
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
10 changes: 10 additions & 0 deletions .github/workflows/ci-docker-image-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
name: Test docker image build

on:
pull_request:
paths:
- 'Dockerfile'

jobs:
build-docker-image:
uses: shlinkio/github-actions/.github/workflows/docker-image-build-ci.yml@main
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ jobs:
ci:
uses: shlinkio/github-actions/.github/workflows/web-app-ci.yml@main
with:
node-version: 20.7
node-version: 22.x
publish-coverage: true
8 changes: 4 additions & 4 deletions .github/workflows/deploy-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@ jobs:
continue-on-error: true
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}
- name: Use node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 20.7
node-version: 22.x
- name: Build
run: |
npm ci && \
node ./scripts/set-homepage.cjs /shlink-web-client/${GITHUB_HEAD_REF#refs/heads/} && \
npm run build
node --run build
- name: Deploy preview
uses: shlinkio/deploy-preview-action@v1.0.1
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ jobs:
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Use node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 20.7
node-version: 22.x
- name: Generate release assets
run: npm ci && VERSION=${GITHUB_REF#refs/tags/v} npm run build:dist
- name: Publish release with assets
Expand Down
4 changes: 1 addition & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@

# production
/build
/dist

npm-debug.log*

docker-compose.override.yml
home
public/servers.json*
28 changes: 28 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,34 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org).

## [4.3.0] - 2024-11-30
### Added
* [#1360](https://github.com/shlinkio/shlink-web-client/issues/1360) Added ability for server IDs to be generated based on the server name and URL, instead of generating a random UUID.

This can improve sharing a predefined set of servers cia servers.json, env vars, or simply export and import your servers in some other device, and then be able to share server URLs which continue working.

All existing servers will keep their generated IDs in existing devices for backwards compatibility, but newly created servers will use the new approach.

* [shlink-web-component#491](https://github.com/shlinkio/shlink-web-component/issues/491) Add support for colors in QR code configurator.
* [shlink-web-component#515](https://github.com/shlinkio/shlink-web-component/issues/515) Add support for geolocation redirect conditions, when using Shlink 4.3 or newer.
* [shlink-web-component#514](https://github.com/shlinkio/shlink-web-component/issues/514) Allow filtering short URLs list by domain, when using Shlink 4.3 or newer.
* [shlink-web-component#520](https://github.com/shlinkio/shlink-web-component/issues/520) Allow navigating from domains list to short URLs list filtered by one domain, when using Shlink 4.3 or newer.
* [shlink-web-component#517](https://github.com/shlinkio/shlink-web-component/issues/517) Update list of known domains when a short URL is created with a new domain.
* [shlink-web-component#292](https://github.com/shlinkio/shlink-web-component/issues/292) Add icon in short URLs list indicating if a short URL has redirect rules.

### Changed
* *Nothing*

### Deprecated
* *Nothing*

### Removed
* *Nothing*

### Fixed
* [shlink-web-component#504](https://github.com/shlinkio/shlink-web-component/issues/504) Fix fallback interval not causing new visits to be loaded.


## [4.2.2] - 2024-10-19
### Added
* *Nothing*
Expand Down
28 changes: 12 additions & 16 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,13 @@ Because of this, the only actual dependencies are [docker](https://docs.docker.c

The first thing you need to do is fork the repository, and clone it in your local machine.

Then you will have to follow these steps:
Then simply run `docker compose up` and you will have the project exposed in port `3000` (http://localhost:3000).

* Copy the file `docker-compose.override.yml.dist` by also removing the `dist` extension.
* Start-up the project by running `docker compose up`.

Once this is finished, you will have the project exposed in port `3000` (http://localhost:3000).
> The first time the container is created, the project dependencies will be installed and the container may take a bit longer to start.

## Project structure

This project is a [react](https://reactjs.org/) & [redux](https://redux.js.org/) application, built with [typescript](https://www.typescriptlang.org/), which is distributed as a 100% client-side progressive web application.
This project is a [react](https://react.dev/) & [redux](https://redux.js.org/) application, built with [typescript](https://www.typescriptlang.org/), which is distributed as a 100% client-side progressive web application.

This is the basic project structure:

Expand All @@ -39,7 +36,7 @@ shlink-web-client
```

* `config`: It contains some configuration scripts, used during testing, linting and building of the project.
* `public`: Will act as the application document root once built, and contains some static assets (favicons, images, etc).
* `public`: Will act as the application document root once built, and contains some static assets (favicons, images, etc.).
* `scripts`: It has some of the CLI scripts used to run tests or building.
* `src`: Contains the main source code of the application, including both web components, SASS stylesheets and files with logic.
* `test`: Contains the project tests.
Expand All @@ -48,20 +45,19 @@ shlink-web-client

> Note: The `indocker` shell script is a helper used to run commands inside the docker container.

* `./indocker npm run lint`: Checks coding styles are fulfilled, both in JS/TS files as well as in stylesheets.
* `./indocker npm run lint:js`: Checks coding styles are fulfilled in JS/TS files.
* `./indocker npm run lint:css`: Checks coding styles are fulfilled in stylesheets.
* `./indocker npm run lint:js:fix`: Fixes coding styles in JS/TS files.
* `./indocker npm run lint:css:fix`: Fixes coding styles in stylesheets.
* `./indocker npm run test`: Runs unit tests with Jest.
* `./indocker npm run mutate`: Runs mutation tests with StrykerJS (this command can be very slow).
* `./indocker node --run lint`: Checks coding styles are fulfilled, both in JS/TS files and in stylesheets.
* `./indocker node --run lint:js`: Checks coding styles are fulfilled in JS/TS files.
* `./indocker node --run lint:css`: Checks coding styles are fulfilled in stylesheets.
* `./indocker node --run lint:js:fix`: Fixes coding styles in JS/TS files.
* `./indocker node --run lint:css:fix`: Fixes coding styles in stylesheets.
* `./indocker node --run test`: Runs unit tests with Jest.

## Building the project

The source code in this project cannot be run directly in a web browser, you need to build it first.

* `./indocker npm run build`: Builds the project using a combination of `webpack`, `babel` and `tsc`, generating the final static files. The content is placed in the `build` folder, which is automatically created if it does not exist.
* `./indocker npm run serve:build`: Serves the static files inside the `build` folder in port 5000 (http://localhost:5000). Useful to test the content built with previous command.
* `./indocker node --run run build`: Builds the project for production using [vite](https://vite.dev/), generating the final static files. The content is placed in the `build` folder, which is automatically created if it does not exist.
* `./indocker node --run run preview`: Serves the static files inside the `build` folder in a random port. Useful to test the content built with previous command.

## Pull request process

Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
FROM node:23.0-alpine as node
FROM node:23.3-alpine AS node
COPY . /shlink-web-client
ARG VERSION="latest"
ENV VERSION ${VERSION}
RUN cd /shlink-web-client && npm ci && npm run build
ENV VERSION=${VERSION}
RUN cd /shlink-web-client && npm ci && node --run build

FROM nginxinc/nginx-unprivileged:1.27-alpine
ARG UID=101
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
[![GitHub license](https://img.shields.io/github/license/shlinkio/shlink-web-client.svg?style=flat-square)](https://github.com/shlinkio/shlink-web-client/blob/main/LICENSE)

[![Mastodon](https://img.shields.io/mastodon/follow/109329425426175098?color=%236364ff&domain=https%3A%2F%2Ffosstodon.org&label=follow&logo=mastodon&logoColor=white&style=flat-square)](https://fosstodon.org/@shlinkio)
[![Bluesky](https://img.shields.io/badge/follow-shlinkio-0285FF.svg?style=flat-square&logo=bluesky&logoColor=white)](https://bsky.app/profile/shlinkio.bsky.social)
[![Bluesky](https://img.shields.io/badge/follow-shlinkio-0285FF.svg?style=flat-square&logo=bluesky&logoColor=white)](https://bsky.app/profile/shlink.io)
[![Paypal Donate](https://img.shields.io/badge/Donate-paypal-blue.svg?style=flat-square&logo=paypal&colorA=cccccc)](https://slnk.to/donate)

A ReactJS-based progressive web application for [Shlink](https://shlink.io).
Expand Down
2 changes: 0 additions & 2 deletions dist/.gitignore

This file was deleted.

7 changes: 0 additions & 7 deletions docker-compose.override.yml.dist

This file was deleted.

3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
services:
shlink_web_client_node:
container_name: shlink_web_client_node
image: node:22.3-alpine
user: 1000:1000 # With this, files created via `indocker` script will belong to the host user
image: node:22.10-alpine
command: /bin/sh -c "cd /home/shlink/www && npm install && npm run start"
volumes:
- ./:/home/shlink/www
Expand Down
Loading
Loading