9082 Commits

Author SHA1 Message Date
Sunil Mohan Adapa
3f20c1668d
ui: Allow users to provide a CSS file to customize styling
- Don't include the file if it does not exist to avoid a 404 error every time a
page it loaded.

- Load the file from a know path under the already known custom static path.

Tests:

- When the user.css file is created, it added to the web page. It is prioritized
over the main.css with CSS cascading rules.

- When the user.css file does not exist on the filesystem, it is not added to
the web page.

- When custom static directory (/var/www/plint) does not exist on the
filesystem, a debug log message is printed that this directory is not served.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-12-01 16:47:34 -05:00
Sunil Mohan Adapa
37e6e3b9b3
ui: Align app icons in the center for home, apps, and help pages
Overall, this is something we can try out.

- This looks better in some cases

  - Default large list of disabled apps

  - Home page with very few icons

  - Help index page /plinth/help

  - Mobile views

- This looks somewhat worse in some cases

  - Last row of a large list of apps, esp. when the number apps left is even and
  the number of apps in the previous row is not (similarly with odd number of
  apps).

  - Mismatch between enabled/disabled app section.

Thanks to @Ged296123 and @fefekrzr for suggesting the change.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-12-01 16:47:32 -05:00
Sunil Mohan Adapa
b346169312
help: Add a class to the help index page
- So that the page appearance can be easily customized in CSS.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-12-01 16:47:29 -05:00
James Valleroy
5ed6d19ff9
radicale: Update link to supported clients
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
2024-11-30 10:43:23 -08:00
Veiko Aasa
50cedaf528
tags: tests: Fix deprecated webdriver attribute
Fixes errors in functional tests:
`AttributeError: 'WebDriver' object has no attribute 'find_element_by_id'`

Tests:
  - All tags tests pass.

Signed-off-by: Veiko Aasa <veiko17@disroot.org>
Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
2024-11-28 11:13:45 -08:00
Sunil Mohan Adapa
987577fae2
notifications: Don't error when dismissing missing notifications
Fixes: #2468.

- Two browser tabs could be loaded with the interface and the same notification
could be dismissed twice. When dismissing the notification for the second time,
we currently throw a 404 error. Instead silently ignore the error.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-28 07:02:33 +02:00
Sunil Mohan Adapa
536721df19
tags: Fix issue with JS init on a page without tags
- On a page without tags, tags.js still loads and initializes. When a tag input
search bar does not exist on the page, this leads to a harmless exception
getting printed on the browser console.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-28 06:41:13 +02:00
John Doe
4705a86f90
Translated using Weblate (French)
Currently translated at 100.0% (1775 of 1775 strings)
2024-11-21 19:00:00 +01:00
Paul Lettich
6c4f485559
Translated using Weblate (German)
Currently translated at 98.9% (1756 of 1775 strings)
2024-11-21 18:59:55 +01:00
109247019824
2ce9599b71
Translated using Weblate (Bulgarian)
Currently translated at 47.2% (838 of 1775 strings)
2024-11-20 23:29:01 +01:00
Jiří Podhorecký
2790ce6f80
Translated using Weblate (Czech)
Currently translated at 100.0% (1775 of 1775 strings)
2024-11-20 23:29:01 +01:00
大王叫我来巡山
a9a5efbbdd
Translated using Weblate (Chinese (Simplified Han script))
Currently translated at 63.5% (1128 of 1775 strings)
2024-11-20 23:29:01 +01:00
Ettore Atalan
08eab8ca63
Translated using Weblate (German)
Currently translated at 98.6% (1751 of 1775 strings)
2024-11-20 23:29:01 +01:00
Besnik Bleta
f3a79cfe8b
Translated using Weblate (Albanian)
Currently translated at 99.7% (1771 of 1775 strings)
2024-11-20 00:24:31 +01:00
109247019824
b446ef67a1
Translated using Weblate (Bulgarian)
Currently translated at 46.7% (829 of 1775 strings)
2024-11-20 00:24:30 +01:00
Burak Yavuz
0ae40087ef
Translated using Weblate (Turkish)
Currently translated at 100.0% (1775 of 1775 strings)
2024-11-20 00:24:30 +01:00
James Valleroy
7a7f9b01e7
Release v24.24 to unstable
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
v24.24
2024-11-18 20:40:25 -05:00
James Valleroy
c4c071ddfd
doc: Fetch latest manual
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-18 20:39:42 -05:00
James Valleroy
ae13278b7d
locale: Update translation strings
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-18 20:14:00 -05:00
Sunil Mohan Adapa
480562890a
nextcloud: Drop diagnostic for checking availability of docker.com
Tests:

