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

Open Links in app #1295

Closed
jesmrec opened this issue Nov 14, 2023 · 11 comments
Closed

Open Links in app #1295

jesmrec opened this issue Nov 14, 2023 · 11 comments
Assignees
Labels
p2-high Escalation, on top of current planning, release blocker
Milestone

Comments

@jesmrec
Copy link
Contributor

jesmrec commented Nov 14, 2023

Existing feature intending to open files/folders in app, by clicking a private link from outside.

Testing done over feature/account-wizard branch, commit 5a3745689

oC10: no issues found. Links are correctly solved: app opened and item highlighted/opened by using owncloud:// scheme

In oCIS links are not working. These are the steps i followed:

  1. Get the privatelink. In my case, i got from PROPFIND response:
    <d:propstat>
      <d:prop>
        ...
        <oc:privatelink>https://ocis.xxxx.owncloud.works/f/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74%21d7301af2-45f5-4a8d-b049-61946c042cd5</oc:privatelink>
        ...
      </d:prop>
      <d:status>HTTP/1.1 200 OK</d:status>
    </d:propstat>
  1. In the app, add the account that contains the file
  2. Create a link in any app/web to open it from outside the oC app
  3. Click the link

Current: Link Resolution error, no matter where the item is stored: root, non-root, personal or custom space
Expected: Item highlighted

Video and logs

ID of the file open in the video:
71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74!a3b603fe-b1a8-490c-96a9-29a57d35021b

RPReplay_Final1699984486.MP4

ownCloud_14_Nov_2023_at_18_54_01.log.txt

Testing over links feature will be led for the following test plan:
https://github.com/owncloud/QA/blob/ios/restructure_some_test_plans/Mobile/iOS/Feature%20template/Links/Open%20from%20Link.md

And new scenarios added to the proper feature file:
https://github.com/owncloud/ios-scenario-testing/blob/master/src/test/resources/io/cucumber/privatelink.feature

@michaelstingl
Copy link
Contributor

For this link:
owncloud://ocis.ocis-traefik.latest.owncloud.works/f/5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7%218148e70c-f473-454f-beb3-43fde213383e
HTTP requests and responses look good I'd say:

2023-11-14 21:39:28.699000+0100 ownCloud[91205:7934084] ⚪️ | [HTTP, Request, …] Sending request:
# REQUEST ---------------------------------------------------------
URL:         https://ocis.ocis-traefik.latest.owncloud.works/remote.php/dav/meta/5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7!8148e70c-f473-454f-beb3-43fde213383e
Error:       -
Req Signals: authAvailable
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PROPFIND /remote.php/dav/meta/5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7!8148e70c-f473-454f-beb3-43fde213383e HTTP/1.1
Host: ocis.ocis-traefik.latest.owncloud.works
Content-Length: 159
Prefer: return=minimal
X-Request-ID: E5B333BB-C3C3-4DDB-B921-A1F69538B8C9
Original-Request-ID: E5B333BB-C3C3-4DDB-B921-A1F69538B8C9
Content-Type: application/xml
Depth: 0
User-Agent: ownCloudApp/12.0.3 (App/271; iOS/17.0.1; iPhone)
Authorization: Bearer [redacted:2]
Accept-Language: en

<?xml version="1.0" encoding="UTF-8"?>
<D:propfind xmlns:D="DAV:" xmlns:oc="http://owncloud.org/ns">
	<D:prop>
		<oc:meta-path-for-user/>
	</D:prop>
</D:propfind>

----------------------------------------------------------------- [… PROPFIND, RequestID:E5B333BB-C3C3-4DDB-B921-A1F69538B8C9, URLSessionTaskID:71] [OCHTTPPipeline.m:1184|FULL]
2023-11-14 21:39:28.747000+0100 ownCloud[91205:7934084] ⚪️ | [HTTP, Response, …] Received response:
# RESPONSE --------------------------------------------------------
Method:      PROPFIND
URL:         https://ocis.ocis-traefik.latest.owncloud.works/remote.php/dav/meta/5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7!8148e70c-f473-454f-beb3-43fde213383e
Request-ID:  E5B333BB-C3C3-4DDB-B921-A1F69538B8C9
Error:       -
Req Signals: authAvailable
Metrics:     { total: [2023-11-14 20:39:28 +0000 - 2023-11-14 20:39:28 +0000, 0.05 sec], startedAfter: 0.00, redirects: 0, transactions: [1: fetchStart: 0.00, request: 0.00..0.01 (0.00), cloud: 0.01..0.04 (0.03), response: 0.04..0.04 (0.00)] }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
207 SUCCESS
Access-Control-Allow-Origin: *
Content-Type: application/xml; charset=utf-8
content-security-policy: default-src 'none';
dav: 1, 3, extended-mkcol
x-download-options: noopen
x-xss-protection: 1; mode=block
x-permitted-cross-domain-policies: none
Date: Tue, 14 Nov 2023 20:39:28 GMT
x-request-id: E5B333BB-C3C3-4DDB-B921-A1F69538B8C9
x-robots-tag: none
Content-Length: 773
x-content-type-options: nosniff
x-frame-options: SAMEORIGIN
Vary: Origin

