mirror of
				https://codeberg.org/yeentown/barkey.git
				synced 2025-10-31 05:24:13 +00:00 
			
		
		
		
	Refactor
This commit is contained in:
		
							parent
							
								
									2615368b1e
								
							
						
					
					
						commit
						6d08909b2f
					
				
					 3 changed files with 4 additions and 4 deletions
				
			
		|  | @ -2060,8 +2060,8 @@ pages: | ||||||
|       _divide: |       _divide: | ||||||
|         arg1: "A" |         arg1: "A" | ||||||
|         arg2: "B" |         arg2: "B" | ||||||
|       remind: "÷ 割った余り" |       mod: "÷ 割った余り" | ||||||
|       _remind: |       _mod: | ||||||
|         arg1: "A" |         arg1: "A" | ||||||
|         arg2: "B" |         arg2: "B" | ||||||
|       eq: "AとBが同じ" |       eq: "AとBが同じ" | ||||||
|  |  | ||||||
|  | @ -161,7 +161,7 @@ export class ASEvaluator { | ||||||
| 			subtract: (a: number, b: number) => a - b, | 			subtract: (a: number, b: number) => a - b, | ||||||
| 			multiply: (a: number, b: number) => a * b, | 			multiply: (a: number, b: number) => a * b, | ||||||
| 			divide: (a: number, b: number) => a / b, | 			divide: (a: number, b: number) => a / b, | ||||||
| 			remind: (a: number, b: number) => a % b, | 			mod: (a: number, b: number) => a % b, | ||||||
| 			strLen: (a: string) => a.length, | 			strLen: (a: string) => a.length, | ||||||
| 			strPick: (a: string, b: number) => a[b - 1], | 			strPick: (a: string, b: number) => a[b - 1], | ||||||
| 			strReplace: (a: string, b: string, c: string) => a.split(b).join(c), | 			strReplace: (a: string, b: string, c: string) => a.split(b).join(c), | ||||||
|  |  | ||||||
|  | @ -58,7 +58,7 @@ export const funcDefs: Record<string, { in: any[]; out: any; category: string; i | ||||||
| 	subtract:        { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faMinus, }, | 	subtract:        { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faMinus, }, | ||||||
| 	multiply:        { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faTimes, }, | 	multiply:        { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faTimes, }, | ||||||
| 	divide:          { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faDivide, }, | 	divide:          { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faDivide, }, | ||||||
| 	remind:          { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faDivide, }, | 	mod:             { in: ['number', 'number'],           out: 'number',      category: 'operation',  icon: faDivide, }, | ||||||
| 	eq:              { in: [0, 0],                         out: 'boolean',     category: 'comparison', icon: faEquals, }, | 	eq:              { in: [0, 0],                         out: 'boolean',     category: 'comparison', icon: faEquals, }, | ||||||
| 	notEq:           { in: [0, 0],                         out: 'boolean',     category: 'comparison', icon: faNotEqual, }, | 	notEq:           { in: [0, 0],                         out: 'boolean',     category: 'comparison', icon: faNotEqual, }, | ||||||
| 	gt:              { in: ['number', 'number'],           out: 'boolean',     category: 'comparison', icon: faGreaterThan, }, | 	gt:              { in: ['number', 'number'],           out: 'boolean',     category: 'comparison', icon: faGreaterThan, }, | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue