adding count2
This commit is contained in:
@@ -11,15 +11,15 @@ defineProps<{ word?: boolean }>();
|
||||
<svg
|
||||
class="logo"
|
||||
:class="{ 'has-word': word }"
|
||||
:viewBox="word ? '64 62 322 206' : '64 64 322 142'"
|
||||
:viewBox="word ? '64 62 270 206' : '64 64 270 142'"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
role="img"
|
||||
aria-label="Numolus"
|
||||
>
|
||||
<g stroke="var(--logo-keyline, #111)" stroke-width="6">
|
||||
<rect x="70" y="70" width="130" height="130" fill="#FFD400" />
|
||||
<rect x="160" y="70" width="130" height="130" fill="#0057FF" />
|
||||
<rect x="250" y="70" width="130" height="130" fill="#E8384F" />
|
||||
<rect x="70" y="100" width="40" height="90" style="fill:rgb(255,212,0);"/>
|
||||
<rect x="115" y="100" width="65" height="90" style="fill:rgb(0,87,255);"/>
|
||||
<rect x="185" y="100" width="130" height="90" style="fill:rgb(232,56,79);"/>
|
||||
</g>
|
||||
<text
|
||||
v-if="word"
|
||||
|
||||
@@ -52,6 +52,10 @@ export const FUNCTIONS: Record<string, FunctionFn> = {
|
||||
return nums(values).length;
|
||||
},
|
||||
|
||||
COUNT2(values) {
|
||||
return values.length;
|
||||
},
|
||||
|
||||
// IF(cond; then; else?) -- evaluator.ts special-cases this name *before*
|
||||
// ever reaching FUNCTIONS, giving it real short-circuit evaluation (only
|
||||
// the taken branch is computed, so e.g. IF(B1=0; 0; A1/B1) never runs the
|
||||
@@ -152,6 +156,7 @@ export const BUILTIN_SIGNATURES: ReadonlyArray<{ name: string; hint: string }> =
|
||||
{ name: 'MIN', hint: 'MIN(Zahl1; Zahl2; …)' },
|
||||
{ name: 'MAX', hint: 'MAX(Zahl1; Zahl2; …)' },
|
||||
{ name: 'COUNT', hint: 'COUNT(Zahl1; Zahl2; …)' },
|
||||
{ name: 'COUNT2', hint: 'COUNT(Text1; Zahl2; …)' },
|
||||
{ name: 'IF', hint: 'IF(Bedingung; Dann; Sonst?)' },
|
||||
{ name: 'DATE', hint: 'DATE(Jahr; Monat; Tag)' },
|
||||
{ name: 'TIME', hint: 'TIME(Std; Min; Sek)' },
|
||||
|
||||
Reference in New Issue
Block a user