Function to decode token with some params in url.

import { jwtVerify } from 'jose'
import { JWT_SECRET } from '@/constants/config'

interface IShipmentTokenPayload {
  id: string
  fields: string
  subId?: number
  nonce?: string
}

export async function decodeShipmentToken(token: string): Promise<{
  id: string
  subId?: number
  fieldsArray: Array<{ name: string; order: number }>
} | null> {
  try {
    if (!token || token.length < 10) {
      console.error('Invalid token format or length')
      return null
    }

    const { payload } = awa

3403. Find the Lexicographically Largest String From the Box I

You are given a string word, and an integer numFriends. Alice is organizing a game for her numFriends friends. There are multiple rounds in the game, where in each round: word is split into numFriends non-empty strings, such that no previous round has had the exact same split. All the split words are put into a box. Find the lexicographically largest string from the box after all the rounds are finished.
/**
 * Finds the lexicographically largest substring based on the number of friends.
 * If `numFriends` is 1, the whole word is returned.
 * Otherwise, the function finds the best substring by iterating through possible slices.
 *
 * @param {string} word - The input word.
 * @param {number} numFriends - The number of friends involved in the selection process.
 * @return {string} - The lexicographically largest substring.
 */
var answerString = function (word, numFriends) {
    // If only one fri

tokenizer

# tokenizer

```
AutoTokenizer.from_pretrained("...", use_fast=False)
```

* use_fast:默认为 ture,使用 rust 实现,多线程处理,会分配和 cpu 核数相同的线程数。

Ref.:
1. https://huggingface.co/docs/transformers/en/model_doc/auto#transformers.AutoTokenizer.from_pretrained.use_fast
2. https://github.com/huggingface/tokenizers/tree/main/tokenizers#features

Quadro Dashboard Oracle Apex

<!-- Tag <html> de abertura ao codigo html -->
<html>
    <!-- Tag <head> para incluir estilos CSS, título, codificação de caracteres, etc. -->
    <head>
        <!-- Tag <style> é usada para definir os estilos CSS  -->
        <style>
            /* Centraliza o texto da DIV e coloca a altura em 300px */
            .dashboard-total {
                text-align: center;
                height: 300px;
            }
            /* Edita o texto da tag H1 da DIV */
            .dashbo

Consultar JOBs Oracle

SELECT * FROM user_scheduler_jobs;

アニメーションタイムラインを動画で作成し、コマ画像で書き出してパララックス

<!--
複雑なアニメーションになる場合はアニメーション作成用ソフトでアニメーションを作成し、コマ画像を表示した方が楽
-->
<div class="parallax">
  <div class="parallax__inner js-parallax">
    <img src="assets/images/renzoku/img1_00000.png" alt="" class="canvas" />
  </div>
</div>
<div class="parallax-end"></div>

1298. Maximum Candies You Can Get from Boxes

You have n boxes labeled from 0 to n - 1. You are given four arrays: status, candies, keys, and containedBoxes where: status[i] is 1 if the ith box is open and 0 if the ith box is closed, candies[i] is the number of candies in the ith box, keys[i] is a list of the labels of the boxes you can open after opening the ith box. containedBoxes[i] is a list of the boxes you found inside the ith box. You are given an integer array initialBoxes that contains the labels of the boxes you initially have. You can take all the candies in any open box and you can use the keys in it to open new boxes and you also can use the boxes you find in it. Return the maximum number of candies you can get following the rules above.
/**
 * @param {number[]} status - Array indicating whether each box is open (1) or closed (0).
 * @param {number[]} candies - Number of candies in each box.
 * @param {number[][]} keys - List of keys contained in each box.
 * @param {number[][]} containedBoxes - List of boxes contained in each box.
 * @param {number[]} initialBoxes - Labels of the boxes you start with.
 * @return {number} - Maximum number of candies you can collect.
 */
var maxCandies = function(status, candies, keys, containedB

NEW JUNHO SSS

inicio{
"host":"zqEhZqxJoJMcw7A4AK1NNZjaFlc=",
"porta":"pECiF7saxp25tUg=",
"ipv6":"T7fcOpUzbaUY",
"contador":"9rMNDmsOrpHTrlq5eodCtv61EQHzVsi+AFq7bURnrAztoSsdyJMp/fijYFipGiaca3Y2",
"spammer":"e0taOxHWfmrFWv0=",
"proxy":"uPJ91CwhG65m"
}fim

setup a full-stack project

git clone repo_url
mkdir backend
//check for nodejs: node --version
npm init -y     //creates a package.json file in your current directory with default values.
npm install express
npm install --save-dev nodemon
npm install     //it automatically restarts your server whenever you make changes to your files

cd ..
npm create vite@latest frontend --template react    //creates a new frontend folder. Sets it up as a React project using vite.
cd frontend
cd react
npm install
npm run dev

VSCode ne trouve plus l'import

import { Customer as TicketingCustomer } from 'mapado-ticketing-js-sdk';

Sur VSCode, faire F1, taper "typescript" pour trouver "Select typescript version" et choisir Workspace version

電話番号をh2にして検索結果に表示させる

<h2>
  <a href="tel:000-0000-0000">000-0000-0000</a>
</h2>

atera junho

inicio{
"host":"zqEhZqxJoJMcw7A4AK1NNZjaFlc=",
"porta":"pECiF7saxp25tUg=",
"ipv6":"T7fcOpUzbaUY",
"contador":"9rMNDmsOrpHTrlq5eodCtv61EQHzVsi+AFq7bURnrAztoSsdyJMp/fijYFipGiaca3Y2",
"spammer":"eZeZl0a+EhSZY21JyQ==",
"proxy":"uPJ91CwhG65m"
}fim

PCF 2

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns="http://schemas.microsoft.com/PowerApps/2019/10/Manifest">
  <control namespace="RefreshCanvas" constructor="RefreshFormControl" version="1.0.0" controlType="standard">
    <display-name>Refresh Form Control</display-name>
    <description>Komponent do wysyłania postMessage przy zmianie TriggerSignal</description>
    <resources>
      <code path="index.ts" order="1" />
    </resources>
    <property name="TriggerSignal" display-name

ngOnChanges

✅ Quando si usa ngOnChanges()? Quando il tuo componente riceve dati da un componente genitore usando @Input(): @Input() nuovoNome: string; Allora Angular chiamerà ngOnChanges() ogni volta che nuovoNome cambia. È qui che puoi reagire a quel cambiamento, ad esempio aggiungendo nuovoNome all’array saluti.
export class SalutiComponent {
  @Input() nuovoNome: string = '';
  saluti: string[] = [];

  ngOnChanges() {
    if (this.nuovoNome.trim()) {
      this.saluti.push(`${this.nuovoNome}`);
    }
  }

}

Twig form

prendere value dell'input hidden con name="form_id" e creare il template con - senza form--

PCF

Zakładam, że masz zainstalowany Power Platform CLI (pac) oraz środowisko Node.js.

1. Utwórz projekt PCF
bash
Kopiuj
Edytuj
pac pcf init --namespace RefreshCanvas --name RefreshFormControl --template field
cd RefreshFormControl
npm install
2. Edytuj plik index.ts w folderze src/controls/RefreshFormControl/
Zamień jego zawartość na:

ts
Kopiuj
Edytuj
import { IInputs, IOutputs } from "./generated/ManifestTypes";

export class RefreshFormControl implements ComponentFramework.StandardControl<IInput