<d:multistatus xmlns:d="DAV:" xmlns:oc="http://owncloud.org/ns" xmlns:s="http://sabredav.org/ns">
	<d:response>
		<d:href>/remote.php/dav/meta/5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7%218148e70c-f473-454f-beb3-43fde213383e/</d:href>
		<d:propstat>
			<d:prop>
				<oc:meta-path-for-user>/Test/Photo-2011-03-13-01-17-25_0001.JPG</oc:meta-path-for-user>
				<oc:id>5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7!8148e70c-f473-454f-beb3-43fde213383e</oc:id>
				<oc:fileid>5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7!8148e70c-f473-454f-beb3-43fde213383e</oc:fileid>
				<oc:spaceid>5e8c7cc9-e0a4-41c6-b50c-456c8b38a961</oc:spaceid>
			</d:prop>
			<d:status>HTTP/1.1 200 OK</d:status>
		</d:propstat>
	</d:response>
</d:multistatus>
----------------------------------------------------------------- [… PROPFIND, RequestID:E5B333BB-C3C3-4DDB-B921-A1F69538B8C9, URLSessionTaskID:71] [OCHTTPPipeline.m:1307|FULL]

@michaelstingl
Copy link
Contributor

Log lines before and after:

2023-11-14 21:47:28.347000+0100 ownCloud[91205.7933898] ⚪️ | [CORE, Sharing] Resolving private link https://ocis.ocis-traefik.latest.owncloud.works/f/5e8c7cc9-e0a4-41c6-b50c-456c8b38a961$534bb038-6f9d-4093-946f-133be61fa4e7%218148e70c-f473-454f-beb3-43fde213383e via server… [OCCore+Sharing.m:631|FULL]
2023-11-14 21:47:28.409000+0100 ownCloud[91205:7934084] ⚠️ | [CONN] retrieveItemListAtLocation: API call without drive ID in drive-based account [OCConnection.m:1848|FULL]

@michaelstingl michaelstingl added this to the 12.1-Current milestone Nov 14, 2023
@michaelstingl michaelstingl added the p2-high Escalation, on top of current planning, release blocker label Nov 14, 2023
@felix-schwarz
Copy link
Contributor

felix-schwarz commented Nov 14, 2023

I looked into it and so far <oc:spaceid> was not used, so that no correct location could be assembled.

I changed the code to use <oc:spaceid>, but then noticed that the driveID provided by it is incomplete, so that the resolution still fails in the end.

Here's an example, resolving https://ocis.ocis-wopi.latest.owncloud.works/f/71135097-2849-442b-b3d8-7701539e8cf5%24e90424c7-1bdb-4512-9e05-cba6b6ffbb74%2197b970f2-18dc-4e80-b154-cec25285b959, which points to folder /555/ in the personal space.

# REQUEST ---------------------------------------------------------
URL:         https://ocis.ocis-wopi.latest.owncloud.works/remote.php/dav/meta/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74!97b970f2-18dc-4e80-b154-cec25285b959
Error:       -
Req Signals: authAvailable
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PROPFIND /remote.php/dav/meta/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74!97b970f2-18dc-4e80-b154-cec25285b959 HTTP/1.1
Host: ocis.ocis-wopi.latest.owncloud.works
Content-Length: 159
Prefer: return=minimal
X-Request-ID: 5364EEF1-0DDB-4886-BACD-3088459998D5
Original-Request-ID: 5364EEF1-0DDB-4886-BACD-3088459998D5
Content-Type: application/xml
Depth: 0
User-Agent: ownCloudApp/12.0.3 (App/271; iOS/17.0.1; iPhone)
Authorization: Bearer [redacted:3]
Accept-Language: en

<?xml version="1.0" encoding="UTF-8"?>
<D:propfind xmlns:D="DAV:" xmlns:oc="http://owncloud.org/ns">
<D:prop>
<oc:meta-path-for-user/>
</D:prop>
</D:propfind>

# RESPONSE --------------------------------------------------------
Method:      PROPFIND
URL:         https://ocis.ocis-wopi.latest.owncloud.works/remote.php/dav/meta/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74!97b970f2-18dc-4e80-b154-cec25285b959
Request-ID:  5364EEF1-0DDB-4886-BACD-3088459998D5
Error:       -
Req Signals: authAvailable
Metrics:     { total: [2023-11-14 23:08:10 +0000 - 2023-11-14 23:08:10 +0000, 0.16 sec], startedAfter: 0.00, redirects: 0, transactions: [1: fetchStart: 0.00, request: 0.00..0.00 (0.00), cloud: 0.00..0.15 (0.15), response: 0.15..0.15 (0.00)] }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
207 SUCCESS
Access-Control-Allow-Origin: *
Content-Type: application/xml; charset=utf-8
content-security-policy: default-src 'none';
dav: 1, 3, extended-mkcol
x-download-options: noopen
x-xss-protection: 1; mode=block
x-permitted-cross-domain-policies: none
Date: Tue, 14 Nov 2023 23:08:10 GMT
x-request-id: 5364EEF1-0DDB-4886-BACD-3088459998D5
x-robots-tag: none
Content-Length: 737
x-content-type-options: nosniff
x-frame-options: SAMEORIGIN
Vary: Origin

<d:multistatus
	xmlns:s="http://sabredav.org/ns"
	xmlns:d="DAV:"
	xmlns:oc="http://owncloud.org/ns">
	<d:response>
		<d:href>/remote.php/dav/meta/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74%2197b970f2-18dc-4e80-b154-cec25285b959/</d:href>
		<d:propstat>
			<d:prop>
				<oc:meta-path-for-user>/555</oc:meta-path-for-user>
				<oc:id>71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74!97b970f2-18dc-4e80-b154-cec25285b959</oc:id>
				<oc:fileid>71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74!97b970f2-18dc-4e80-b154-cec25285b959</oc:fileid>
				<oc:spaceid>71135097-2849-442b-b3d8-7701539e8cf5</oc:spaceid>
			</d:prop>
			<d:status>HTTP/1.1 200 OK</d:status>
		</d:propstat>
	</d:response>
</d:multistatus>

The drive/space ID returned here is different from what the drive list returned earlier for the personal space:

  • 71135097-2849-442b-b3d8-7701539e8cf5 (returned by meta endpoint)
  • 71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74 (returned by the drive list endpoint)
# RESPONSE --------------------------------------------------------
Method:      GET
URL:         https://ocis.ocis-wopi.latest.owncloud.works/graph/v1.0/me/drives
Request-ID:  D2AF9AAD-4BCA-41F4-9980-35D343B926CF
Error:       -
Req Signals: authAvailable
Metrics:     { total: [2023-11-14 23:02:35 +0000 - 2023-11-14 23:02:36 +0000, 0.64 sec], startedAfter: 0.00, redirects: 0, transactions: [1: fetchStart: 0.00, request: 0.00..0.00 (0.00), cloud: 0.00..0.63 (0.63), response: 0.63..0.63 (0.00)] }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
200 NO ERROR
x-content-type-options: nosniff
Content-Type: application/json
content-security-policy: frame-ancestors 'none'
Date: Tue, 14 Nov 2023 23:02:36 GMT
x-frame-options: DENY
x-request-id: D2AF9AAD-4BCA-41F4-9980-35D343B926CF
x-graph-version: 5.0.0-alpha.2+552b87654
Vary: Origin

{
  "value": [
    {
      "driveAlias": "virtual/shares",
      "driveType": "virtual",
      "id": "a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668",
      "name": "Shares",
      "root": {
        "eTag": "DECAFC00FEE",
        "id": "a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668",
        "webDavUrl": "https://ocis.ocis-wopi.latest.owncloud.works/dav/spaces/a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668"
      },
      "webUrl": "https://ocis.ocis-wopi.latest.owncloud.works/f/a0ca6a90-a365-4782-871e-d44447bbc668$a0ca6a90-a365-4782-871e-d44447bbc668"
    },
    {
      "driveAlias": "personal/admin",
      "driveType": "personal",
      "id": "71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74",
      "lastModifiedDateTime": "2023-11-14T17:51:30.060115701Z",
      "name": "Admin",
      "owner": {
        "user": {
          "displayName": "",
          "id": "e90424c7-1bdb-4512-9e05-cba6b6ffbb74"
        }
      },
      "quota": {
        "remaining": 27148849152,
        "state": "normal",
        "total": 0,
        "used": 540925
      },
      "root": {
        "eTag": "\"a62df2dccd83d865246053818b1616de\"",
        "id": "71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74",
        "webDavUrl": "https://ocis.ocis-wopi.latest.owncloud.works/dav/spaces/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74"
      },
      "webUrl": "https://ocis.ocis-wopi.latest.owncloud.works/f/71135097-2849-442b-b3d8-7701539e8cf5$e90424c7-1bdb-4512-9e05-cba6b6ffbb74"
    },
    {
      "driveAlias": "project/test-space",
      "driveType": "project",
      "id": "71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7",
      "lastModifiedDateTime": "2023-11-14T12:28:40.615466025Z",
      "name": "test space",
      "owner": {
        "user": {
          "displayName": "",
          "id": "13e07352-d7e5-42e1-9a4d-2d926dfb4ec7"
        }
      },
      "quota": {
        "remaining": 999999954,
        "state": "normal",
        "total": 1000000000,
        "used": 46
      },
      "root": {
        "eTag": "\"3c9ef1515aaa323eaf9489f39da1d96c\"",
        "id": "71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7",
        "permissions": [
          {
            "grantedToIdentities": [
              {
                "user": {
                  "displayName": "Admin",
                  "id": "e90424c7-1bdb-4512-9e05-cba6b6ffbb74"
                }
              }
            ],
            "roles": [
              "manager"
            ]
          }
        ],
        "webDavUrl": "https://ocis.ocis-wopi.latest.owncloud.works/dav/spaces/71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7"
      },
      "special": [
        {
          "eTag": "\"ddb6a24fcc117154565d3c1b239eb5b1\"",
          "file": {
            "mimeType": "text/markdown"
          },
          "id": "71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7!74942287-e186-4c09-9a57-c01bde822867",
          "lastModifiedDateTime": "2023-11-14T12:24:30.645807334Z",
          "name": "readme.md",
          "parentReference": {
            "driveId": "71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7",
            "driveType": "project",
            "id": "71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7!d933176a-c2d4-4827-9858-bc1948c81aac"
          },
          "size": 46,
          "specialFolder": {
            "name": "readme"
          },
          "webDavUrl": "https://ocis.ocis-wopi.latest.owncloud.works/dav/spaces/71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7%2113e07352-d7e5-42e1-9a4d-2d926dfb4ec7/.space/readme.md"
        }
      ],
      "webUrl": "https://ocis.ocis-wopi.latest.owncloud.works/f/71135097-2849-442b-b3d8-7701539e8cf5$13e07352-d7e5-42e1-9a4d-2d926dfb4ec7"
    }
  ]
}