- Run diagnostics for nextcloud and notice that there is not check to reach
docker.com.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-15 16:46:52 -05:00
Sunil Mohan Adapa
983c0f53af
nextcloud: Switch to using FreedomBox container registry
- Should fix issues related to rate limiting on docker.io and improve privacy
for our users.

Tests:

- Install nextcloud, install succeeds. 'podman image list' shows that image is
from registry.freedombox.org.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-15 16:46:41 -05:00
Sunil Mohan Adapa
5fedde1bda
ui: Drop box shadow around the card in card lists
- Drop the box shadow around a card item. Applies to home, apps, system, and
help pages.

- Replace the box shadow on hover with gray background. This gives the card a
much flatter look.

- Drop the top and bottom padding for app title as this is no longer necessary
as the white space around the icon/text is not overwhelming.

  - Add top padding for app titles to make them level with icon tops.

- Drop the margin around the cards as it is not needed anymore. This completely
removes non-clickable area between the cards (which is unnecessary).

  - Increase the padding to compensate for the reduction in the total gap
  between the cards.

  - In system page, increase in top margin for the section title is needed to
  compensate for the loss of bottom margin for cards.

  - In system page, increase in the total width of the card is necessary to make
  the total row size the size of the container.

Tests:

- In apps and system pages, gap between the section title and cards in the
previous row is sufficient.

- In system page, 4 cards fit exactly in each row given the screen is large
enough.

- In apps page, app titles margins appear pleasant.

- In system page, the app titles align with icon tops.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-12 13:19:50 -05:00
Sunil Mohan Adapa
d14eb15a43
ui: Drop logo backgrounds for index, apps, and system pages
- When the box shadows are dropped, the cards overlay on those backgrounds is
not pleasant.

Tests:

- MediaWiki functional tests pass.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-12 13:19:47 -05:00
Sunil Mohan Adapa
3c07d245d4
networks: wifi: In new connection page set form defaults properly
- When a link on 'Nearby Wi-Fi Networks' page is clicked, a new Wi-Fi connection
page is shown. In this form, the DNS-over-TLS and IPv6 method radio buttons are
not pre-selected with default value. Fix this by setting default values for
them.

Tests:

- On a system with Wi-Fi device, click on 'Nearby Wi-Fi Networks', click on a
Wi-Fi network and go to new Wi-Fi connection creation page. Notice that values
for DNS-over-TLS and IPv6 connection method are filled in. Simply clicking
'Submit' creates the connection.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-11 15:47:28 +02:00
Sunil Mohan Adapa
064f3c6c0c
networks: Overhaul Wi-Fi network scan page
Fixes: #1725.

- Show multiple Wi-Fi devices in separate tables so that users can pick them
understanding what they are. Also avoids some confusion related to why APs are
duplicated.

- Request scanning if the last scan time was long ago.

- Show the last scanned time.

- Refresh page in 10 seconds if scan has been requested so that the results of
scan can be shown without user explicitly refreshing the page. Show spinner when
scan has been requested and we are awaiting results.

- Refresh page every 60 seconds in other cases.

- When an SSID can't be decoded into a string, don't show it.

- Don't show hidden networks with no SSID set.

- Improve the styling for signal strength.

- Show a message when no Wi-Fi devices are present.

- Show a message when no Wi-Fi networks are found for a device.

Tests:

- Test on a machine with Wi-Fi device available.

- When page is loaded is for the first time, spinner is shown and refresh
happens in 10 seconds. After refresh if the scan has not completed, again,
spinner is shown and page is reloaded in 10 seconds. Otherwise, spinner is not
shown and page is reloaded in 60 seconds.

