Show HN: I made a web-based notepad with a built in unit calculator (numpad.io)
Hi HN
It also supports percentages, dates and variables.
I've been working on this alone for a few years now, so would love to get some feedback.
It also supports percentages, dates and variables.
I've been working on this alone for a few years now, so would love to get some feedback.
245 comments
[ 3.0 ms ] story [ 121 ms ] threadgreat work, bookmarked.
"Share doc" is not clear imo. Why not "Save & Share"?
Looks much like the original idea behind lighttable IDE which is basically a REPL plugin that allows to evaluate certain lines within it. There are several similar projects around.
I was a big fan of Light Table when it first came out and the developers behind it have gone on to do some really interesting things, but I want to keep this project more limited in scope for now.
That can be an issue if you provide a limitless cloud instance, but you can roll the ball to user’s roof with client a side engine, either JS or a local instance, depending your vision for such an app.
It's still in development. I built a proof-of-concept from scratch almost a year ago, which I just open-sourced at the following link.
https://github.com/nonoesp/note-parser
I intend to develop it a bit more and host it online.
A previous prototype, really barebones, is at https://expensed.me.
The idea is to drag and drop (or type) a plain-text note and visualize the data as a scatterplot or other charts.
I've been thinking of ways to parser phone screenshots with payment data or use bank APIs to add data to my expense tracker, as opposed to adding everything manually, which is the best way I've found for consistency and to make sure everything is properly formatted.
I didn't know about PSD2. Do you have any links or references for me to look at?
Just a little bug: I found that if I click a number to copy, then click it again, I'll get the original string in my clipboard concatenated with " Copied!"
8:00pm 24 Aug Toronto time in Dubai time
And have the conversion show up.
> 1 metre + 8 chain = 161.9344 m
> 1 tonne + 1 short ton = 1.90718474 t
> 1 tonne + 1 long ton = 2.0160469 t
and give it a pass for not supporting pre 1963 UK | US historic weights and measures .. that's getting into a pretty specific use case where Standards nerds like to have a clear display of what conversion factors are in play and what provenance those factors have.
Time Zone support (on your About ToDo) will be interesting, historic computations with daytime savings support will be a quagmnire :-)
The SHARE DOC URLs seem a bit long - something like "base64 full text of doc as an URL" I guess.
Will this hit a URL length limit if widespread use becomes a thing?
jq play : https://jqplay.org/s/f1r-BZ5xYd2
regex101 : https://regex101.com/r/OqojJl/1
do server side storage and doc hash .. which has issues of its own.
there are so many reference ellipsoids and datums used in different parts of the world at different times .. and then there are the many variations on curved surface to flat map projections to deal with.
But yes - Time and date is an iceberg domain :-)
[1] https://en.wikipedia.org/wiki/Gill_(unit)
> 14 furlongs / 2 weeks in mph [0.0052083333 mph]
This reminds me of the open source NoteCalc: https://bbodi.github.io/notecalc3/
It was discussed on HN, you might look there for inspiration: https://news.ycombinator.com/item?id=25495393
As a sidenote I would like to mention that NoteCalc is still in active (but slow) development, though I do it privately, and the next big release will be definitely this year.
1. Doesn't seem to support area conversions (tried 400 square meters, 400 m^2, and abbreviations in between).
2. If I only give a time, it would be more useful if it gave a time-only result rather than defaulting to the current date - unless it rolls over to a different date. (E.g. in Soulver, "2:30pm + 20hr" gives "Tomorrow at 10:30".)
3. It would be nice to support multiple abbreviations for minutes (mn/min are both used in various countries).
... works for me.
Re dateless times, yes, I think the Soulver way is unambiguous but still human-friendly.
1. "square" before a unit I probably will implement that in the future. I'm not sure why "400 m^2" isn't working for you, I've just tried it and it works as expected for me?
2. It's a little bit clunky, but I decided to always specify the time and date being shown because there's so much potential for ambiguity. I might revisit this if I can think of a better way of doing it that's still unambiguous (the Soulver way isn't bad tbh)
3. "min" is supported, I've never come across "mn", do you know where it's used?
Minor bug report -
* 5 feet 8 inches to centimeters -> -171.72 cm
* 5 feet 8 inches to meters -> -0.7272 m
* 5 feet 8 inches to cms -> doesn't work
The conversion seems wrong in the case of cms, and I'm not sure why it's always negative.
As in (distance from) 30 to 50 (is 20 == 50 - 30 )
[0] https://jasper.monster/sharex/firefox_eXIffwiyBq.png
//EDIT
Ah yeah, replace "to" with "in" and you're good! [1]
[1] https://jasper.monster/sharex/firefox_rVKx2w1TUI.png
> * 5 feet 8 inches to centimeters -> -171.72 cm
As @defrost said, the 'to' operator instructs NumPad to calculate the distance from the unit before 'to' and the unit after 'to'.
To the nearest mm, 5 feet 8 inches = 172.72cm
It appears that NumPad is defaulting to a value of '1' where no value is specified, so it is calcuating the distance BACK from '5 feet 8 inches' TO '1 centimeters'.
It correctly responds with -171.72, which is 1cm less than 172.72.
> * 5 feet 8 inches to meters -> -0.7272 m
Same as above, except the calucation is the distance back from '5 feet 8 inches' TO '1 metres'.*
If you use the operator 'in', NumPad calculates the answer correctly:
5 feet 8 inches in metres -> 1.7272 m
9 - 3 ^ 2 = 0
9 -3 ^ 2 = 18 ???
pi = 3.1415926536
2 pi = 5.1415926536 ???
sin(3.1415926536 radians) = -0
sin(pi radians) = Incompatible units ???
One bit of very minor feedback:
`x^y tonnes` errors 'exponent must be unitless'. The more expected (IMO) grouping `(x^y) tonnes` works, so why not have the non-error grouping be the implied one, when no parens given?
Getting operator precedence right has been pretty fraught tbh. For example "1km / 3 hours" is evaluated as "(1km) / (3 hours)", but "1 / 3 hours" is evaluated as "(1 / 3) hours", which is odd from a PL perspective, but I think it's more intuitive from a user perspective for this sort of thing.