Skip to content

Commit f4f17f3

Browse files
committed
Add the "where is your data?" frontend
Signed-off-by: Michael Weimann <mail@michael-weimann.eu>
1 parent 3068f07 commit f4f17f3

File tree

17 files changed

+60641
-70
lines changed

17 files changed

+60641
-70
lines changed

core/css/styles.scss

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,15 @@ a {
6060
* {
6161
cursor: pointer;
6262
}
63-
}
6463

65-
a.external {
66-
margin: 0 3px;
67-
text-decoration: underline;
64+
&.external {
65+
margin: 0 3px;
66+
text-decoration: underline;
67+
}
68+
69+
&.highlighted {
70+
color: var(--color-primary);
71+
}
6872
}
6973

7074
input {

lib/private/Settings/Personal/PersonalInfo.php

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
use OCP\IUserManager;
3939
use OCP\L10N\IFactory;
4040
use OCP\Settings\ISettings;
41+
use OCP\Encryption\IManager as EncryptionManager;
4142

4243
class PersonalInfo implements ISettings {
4344

@@ -55,6 +56,8 @@ class PersonalInfo implements ISettings {
5556
private $l10nFactory;
5657
/** @var IL10N */
5758
private $l;
59+
/** @var EncryptionManager */
60+
private $encryptionManager;
5861

5962
/**
6063
* @param IConfig $config
@@ -71,7 +74,8 @@ public function __construct(
7174
AccountManager $accountManager,
7275
IAppManager $appManager,
7376
IFactory $l10nFactory,
74-
IL10N $l
77+
IL10N $l,
78+
EncryptionManager $encryptionManager
7579
) {
7680
$this->config = $config;
7781
$this->userManager = $userManager;
@@ -80,6 +84,7 @@ public function __construct(
8084
$this->appManager = $appManager;
8185
$this->l10nFactory = $l10nFactory;
8286
$this->l = $l;
87+
$this->encryptionManager = $encryptionManager;
8388
}
8489

8590
/**
@@ -135,9 +140,15 @@ public function getForm() {
135140
'twitterScope' => $userData[AccountManager::PROPERTY_TWITTER]['scope'],
136141
'twitterVerification' => $userData[AccountManager::PROPERTY_TWITTER]['verified'],
137142
'groups' => $this->getGroups($user),
143+
'dataLocation' => 'Germany',
144+
'provider' => 'Hetzner Online GmbH',
145+
'providerLink' => 'https://www.hetzner.de/',
146+
'providerPrivacyLink' => 'https://www.hetzner.de/rechtliches/datenschutz',
147+
'encryptionEnabled' => true || $this->encryptionManager->isEnabled(),
148+
'adminName' => 'Michael Weimann',
149+
'adminMail' => 'mail@michael-weimann.eu'
138150
] + $messageParameters + $languageParameters + $localeParameters;
139151

140-
141152
return new TemplateResponse('settings', 'settings/personal/personal.info', $parameters, '');
142153
}
143154

settings/css/settings.scss

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ input {
9898

9999
#personal-settings-avatar-container {
100100
display: inline-grid;
101+
grid-row: span 3;
101102
grid-template-columns: 1fr;
102103
grid-template-rows: 2fr 1fr;
103104
vertical-align: top;
@@ -178,6 +179,15 @@ select {
178179
grid-template-columns: 1fr;
179180
#personal-settings-avatar-container {
180181
grid-template-rows: 1fr;
182+
183+
// swap "Where is my data" and "Detail"
184+
*:nth-child(2) {
185+
order: 3;
186+
}
187+
188+
*:nth-child(3) {
189+
order: 2;
190+
}
181191
}
182192
.personal-settings-container {
183193
grid-template-columns: 1fr 1fr;

settings/js/0.js

Lines changed: 348 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

settings/js/0.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

settings/js/1.js

Lines changed: 9 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

settings/js/1.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

settings/js/2.js

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

settings/js/2.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

settings/js/3.js

Lines changed: 6487 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)