So that the resolution fails at that point with an internal "unknown drive" error:

2023-11-15 00:20:41.879000+0100 ownCloud[36623:6310170] 🛑 | [CONN, Drives] Path for WebDAV endpoint for driveID 71135097-2849-442b-b3d8-7701539e8cf5 could not be generated: unknown drive

@felix-schwarz
Copy link
Contributor

I've updated the PR for feature/account-wizard with the latest SDK which adds support for <oc:spaceid>.

@jesmrec
Copy link
Contributor Author

jesmrec commented Nov 15, 2023

I still get Resolution Link error with latest commit.

ownCloud_15_Nov_2023_at_10_10_00.log.txt

@michaelstingl
Copy link
Contributor

michaelstingl commented Nov 20, 2023

@jesmrec please check if it's fixed with the latest backend:

[Log]  ownCloud Web UI 8.0.0-alpha.8  (index.html-dac79322.mjs, line 1)
[Log]  Infinite Scale 5.0.0-alpha.2+b3e658cf8 Community  (index.html-dac79322.mjs, line 1)

@jesmrec
Copy link
Contributor Author

jesmrec commented Nov 21, 2023

Problem regarding spaceid for Link resolution error is fixed as:

ownCloud Web UI 8.0.0-alpha.9 index.html-qmmJHXdx.mjs:1:453410
 Infinite Scale 5.0.0-alpha.2+279d0f856 Community

@jesmrec
Copy link
Contributor Author

jesmrec commented Nov 21, 2023

(2)

(maybe expected)

  1. Open the app
  2. Open Settings view
  3. With the app open in Settings view, go to the place in which link will be clicked
  4. Click the link and OPEN from the web

Current: Settings view on the screen. Clicking on Done removes the view and shows the file
Expected: Settings view dismissed to show the linked item

RPReplay_Final1700571348.MP4

iPhoneXR v17.2
a27068d6

@jesmrec
Copy link
Contributor Author

jesmrec commented Nov 21, 2023

(3)

  1. Open a valid link over a cached item
  2. Remove device connection
  3. Open again the valid link over the same cached item

Current: following error is displayed:

Screenshot 2023-11-21 at 17 43 09

device is offline but file is cached. Here a video:

RPReplay_Final1700585106.MP4

iPhoneXR v17.2
a27068d6

felix-schwarz added a commit that referenced this issue Nov 23, 2023
@felix-schwarz
Copy link
Contributor

felix-schwarz commented Nov 23, 2023

@jesmrec (2) revealing a private link's location regardless of where in the app a user currently is would take a lot of effort with little to gain. Since it's not expected, I'd leave it as-is for now and only make changes here if there turns to be respective expectations from enough users.

(3) Fixed in dab3ab4 in #1274.

@jesmrec
Copy link
Contributor Author

jesmrec commented Nov 24, 2023

(2) -> won't fox
(3) -> fixed

as today, testing only in instances which returns spaceid in a correct way from the meta endpoint

From my side, this is healthy and OK to go.

@jesmrec jesmrec closed this as completed Nov 27, 2023
hosy added a commit that referenced this issue Jan 29, 2024
* removed the logo label from the sidebar navigation bar to have more space for the logo image

* - fix #1254

