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

Payment Handler spec defines IDL types very similar to manifest #652

Closed
kenchris opened this issue Feb 7, 2018 · 4 comments
Closed

Payment Handler spec defines IDL types very similar to manifest #652

kenchris opened this issue Feb 7, 2018 · 4 comments

Comments

@kenchris
Copy link
Collaborator

kenchris commented Feb 7, 2018

ie.

Manifest: https://www.w3.org/TR/appmanifest/#imageresource-and-its-members

dictionary ImageResource {
    required USVString src;
             DOMString sizes;
             USVString type;
             USVString purpose;
             USVString platform;
};

Payment Handler: https://w3c.github.io/payment-handler/#dom-imageobject

dictionary ImageObject {
    required USVString src;
             DOMString sizes;
             DOMString type;
};

Unfortunately they are also slightly different, ie the use of USVString vs DOMString

@marcoscaceres
Copy link
Member

Yeah, we need to get Payment Handler to use our definitions... working on this. The problem is that the manifest format might not work well for the API... basically the enum issue we identified earlier (it might not affect us here, but might bite us elsewhere!).

We need to sort all that out. We also need to define how to fetch an image without passing in the manifest.

cc'in @agektmr, as he mentioned this issue in #233 and might find this discussion interesting.

@marcoscaceres
Copy link
Member

To be clear, we need to generalize the algorithms or we need to find other specs that handle this kind of thing already (e.g., web notifications handles ImageResource type things). We need to bring all those pieces together, so we don't have duplicates "this is an image" and "this is how you fetch it" in lots of different places in the platform.

The current situation is not ideal.

@kenchris
Copy link
Collaborator Author

kenchris commented Feb 8, 2018

I totally agree.

@marcoscaceres
Copy link
Member

Closing as there is no action here... will follow up on the Payment Handler side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants