InteropIO / wedbush-io-browser

0 stars 0 forks source link

How to include a website without iConnect lib #2

Open pedro-young-wedbush opened 2 weeks ago

pedro-young-wedbush commented 2 weeks ago

@bogdandinchev

We need to include the third-party sites in AIW Browser Platform. You can use https://bluemetrics.com.br/ as an example.

bogdandinchev commented 2 weeks ago

@pedro-young-wedbush

The reason why some third party websites can't load is because of Content-Security-Policy. A site can set its 'frame-ancestors' directive to 'self' and only known domains, which fodbids it to be embedded in other places (including our windows in the workspace). Unfortunately... not much can be done about that.

There is a plan to bypass this with a browser extention a few months in the future (but still it is not a 100% reliable option, because there are other mechanism that can prevent embedding). For now you will have to check which sites can/can't be embedded manually.

For example - https://bluemetrics.com.br/ allows itself to be embedded, but google/cnn/linkedin for example don't

pedro-young-wedbush commented 2 weeks ago

Is there a way to set third-party apps to open in a new browser tab as an alternative?

bogdandinchev commented 2 weeks ago

I have updated the master branch with an example for opening an external app as a new window in the custom section: https://github.com/InteropIO/wedbush-io-browser/commit/6cadd5b4d8429fc233a0535bdaff6b10fe3a316a

You can read more on window management in the docs here: https://docs.interop.io/browser/capabilities/windows/window-management/index.html#overview

In the default section there is a menu on each item, which gives the option to open in a new window: [cid:ba6bba33-8fea-4947-a41f-891741e82d8c]

Regards,

[cid:4700b394-144b-4346-b728-5a8c411d1605]

Bogdan Dinchev

Consultant

@.***


From: pedro-young-wedbush @.> Sent: Thursday, August 29, 2024 5:45 PM To: InteropIO/wedbush-io-browser @.> Cc: Bogdan Dinchev @.>; State change @.> Subject: Re: [InteropIO/wedbush-io-browser] How to include a website without iConnect lib (Issue #2)

Is there a way to set third-party apps to open in a new browser tab as an alternative?

— Reply to this email directly, view it on GitHubhttps://github.com/InteropIO/wedbush-io-browser/issues/2#issuecomment-2317931780, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BFLNGQ7MMFKZN5KOF7LJZV3ZT4XYBAVCNFSM6AAAAABNIOZGRSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMJXHEZTCNZYGA. You are receiving this because you modified the open/close state.Message ID: @.***>

pedro-young-wedbush commented 2 weeks ago

@bogdandinchev - Also instead of a popup window, can it be opened as a new tab?

image

bogdandinchev commented 2 weeks ago

We can use the browser api to open the window in a new tab:

https://github.com/InteropIO/wedbush-io-browser/commit/308bacad6aff5b1a0be61d70703a6e1a776eb6ab

[cid:f9d6f8c6-6fa4-406d-8a52-0e8d74d7cd66]

Bogdan Dinchev

Consultant

@.***


From: pedro-young-wedbush @.> Sent: Friday, August 30, 2024 6:20 AM To: InteropIO/wedbush-io-browser @.> Cc: Bogdan Dinchev @.>; State change @.> Subject: Re: [InteropIO/wedbush-io-browser] How to include a website without iConnect lib (Issue #2)

Also instead of a popup window, can it be opened as a new tab?

image.png (view on web)https://github.com/user-attachments/assets/ef6113d6-265d-4b34-833c-7d85ad17fc1a

— Reply to this email directly, view it on GitHubhttps://github.com/InteropIO/wedbush-io-browser/issues/2#issuecomment-2319877230, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BFLNGQZ4PLU6TRLPGH2RYXLZT7QJXAVCNFSM6AAAAABNIOZGRSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMJZHA3TOMRTGA. You are receiving this because you modified the open/close state.Message ID: @.***>