hr_lite 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9dc0713440cde019ffbf731932a0efef58980b58baff2ccb55991aecae807714
4
- data.tar.gz: 3cbfdca3513b1d5ce604accb369f7c63e425d98ce5efe88ad2544b070900f284
3
+ metadata.gz: 57ee911f7b4340c811de3636a4b9bef1a206e722fa1c6ff0efebdfa176e6c8cb
4
+ data.tar.gz: adbadd872c07e237addd070608991d3316db58dda3ce9fd57dee7943b546deda
5
5
  SHA512:
6
- metadata.gz: 3e6a06f68ce96bb223860cd8ddb091986207958acccdd2ee4947c066a7885e119ae7d79e954e5ca9514eabb072b7ff3da46a95cc91463a702b553979de74e1da
7
- data.tar.gz: 72e3acb4196071320611198ac549a9c5f6301182ddd882240cb12ccfb97f0257e5d21915812b48afe760b38c41addb7be15d159400bcb8d13c8bb04c2aa5d2d5
6
+ metadata.gz: c6db60f81387a610b0a9de87b19f07873f135e8872f8683ba07e2eeaef62481ab582f523296c779f3a7d43ca1d665c498a614ca2abd8ecc33500ed9228c58a4d
7
+ data.tar.gz: 2beba306b8543851c13b3a41c5a1805b1c09b35af57a88eb650b7eb14a31c4744c6b47bedc09c15100bc373762c32194301ce38fc149e9efb3b678dcd3c83621
data/CHANGELOG.md CHANGED
@@ -7,6 +7,21 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.1.1] - 2026-07-19
11
+
12
+ ### Added
13
+
14
+ - `bin/demo`: one-command sandbox — fresh sqlite database, engine
15
+ migrations from the gem, rich sample data (three persona tiers,
16
+ attendance history, leaves, kudos, a published payroll run, a shared
17
+ appraisal) and a click-to-sign-in persona picker.
18
+
19
+ ### Fixed
20
+
21
+ - `hrl_money` Indian digit grouping (₹3,69,000.00 — previously mis-grouped).
22
+ - Layout `<title>` uses the configured company name instead of a
23
+ hardcoded brand.
24
+
10
25
  ## [0.1.0] - 2026-07-19
11
26
 
12
27
  Initial release.
data/README.md CHANGED
@@ -21,6 +21,18 @@ promotions. Think Keka-lite, mounted inside your existing app in a few lines.
21
21
  - **Encrypted at rest**: PAN/UAN/bank numbers and every money amount use
22
22
  ActiveRecord encryption.
23
23
 
24
+ ## Try it in one command
25
+
26
+ ```bash
27
+ git clone https://github.com/kshtzkr/hr_lite && cd hr_lite
28
+ bin/demo # → http://localhost:3999
29
+ ```
30
+
31
+ A throwaway sandbox boots with three persona tiers (leadership / admin /
32
+ employee — one click to sign in as each) and pre-seeded attendance, leaves,
33
+ kudos, a published payroll run and a shared appraisal. Data resets on every
34
+ restart.
35
+
24
36
  ## Installation
25
37
 
26
38
  Everything lives in the gem — a host app adds the gem, a mount line and one
@@ -69,11 +69,15 @@ module HrLite
69
69
  return "—" if amount.nil?
70
70
 
71
71
  whole, fraction = HrLite::Money.round2(amount).to_s("F").split(".")
72
- sign = whole.delete_prefix!("-") ? "-" : ""
73
- # Indian digit grouping: 12,34,567
74
- grouped = whole.reverse.scan(/\d{1,2}(?=\d{2})|\d{1,3}/).join(",").reverse if whole.length > 3
75
- grouped ||= whole
76
- "#{sign}#{HrLite.config.currency_symbol}#{grouped}.#{fraction.ljust(2, '0')}"
72
+ sign = whole.start_with?("-") ? "-" : ""
73
+ whole = whole.delete_prefix("-")
74
+ # Indian digit grouping: last three digits together, then pairs
75
+ # (12,34,567 — not the western 1,234,567).
76
+ if whole.length > 3
77
+ head = whole[0..-4].reverse.scan(/\d{1,2}/).join(",").reverse
78
+ whole = "#{head},#{whole[-3..]}"
79
+ end
80
+ "#{sign}#{HrLite.config.currency_symbol}#{whole}.#{fraction.ljust(2, '0')}"
77
81
  end
78
82
 
79
83
  ONES = %w[zero one two three four five six seven eight nine ten eleven twelve thirteen fourteen
@@ -1,7 +1,7 @@
1
1
  <!DOCTYPE html>
2
2
  <html lang="en">
3
3
  <head>
4
- <title><%= [ content_for(:page_title), "Earthly HR" ].compact.join(" · ") %></title>
4
+ <title><%= [ content_for(:page_title), "#{HrLite.config.company.call[:name].presence || 'HR'} — HR" ].compact.join(" · ") %></title>
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
6
6
  <%= csrf_meta_tags %>
7
7
  <%= csp_meta_tag %>
@@ -1,3 +1,3 @@
1
1
  module HrLite
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hr_lite
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - kshitiz sinha
@@ -224,7 +224,6 @@ homepage: https://github.com/kshtzkr/hr_lite
224
224
  licenses:
225
225
  - MIT
226
226
  metadata:
227
- homepage_uri: https://github.com/kshtzkr/hr_lite
228
227
  source_code_uri: https://github.com/kshtzkr/hr_lite
229
228
  changelog_uri: https://github.com/kshtzkr/hr_lite/blob/main/CHANGELOG.md
230
229
  bug_tracker_uri: https://github.com/kshtzkr/hr_lite/issues