bindu 1.2.0 → 1.3.0

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.
package/ChangeLog CHANGED
@@ -1,3 +1,8 @@
1
+ 2025.12.08, v1.3.0
2
+
3
+ feature:
4
+ - e8cfd00 bindu: sindhi: apply-vriddhi: add
5
+
1
6
  2025.12.08, v1.2.0
2
7
 
3
8
  fix:
package/README.md CHANGED
@@ -42,6 +42,7 @@ places[0].message;
42
42
  - ✅[`sandhi/apply-dirgha`](https://putout.cloudcmd.io/#/gist/0ad8154614be489ae50931109618100a/5ce86f7344b37fd40afeb229e6cb1f668d4f92fd): [अकः सवर्णे दीर्घः](https://www.learnsanskrit.org/vyakarana/sounds/ac-sandhi/?utm_source=chatgpt.com#:~:text=a%20new%20rule%3A-,%E0%A4%85%E0%A4%95%E0%A4%83%20%E0%A4%B8%E0%A4%B5%E0%A4%B0%E0%A5%8D%E0%A4%A3%E0%A5%87%20%E0%A4%A6%E0%A5%80%E0%A4%B0%E0%A5%8D%E0%A4%98%E0%A4%83%E0%A5%A4%20%E0%A5%AC.%E0%A5%A7.%E0%A5%A7%E0%A5%A6%E0%A5%A7,-aka%E1%B8%A5%20savar%E1%B9%87e%20d%C4%ABrgha%E1%B8%A5);
43
43
  - ✅[`sandhi/apply-yan`](https://putout.cloudcmd.io/#/gist/3091528d3d3eb095032fbec200599df0/c4dcefa2d29fd85f9d3d768b6eaf6934fd5a3fbb): [इको यणचि](https://www.learnsanskrit.org/vyakarana/sounds/vidhi-rules);
44
44
  - ✅[`sandhi/apply-guna`](https://putout.cloudcmd.io/#/gist/c057229cbbedf356c1d317022141f8ca/dea60bda78c84f12aef77a9e08bc17274d66c65e): [आद्गुणः](https://www.learnsanskrit.org/panini/vowel/?utm_source=chatgpt.com#:~:text=in%20ayav%C4%81y%C4%81v.-,6.1.87,-%E0%A4%86%E0%A4%A6%E0%A5%8D%E0%A4%97%E0%A5%81%E0%A4%A3%E0%A4%83);
45
+ - ✅[`sandhi/apply-vriddhi`](https://putout.cloudcmd.io/#/gist/7cdc2383c74d7afeb8cfd93df7b5f868/79b1c979be725fc082cf81991b16fac527cfcd7b): [वृद्धिरेचि](https://www.learnsanskrit.org/panini/vowel/?utm_source=chatgpt.com#:~:text=and%20%C4%81.-,6.1.88,-%E0%A4%B5%E0%A5%83%E0%A4%A6%E0%A5%8D%E0%A4%A7%E0%A4%BF%E0%A4%B0%E0%A5%87%E0%A4%9A%E0%A4%BF);
45
46
 
46
47
  ## License
47
48
 
@@ -0,0 +1,47 @@
1
+ import {operator} from 'putout';
2
+
3
+ const {remove} = operator;
4
+ const SANDHI = {
5
+ e: 'ai',
6
+ o: 'au',
7
+ };
8
+
9
+ export const report = () => `vṛddhireci`;
10
+
11
+ export const fix = ({path, next, name, nextName, vriddhi}) => {
12
+ path.node.name = `${name.slice(0, -1)}${vriddhi}${nextName.slice(1)}`;
13
+ remove(next);
14
+ };
15
+
16
+ export const traverse = ({push}) => ({
17
+ Identifier(path) {
18
+ const next = path.getNextSibling();
19
+
20
+ if (!next.node)
21
+ return;
22
+
23
+ const {name} = path.node;
24
+ const nextName = next.node.name;
25
+
26
+ const last = name
27
+ .at(-1)
28
+ .toLowerCase();
29
+
30
+ const first = nextName
31
+ .at(0)
32
+ .toLowerCase();
33
+
34
+ if (last !== 'a' || !/[eo]/.test(first))
35
+ return;
36
+
37
+ const vriddhi = SANDHI[first];
38
+
39
+ push({
40
+ path,
41
+ next,
42
+ vriddhi,
43
+ name,
44
+ nextName,
45
+ });
46
+ },
47
+ });
@@ -1,3 +1,4 @@
1
+ import * as applyVriddhi from './apply-vriddhi/index.js';
1
2
  import * as applyGuna from './apply-guna/index.js';
2
3
  import * as applyYan from './apply-yan/index.js';
3
4
  import * as applyDirgha from './apply-dirgha/index.js';
@@ -6,4 +7,5 @@ export const rules = {
6
7
  'apply-dirgha': applyDirgha,
7
8
  'apply-yan': applyYan,
8
9
  'apply-guna': applyGuna,
10
+ 'apply-vriddhi': applyVriddhi,
9
11
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bindu",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "Pāṇini Aṣṭādhyāyī",
5
5
  "main": "lib/bindu.js",
6
6
  "bin": {