From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id 25DAF1FF17C for ; Wed, 3 Sep 2025 11:51:52 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 2124180E1; Wed, 3 Sep 2025 11:52:07 +0200 (CEST) Message-ID: <48e54eac-d6e8-4b42-b26b-a26f450ddd5b@proxmox.com> Date: Wed, 3 Sep 2025 11:52:05 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: Lukas Wagner , Proxmox Datacenter Manager development discussion References: <20250902151427.425017-1-l.wagner@proxmox.com> <20250902151427.425017-10-l.wagner@proxmox.com> <8b20cc07-8c04-47e6-bc95-3547a40e07a7@proxmox.com> Content-Language: en-US From: Stefan Hanreich In-Reply-To: X-SPAM-LEVEL: Spam detection results: 0 AWL 0.709 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_MSPIKE_H2 0.001 Average reputation (+2) SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: Re: [pdm-devel] [PATCH proxmox-datacenter-manager 3/4] ui: pve: move node overview to a new overview tab X-BeenThere: pdm-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox Datacenter Manager development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox Datacenter Manager development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pdm-devel-bounces@lists.proxmox.com Sender: "pdm-devel" On 9/3/25 11:47 AM, Lukas Wagner wrote: > On Wed Sep 3, 2025 at 11:10 AM CEST, Stefan Hanreich wrote: >> one small nit inline (pre-existing) I noticed while looking over the changes >> >>> +impl yew::Component for NodeOverviewPanelComp { >>> + type Message = Msg; >>> + type Properties = NodeOverviewPanel; >>> + >>> + fn create(ctx: &yew::Context) -> Self { >>> + ctx.link().send_message(Msg::ReloadRrd); >>> + ctx.link().send_message(Msg::ReloadStatus); >>> + Self { >>> + time_data: Rc::new(Vec::new()),> + cpu_data: Rc::new(Series::new("", Vec::new())), >>> + load_data: Rc::new(Series::new("", Vec::new())), >>> + mem_data: Rc::new(Series::new("", Vec::new())), >>> + mem_total_data: Rc::new(Series::new("", Vec::new())), >> >> pre-existing but this could profit from a Default implementation >> > > Mhhm, does that make sense though? Default::default is off course > public, and it does not really make much sense to offer a second way to > instantiate the component that is not `create`... but maybe I'm missing > something here. I meant Series itself, sorry if that wasn't clear. Then we could use Default::default here for a lot of the fields. _______________________________________________ pdm-devel mailing list pdm-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pdm-devel