xireso / google-power-search

A helper that automatically generates a google search string using google supported operators
Apache License 2.0
11 stars 2 forks source link

[Feature Request/Customisation Question] Adding additional 4 character file types for the newer Office documents (e.g. docx) #6

Open ghost opened 3 years ago

ghost commented 3 years ago

This is an amazing tool overall, but I was looking to add .docx, .xlsx and .pptx to the narrow down and exclude by file types lists.

I am not a programmer, but just try to use some common sense to do things.

I find this in index.html:

I cannot find any other references in index.html, main.js or styles.css to "doc" or "doc-file-narrow", so I tried to edit it to:

When I do this, a docx option does show on the page, but when clicked, it adds -filetype:docx to the search string even though this is in the narrow down and not the excude section

I saw a file type length set to 3 in main.js which I changed to 4 but the docx issue is not fixed, and now a hyphen is added to the end of all of the 3 character file type strings, like filetype:txt-

I can't see anything else I can change and my knowledge stops here.

Is there any way to add my own 4 character file type button of my own or shall I just always manually type it as a custom type?

Thanks

Lewis8379 commented 3 years ago

I have found myself needing this functionality too recently, and I have had to type in the extension manually. Would love to be able to add my own custom ones easily!

stevestar888 commented 3 years ago

Will look into it @Lewis8379