- Hidden networks are not shown.

- On a machine with no Wi-Fi devices, 'No Wi-Fi device detected.' message is
shown.

- Clicking on a network takes us to new Wi-Fi network connection page with
'connection name', 'network interface' and SSID filled in correctly.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
2024-11-11 13:28:34 +02:00
Sunil Mohan Adapa
a32a226492
tests: functional: Fix visit() returning prematurely before page load
- It appears from the functional tests run in Gitlab CI pipelines that visit()
is returning before the page has loaded fully. In the screenshots for help app
test failures, we see gitweb web page.

- To fix this, wait for a proper page load in visit().

- Cleanup syntax, rename the non-existent search class, and mechanism for
matching expected URLs.

- Also refactor waiting for uninstall page in uninstall() method. Using the
wait_for_page_update() method as context processor is more accurate.

Tests:

- Run all functional tests and ensure that there are no errors in visit()
method.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-09 08:14:51 +02:00
Veiko Aasa
90fd6a71f7
container: Quote arguments that contain spaces when restoring pytest args
Adds single quotes inside single-quoted string, for example bash command
`echo ' '"'"'test'"'"' '` prints ` 'test' `.

Also:
  - Remove wrong comment in the same function.
  - Fix quote usages in container script.

Tested that running bepasty tests with keyword expression filter
`-k "enable_disable or uninstall` works.

Signed-off-by: Veiko Aasa <veiko17@disroot.org>
[sunil: Use shlex.quote() for quoting]
[sunil: Pipe the script 'ssh sudo bash' instead of sending argument]
[sunil: enable color always for pytest]
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
2024-11-08 08:41:30 -08:00
Sunil Mohan Adapa
63ada3ee62
tests: functional: Don't enable/disable app during tests
- Currently, after every test we disable the app and re-enable for the next
test. The original purpose of this disabling is to make sure that an app is
disabled after test on it. So, change the scope of disabling the app to ensure
that it is only disabled once after all the tests on the app. This should
improve the run time of the tests.

Tests:

- Run functional tests on bepasty app.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-08 10:30:55 +02:00
Jiří Podhorecký
fe98e3eb69
Translated using Weblate (Czech)
Currently translated at 100.0% (1770 of 1770 strings)
2024-11-07 16:00:23 +01:00
Dietmar
62d7369724
Translated using Weblate (German)
Currently translated at 98.1% (1738 of 1770 strings)
2024-11-07 16:00:19 +01:00
Sunil Mohan Adapa
c381271601
rssbridge: Mention miniflux in app description similar to tt-rss
Tests:

- App description appears as expected. Links work.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 12:18:12 +02:00
Sunil Mohan Adapa
c5a967a1a2
i18n: Fix translation of FreedomBox name in various places
Tests:

- With a locale that has translation for the 'FreedomBox' source string, check
the following locations have translated string for 'FreedomBox':

  - Default backup repository label.

  - Firewall app description.

  - Network forms for: topology, internet connection type, and router
  configuration.

  - RSS-Bridge app description.

  - TiddlyWiki app description.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 12:17:34 +02:00
Sunil Mohan Adapa
3807ee4c54
tests: functional: Wait for uninstall page load before uninstalling
- Many functional test failures in the Gitlab CI pipeline show that uninstall
form was attempted to submitted while still in the app page. After clicking on
the uninstall menu item, we are not waiting for the page to load fully. Fix this
by waiting for page load. This change is expected to fix most of the functional
tests failures in the pipeline.

Tests:

- Ran bepasty functional tests.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 10:07:12 +02:00
Sunil Mohan Adapa
85cf5a16c8
networks: Improve styling of badges in the information tables
- Make text size and weight to be regular.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 08:41:18 +02:00
Sunil Mohan Adapa
0e59b67bbd
networks: Fix display of strength and channel for Wi-Fi connections
- Currently, strength and channel information is not shown for Wi-Fi connections
in connection information page. This is a regression related to handling SSID as
a binary string. Fix this.

- Also fix the styling to not make signal strength too prominent.

Tests:

- On a machine with Wi-Fi network device. Viewing the Wi-Fi connection
information does not signal strength and channel without patch but show with the
patch.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 08:41:04 +02:00
Sunil Mohan Adapa
7fa664d445
networks: Fix display of mangled SSIDs when scanning Wi-Fi networks
In the list of Wi-Fi networks shown after scanning, the SSID shows as "b'myap'"
instead of "myap". Fix this.

Tests:

- On a machine with Wi-Fi network device, scan of Wi-Fi networks. Without the
patch, incorrect SSID labels show up. With patch, SSID is correct.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 08:40:52 +02:00
Sunil Mohan Adapa
bfdb05bf0d
networks: Fix editing wireless connections with SSID field
Fixes: #2447.

- When editing an existing wireless connection, SSID field shows as "b'myap'"
instead of "myap". Fix this.

Tests:

- On a machine with a wireless connection, edit the connection. Without the
patch, form show SSID incorrectly. With the patch, it shows the correct value.

- Unit tests in test_network.py pass when run as root.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: Veiko Aasa <veiko17@disroot.org>
2024-11-07 08:39:56 +02:00
Besnik Bleta
ff4250f24e
Translated using Weblate (Albanian)
Currently translated at 99.7% (1766 of 1770 strings)
2024-11-06 06:06:56 +01:00
109247019824
01f28a1d45
Translated using Weblate (Bulgarian)
Currently translated at 46.8% (829 of 1770 strings)
2024-11-06 06:06:56 +01:00
大王叫我来巡山
1f3612e0ec
Translated using Weblate (Chinese (Simplified Han script))
Currently translated at 63.5% (1125 of 1770 strings)
2024-11-06 06:06:56 +01:00
Burak Yavuz
d46c0d7258
Translated using Weblate (Turkish)
Currently translated at 100.0% (1770 of 1770 strings)
2024-11-06 06:06:55 +01:00
James Valleroy
f0082f2102
Release v24.23 to unstable
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
v24.23
2024-11-04 20:56:14 -05:00
James Valleroy
3a403e7b57
debian: Drop python3-flake8 build dependency
Although flake8 is used in development, it is not needed for building
the package.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-04 20:54:47 -05:00
James Valleroy
e02ffd086c
doc: Fetch latest manual
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-04 20:36:41 -05:00
James Valleroy
8b46fbdd1d
locale: Update translation strings
Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-04 20:12:32 -05:00
Sunil Mohan Adapa
5cca536765
index: css: Move the 'powered by' logo further down
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-02 21:20:20 -04:00
Sunil Mohan Adapa
5c41a67267
base: Add link to about for unauthenticated users
Since the about page is now public, adding a link to it in the navbar allows the
users to easily discover it and find out about FreedomBox.

Tests:

- In mobile view, the hamburger menu show the icon and text. Link works.

- In desktop mode, only the icon is visible. Link works.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-02 21:20:18 -04:00
Sunil Mohan Adapa
6bb13140e8
index: Remove links and about text and link to about page
- Make a separate image for 'FreedomBox Powered'.

- Link to the now publicly available about page.

Tests:

- Clicking on the new 'Powered' image leads to about page which is available to
logged in and logged out users.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-02 21:20:15 -04:00
Sunil Mohan Adapa
6084b95a65
help: Add all footer links to about page
Fixes: #2464.

- This page will act as replacement for the footer links in the home page.

- Remove link to FreedomBox Foundation and add link to Weblate project. We
already have a donate link to the foundation website.

Tests:

- About page is shown as expected. Old 'Learn more' button is no more. So is the
last paragraph.

- Styling is as expected. All the section have equal width.

- All links work.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-02 21:20:13 -04:00
Sunil Mohan Adapa
62e67c6c99
help: Make about page available to unauthenticated users
- This page will replace the rather large footer in the front page.

Tests:

- Log out. Visit the help about page. It is available without redirection to
login page. Version related alert is not shown.

- Log in. Visit the help about page. It is available. Version related alert is
shown.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
2024-11-02 21:20:10 -04:00