feat: Allow filtering in ConstantConverter based on type - #925
Conversation
|
Thanks! Can you document how it is used? I tried {
"comment": "Serve the Mashlib Data Browser as default container representation",
"@id": "urn:solid-server:default:DefaultUiConverter",
"@type": "ConstantConverter",
"filePath": "./node_modules/mashlib/dist/databrowser.html",
"contentType": "text/html",
"options_minQuality": 1,
"options_container": true,
"options_document": true,
"options_disabledMediaRanges": ["application/pdf"]
} |
|
That looks good! You're running v1.1.0? |
|
Yes I am running v1.1.0. Turns out the option works fine, but the problem lies in ACL / authentication. If I grant public access to the PDF I can load it in the browser, but if the access is restricted it serves the data browser. |
|
Super, that was the intended behavior, because Databrowser has a UI that helps you sign in. |
|
Not sure if the behaviour is really intended like that, because even after signing in via UI I am getting served the HTML, not the raw PDF. I guess this is because the browser's get request ist getting a 401 still, since it does not include an Authorization header and plain cookies are not supported? (I tried with a data browser that is using @inrupt/solid-client-authn-browser, so this is not an issue with old-style auth) |
Yes, Databrowser is currently not compatible with the Solid specification; there is an active branch that is adding support, expected in the next couple of weeks. |
Closes #896.