* Example JSON + README (#1255)

Co-authored-by: Michael Stingl <git@michaelstingl.com>

* Cleanup of Theming folder (#1260)

* Remove old PLIST examples

* move ownCloud.online theme + assets

* move EMM assets

* Adjust Fastfile for moved themes + assets

* updated to Xcode 14.3

* move all app resources to the correct place in one copy command

* updated to 14.3.1

---------

Co-authored-by: Michael Stingl <git@michaelstingl.com>
Co-authored-by: Matthias Hühne <github@hosy.de>

* - FileProvider: fix enumerator queue completion slowdown/blocking

* - show vendor label in the sidebar if app is unbranded
- added accessibility label to the logo image

* - FileProvider cleanup and additional debug logging

* - BottomButtonBar: avoid collapse of selectButton (fixes owncloud/enterprise#5889)

* - add background image to welcome screen
- add support for RGBA hex values to CSS

* - change welcome screen background default color from dark to bright

* - BookmarkViewController: add .bookmarkEditor CSS selector

* - ThemeCSS: add support for $cssSelector.cssProperty

* Assets.xcassets/AppIcon.appiconset generated with fastlane + welcome screen background (#1264)

* - add background image to welcome screen
- add support for RGBA hex values to CSS

* Assets.xcassets/AppIcon.appiconset generated with fastlane

* align icon name with branding

---------

Co-authored-by: Felix Schwarz <fs-git@iospirit.com>
Co-authored-by: Michael Stingl <git@michaelstingl.com>

* - change welcome screen background default color from dark to bright

* Assets.xcassets/AppIcon.appiconset generated with fastlane

* rename vanilla appiconset again for fastlane changes

* - ThemeCSS+SystemColors: add convenience methods to easily add CSS records for colors, incl. a set of system colors
- ThemeCollection: add system colors (f.ex. UIColor.systemBlue as `os.color.blue`) and theme base colors (as `theme.color.light` and `theme.color.dark`) to CSS object

* Vanilla: change welcome screen background default color from bright to dark

* - BookmarkViewController:
	- add permanent logo branding to top of the view
	- make branding elements use same CSS selectors as welcome screen
- ComposedMessageView: make CSS selectors extension public
- RoundCornerBackgroundView: add new .fillImage property that allows filling the view with an image with "scaleAspectFill" contentMode

* - BookmarkViewController: remove table view background image from branded builds

* - RoundCornerBackgroundView: fix bug in sizeThatFills()

* - DisplayViewController: handle nil OCQueryChangeSet.queryResult (should fix crash reported in #1245 (comment))

* fixed missing translation strings or localized function

* fixed bug in sidebar: label color got the same color as background color and label was not readable, if lightBrandColor was similar to #000000

* - FileProviderExtension: add safeguards around `[NSError fileProviderErrorForNonExistentItemWithIdentifier:]` for the case that iOS (illegally) passes in a nil `identifier`, leading to a crash in said NSError method

* [fix/overlapping-sharing-buttons] Overlapping Sharing Buttons (#1248)

* [fix/passcode-device-enforced] MDM Parameter - Enforce Passcode Setup (#1249)

* [fix/sidebar-logo] Sidebar Logo (#1247)

* [translation-sync] Translation sync (#1250)

* - minimal change to reopen PR

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* - revert minimum change to THIRD_PARTY.txt

* [tx] updated from transifex

* - fixed UTF issues
- fixed missing german translations

---------

Co-authored-by: Felix Schwarz <fs-git@iospirit.com>
Co-authored-by: ownClouders <devops@owncloud.com>

* - update SDK

* - update SDK to update error message for OCErrorAuthorizationNoMethodData

* - add "An error occurred" to Localizable.strings

* - SDK update with updated strings

* GH workflows:
- add LocalizationTests with automatic UTF-16 to UTF-8 conversion

* - GitHub workflows: move new GH workflow out of workflows folder to avoid permission issue
- fix non-empty Branding.plist

* Translation sync (#1269)

* - minimal change to reopen PR

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* - revert minimum change to THIRD_PARTY.txt

* [tx] updated from transifex

* - fixed UTF issues
- fixed missing german translations

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* - fix file encoding for en-GB.lproj/Localizable.strings

---------

Co-authored-by: Matthias Hühne <github@hosy.de>
Co-authored-by: ownClouders <devops@owncloud.com>

* - update ios-sdk to gain ocstringstool
- remove LocalizationTests.swift
- remove UTF-8/16 enforcements for .strings files from ownCloud.xcodeproj
- add tools/normalizestrings based on ios-sdk/ocstringstool
- update GH action (now normalize-strings.yml)
- normalize strings files to UTF-8

* - update release notes for 12.0.3

* - NSObject+ThemeApplication: fix wrong label colors for ThemeCSSLabels that are also subject to NSObject.applyThemeCollection() calls

* - AppRootViewController + InitialSetupViewController: move initial setup view into own view controller
- InitialSetupViewController: implement status bar style support for consistent status bar colors also pre-iOS 17

* - fix iOS 17 initial setup color issue

* - address owncloud/core#40953 (comment) via SDK update

* - fix: rename of a bookmark is not always reflected in the account list

* - BottomButtonBar: adapt layout dynamically to size class, placing the promptText above the buttons in any but regular horizontal class size and stretching the buttons to fill the space beneath it

* - ClientSidebarViewController: properly initialize accountsControllerSectionSource with item version tracking

* - fix SwiftLint warnings

* - BookmarkViewController: add modern password manager integration to BookmarkViewController via input field content types

* - SDK update: OCHTTPPipeline: move metrics logging to response logging block

* - SDK update for better formatted metrics line

* SDK rebase

* - add BookmarkComposer
- add BookmarkSetupViewController UI for BookmarkComposer
- other improvements

* - BookmarkComposer: fix progress reporting, complete infinite PROPFIND implementation
- BookmarkSetupStepPrepopulateViewController: implement infinite PROPFIND UI
- BookmarkSetupStepViewController: allow updating the continue button label through .continueButtonLabelText
- BookmarkSetupViewController: add CSS support for status bar style

* - BookmarkComposer:
	- add optional .intro step and support in configuration
	- differentiate between user and internal actions when recording undo actions
- BookmarkSetupStepIntroViewController: new intro view controller
- AppRootViewController: use new BookmarkComposerConfiguration.hasIntro option

* - Bookmark Composer:
	- add support for help button + label
	- add support for settings in .intro step
	- add basic theming support (WIP)
	- auto-focus on URL and username fields

* - adopted step names
- skip completed step if editing account is not allowed

* respect can add account for adding toolbar button

* - changed account css values to support system dark mode
- moved logo image from the intro screen into the general account view
- added navigation bar in account view (visible, if cancel button is visible)
- removed title "Account Setup" and app name in branded client

* - BookmarkSetupViewController:
	- add step-specific CSS selector
	- move logo on top of the step views and center both together vertically
	- replace UINavigationBar subview usage with UINavigationItem usage
	- rename step from .oidc to .authenticate because the step covers all auth methods, not just OIDC
	- use BookmarkComposerConfiguration.nameEditable to skip completed view instead of Branding.shared.canEditAccount directly
	- allow setting custom title and message for every step through locale.overrides
	- remove .headerTitle since it is no longer used
	- clean up code
- BookmarkComposerConfiguration: make newBookmarkConfiguration use Branding.shared.canEditAccount for .nameEditable
- BookmarkSetupStepViewController:
	- add support for moving focus and continue to the next step when pressing the return key
	- adopt in subclasses via the new .focusTextFields property
- BookmarkViewController: wrap BookmarkSetupViewController in a ThemeNavigationController to add a standard navigation bar on top when adding an additional account
- fix CSS color errors

* - BookmarkComposer:
	- improve error handling in .enterURL step (fixing finding (3) in #1274)
	- also clear certificates when returning to .enterURL step (fixes displaying a certificate for a different server if a https server was chosen, then the user went back and changed the URL to a plain HTTP URL)
- BookmarkComposerConfiguration: make .hasIntro default to false (=> no longer shows the intro screen when adding additional bookmarks)
- BookmarkSetupStepViewController: add .cacheViewController property to allow signaling BookmarkSetupViewController that the view controller should not be cached
- BookmarkSetupStepAuthenticateViewController: opt out of view controller caching
- ThemeCollection: restore changes from 09e63b9 as comments

* - ThemeCollection: restore changes from 09e63b9, keep previous state as comments

* - Branding+App: add .certificateSummary CSS selector
- CertificateSummaryView:
	- configure button to use a clear background color
	- make addressable via CSS .certificateSummary
- ThemeCollection: make .certificateSummary default to a clear background color

* - ownCloud.xcodeproj: fix Xcode 15 build errors
- BookmarkComposer: pre-fill user name from server locator in subsequent token-based auth (fix finding (4) in #1274)
- AccountControllerCell: fix layout issue where the eject button would get compressed to 0px for long user names (fix finding (5) in #1274)

* Configuration documentation updated

* - remove unused/replaced InitialSetupViewController
- Branding:
	- introduce BrandingAssetSuffix type and new method to retrieve image with suffix where available
	- rename BrandingImageName.loginLogo and .loginBackground to .brandLogo and .brandBackground
	- add new BrandView to standardize display of logo, background and background color
- add BrandView to top of side bar
- BookmarkSetupViewController: add background view for hud message view and align font with steps

* - AccountControllerCell: set content view height with priority .defaultHigh, fixing a conflicting constraints message

* generate.sh for easy theme generation (#1281)

* genrate.sh for easy theme generation

* check if script is executed in the correct path

* changed wording

---------

Co-authored-by: Michael Stingl <git@michaelstingl.com>
Co-authored-by: Matthias Hühne <github@hosy.de>

* - Branding
	- rename "branding-login-background.png" to "branding-background.png" and add transient fallback for old name
	- rename "branding-login-logo.png" to "branding-logo.png" and add transient fallback for old name
	- BrandView: ensure BrandView can't be selected in the sidebar by adding compliance with DataItemSelectionInteraction, also fixing rectangular edges
- BookmarkSetupStepViewController: use themed buttons
- ThemeCollection: update CSS records for BookmarkSetupStepViewController to no longer use dynamic system colors
- BookmarkSetupViewController: fix constraints warning for .contentView
- Localizable.strings: add missing "Enter password" string to
- Fastlane/Building: rename "app.version-number" build setting to "build.version-number" and add MDM documentation

* Configuration documentation updated

* - OCShare+UniversalItemListCellContentProvider: add "Decline" button to Accepted "for me" shares
- ClientActivityViewController/MessageView: set a lower compression resistance for secondary text (message) to fix view controller expansion beyond screen size (per reports)
- Localize "Loading…" in English and German

* - add new dark and light themes based on system colors
- use system color themes for branded clients unless they provide their own themes
- enable theme switcher for branded clients using the system color themes
- add new and fine-tune existing CSS records

* - BookmarkSetupViewController
	- limit logo height to better fit screen height
	- no longer show logo when adding additional accounts to make up for the lost space due to the UINavigationBar being included, to work across all screen heights

* - AppRootViewController: forward supported interface orientations and use of iOS 16 API to tell the OS of changes
- BookmarkSetupViewController: limit to portrait orientation
- SceneDelegate: no longer add root view controller's view manually, "fixing" a console message that informs this is no longer supported
- OCAction+UIAction: add convenience method that builds a UIAction from a OCAction
- NSObject+ThemeApplication: code cosmetics
- ThemeCollection: add new CSS records for navigation bar popup icon colors
- ThemeNavigationController: add support for forwarding supported interface orientations
- ClientLocationPopupButton: new, re-usable button view that provides a breadcrumb view for a given OCLocation
- DisplayViewController / DisplayHostViewController:
	- add location breadcrumb dropdown title
	- fix broken KVO observation that led to a lack of dynamic UI updates
- ClientItemViewController:
	- add location breadcrumb dropdown title (iPad only due to lack of horizontal space on iPhone)

* - Branding: add support for branding.theme-tint-color to allow providing a tint color to replace the standard iOS tint color

* - workaround build issue on Xcode 14.2 (GitHub actions), preventing documentation updates

* Configuration documentation updated

* - BookmarkSetupViewController: snap width of progress hud to 400 points - in line with the rest of the interface, to look consistent on iPad with larger screen widths

* # Branding changes:
## Default theme
- now uses `Follow system appearance` rather than "first theme" by default

## Dynamic choice of branding assets
- moved pristine app branding assets to `com.owncloud.ios-app` folder
- added new `branding-assets folder
- removed individual branding-*.png assets from Xcode project file
- renamed assets in `online.owncloud.ios-app` to match new name conventions
- added new build phase copying branding-*.png assets from
	- `com.owncloud.ios-app` if `branding-assets` contains no files matching `branding-*.png`
	- `branding-assets` if `branding-assets` contains files matching `branding-*.png`
	- integration via input and output xcfilelists

## BrandView changes
- when showing the background, no longer choose between either the background color OR the background image, but show both if a background image is provided; adding support for background images with alpha channel

## Branding parameter extension and cleanup
- added `branding.theme-css-records`:- new MDM/branding parameter to provide an array of CSS record strings that are interpreted and added to the CSS space of system-color-based themes for branded clients. Mutually exclusive with theme-definitions.
- removed `branding.theme-generic-colors`: no longer used
- removed code for (generic) `Colors` from `branding.theme-definitions`: no longer used

* Configuration documentation updated

* Branding changes:
- remove branding.theme-tint-color to include it into a new option
- add branding.theme-colors as an abstraction layer for commonly customized colors (allows custom handling and f.ex. using a single color for creating multiple CSS records in the future)
- allow "black" and "white" as status bar styles

Documentation changes:
- update configuration.adoc.tmpl to support new "possibleKeys", used for the first time in branding.theme-colors

* Configuration documentation updated

* - Branding+App: documentation/description changes

* Configuration documentation updated

* - consistently use branding-splashscreen-[logo|background].png
- AppRootViewController: pass-through for .preferredInterfaceOrientationForPresentation to contentViewController

* - AccountSettingsProvider: use Branding instead of UIImage() directly

* - remove `branding-bookmark-icon.png` and fill those edge case places where it was used with `BrandView`

* - remove last reference to branding-bookmark-icon.png
- add target path for optional branding-sidebar-link-icon.png
- run com.owncloud.ios-app branding assets through ImageOptim, reducing size by 70% to 95%

* - AccountController: add support for DataItemDropInteraction
- LocalDataItem: make properties publicly
- ClientSidebarViewController: add support for reordering accounts via drag & drop
- SDK update

* - ThemeCollection: make TVG files use default colors extracted from original SVG files

* - add additional color selectors for additional TVG placeholders for: office document, office presentation, office spreadsheet, PDF files
- allow setting all file icon colors to the same color at once via "file-icon-color"

* - remove AccountSettingsProvider (`account-settings.*`) and use equivalent settings from `branding.*` instead
- Branding+App: fix indentation and add default value for `branding.profile-allow-url-configuration`

* - ClientSidebarViewController: add `self.` to allow compilation with Xcode 14 (CI)

* Configuration documentation updated

* - DataSourceCondition: only perform initial call after a .fulfilled value could be determined for the first time (fixing crash/finding 8 in #1274)

* - ThemeCollection: correctly map office document color
- change officeFileFillColor to documentFileFillColor

* - SDK update: no longer fail validation of entire dictionary if there is a key that's not included in the list of possible keys

* - update SDK to add support for <oc:spaceid> when resolving private links

* - SDK update to fix #1128

* - update SDK to fix #1299

* Calens changelog updated

* - update SDK to add support for local resolution of ocis private link (fixes fix finding (3) in #1295)

* - ShareViewController: add support for entering and editing names of link shares

* - update SDK (fix (2) in #1297)
- OCShare+UniversalItemListCellContentProvider: show token instead of "Link" as placeholder for unnamed links (fix (3) in #1297)
- ShareViewController:
	- show token instead of "Link" as placeholder for unnamed links (fix (3) in #1297)
	- fix layout issue for name text field (fix (1) in #1297)

* - UniversalItemListCell: add new Content.iconWidth property to control icon width in the universal cell, with fallback to defaults
- OCShareRole+UniversalItemListCellContentProvider: adapt icon width to size of option icons in ShareViewController

* - update SDK to gain OCAppIdentity convenience URL schemes property
- CancelLabelViewController: allow customizing the button label and use a proper type for the cancelAction
- DocumentActionViewController:
	- refactor to allow custom button label and custom action
	- show message and open app if no account has been set up in the app yet

* - add localizable strings

* - update SDK
- update Theme/CSS/README.md with documentation and examples on branding.theme-css-records, branding.theme-colors; add examples in flat notation

* - add VisionKit text / machine-readable code / visual look up integration to image viewer (requires iOS 16+)

* - add action.allow-image-interactions. To disable Image Interactions, set action.allow-image-interactions = false

* [feature/suffix-protection] File extension / suffix protection (#1298)

* - NamingViewController: add option .requiredFileExtension that enforces a particular suffix when set
- CreateDocumentAction: take advantage of NamingViewController.requiredFileExtension to prevent changing file suffix for new files

* - ThemeCSSTextField: add support for requiring a file extension (.requiredFileExtension)
- NamingViewController: remove delegate code for .requiredFileExtension and use ThemeCSSTextField.requiredFileExtension instead
- StaticTableViewRow: add support for requiring a file extension (.requiredFileExtension) based on ThemeCSSTextField.requiredFileExtension
- ScanViewController: use StaticTableViewRow.requiredFileExtension to prevent deletion of required file extension

* - ios-sdk update: fixes crash (finding #1 in #1298)
- ScanViewController, NamingViewController: when enforcing file suffixes: prevent choice of filenames consisting just of a suffix (since these would be hidden files) by disabling the primary action button

* Calens changelog updated

---------

Co-authored-by: felix-schwarz <felix-schwarz@users.noreply.github.com>
Co-authored-by: Matthias Hühne <github@hosy.de>

* using correct ios-sdk commit

* - ClientItemViewController: do not show breadcrumb dropdown for root folder
- ClientLocationPopupButton: add excludeLastPathComponent option to exclude last path component from the popup's breadcrumbs
- OCLocation+Breadcrumbs: for OC10 hosts, add the account's root folder to the breadcrumbs if drive name should be included

* added remove extensions shell script if passed by app build flags

* added new remove extension shell script to remove a target from the given ipa file

* Update BUILD_CUSTOMIZATION.md with new build flag

* [fix/fp-fixes] File Provider fixes (#1294)

* - SDK update for less verbose logging
- FileProviderExtension: log thumbnail requests
- FileProviderExtensionThumbnailRequest:
	- fix retain cycle that could prompt the Files.app to repeatedly ask for thumbnails of files that don't have any
	- if no image was found, return a nil error rather than OCErrorInternal
- ownCloud File Provider xcscheme: update logging configurations/env variables and enable malloc stack logging

* - FileProviderExtension: change log level of core[enter|leave] messages to verbose

* new app and build version

* - update SDK to include JSON logging (owncloud/client#11224)

* [feature/share-action-extension] Share Action Extension "Save to ownCloud" (#1301)

* #1293 added a share action extension "Save to ownCloud"

* Calens changelog updated

* adopted fastlane code signing for new target "ownCloud Action Extension"

* adopted the resign script and resign inspector for new action extension

* - added action extension
- fixed wrong emm identifier

* fixed adding default bundle display name

* replace CFBundleDisplayName in action extension with branded app name for english and german localisations

* Update fastlane/Fastfile

Co-authored-by: Felix Schwarz <fs-git@iospirit.com>

---------

Co-authored-by: hosy <hosy@users.noreply.github.com>
Co-authored-by: Felix Schwarz <fs-git@iospirit.com>

* fixed disabling edit mode in markup document on iOS 17 (#1309)

* - copying branded action extension icon into the correct branding assets folder
- set a custom icon for the action extension target

* update Xcode version for development VM

* escape spaces in shell command path

* set correct file path in shell command

* escape path in fastlane shell command

* fixed variable name in fastlane file

* assigned final Xcode version for the release

* only copy branding-action-extension-icon.png icon if available

* fixed issues with fastlane app icon creation for branded builds

* Added changelog files for version 12.1

* Calens changelog updated

* added 12.1 in-app release notes

* updated changelog file

* Calens changelog updated

* added app store release notes

* - change SDK commit from develop to corresponding master commit after rebase

* fixed app icon path generation in fastlane file

* Removed tmp AppIcon assets

* copy Branding.plist file for oC.online build to correct path

* updated app version number

* added missing localisation strings

* updated app version number

* Update SDK to add authentication-oauth2.omit-authorization-parameters option to allow omitting parameters from authorization requests (implements #1318)

* added EMM suffix to ownCloud EMM app

* removed unneeded color values from oC.online app

* removed light and dark themes and set their identifier for system light and system dark. Allow theme selection for all clients.

* - fixed theme key names
- removed allowed authentication methods
- added more allowed hosts

* removed unneeded icon files (duplicated)

* using new branding theme key names

* new build number

* - fixed switching dark/light themes
- updated build number

* use new app name "ownCloud EMM" for EMM version

* Translation sync (#1317)

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

* [tx] updated from transifex

---------

Co-authored-by: ownClouders <devops@owncloud.com>

* Calens changelog updated

* - updated app store and in-app release notes
- changed changelog release date

* Calens changelog updated

* added missing release notes entry

---------

Co-authored-by: Matthias Hühne <github@hosy.de>
Co-authored-by: Michael Stingl <214010+michaelstingl@users.noreply.github.com>
Co-authored-by: Michael Stingl <git@michaelstingl.com>
Co-authored-by: Matthias Hühne <mhuehne@owncloud.com>
Co-authored-by: ownClouders <devops@owncloud.com>
Co-authored-by: felix-schwarz <felix-schwarz@users.noreply.github.com>
Co-authored-by: hosy <hosy@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p2-high Escalation, on top of current planning, release blocker
Projects
None yet
Development

No branches or pull requests

3 participants